SDK reference

Drive

Each route's function in the SDK, its call beside the same request in cURL.
orgDriveDrives

GET/v1/orgs/:orgId/drive/drives

My Drive, the shared drives the caller belongs to (every one, to manage, for org admins) and storage use.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveDrives

POST/v1/orgs/:orgId/drive/drives

Creates a shared drive; the caller becomes its manager. Not in personal spaces; not for viewers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example"
  }'
orgDriveDrivesByDriveId

GET/v1/orgs/:orgId/drive/drives/:driveId

A drive with its members (shared drives) and whether the caller can manage them.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
patchOrgDriveDrivesByDriveId

PATCH/v1/orgs/:orgId/drive/drives/:driveId

Renames a shared drive or changes its description (managers, and org owners and admins).

Parameters and answers
curl -X PATCH 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "description": "example"
  }'
deleteOrgDriveDrivesByDriveId

DELETE/v1/orgs/:orgId/drive/drives/:driveId

Deletes an empty shared drive (its trash too must be empty).

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
putOrgDriveDrivesMembersByPrincipalId

PUT/v1/orgs/:orgId/drive/drives/:driveId/members/:principalId

Adds a person or team to a shared drive, or changes their role (viewer, commenter, editor, manager). A drive always keeps a manager who is a person.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives/{driveId}/members/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "role": "viewer"
  }'
deleteOrgDriveDrivesMembersByPrincipalId

DELETE/v1/orgs/:orgId/drive/drives/:driveId/members/:principalId

Removes a member (anyone may remove themselves).

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/drives/{driveId}/members/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveUsage

GET/v1/orgs/:orgId/drive/usage

Storage the space uses (every version, the trash included) and its limit, in bytes.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/usage' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDrivePeople

GET/v1/orgs/:orgId/drive/people

A person to share with, by exact email address: an org member here, any account for personal files.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/people?email=person%40example.com' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveLog

GET/v1/orgs/:orgId/drive/log

Personal spaces: the owner's log of every change and access (who opened, downloaded or listed what, links included).

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/log' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveItemsByItemId

GET/v1/orgs/:orgId/drive/items/:itemId

A file or folder with its path (from the highest folder you can open), your role and what it allows, its shares (for editors) and its link setting. Photo details lose location and camera for people who only view, when the owner removes them.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
patchOrgDriveItemsByItemId

PATCH/v1/orgs/:orgId/drive/items/:itemId

Renames an item (names are unique per folder, ignoring case) or sets its description. Editors.

Parameters and answers
curl -X PATCH 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "description": "example"
  }'
orgDriveItemsChildren

GET/v1/orgs/:orgId/drive/items/:itemId/children

A folder's contents, folders first, sorted by name, modified or size (order), in pages of up to 1,000 (cursor).

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/children' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveItemsFile

GET/v1/orgs/:orgId/drive/items/:itemId/file

A one-hour link to the file's bytes (inline=1 to show it in the browser; versionId for an earlier version, editors only; transcode=1 with inline=1: a video's preview transcode, pending while it's made).

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/file' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveItemsVersions

GET/v1/orgs/:orgId/drive/items/:itemId/versions

A file's versions, newest first, with who uploaded each; canManage for editors.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/versions' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveItemsVersionsRestore

POST/v1/orgs/:orgId/drive/items/:itemId/versions/:versionId/restore

Makes an earlier version current again as a new version (a copy in the bucket; counts against storage). Editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/versions/{versionId}/restore' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
deleteOrgDriveItemsVersionsByVersionId

DELETE/v1/orgs/:orgId/drive/items/:itemId/versions/:versionId

