Introduction to Core APIs
The Core APIs serve as the infrastructure engine of Webround. Unlike modules focused on retail operations, the Core APIs are designed to manage the lifecycle of your projects (Drafts) and the physical orchestration of the static resources that build your store.
These APIs are the primary tool for creating new shops and, most importantly, for managing media assets (images and videos) uploaded directly to our infrastructure.
Asset Management: Core vs. Commerce APIs
In Webround, asset management can occur through two different channels. It is crucial to understand which one to use based on the source of your file.
1. Core APIs: Native Storage Management
Use the Core APIs when you need to upload a physical file (image or video) directly to Webround.
- Upload: The file is transferred to your private Cloud Storage bucket associated with the Draft/Store.
- Storage Sync: Every byte uploaded is counted toward your billing plan. The Core APIs ensure that your storage usage metrics are always synchronized.
- Physical Deletion: When you delete an asset via the Core APIs, the system does not just remove the database reference; it physically deletes the file from our storage servers. This ensures that the occupied space is immediately released from your subscription quota.
2. Commerce APIs: External Reference Management
Use the Commerce APIs if you prefer to host your files on an external CDN (e.g., your own S3 bucket or proprietary server) and only want to provide Webround with the resource URL.
- No Upload: Webround only stores the link (URL).
- Logical Deletion: If you delete a resource via the Commerce APIs, you only remove the reference in the Webround database. The original file on your external CDN remains untouched.
If you use the Commerce APIs to delete a file that was originally uploaded via the Core APIs (and thus resides on our servers), the database reference will be removed, but the physical file may remain orphaned in storage. This means it will continue to occupy space in your plan even though it is no longer visible in your dashboard.
Golden Rule: If the file is hosted by Webround, always use the Core APIs for its deletion.
Performance and Caching
Webround utilizes a global distribution network (CDN) to ensure your images and videos are lightning-fast for your customers worldwide.
Due to static file caching mechanisms, when you delete an asset (via Core APIs), the resource is removed instantly from our origin servers. However, a copy of the file may remain accessible via public URL for a short period in edge caches. Do not expect files to vanish globally at the exact millisecond the deletion request is made.
Authentication and Security
Core APIs are high-privilege operations that act directly on the structure of your business.
- Authentication: Requires a valid Merchant JWT (Bearer Token).