Get started

Storage API

Storage API

Manage file storage for your organization. Upload, retrieve, and delete files via presigned URLs.

GET/organizations/:orgId/storages

List all storages in an organization.

Response
{
  "storages": [
    {
      "id": "stor_abc123",
      "name": "My Storage",
      "status": "active",
      "createdAt": "2026-03-20T...",
      "updatedAt": "2026-03-20T..."
    }
  ]
}
POST/organizations/:orgId/storages/:storageId/files

Create file entries and get presigned upload URLs. Upload your files to the returned URLs within 1 hour.

Request body
{
  "files": [
    { "name": "photo.png", "mime": "image/png" },
    { "name": "data.json", "mime": "application/json" }
  ]
}
Response
{
  "files": [
    {
      "id": "f1234567-abcd-...",
      "name": "photo.png",
      "path": "photo.png",
      "mime": "image/png",
      "size": 0,
      "status": "pending",
      "error": null,
      "createdAt": "2026-03-20T...",
      "updatedAt": "2026-03-20T...",
      "url": "https://upload.justdeploy.net/..." // Presigned upload URL
    }
  ]
}

Upload your zip file to the presigned URL:

Upload
curl -X PUT "$UPLOAD_URL" \
  -H "Content-Type: image/png" \
  --data-binary @photo.png
GET/organizations/:orgId/storages/:storageId/files/:fileId

Get file metadata and a signed download URL. The URL expires in 1 hour.

Response
{
  "file": {
    "id": "f1234567-abcd-...",
    "name": "photo.png",
    "path": "photo.png",
    "mime": "image/png",
    "size": 102400,
    "status": "active",
    "error": null,
    "createdAt": "2026-03-20T...",
    "updatedAt": "2026-03-20T...",
    "url": "https://cdn.justdeploy.net/..." // Signed download URL
  }
}
DELETE/organizations/:orgId/storages/:storageId/files/:fileId

Delete a file from storage.