Deletes an earlier version (never the current one). Editors.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/versions/{versionId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveItemsActivity

GET/v1/orgs/:orgId/drive/items/:itemId/activity

What happened to an item (and, for folders, to what's in them), newest first, a year back.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/activity' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveItemsComments

GET/v1/orgs/:orgId/drive/items/:itemId/comments

Comments on a file or folder, oldest first; canComment for commenters and editors.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/comments' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveItemsComments

POST/v1/orgs/:orgId/drive/items/:itemId/comments

Adds a comment (up to 4,000 characters). Commenters and editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/comments' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "body": "example"
  }'
deleteOrgDriveItemsCommentsByCommentId

DELETE/v1/orgs/:orgId/drive/items/:itemId/comments/:commentId

Deletes a comment: its author, or an editor.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/comments/{commentId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
putOrgDriveItemsSharesByPrincipalId

PUT/v1/orgs/:orgId/drive/items/:itemId/shares/:principalId

Shares an item (and everything in it) with a person or team as viewer, commenter or editor. Org spaces: members and teams of the org; personal spaces: any person, no teams. Editors; at most 100 per item.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/shares/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "role": "viewer"
  }'
deleteOrgDriveItemsSharesByPrincipalId

DELETE/v1/orgs/:orgId/drive/items/:itemId/shares/:principalId

Removes someone's access given on this item (inherited access stays). Anyone may remove their own.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/shares/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveItemsTransfer

POST/v1/orgs/:orgId/drive/items/:itemId/transfer

Gives a My Drive item (org spaces) to another member: it moves to the top of their My Drive and you keep editor access. Owners.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/{itemId}/transfer' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "userId": "<userId>"
  }'
postOrgDriveFolders

POST/v1/orgs/:orgId/drive/folders

Creates a folder (onConflict: fail, the default, or rename for a numbered name). Editors of the parent.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/folders' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "parentId": "<parentId>",
    "name": "Example"
  }'
postOrgDriveFoldersPaths

POST/v1/orgs/:orgId/drive/folders/paths

Folder uploads: makes each relative path's folders (a, a/b) under parentId, reusing existing ones.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/folders/paths' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "parentId": "<parentId>",
    "paths": [
      "example"
    ]
  }'
postOrgDriveItemsMove

POST/v1/orgs/:orgId/drive/items/move

Moves items into a folder (up to 500). Between drives (everything inside goes too, at most 2,000 items) only for My Drive's owner or the source drive's managers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/move' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ],
    "parentId": "<parentId>"
  }'
postOrgDriveItemsCopy

POST/v1/orgs/:orgId/drive/items/copy

Copies files (not folders) into a folder, Copy of … next to the original by default (server-side, up to 20 GB each; counts against storage).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/copy' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postOrgDriveItemsTrash

POST/v1/orgs/:orgId/drive/items/trash

Moves items (with everything in them) to their drive's trash; deleted forever after 30 days. Editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/trash' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postOrgDriveItemsRestore

POST/v1/orgs/:orgId/drive/items/restore

Puts trashed items back where they were (else at the top of their drive), with a numbered name if the name was taken meanwhile.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/restore' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postOrgDriveItemsDelete

POST/v1/orgs/:orgId/drive/items/delete

Deletes trashed items forever (owner or managers). Large folders finish in the background (done: false).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/delete' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postOrgDriveItemsStar

POST/v1/orgs/:orgId/drive/items/star

Stars or unstars items for the caller (starred).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/items/star' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ],
    "starred": true
  }'
orgDriveTrash

GET/v1/orgs/:orgId/drive/trash

A drive's trash (My Drive by default, or driveId): items trashed there, newest first, with canEmpty for its owner or managers.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/trash' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveTrashEmpty

POST/v1/orgs/:orgId/drive/trash/empty

Deletes everything in a drive's trash forever (My Drive by default). Owner or managers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/trash/empty' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "driveId": "<driveId>"
  }'
orgDriveRecent

GET/v1/orgs/:orgId/drive/recent

Files you opened or changed in the last 60 days, newest first.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/recent' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveStarred

GET/v1/orgs/:orgId/drive/starred

Your starred items you can still open.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/starred' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
orgDriveShared

GET/v1/orgs/:orgId/drive/shared

Items shared with you (or your teams), newest first, outside your own My Drive. Personal context: personal files people shared with you.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/shared' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveUploads

POST/v1/orgs/:orgId/drive/uploads

Starts an upload: answers the part size and links for the first parts (PUT each part, then complete).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/uploads' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "size": 1
  }'
postOrgDriveUploadsParts

POST/v1/orgs/:orgId/drive/uploads/:uploadId/parts

