Widgets and collections
Manage origin-restricted browser upload widgets and ordered collections that publish branded file portals.
Upload widget management
POST/api/widgets
201 CreatedCreate a create-or-replace widget with explicit origins, file rules, destination, and approval policy.
Required scopeassets:write
{
"name": "Campaign intake",
"mode": "create",
"destinationBucketId": "bucket_uuid",
"acceptedTypes": ["image/*", ".pdf"],
"maxBytes": 26214400,
"buttonText": "Choose a file",
"theme": "light",
"allowedOrigins": ["https://example.com"],
"approvalMode": "review",
"allowAutoPublish": false,
"active": true
}
Origins contain only scheme and host. The API accepts multiple array values and also normalizes comma- or whitespace-separated origins.
List widget configurations and public keys for the workspace.
Required scopeassets:read
PATCH/api/widgets/{widget_id}
200 OKReplace a widget configuration using the same fields as create.
Required scopeassets:write
GET/api/widgets/submissions
200 OKList reviewable, approved, rejected, failed, and expired widget uploads.
Required scopeassets:read
POST/api/widgets/submissions/{submission_id}/approve
200 OKCommit a reviewed upload as a file or replacement and optionally add it to a collection.
Required scopeassets:write
POST/api/widgets/submissions/{submission_id}/reject
200 OKReject a reviewable upload and remove its temporary bytes.
Required scopeassets:write
Public widget capability
POST/api/public/widgets/{public_key}/initialize
200 OKValidate the browser Origin, filename, MIME, and size, then return a ten-minute presigned upload URL.
POST/api/public/widgets/{public_key}/complete
200 OKConsume the one-time session token and either publish or queue the upload for review.
Both public calls require a browser Origin matching the widget. The completion request also sends the short-lived session token as Authorization: Bearer. CORS is returned only for the validated origin.
Collections and portals
POST/api/collections
201 CreatedCreate a private, public, password-protected, or expiring collection.
Required scopeassets:write
GET/api/collections/{collection_id}
200 OKRead collection settings and ordered items.
Required scopeassets:read
PATCH/api/collections/{collection_id}
200 OKUpdate access, expiration, indexing, and eligible paid branding fields.
Required scopeassets:write
POST/api/collections/{collection_id}/items
200 OKAdd an asset that follows current or is pinned to one retained revision.
Required scopeassets:write
{ "assetId": "asset_uuid", "version": 12 }
PUT/api/collections/{collection_id}/items/order
200 OKReplace the complete item order using every current item ID exactly once.
Required scopeassets:write
PATCH/api/collections/{collection_id}/items/{item_id}
200 OKPin an item to a revision or set version to null to follow current.
Required scopeassets:write
GET/api/collections/{collection_id}/analytics
200 OKRead aggregate and daily portal views and downloads.
Required scopeanalytics:read
GET/api/public/collections/{slug}
200 OKRead recipient-safe portal metadata and preview URLs after satisfying its access mode.
GET/api/public/collections/{slug}/items/{item_id}/preview
200 OKStream an inline preview without incrementing download analytics.
GET/api/public/collections/{slug}/items/{item_id}/download
200 OKDownload the resolved clean revision and increment portal download analytics.