Asset Store โ
The Asset Store is S-Launch's content repository โ a folder/asset tree plus an external sharing layer. Every binary the platform manages (uploaded artwork, generated PDFs, attachments) lives here. The store is organized around three resources:
| Resource | What it is | Lives at |
|---|---|---|
| Assets | Individual files โ image, PDF, archive, etc. | /api/store/asset/* |
| Folders | Hierarchical containers for assets. | /api/store/folder/* |
| Shares | External, token-based links that grant time-limited access to an asset or folder. | /api/share/* |
There is also a single "resolve a store object by URL" endpoint that sits above this resource grouping:
Endpoints (Asset Store) โ
Get Store Object by URL โ
GET /api/store/
Resolves a store URL to its underlying object (asset or folder) and returns the record. Useful when you have a permalink or path and need to identify what it points at.
Required scope: store:read ยท also accepts API key
Query parameters
| Name | Type | Default | Description |
|---|---|---|---|
url | string | โ | The store URL to resolve. Required. |
as_json | boolean | โ | When true, the response is JSON. When false, the raw object is streamed. |
hydrate | boolean | true | When false, related objects are returned as IDs only. See Conventions โบ Hydration. |
Response 200 โ the resolved store object (an AssetRead, FolderRead, or similar, depending on what the URL points at).
Errors: 401, 403, 404, 422 โ see Conventions โบ Errors.
Scopes โ
| Scope | Reach |
|---|---|
store:read | Reading assets, folders, and share metadata. Required for nearly every list/get operation in this section. |
store:write | Creating, updating, deleting assets, folders, and shares. |
store:share | Creating new share links and emailing them out. Separate from store:write so a role can create assets without distributing them. |
Workflow: Upload an Asset and Share It โ
A common end-to-end flow combines the Assets and Shares endpoints:
# 1. Upload an asset (multipart/form-data; `folder` query param is optional).
ASSET_ID=$(curl -X POST "https://<tenant>.s-launch.com/api/store/asset/upload?folder=$FOLDER_ID" \
-H "X-API-Key: $API_KEY" \
-F "file=@./brochure.pdf" \
| jq -r '.id')
# 2. Create a share link pointing at the asset.
SHARE=$(curl -X POST "https://<tenant>.s-launch.com/api/share/" \
-H "X-API-Key: $API_KEY" \
-H "Content-Type: application/json" \
-d "{\"object_id\":\"$ASSET_ID\",\"object_type\":\"asset\"}")
# 3. (Optional) Email the share link to recipients.
curl -X POST "https://<tenant>.s-launch.com/api/share/send_email" \
-H "X-API-Key: $API_KEY" \
-H "Content-Type: application/json" \
-d "{\"share_id\":\"$(echo $SHARE | jq -r '.id')\",\"to\":[\"client@example.com\"]}"The exact body shape for share create and email is defined in ShareWriteCreate and ShareEmailRequest. Use the Interactive Reference to see all available fields.
See also โ
- Conventions โ pagination, filtering, hydration, and error patterns used across every store endpoint.
- Scopes โบ Asset Store & Sharing โ the canonical scope list.