Links (an hour each) for more parts of an upload, up to 100 at a time.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/uploads/{uploadId}/parts' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "partNumbers": [
      1
    ]
  }'
orgDriveUploadsByUploadId

GET/v1/orgs/:orgId/drive/uploads/:uploadId

Where an upload stands, with the parts already stored, to resume it.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/uploads/{uploadId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveUploadsComplete

POST/v1/orgs/:orgId/drive/uploads/:uploadId/complete

Finishes an upload once every part has arrived: checks the size, counts it against storage (413 when it doesn't fit) and records the file or its new version.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/uploads/{uploadId}/complete' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
deleteOrgDriveUploadsByUploadId

DELETE/v1/orgs/:orgId/drive/uploads/:uploadId

Cancels an upload and discards its parts.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/uploads/{uploadId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postOrgDriveArchives

POST/v1/orgs/:orgId/drive/archives

A ZIP of files and folders, made in the background; ask for it until status is ready, then download url.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/archives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
orgDriveArchivesByArchiveId

GET/v1/orgs/:orgId/drive/archives/:archiveId

A ZIP's status (queued, building, ready, failed) and, when ready, a one-hour download link; left adds up what its Word, Excel and PowerPoint files changed or left out.

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/drive/archives/{archiveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveDrives

GET/v1/me/drive/drives

My Drive, the shared drives the caller belongs to (every one, to manage, for org admins) and storage use.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/drives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveDrives

POST/v1/me/drive/drives

Creates a shared drive; the caller becomes its manager. Not in personal spaces; not for viewers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/drives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example"
  }'
meDriveDrivesByDriveId

GET/v1/me/drive/drives/:driveId

A drive with its members (shared drives) and whether the caller can manage them.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
patchMeDriveDrivesByDriveId

PATCH/v1/me/drive/drives/:driveId

Renames a shared drive or changes its description (managers, and org owners and admins).

Parameters and answers
curl -X PATCH 'https://api.cactive.com.au/v1/me/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "description": "example"
  }'
deleteMeDriveDrivesByDriveId

DELETE/v1/me/drive/drives/:driveId

Deletes an empty shared drive (its trash too must be empty).

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/drives/{driveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
putMeDriveDrivesMembersByPrincipalId

PUT/v1/me/drive/drives/:driveId/members/:principalId

Adds a person or team to a shared drive, or changes their role (viewer, commenter, editor, manager). A drive always keeps a manager who is a person.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/me/drive/drives/{driveId}/members/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "role": "viewer"
  }'
deleteMeDriveDrivesMembersByPrincipalId

DELETE/v1/me/drive/drives/:driveId/members/:principalId

Removes a member (anyone may remove themselves).

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/drives/{driveId}/members/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveUsage

GET/v1/me/drive/usage

Storage the space uses (every version, the trash included) and its limit, in bytes.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/usage' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDrivePeople

GET/v1/me/drive/people

A person to share with, by exact email address: an org member here, any account for personal files.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/people?email=person%40example.com' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveLog

GET/v1/me/drive/log

Personal spaces: the owner's log of every change and access (who opened, downloaded or listed what, links included).

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/log' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveItemsByItemId

GET/v1/me/drive/items/:itemId

A file or folder with its path (from the highest folder you can open), your role and what it allows, its shares (for editors) and its link setting. Photo details lose location and camera for people who only view, when the owner removes them.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
patchMeDriveItemsByItemId

PATCH/v1/me/drive/items/:itemId

Renames an item (names are unique per folder, ignoring case) or sets its description. Editors.

Parameters and answers
curl -X PATCH 'https://api.cactive.com.au/v1/me/drive/items/{itemId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "description": "example"
  }'
meDriveItemsChildren

GET/v1/me/drive/items/:itemId/children

A folder's contents, folders first, sorted by name, modified or size (order), in pages of up to 1,000 (cursor).

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/children' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveItemsFile

GET/v1/me/drive/items/:itemId/file

A one-hour link to the file's bytes (inline=1 to show it in the browser; versionId for an earlier version, editors only; transcode=1 with inline=1: a video's preview transcode, pending while it's made).

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/file' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveItemsVersions

GET/v1/me/drive/items/:itemId/versions

A file's versions, newest first, with who uploaded each; canManage for editors.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/versions' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveItemsVersionsRestore

POST/v1/me/drive/items/:itemId/versions/:versionId/restore

Makes an earlier version current again as a new version (a copy in the bucket; counts against storage). Editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/versions/{versionId}/restore' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
deleteMeDriveItemsVersionsByVersionId

DELETE/v1/me/drive/items/:itemId/versions/:versionId

Deletes an earlier version (never the current one). Editors.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/versions/{versionId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveItemsActivity

GET/v1/me/drive/items/:itemId/activity

What happened to an item (and, for folders, to what's in them), newest first, a year back.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/activity' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveItemsComments

GET/v1/me/drive/items/:itemId/comments

Comments on a file or folder, oldest first; canComment for commenters and editors.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/comments' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveItemsComments

POST/v1/me/drive/items/:itemId/comments

Adds a comment (up to 4,000 characters). Commenters and editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/comments' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "body": "example"
  }'
deleteMeDriveItemsCommentsByCommentId

DELETE/v1/me/drive/items/:itemId/comments/:commentId

Deletes a comment: its author, or an editor.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/comments/{commentId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
putMeDriveItemsSharesByPrincipalId

PUT/v1/me/drive/items/:itemId/shares/:principalId

Shares an item (and everything in it) with a person or team as viewer, commenter or editor. Org spaces: members and teams of the org; personal spaces: any person, no teams. Editors; at most 100 per item.

Parameters and answers
curl -X PUT 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/shares/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "role": "viewer"
  }'
deleteMeDriveItemsSharesByPrincipalId

DELETE/v1/me/drive/items/:itemId/shares/:principalId

Removes someone's access given on this item (inherited access stays). Anyone may remove their own.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/shares/{principalId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveItemsTransfer

POST/v1/me/drive/items/:itemId/transfer

Gives a My Drive item (org spaces) to another member: it moves to the top of their My Drive and you keep editor access. Owners.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/{itemId}/transfer' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "userId": "<userId>"
  }'
postMeDriveFolders

POST/v1/me/drive/folders

Creates a folder (onConflict: fail, the default, or rename for a numbered name). Editors of the parent.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/folders' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "parentId": "<parentId>",
    "name": "Example"
  }'
