POST /api/v1/assets/upload
Accepts standard multipart form payloads. Returns asset metadata, unique UUID, SHA-256 checksum, and precomputed delivery URLs.
Everything you need to stream, optimize, and deliver digital media directly from your mobile apps, microservices, or frontend web frameworks.
AssetDock divides media management into two decoupled micro-operations: Storage Ingestion (deduplicating, checking quota, streaming binary) and Edge Transformation (stateless variant creation and immutable delivery).
Accepts standard multipart form payloads. Returns asset metadata, unique UUID, SHA-256 checksum, and precomputed delivery URLs.
Instant WebP/PNG streaming. Responses include Cache-Control: public, max-age=31536000, immutable and ETag validation.
Authenticate all REST API requests by supplying your tenant API Key in the X-API-Key request header.
ad_live_00000000000000000000
X-API-Key: ad_live_00000000000000000000
Accept: application/json
Streams a binary asset into the tenant storage vault, verifies SHA-256 deduplication, and kicks off responsive variant generation.
| Field | Type | Required | Description |
|---|---|---|---|
file |
File (Binary) | Yes | Supported formats: JPEG, PNG, WEBP, GIF, SVG, PDF, MP4. Max 50 MB per request. |
visibility |
String | No | public (default, cached on CDN) or private (requires signed download ticket). |
tags |
String | No | Comma-separated indexing tags (e.g. profile,avatar,user_99). |
folder |
String | No | Cloudinary-style folder routing (e.g. client_profiles, user_avatars). Automatically assigns or creates the project folder. |
project_slug |
String | No | Assign asset to an existing workspace project (defaults to website-assets). |
{
"success": true,
"message": "Asset uploaded and processed successfully.",
"data": {
"id": "01a15e84-e08a-704d-bc84-5c6032ffd799",
"display_name": "hero-banner",
"original_name": "hero-banner.png",
"url": "https://assetdock.cybershoora.com/media/01a15e84-e08a-704d-bc84-5c6032ffd799/hero-banner.png",
"visibility": "public",
"size_bytes": 102400,
"formatted_size": "100 KB",
"width": 1920,
"height": 1080,
"checksum_sha256": "c414cd0e204de974f73753c7e28d7638e7b3691bb8b1a2bab6b25bb7fed7ce77",
"variants": {
"avatar_128": "https://assetdock.cybershoora.com/media/01a15e84-e08a-704d-bc84-5c6032ffd799/variant/avatar_128",
"thumb_320": "https://assetdock.cybershoora.com/media/01a15e84-e08a-704d-bc84-5c6032ffd799/variant/thumb_320",
"medium_960": "https://assetdock.cybershoora.com/media/01a15e84-e08a-704d-bc84-5c6032ffd799/variant/medium_960"
}
}
}
No need to re-upload multiple sizes. Append the variant preset slug to any asset URL to get optimized WebP/PNG streaming.
/variant/profile_photo
1:1 square crop. Perfect for client profile photos, team rosters, and member avatars.
/variant/avatar_128
Square crop with focus preservation. Ideal for user profiles, navigation avatars, and list rows.
/variant/thumb_320
Aspect-ratio preserved thumbnail. Perfect for grid views, media pickers, and feed cards.
/variant/medium_960
Retina-ready high definition. Engineered for product zooms, article hero headers, and modals.
/media/{id}/{filename}
Direct master file streaming with bit-for-bit SHA-256 integrity.
For KYC records, PAN documents, invoices, and sensitive contracts. Private assets cannot be scraped or accessed directly without a cryptographically signed, time-limited ticket.
// 1. Request Download Ticket (valid for 15 minutes)
POST /assets/{asset_id}/ticket
Header: X-API-Key: ad_live_00000000000000000000
// 2. Response provides one-time temporary delivery URL
{
"ticket": "tkt_live_99d8b12f6a7c41",
"download_url": "https://assetdock.cybershoora.com/media/download/ticket/tkt_live_99d8b12f6a7c41",
"expires_at": "2026-10-21T14:45:00Z"
}
Drop-in code snippets ready to copy and paste into your project codebase.
curl -X POST "https://assetdock.cybershoora.com/api/v1/assets/upload" \
-H "X-API-Key: ad_live_00000000000000000000" \
-F "file=@/path/to/image.png" \
-F "visibility=public" \
-F "tags=avatar,profile"
Test your cURL syntax or upload a sample image right now to preview the real JSON payload and variant generation.
Watch live bit-routing across our 5 architecture stages. Click any scenario button below or click on any node to see exact endpoints, controller actions, and database models.
Direct answers designed for software architects, engineering leads, and AI overview search models.
AssetDock is a self-hosted, private-first platform. You retain 100% data ownership of all raw and transformed assets, pay zero opaque egress bandwidth penalties, and benefit from KYC PAN enterprise tenant isolation.
All public media responses ship with Cache-Control: public, max-age=31536000, immutable and cryptographically strong ETags. Once an asset or variant is requested, global POP nodes cache it indefinitely until purged.
Yes. The REST upload API uses standard HTTP multipart requests. You can upload directly using standard HTTP clients or use our copyable Flutter and JavaScript code kits.
During upload reservation, AssetDock computes the SHA-256 digest of the incoming stream. If an identical file already exists in your workspace, AssetDock links the record instantly without wasting disk quota or CPU cycles.