Drive API

List spaces, upload, download, move and delete files and folders, and manage sharing.

Drive stores files for your team. This API lists spaces, uploads, downloads, moves and deletes files, and manages sharing. In the product the containers are called spaces; the API calls them buckets.

Files are addressed by a key, a path-like name such as contracts/2026/acme.pdf. Folders are the parts of the path: a folder exists when a key starts with it. A key ending in / is a folder.

Endpoints

Method Path What it does
GET /orgs/{orgId}/drive/overview Recent files and storage by file type
GET /orgs/{orgId}/drive/buckets List spaces (and files shared with you)
POST /orgs/{orgId}/drive/buckets Create a space
DELETE /orgs/{orgId}/drive/buckets/{bucketId} Delete a space
GET /orgs/{orgId}/drive/buckets/{bucketId}/objects List a folder
POST /orgs/{orgId}/drive/buckets/{bucketId}/objects Upload a file
DELETE /orgs/{orgId}/drive/buckets/{bucketId}/objects?key= Delete a file or folder
GET /orgs/{orgId}/drive/buckets/{bucketId}/download?key= Download a file
POST /orgs/{orgId}/drive/buckets/{bucketId}/folders Create a folder
POST /orgs/{orgId}/drive/buckets/{bucketId}/move Rename or move
GET · POST /orgs/{orgId}/drive/buckets/{bucketId}/shares List or add shares
DELETE /orgs/{orgId}/drive/buckets/{bucketId}/shares/{shareId} Remove a share
GET /orgs/{orgId}/drive/buckets/{bucketId}/versions?key= A file's earlier versions
GET /orgs/{orgId}/drive/buckets/{bucketId}/versions/{versionId}/download?key= Download a version
POST /orgs/{orgId}/drive/buckets/{bucketId}/versions/{versionId}/restore Restore a version
DELETE /orgs/{orgId}/drive/buckets/{bucketId}/versions/{versionId}?key= Delete a version
GET · POST /orgs/{orgId}/drive/buckets/{bucketId}/links List or create public links
DELETE /orgs/{orgId}/drive/buckets/{bucketId}/links/{linkId} Turn a public link off

Permissions

Access is decided per space, not per route.

  • Team spaces (the shared workspace space and any custom spaces): drive:read to list and download, drive:write to upload, move and delete, drive:link to make public links, drive:manage to create or delete a space and manage its shares. The resource is the space's key, so a role can be limited to one space. See Permissions reference.
  • Personal drives belong to one person. Only the owner, or people the owner has shared a folder with, can reach them. Permissions on roles do not apply to them.

A space you have no standing in answers 404 NOT_FOUND; one you can see but not change answers 403 FORBIDDEN.

Spaces

{
  "id": "0190f700-…",
  "key": "contracts",
  "name": "Contracts",
  "type": "custom",
  "object_count": 128,
  "total_bytes": 48211904,
  "created_at": "2026-10-01T08:00:00Z"
}

type is user (a personal drive), org (the shared workspace space) or custom.

POST /drive/buckets takes key (lowercase letters, digits and hyphens, 2 to 63 characters, starting with a letter or digit; org and keys starting user- are reserved), name (up to 120 characters), and type. Use "type": "personal" for an extra personal drive owned by the caller: it needs a name, ignores key, and can only be created by a person, not an access key. Anything else creates a team space and needs drive:manage on that key. Response 201. Errors: 409 KEY_TAKEN, 400 VALIDATION_ERROR, 402 LIMIT_EXCEEDED.

DELETE /drive/buckets/{bucketId} answers 204. A space must be empty first (400 VALIDATION_ERROR, "bucket is not empty"). The shared workspace space and each person's main personal drive cannot be deleted.

The list response is { "buckets": [ … ], "shared": [ … ] }, where shared holds folders and files other people shared with you.

GET …/objects

List the contents of a folder, one level deep.

Parameter Notes
prefix The folder, such as contracts/2026/. Empty for the top
q Search by name within the folder and below
limit Default 100, maximum 200
cursor The cursor from the previous page
{
  "data": {
    "folders": [ { "prefix": "contracts/2026/", "name": "2026" } ],
    "objects": [
      {
        "key": "contracts/acme.pdf",
        "name": "acme.pdf",
        "size": 184320,
        "content_type": "application/pdf",
        "sha256": "9f2c…",
        "created_by": "0190f0a0-…",
        "created_at": "2026-10-01T08:00:00Z",
        "updated_at": "2026-10-04T09:00:00Z"
      }
    ],
    "cursor": "…"
  }
}

cursor is absent on the last page.

POST …/objects (upload)

A multipart form with a file part and an optional key field. If key is left out, the file's own name is used. Uploading to an existing key replaces the file; the replaced content is kept as a version (see below).

curl -s -X POST https://axisiq.co/api/v1/orgs/$ORG/drive/buckets/$BUCKET/objects \
  -H "Authorization: Bearer $AXIS_KEY" \
  -F "key=contracts/acme.pdf" -F "file=@acme.pdf"