postMeDriveFoldersPaths

POST/v1/me/drive/folders/paths

Folder uploads: makes each relative path's folders (a, a/b) under parentId, reusing existing ones.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/folders/paths' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "parentId": "<parentId>",
    "paths": [
      "example"
    ]
  }'
postMeDriveItemsMove

POST/v1/me/drive/items/move

Moves items into a folder (up to 500). Between drives (everything inside goes too, at most 2,000 items) only for My Drive's owner or the source drive's managers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/move' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ],
    "parentId": "<parentId>"
  }'
postMeDriveItemsCopy

POST/v1/me/drive/items/copy

Copies files (not folders) into a folder, Copy of … next to the original by default (server-side, up to 20 GB each; counts against storage).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/copy' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postMeDriveItemsTrash

POST/v1/me/drive/items/trash

Moves items (with everything in them) to their drive's trash; deleted forever after 30 days. Editors.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/trash' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postMeDriveItemsRestore

POST/v1/me/drive/items/restore

Puts trashed items back where they were (else at the top of their drive), with a numbered name if the name was taken meanwhile.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/restore' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postMeDriveItemsDelete

POST/v1/me/drive/items/delete

Deletes trashed items forever (owner or managers). Large folders finish in the background (done: false).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/delete' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
postMeDriveItemsStar

POST/v1/me/drive/items/star

Stars or unstars items for the caller (starred).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/items/star' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ],
    "starred": true
  }'
meDriveTrash

GET/v1/me/drive/trash

A drive's trash (My Drive by default, or driveId): items trashed there, newest first, with canEmpty for its owner or managers.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/trash' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveTrashEmpty

POST/v1/me/drive/trash/empty

Deletes everything in a drive's trash forever (My Drive by default). Owner or managers.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/trash/empty' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "driveId": "<driveId>"
  }'
meDriveRecent

