API

Storage

Browse and manage S3 buckets: files, uploads, CORS, versioning and lifecycle rules.

These routes back the file browser in Cloud. Uploads and downloads go straight to S3 through short-lived links; the API never handles file bodies. See Buckets.

Every route below, with its parameters, request and response, errors and samples, is in the API reference.

RouteWhat it does
GET /v1/orgs/:orgId/storageThe org's buckets with their latest daily size and object count.
GET /v1/orgs/:orgId/storage/:resourceIdA bucket record with its versioning status and latest daily usage.
GET /v1/orgs/:orgId/storage/:resourceId/objectsOne level of the bucket: folders (common prefixes) and files under prefix.
GET /v1/orgs/:orgId/storage/:resourceId/objectOne file's size, type, modification time and metadata.
GET /v1/orgs/:orgId/storage/:resourceId/downloadA download link valid for five minutes. versionId downloads an earlier version.
GET /v1/orgs/:orgId/storage/:resourceId/object/versionsEvery version and delete marker of one file, newest first (versioned buckets).
POST /v1/orgs/:orgId/storage/:resourceId/object/restoreMakes an earlier version of a file current again (copied on top, so history is kept). With the newest delete marker of a deleted file, removes the marker and so brings the file back.
POST /v1/orgs/:orgId/storage/:resourceId/object/versions/deleteDeletes one version of a file for good; its other versions stay.
GET /v1/orgs/:orgId/storage/:resourceId/deletedDeleted files in one folder of a versioned bucket (their newest version is a delete marker).
POST /v1/orgs/:orgId/storage/:resourceId/objects/moveMoves or renames files and folders (copy, then delete the original); never overwrites. Folders move in batches: done: false means call again with the same moves and resume: true.
POST /v1/orgs/:orgId/storage/:resourceId/uploads/multipartStarts a multipart upload for a large file (up to 5 TB): the part size and how many parts to send.
POST /v1/orgs/:orgId/storage/:resourceId/uploads/multipart/partsUpload links (15 minutes) for parts of a multipart upload; the browser PUTs each part and keeps its ETag.
POST /v1/orgs/:orgId/storage/:resourceId/uploads/multipart/completeFinishes a multipart upload from its parts' numbers and ETags.
POST /v1/orgs/:orgId/storage/:resourceId/uploads/multipart/abortCancels a multipart upload and discards the parts sent so far.
POST /v1/orgs/:orgId/storage/:resourceId/uploadsUpload links (PUT, 15 minutes, up to 5 GB each). The browser sends each file straight to S3.
POST /v1/orgs/:orgId/storage/:resourceId/foldersCreates an empty folder under prefix.
POST /v1/orgs/:orgId/storage/:resourceId/objects/deleteDeletes files and folders (with everything in them). done: false means call again to finish large folders.
GET /v1/orgs/:orgId/storage/:resourceId/settingsCORS rules, versioning and lifecycle rules.
PUT /v1/orgs/:orgId/storage/:resourceId/corsReplaces the bucket's CORS rules (Cloud's upload rule is kept separately).
PUT /v1/orgs/:orgId/storage/:resourceId/versioningTurns versioning on, or suspends it.
POST /v1/orgs/:orgId/storage/:resourceId/lifecycleAdds a rule that deletes files under a prefix a number of days after they're written.
DELETE /v1/orgs/:orgId/storage/:resourceId/lifecycle/:ruleIdRemoves a lifecycle rule.
DELETE /v1/orgs/:orgId/storage/:resourceIdDeletes an empty bucket (old versions of deleted files go with it) and its record.