Response 201 when the key is new, 200 when it replaced a file, both with the file object. A file over the upload limit is refused with 400 VALIDATION_ERROR and a message that states the limit. Free workspaces can also hit the storage cap (402 LIMIT_EXCEEDED).

Keys may be up to 1,024 bytes, cannot start with /, contain //, backslashes or control characters, and file keys must not end with /.

GET …/download?key=

Streams the file. The response includes ETag (the file's SHA-256), Last-Modified, and supports If-None-Match (answers 304) and Range for partial downloads. Images, PDFs, plain text, common video and audio are served for inline viewing; everything else, including HTML and SVG, is served as an attachment.

Folders, moving and deleting

  • POST …/folders with { "key": "contracts/2027/" } creates an empty folder. Response 201 { "prefix": …, "name": … }.
  • POST …/move with { "from": "contracts/old.pdf", "to": "contracts/2026/old.pdf" } renames a file. Give folder keys ending in / to move a whole folder. Response { "moved": 1 }. Moving onto an existing key is 409 KEY_TAKEN; moving between a file and a folder, or to the same place, is 400 VALIDATION_ERROR.
  • DELETE …/objects?key= deletes a file; with a key ending in / it deletes the whole folder. Response { "deleted": 3 }. A folder move or delete that touches more than 2,000 files is refused with 400 VALIDATION_ERROR; do it in smaller folders.

Important: Deletes cannot be undone.

Sharing

GET …/shares returns a plain array of shares. POST …/shares shares a folder, a file or the whole space in a personal drive or a team space. Only the drive's owner, or drive:manage on a team space, can do this. The shared workspace space has no shares; its roles decide access.

Field Type Notes
prefix string The folder (ending /) or file key to share. Empty for everything
email string A member's email address. One of email, user_id or org_wide is required
user_id string Alternatively a member's id
org_wide boolean Share with the whole workspace
mode string Required: view or edit

Response 201 with { id, prefix, grantee_id, grantee_name, org_wide, mode, created_at }. DELETE …/shares/{shareId} answers 204.

Versions

Uploading over an existing file keeps what it replaced. A file keeps its newest 25 versions; uploading identical bytes adds none. Versions follow the file through renames, moves and the trash, are deleted with it, and count toward storage.

GET …/versions?key= returns { "versions": [ { "id", "size", "content_type", "sha256", "uploaded_at", "replaced_by", "replaced_by_name", "replaced_at" } ], "keep": 25 }, newest first. Needs view access.

  • GET …/versions/{versionId}/download?key= streams that version, with the same headers as a download.
  • POST …/versions/{versionId}/restore with { "key": "contracts/acme.pdf" } makes it current and keeps the current content as a version. Response 200 with the file object. Needs edit access.
  • DELETE …/versions/{versionId}?key= deletes it for good. Response 204. Needs edit access.

A version that does not belong to the file at key answers 404 NOT_FOUND.

A public link lets anyone with the address view and download a file, a folder or a whole space, without an account. See Public endpoints for what the visitor calls.

POST …/links:

Field Type Notes
key string A file key, a folder ending /, or empty for the whole space
days number 1 to 366, default 7
password string Optional, 4 to 72 characters
label string Optional note, up to 120 characters

Response 201:

{
  "id": "01a13faf-…",
  "key": "accounts/",
  "folder": true,
  "label": "For our CA",
  "token": "34562ed1…",
  "expires_at": "2026-10-22T10:00:00Z",
  "has_password": true,
  "downloads": 0,
  "created_by": "0190f0a0-…",
  "created_at": "2026-10-15T10:00:00Z"
}

The visitor's address is https://axisiq.co/s/{orgId}/{id}/{token}.

  • Who can make one: in a personal drive, its owner; in a team space, view access plus drive:link on the space's key. Spaces that belong to other apps cannot be linked (403 FORBIDDEN). Up to 200 links per space.
  • A link reads as its creator. Every visit checks the creator's current access; if they leave the workspace or lose access (or drive:link), the link stops working.
  • A file link follows the file by id: renames and moves keep it working, the trash or a delete ends it.
  • GET …/links?key= lists the links on that file or folder (all links in the space when key is empty) that you could make, plus your own. Expired links are listed until removed.
  • DELETE …/links/{linkId} answers 204. The creator, or anyone who could make the link, can turn it off.

GET /orgs/{orgId}/drive/overview

Optional limit. Returns recent and types ([{ "content_type", "count", "bytes" }]) across your own spaces, plus:

  • largest — the 10 biggest files in your own spaces (shares excluded), shaped like recent.
  • storage — the whole workspace's storage: used, files, versions (past versions of replaced files), sites (hosted websites), all in bytes; limit (the plan allowance in bytes, -1 for no limit) and hard (true on the free plan or a trial, where uploads past the limit answer 402 LIMIT_EXCEEDED; otherwise extra storage is billed).