GET/v1/me/drive/recent

Files you opened or changed in the last 60 days, newest first.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/recent' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveStarred

GET/v1/me/drive/starred

Your starred items you can still open.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/starred' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
meDriveShared

GET/v1/me/drive/shared

Items shared with you (or your teams), newest first, outside your own My Drive. Personal context: personal files people shared with you.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/shared' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveUploads

POST/v1/me/drive/uploads

Starts an upload: answers the part size and links for the first parts (PUT each part, then complete).

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/uploads' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Example",
    "size": 1
  }'
postMeDriveUploadsParts

POST/v1/me/drive/uploads/:uploadId/parts

Links (an hour each) for more parts of an upload, up to 100 at a time.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/uploads/{uploadId}/parts' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "partNumbers": [
      1
    ]
  }'
meDriveUploadsByUploadId

GET/v1/me/drive/uploads/:uploadId

Where an upload stands, with the parts already stored, to resume it.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/uploads/{uploadId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveUploadsComplete

POST/v1/me/drive/uploads/:uploadId/complete

Finishes an upload once every part has arrived: checks the size, counts it against storage (413 when it doesn't fit) and records the file or its new version.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/uploads/{uploadId}/complete' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
deleteMeDriveUploadsByUploadId

DELETE/v1/me/drive/uploads/:uploadId

Cancels an upload and discards its parts.

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/me/drive/uploads/{uploadId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
postMeDriveArchives

POST/v1/me/drive/archives

A ZIP of files and folders, made in the background; ask for it until status is ready, then download url.

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/me/drive/archives' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemIds": [
      "example"
    ]
  }'
meDriveArchivesByArchiveId

GET/v1/me/drive/archives/:archiveId

A ZIP's status (queued, building, ready, failed) and, when ready, a one-hour download link; left adds up what its Word, Excel and PowerPoint files changed or left out.

Parameters and answers
curl 'https://api.cactive.com.au/v1/me/drive/archives/{archiveId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsList

GET/v1/orgs/:orgId/signatures

List signing requests you sent

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsToSign

GET/v1/orgs/:orgId/signatures/to-sign

List requests waiting for your signature

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/to-sign' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsForFile

GET/v1/orgs/:orgId/signatures/files/:itemId

A file's signing requests

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/files/{itemId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsCreate

POST/v1/orgs/:orgId/signatures

Start a signing request

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "itemId": "<itemId>"
  }'
signaturesRequestsGet

GET/v1/orgs/:orgId/signatures/:requestId

Get a signing request

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsUpdate

PATCH/v1/orgs/:orgId/signatures/:requestId

Change a draft signing request

Parameters and answers
curl -X PATCH 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "title": "Example",
    "message": "example",
    "signers": [
      {
        "name": "Example",
        "email": "person@example.com",
        "order": 1
      }
    ]
  }'
signaturesRequestsSend

POST/v1/orgs/:orgId/signatures/:requestId/send

Send a signing request

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/send' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsRemind

POST/v1/orgs/:orgId/signatures/:requestId/remind

Remind signers

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/remind' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesRequestsVoid

POST/v1/orgs/:orgId/signatures/:requestId/void

Cancel a signing request

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/void' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "reason": "example"
  }'
signaturesRequestsDelete

DELETE/v1/orgs/:orgId/signatures/:requestId

Delete a draft signing request

Parameters and answers
curl -X DELETE 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesSigningGet

GET/v1/orgs/:orgId/signatures/:requestId/signing

Open a request to sign

Parameters and answers
curl 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/signing' \
  -H "Authorization: Bearer $CACTIVE_TOKEN"
signaturesSigningSign

POST/v1/orgs/:orgId/signatures/:requestId/sign

Sign a request

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/sign' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "values": [
      {
        "fieldId": "<fieldId>"
      }
    ]
  }'
signaturesSigningDecline

POST/v1/orgs/:orgId/signatures/:requestId/decline

Decline a request

Parameters and answers
curl -X POST 'https://api.cactive.com.au/v1/orgs/{orgId}/signatures/{requestId}/decline' \
  -H "Authorization: Bearer $CACTIVE_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{
    "reason": "example"
  }'