List CDN assets
GET /cdn/assets. Requires cdn.read.
Retrieve a CDN asset
GET /cdn/assets/{id}. One asset by id. Requires cdn.read.
Start a CDN upload
POST /cdn/assets. Same three-step flow as files, see Uploading. CDN assets are public and permanent, they never expire and are not encrypted, because a browser has to be able to render them. Requires cdn.write.
Finish a CDN upload
POST /cdn/assets/{id}/complete. Commits a new upload or a swap. The size is read back from storage, so your quota is charged for the bytes that actually landed. Requires cdn.write.
Swap an asset in place
POST /cdn/assets/{id}/swap. Replaces the bytes behind an existing asset while keeping its id and public URL, so anything already linking to it picks up the new version. PUT the bytes, then call complete. Requires cdn.write.
Delete a CDN asset
DELETE /cdn/assets/{id}. Removes the asset and its bytes. The public URL stops working immediately. Requires cdn.delete.
Example asset object
