Files and spaces.
Spaces are how people open storage. A path is relative to the space, uses /, and has no leading slash. kind on a space is shared or personal. level is view, edit, or full. icon is folder, home, users, film, image, music, or briefcase. The older root-and-path calls still work.
While Trash is on (Admin → System → Maintenance), deleting a file or folder moves it to the caller's Trash, and it is deleted for good after the number of days the administrator chose. Send permanent=true to delete it for good at once. A service account's key always deletes for good, because nobody would see its Trash. The Trash calls list, restore, and delete what is there.
Authentication, errors, and paging are in the API reference. Sending the key is described once there.
Spaces
GET /api/v1/home/live
What is moving now that the caller can see, with the 24-hour counts. Polled by the home screen.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
storage is a StorageSummary: the room the caller has left in their private folders and in shared spaces, and for an administrator every location and everything nearly full.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
asOf | string | required | When the counts were read. The list and the rate are always current. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
counts | object | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
sendingBps | integer | required | Sum of the visible running transfers, bits per second. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
ceilingBps | integer | optional, left out when empty | The last speed check's sending ceiling, bits per second. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
running | array of objects | required | Up to five, fastest first. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
paused | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
queued | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
more | integer | required | Running, paused and queued items not listed. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
map | Map | optional, left out when empty | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
storage | object | required | The caller's storage: room left in their private folders and in shared spaces, and for an administrator every location and what is nearly full. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"asOf": "example",
"counts": {
"running": 1,
"queued": 1,
"paused": 1,
"done24h": 1,
"failed24h": 1,
"moved24h": 1
},
"sendingBps": 1,
"running": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"direction": "download",
"kind": "file",
"owner": {
"kind": "file",
"name": "Rush delivery"
},
"bps": 1,
"done": 1,
"size": 1048576
}
],
"paused": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"direction": "download",
"kind": "file",
"owner": {
"kind": "file",
"name": "Rush delivery"
},
"bps": 1,
"done": 1,
"size": 1048576
}
],
"queued": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"direction": "download",
"kind": "file",
"owner": {
"kind": "file",
"name": "Rush delivery"
},
"bps": 1,
"done": 1,
"size": 1048576
}
],
"more": 1,
"storage": {
"home": {
"used": 1,
"name": "Rush delivery",
"warn": true,
"over": true,
"counting": true,
"lowSpace": true
},
"shared": {
"used": 1,
"name": "Rush delivery",
"warn": true,
"over": true,
"counting": true,
"lowSpace": true
},
"received": 1,
"countedSoFar": 1,
"locations": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"kind": "shared",
"quota": 1,
"usage": {
"used": 1,
"files": 1,
"countedAt": "2026-10-05T18:00:00Z",
"counting": true
},
"capacity": {
"free": 1,
"total": 1
}
}
],
"nearlyFull": [
{
"level": {},
"scope": {
"event": {
"file": {
"name": "rush.mov"
}
},
"rule": {},
"now": 1,
"steps": {
"file": {
"name": "rush.mov"
}
},
"secrets": {},
"command_root": {}
},
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"used": 1,
"limit": 50
}
]
}
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/home/series
Throughput the caller can see, in 48 half-hour points over the last 24 hours.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Success. 200.
| Field | Type | Meaning | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
points | array of objects | required | |||||||||||||
Each item is an object:
| |||||||||||||||
ceilingBps | integer | optional, left out when empty | |||||||||||||
{
"points": [
{
"ts": 1,
"bps": 1
}
],
"ceilingBps": 1
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/home
The spaces this caller can open. Personal spaces come first. Each has usage, a Room: the room the caller has left there.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
spaces | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
anySpaces | boolean | required | Whether this server has any space at all. An empty list means "nothing has been set up yet" when this is false and "none of it is yours" when it is true, and the two need different words. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"spaces": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"level": "edit",
"usage": {
"used": 1,
"name": "Rush delivery",
"warn": true,
"over": true,
"counting": true,
"lowSpace": true
}
}
],
"anySpaces": true
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/spaces/{id}
One space: name, icon, kind and the caller's level. An administrator also gets the location's name.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
id | string | required | The id. |
name | string | required | The name. |
icon | string | required | folder, home, users, film, image, music, or briefcase. |
kind | string | required | |
level | string | required | |
locationName | string | optional, left out when empty |
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"level": "edit",
"locationName": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 404 | not_found | not there, or not visible to this caller |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "not_found",
"message": "not found"
}
}
GET /api/v1/spaces/{id}/files
One folder inside a space.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Each entry has a level: view, edit, full, or traverse when the folder is only on the way to a grant. A file also has its version and preview: ok, none, tooLarge, kindOff or spaceOff. The listing's usage is a Room: the room the caller has left in this folder.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The space. |
path | query | string | optional | Folder, relative to the space. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
level | string | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
items | array of objects | required | The records in this reply. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
usage | object | required | The room this person has left in this folder. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"path": "projects/rush",
"level": "edit",
"items": [
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example",
"level": "edit",
"version": "example",
"preview": "example"
}
],
"usage": {
"used": 1,
"name": "Rush delivery",
"warn": true,
"over": true,
"counting": true,
"lowSpace": true
}
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
DELETE /api/v1/spaces/{id}/files
Delete a file or a folder inside a space. While Trash is on, a person's delete moves it to Trash; see /api/v1/trash.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Moves the file or folder to the caller's Trash while the Trash setting (trashDays in the maintenance settings) is on. It leaves the listing at once. permanent=true, a service account's key, or Trash being off deletes it for good instead.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The space. |
path | query | string | optional | What to delete, relative to the space. |
permanent | query | boolean | optional | Delete for good even when Trash is on. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
The reply has no body.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | name a file or a folder |
| 404 | not_found | not there, or not visible to this caller |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "name a file or a folder"
}
}
POST /api/v1/spaces/{id}/folder
Make a folder inside a space. Body: {path}.
Who. Any user with a key that has the write scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
path | string | optional | A path relative to the space or the storage location, with / between folders and no leading slash. |
{
"path": "projects/rush"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
kind | string | required | |
size | integer | required | Size in bytes. |
modified | string | optional, left out when empty |
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | name the folder |
| 409 | conflict | something is already there |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "name the folder"
}
}
POST /api/v1/spaces/{id}/rename
Rename or move inside a space. Body: {from, to}.
Who. Any user with a key that has the write scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
from | string | optional | |
to | string | required |
{
"from": "projects/rush",
"to": "projects/rush"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
kind | string | required | |
size | integer | required | Size in bytes. |
modified | string | optional, left out when empty |
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | name a file or a folder |
| 409 | conflict | something is already there |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "name a file or a folder"
}
}
POST /api/v1/spaces/{id}/move
Move files and folders into a folder of this space or another one. Body: {paths, toSpace, toPath}. Replies {transferId, done}; when done is false the move carries on as a transfer with direction move.
Who. Any user with a key that has the write scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
paths | array of string | required | Files and folders in this space. |
toSpace | string | required | The space they go to, which may be this one. |
toPath | string | optional | The folder in that space they go into. Empty for its top. |
{
"paths": [
"projects/rush"
],
"toSpace": "example",
"toPath": "projects/rush"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
transferId | string | required | The id. |
done | boolean | required | True when everything is already in its new place. False while the files are being copied there; the transfer says how it is going. |
{
"transferId": "k7Qm2sLp9vX4aB1c",
"done": true
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | everything chosen is already in that folder |
| 409 | conflict | something is already there |
| 404 | not_found | not there, or not visible to this caller |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "everything chosen is already in that folder"
}
}
Managing spaces
GET /api/v1/admin/spaces
Every space, and storage locations that are not shared yet.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
spaces | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
unshared | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
signInOpenToAnyone | array of string | required | The sign-in methods that let in anybody the directory or provider accepts, each of whom gets a folder in a personal space for everyone. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"spaces": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"rootId": "k7Qm2sLp9vX4aB1c",
"basePath": "projects/rush",
"position": 1,
"createdAt": "2026-10-05T18:00:00Z",
"allowPreviews": true,
"locationName": "example",
"locationKind": "example",
"locationPath": "projects/rush",
"usage": {
"used": 1,
"files": 1,
"countedAt": "2026-10-05T18:00:00Z",
"counting": true
},
"warnings": [
"example"
]
}
],
"unshared": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"kind": "shared"
}
],
"signInOpenToAnyone": [
"example"
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
POST /api/v1/admin/spaces
Create a space.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Body: {name, icon, rootId, basePath, kind: shared|personal, template, forGroup, allowPreviews, quota}. allowPreviews is true when left out. quota is bytes; on a personal space it is the total for all its private folders. Each space in a reply has quota, usage (a Usage), effective {bytes, cappedBy} and warnings.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
icon | string | optional | folder, home, users, film, image, music, or briefcase. |
rootId | string | required | The id. |
basePath | string | optional | |
kind | string | required | |
template | string | optional | |
forGroup | string | optional | |
allowPreviews | boolean | optional | On when left out. |
quota | integer | optional | Bytes. Absent or null is no limit. |
{
"name": "Rush delivery",
"rootId": "k7Qm2sLp9vX4aB1c",
"kind": "shared"
}
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
id | string | required | The id. | ||||||||||||||||||||
name | string | required | The name. | ||||||||||||||||||||
icon | string | required | folder, home, users, film, image, music, or briefcase. | ||||||||||||||||||||
kind | string | required | |||||||||||||||||||||
rootId | string | required | The id. | ||||||||||||||||||||
basePath | string | required | |||||||||||||||||||||
template | string | optional | |||||||||||||||||||||
forGroup | string | optional | |||||||||||||||||||||
position | integer | required | |||||||||||||||||||||
createdAt | string | required | A time, as RFC 3339. | ||||||||||||||||||||
allowPreviews | boolean | required | |||||||||||||||||||||
locationName | string | required | |||||||||||||||||||||
locationKind | string | required | |||||||||||||||||||||
locationPath | string | required | |||||||||||||||||||||
privateFolders | integer | optional, left out when empty | How many people have a private folder in a personal space. | ||||||||||||||||||||
quota | integer | optional | Bytes the space may hold; on a personal space, all its private folders together. None is no limit. | ||||||||||||||||||||
usage | object | required | |||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||
effective | Effective | optional, left out when empty | |||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||
warnings | array of string | required | Limits that cannot all be met. Saving is never refused for these. | ||||||||||||||||||||
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"rootId": "k7Qm2sLp9vX4aB1c",
"basePath": "projects/rush",
"position": 1,
"createdAt": "2026-10-05T18:00:00Z",
"allowPreviews": true,
"locationName": "example",
"locationKind": "example",
"locationPath": "projects/rush",
"usage": {
"used": 1,
"files": 1,
"countedAt": "2026-10-05T18:00:00Z",
"counting": true
},
"warnings": [
"example"
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the name, kind or template is not usable |
| 409 | conflict | the name is taken |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the name, kind or template is not usable"
}
}
POST /api/v1/admin/spaces/preview
The warnings a new space would raise, without saving it. Same body as creating one.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
icon | string | optional | folder, home, users, film, image, music, or briefcase. |
rootId | string | required | The id. |
basePath | string | optional | |
kind | string | required | |
template | string | optional | |
forGroup | string | optional | |
allowPreviews | boolean | optional | On when left out. |
quota | integer | optional | Bytes. Absent or null is no limit. |
{
"name": "Rush delivery",
"rootId": "k7Qm2sLp9vX4aB1c",
"kind": "shared"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
warnings | array of string | required |
{
"warnings": [
"example"
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/admin/spaces/{id}
One space, including the location path. A personal space includes the people who have opened their folder; a shared space includes topUsers, the people whose files take the most room.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
space | object | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
people | array of objects | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
signInOpenToAnyone | array of string | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
topUsers | array of objects | required | In a shared space, the people whose files take the most room. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"space": {
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"rootId": "k7Qm2sLp9vX4aB1c",
"basePath": "projects/rush",
"position": 1,
"createdAt": "2026-10-05T18:00:00Z",
"allowPreviews": true,
"locationName": "example",
"locationKind": "example",
"locationPath": "projects/rush",
"usage": {
"used": 1,
"files": 1,
"countedAt": "2026-10-05T18:00:00Z",
"counting": true
},
"warnings": [
"example"
]
},
"people": [
{
"userId": "k7Qm2sLp9vX4aB1c",
"email": "[email protected]",
"displayName": "example"
}
],
"signInOpenToAnyone": [
"example"
],
"topUsers": [
{
"userId": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"used": 1
}
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
PATCH /api/v1/admin/spaces/{id}
Rename a space, change its icon or position, change which group a personal space is for, turn previews in it on or off (allowPreviews), or set its quota in bytes (null for no limit).
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | optional | The name. |
icon | string | optional | folder, home, users, film, image, music, or briefcase. |
position | integer | optional | |
forGroup | string | optional | |
allowPreviews | boolean | optional | |
quota | integer | optional | Bytes. Left out keeps the quota; null removes it. |
{
"name": "Rush delivery",
"icon": "folder",
"position": 1,
"forGroup": "example",
"allowPreviews": true,
"quota": 1
}
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
id | string | required | The id. | ||||||||||||||||||||
name | string | required | The name. | ||||||||||||||||||||
icon | string | required | folder, home, users, film, image, music, or briefcase. | ||||||||||||||||||||
kind | string | required | |||||||||||||||||||||
rootId | string | required | The id. | ||||||||||||||||||||
basePath | string | required | |||||||||||||||||||||
template | string | optional | |||||||||||||||||||||
forGroup | string | optional | |||||||||||||||||||||
position | integer | required | |||||||||||||||||||||
createdAt | string | required | A time, as RFC 3339. | ||||||||||||||||||||
allowPreviews | boolean | required | |||||||||||||||||||||
locationName | string | required | |||||||||||||||||||||
locationKind | string | required | |||||||||||||||||||||
locationPath | string | required | |||||||||||||||||||||
privateFolders | integer | optional, left out when empty | How many people have a private folder in a personal space. | ||||||||||||||||||||
quota | integer | optional | Bytes the space may hold; on a personal space, all its private folders together. None is no limit. | ||||||||||||||||||||
usage | object | required | |||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||
effective | Effective | optional, left out when empty | |||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||
warnings | array of string | required | Limits that cannot all be met. Saving is never refused for these. | ||||||||||||||||||||
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"icon": "folder",
"kind": "shared",
"rootId": "k7Qm2sLp9vX4aB1c",
"basePath": "projects/rush",
"position": 1,
"createdAt": "2026-10-05T18:00:00Z",
"allowPreviews": true,
"locationName": "example",
"locationKind": "example",
"locationPath": "projects/rush",
"usage": {
"used": 1,
"files": 1,
"countedAt": "2026-10-05T18:00:00Z",
"counting": true
},
"warnings": [
"example"
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
DELETE /api/v1/admin/spaces/{id}
Remove a space.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Access another shared space also holds moves to the innermost such space; all other access on the space is removed, and one space.deleted audit entry lists both. The files stay on the storage location. Jobs keep their location and path.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
The reply has no body.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 409 | conflict | a personal space whose private folders shared access on the location would then reach |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "conflict",
"message": "a personal space whose private folders shared access on the location would then reach"
}
}
GET /api/v1/admin/spaces/{id}/removal
What removing the space would do, without doing it: {name, kind, locationName, lose, keep, exposes}.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
lose is the access that would be removed, keep the access that would move to another space (with spaceId and spaceName), and exposes the shared access that stops a personal space from being removed.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
name | string | required | The name. | ||||||||||||||||||||||||||||||||||||||||||||||||
kind | string | required | |||||||||||||||||||||||||||||||||||||||||||||||||
locationName | string | required | |||||||||||||||||||||||||||||||||||||||||||||||||
lose | array of objects | required | Access that goes with the space, because no other space holds its folder. Paths are relative to the space. | ||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||
keep | array of objects | required | Access another shared space also holds. It moves there and keeps working. | ||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||
exposes | array of objects | required | Shared access on the location that would reach into this personal space's private folders once the space no longer marks them as private. Paths are relative to the location. While there is any, the space is not removed. | ||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||
{
"name": "Rush delivery",
"kind": "shared",
"locationName": "example",
"lose": [
{
"id": "k7Qm2sLp9vX4aB1c",
"kind": "shared",
"principalId": "k7Qm2sLp9vX4aB1c",
"principalName": "example",
"path": "projects/rush",
"level": "edit"
}
],
"keep": [
{
"access": {
"id": "k7Qm2sLp9vX4aB1c",
"kind": "shared",
"principalId": "k7Qm2sLp9vX4aB1c",
"principalName": "example",
"path": "projects/rush",
"level": "edit"
},
"spaceId": "k7Qm2sLp9vX4aB1c",
"spaceName": "example"
}
],
"exposes": [
{
"id": "k7Qm2sLp9vX4aB1c",
"kind": "shared",
"principalId": "k7Qm2sLp9vX4aB1c",
"principalName": "example",
"path": "projects/rush",
"level": "edit"
}
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/admin/spaces/{id}/access
Grants on this space, paths relative to the space.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
The body is an array.
| Field | Type | Meaning | |
|---|---|---|---|
id | string | required | The id. |
kind | string | required | |
principalId | string | required | The id. |
principalName | string | required | |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
level | string | required |
[
{
"id": "k7Qm2sLp9vX4aB1c",
"kind": "shared",
"principalId": "k7Qm2sLp9vX4aB1c",
"principalName": "example",
"path": "projects/rush",
"level": "edit"
}
]
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
PUT /api/v1/admin/spaces/{id}/access
Give a person or a group view, edit or full access on the space or a folder in it.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
userId | string | optional | The id. |
groupId | string | optional | The id. |
path | string | optional | A path relative to the space or the storage location, with / between folders and no leading slash. |
access | string | required |
{
"userId": "k7Qm2sLp9vX4aB1c",
"groupId": "k7Qm2sLp9vX4aB1c",
"path": "projects/rush",
"access": "edit"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
id | string | required | The id. |
kind | string | required | |
principalId | string | required | The id. |
principalName | string | required | |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
level | string | required |
{
"id": "k7Qm2sLp9vX4aB1c",
"kind": "shared",
"principalId": "k7Qm2sLp9vX4aB1c",
"principalName": "example",
"path": "projects/rush",
"level": "edit"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | neither or both of userId and groupId, or a personal space |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "neither or both of userId and groupId, or a personal space"
}
}
DELETE /api/v1/admin/spaces/{id}/access/{grant_id}
Take one space grant away.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The space. |
grant_id | path | string | required | The grant. |
Success. 200.
The reply has no body.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/admin/spaces/{id}/personal/{user_id}/files
Open one person's personal folder. Writes space.personal.opened to the audit log.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The space. |
user_id | path | string | required | The person. |
path | query | string | optional | Folder, relative to their folder. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
level | string | required | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
items | array of objects | required | The records in this reply. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
usage | object | required | The room this person has left in this folder. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{
"path": "projects/rush",
"level": "edit",
"items": [
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example",
"level": "edit",
"version": "example",
"preview": "example"
}
],
"usage": {
"used": 1,
"name": "Rush delivery",
"warn": true,
"over": true,
"counting": true,
"lowSpace": true
}
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
GET /api/v1/admin/access/folder
Who can reach this folder, and why.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
space | query | string | required | The space. |
path | query | string | optional | Folder, relative to the space. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
The body is an array.
| Field | Type | Meaning | |
|---|---|---|---|
kind | string | required | |
name | string | required | The name. |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
level | string | required | |
why | string | required |
[
{
"kind": "shared",
"name": "Rush delivery",
"path": "projects/rush",
"level": "edit",
"why": "example"
}
]
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
GET /api/v1/admin/users/{id}/access
Every space and folder one person can reach, and why.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
The body is an array.
| Field | Type | Meaning | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
id | string | required | The id. | ||||||||||||||||||||||||
name | string | required | The name. | ||||||||||||||||||||||||
kind | string | required | |||||||||||||||||||||||||
paths | array of objects | required | |||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||
[
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"kind": "shared",
"paths": [
{
"kind": "shared",
"name": "Rush delivery",
"path": "projects/rush",
"level": "edit",
"why": "example"
}
]
}
]
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
Files and folders
GET /api/v1/roots
The storage locations this caller may see. GET /api/v1/home lists their spaces.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Success. 200.
The body is an array.
| Field | Type | Meaning | |
|---|---|---|---|
id | string | required | The id. |
name | string | required | The name. |
kind | string | required | |
canWrite | boolean | required | What this caller may do anywhere in the storage location. The portal uses these to decide which buttons to draw; the server checks again per path, because a grant can cover one folder and not another. |
canDelete | boolean | required |
[
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"kind": "shared",
"canWrite": true,
"canDelete": true
}
]
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "unauthenticated",
"message": "sign in to continue"
}
}
GET /api/v1/files
One folder's contents: {items, total, nextCursor}.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
root | query | string | required | Which storage location. |
path | query | string | optional | Folder, relative to the storage location. / separated, no leading slash. |
sort | query | string | optional | name, size or modified. Defaults to name. |
dir | query | string | optional | asc or desc. Defaults to asc. |
filter | query | string | optional | Narrow the listing. Matched against the name, ignoring case. |
cursor | query | string | optional | Where to resume: the previous reply's nextCursor. Omit to start. |
limit | query | integer | optional | How many entries, from 1 to 1000. Defaults to 200. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
items | array of objects | required | The records in this reply. | ||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||
total | integer | required | How many matched, including ones not on this page. | ||||||||||||||||||||||||
nextCursor | string | optional | Send this back as cursor to get the next page. Left out when this is the last page. | ||||||||||||||||||||||||
{
"items": [
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example"
}
],
"total": 1,
"nextCursor": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
nextCursor. limit defaults to 200 and must be from 1 to 1000. A folder this caller may not see is 404, the same answer as a folder that is not there.DELETE /api/v1/files
Delete a file or a folder. Body: {root, path, permanent}.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
While the Trash setting is on, a person's delete moves the file or folder to their Trash (see /api/v1/trash). permanent: true, a service account's key, or Trash being off deletes it for good.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
root | string | required | |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
permanent | boolean | optional | Delete for good even when Trash is on. |
{
"root": "k7Qm2sLp9vX4aB1c",
"path": "projects/rush",
"permanent": true
}
Success. 200.
The reply has no body.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 404 | not_found | not there, or this caller may not delete it |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
POST /api/v1/files/folder
Make a folder.
Who. Any user with a key that has the write scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
root | string | required | |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
{
"root": "k7Qm2sLp9vX4aB1c",
"path": "projects/rush"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
kind | string | required | |
size | integer | required | Size in bytes. |
modified | string | optional, left out when empty |
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 409 | conflict | something is already there |
| 404 | not_found | not there, or not visible to this caller |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
POST /api/v1/files/rename
Rename or move within a storage location.
Who. Any user with a key that has the write scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
root | string | required | |
from | string | required | |
to | string | required |
{
"root": "k7Qm2sLp9vX4aB1c",
"from": "projects/rush",
"to": "projects/rush"
}
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
name | string | required | The name. |
path | string | required | A path relative to the space or the storage location, with / between folders and no leading slash. |
kind | string | required | |
size | integer | required | Size in bytes. |
modified | string | optional, left out when empty |
{
"name": "Rush delivery",
"path": "projects/rush",
"kind": "file",
"size": 1048576,
"modified": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 409 | conflict | something is already there |
| 404 | not_found | not there, or not visible to this caller |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
POST /api/v1/files/download/done
A browser says its download of a file is over, so the transfer ends now rather than after two minutes without a request.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Body: {transfer, outcome, reused}: transfer is the id from x-farwing-transfer, outcome is done or cancelled, and the optional reused is how many bytes the browser took from an older copy instead of downloading them. A download that fetched only part of the file, because the rest came from an older copy, ends as done with the bytes that were sent and the bytes it reused. A download that is no longer open is answered the same way. Listed as download.done in /api/v1/version.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
transfer | string | required | The download, as x-farwing-transfer named it. |
outcome | string | required | done when the browser asks for nothing more, cancelled when the person stopped it. |
reused | integer | optional | Bytes the browser took from an older copy already on the computer instead of downloading them. |
{
"transfer": "example",
"outcome": "example",
"reused": 1
}
Success. 200.
JSON object.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | outcome is neither done nor cancelled |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "outcome is neither done nor cancelled"
}
}
GET /api/v1/files/manifest
The chunk list of a file, to fetch only the ranges an older copy lacks.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
200 with the binary chunk list and x-farwing-mtime; 202 with {"checking": {"done", "total"}} while the server reads the file; 204 when the file is too small to be worth it. Listed under delta in /api/v1/version.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
root | query | string | optional | The location, for a caller that still names storage directly. |
path | query | string | required | The file, relative to the storage location. |
space | query | string | optional | The space, when path is relative to one. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
JSON object.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | name a file, not the whole root |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "name a file, not the whole root"
}
}
GET /api/v1/files/checksum
The BLAKE3 checksum of one exact source file version, used to verify a saved browser download.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
root | query | string | optional | The location, for a caller that still names storage directly. |
path | query | string | required | The file, relative to the storage location. |
space | query | string | optional | The space, when path is relative to one. |
Encode the query value. A slash in a path may stay as / or be written %2F; the server reads the decoded value. Do not put a leading slash on the path.
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
algorithm | string | required | |
checksum | string | required |
{
"algorithm": "example",
"checksum": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | the request is not valid |
| 404 | not_found | not there, or not visible to this caller |
| 409 | conflict | this storage location cannot identify a stable file version |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "the request is not valid"
}
}
POST /api/v1/files/set
List the individual files and empty folders represented by a selection.
Who. Any user with a key that has the read scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Body: {space, paths} or {root, paths}, with paths relative to the space or location. Answers {name, files, empty, bytes}; each file has its source path, destination relativePath, and byte size. A folder-capable browser uses this to save each file under a folder the person chose.
Request body. JSON.
A field the server does not know is ignored.
| Field | Type | Meaning | |
|---|---|---|---|
space | string | optional | The space the paths are relative to. |
root | string | optional | The location, for a caller that still names storage directly. |
paths | array of string | required |
{
"space": "k7Qm2sLp9vX4aB1c",
"paths": [
"projects/rush"
]
}
Success. 200.
| Field | Type | Meaning | |||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
name | string | required | The name. | ||||||||||||||||
files | array of objects | required | |||||||||||||||||
Each item is an object:
| |||||||||||||||||||
empty | array of string | required | Empty folders to create under the chosen folder. | ||||||||||||||||
bytes | integer | required | Size in bytes. | ||||||||||||||||
{
"name": "Rush delivery",
"files": [
{
"path": "projects/rush",
"relativePath": "projects/rush",
"bytes": 1048576
}
],
"empty": [
"example"
],
"bytes": 1048576
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | nothing was named, the whole space was named, or there are too many files |
| 404 | not_found | a path is not there, or this caller may not see it |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "nothing was named, the whole space was named, or there are too many files"
}
}
Trash
GET /api/v1/trash
One page of the caller's Trash: {purgeAfterDays, summary, items, nextCursor}.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
summary is {items, bytes} for everything that matches, not only this page. Each item is {id, name, kind, bytes, files, originalDisplayPath, trashedAt, purgeAt}; purgeAt is when it is deleted for good under the setting now, null while Trash is off. An administrator's items also have location and path, the storage location and the path in it. purgeAfterDays is the setting, null when off. Items still being moved to or from Trash are not listed.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
limit | query | integer | optional | How many items, from 1 to 200. Defaults to 100. |
cursor | query | string | optional | Where to resume: the previous reply's nextCursor. Omit to start. |
sort | query | string | optional | trashedAt or bytes. Defaults to trashedAt. |
dir | query | string | optional | desc or asc. Defaults to desc. |
q | query | string | optional | Part of the name, ignoring case. |
user | query | string | optional | Administrators only: whose Trash to list. Defaults to the caller. |
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
purgeAfterDays | integer | optional | |||||||||||||||||||||||||||||||||||||||||||||
summary | object | required | |||||||||||||||||||||||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||
items | array of objects | required | The records in this reply. | ||||||||||||||||||||||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||||||||||||||||||||||
nextCursor | string | optional | Send this back as cursor to get the next page. Left out when this is the last page. | ||||||||||||||||||||||||||||||||||||||||||||
{
"purgeAfterDays": 1,
"summary": {
"items": 1,
"bytes": 1048576
},
"items": [
{
"id": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"kind": "shared",
"bytes": 1048576,
"files": 1,
"originalDisplayPath": "projects/rush",
"trashedAt": "2026-10-05T18:00:00Z"
}
],
"nextCursor": "example"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | a limit, sort, dir or cursor that is not usable |
| 403 | forbidden | `user` names someone else and the caller is not an administrator |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "a limit, sort, dir or cursor that is not usable"
}
}
DELETE /api/v1/trash
Empty the caller's Trash: everything in it is deleted for good. Answers {removed, bytes}.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Written to the audit log as trash.empty.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
user | query | string | optional | Administrators only: whose Trash to empty. Defaults to the caller. |
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
removed | integer | required | |
bytes | integer | required | Size in bytes. |
{
"removed": 1,
"bytes": 1048576
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 403 | forbidden | `user` names someone else and the caller is not an administrator |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "forbidden",
"message": "you do not have access to this"
}
}
GET /api/v1/trash/summary
Administrators only: how much each person has in Trash. Answers {purgeAfterDays, total: {items, bytes, users}, rows}.
Who. An administrator, with a key that has the admin scope. An administrator's key that does not have that scope is refused. The key needs a license that includes the REST API.
One row per person with anything in Trash, largest first: {userId, name, items, bytes, nextPurgeAt}. nextPurgeAt is when their oldest item is deleted for good under the setting now, null while Trash is off. Open one person's items with GET /api/v1/trash?user=.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
by | query | string | optional | user, the only grouping. |
Success. 200.
| Field | Type | Meaning | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
purgeAfterDays | integer | optional | |||||||||||||||||||||||||
total | object | required | How many matched, including ones not on this page. | ||||||||||||||||||||||||
It is an object:
| |||||||||||||||||||||||||||
rows | array of objects | required | |||||||||||||||||||||||||
Each item is an object:
| |||||||||||||||||||||||||||
{
"purgeAfterDays": 1,
"total": {
"items": 1,
"bytes": 1048576,
"users": 1
},
"rows": [
{
"userId": "k7Qm2sLp9vX4aB1c",
"name": "Rush delivery",
"items": 1,
"bytes": 1048576,
"nextPurgeAt": "2026-10-05T18:00:00Z"
}
]
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 400 | bad_request | `by` is not user |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "bad_request",
"message": "`by` is not user"
}
}
DELETE /api/v1/trash/{id}
Delete one item in the caller's Trash for good.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Written to the audit log as trash.delete.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Success. 200.
JSON object.
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 404 | not_found | not in the caller's Trash |
| 409 | conflict | it is still being moved to or from Trash |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "not_found",
"message": "not found"
}
}
POST /api/v1/trash/{id}/restore
Put an item back where it was. Answers {restoredTo, renamed, done, spaceId, spacePath}; the last two name the space and the path in it, and are absent when no space held it.
Who. Any user with a key that has the delete scope. A key with the admin scope includes the others. The key needs a license that includes the REST API.
Never replaces anything: when something else now has its name it comes back as name (restored).ext, and renamed is true. Folders on the way that are gone are made again. restoredTo is the path people see. On a storage location that cannot rename in place the copy back carries on as a transfer with direction move, and done is false until it ends. Written to the audit log as trash.restore.
Parameters.
| Name | In | Type | Meaning | |
|---|---|---|---|---|
id | path | string | required | The resource's id. |
Request body. None.
Success. 200.
| Field | Type | Meaning | |
|---|---|---|---|
restoredTo | string | required | Where it is now, as people see the path. |
renamed | boolean | required | Something else had taken its old name, so it came back as name (restored). |
done | boolean | required | False while a copy back is still running on a bucket. |
spaceId | string | optional, left out when empty | The space it is back in and its path there, for a link to its folder. Absent when no space held it. |
spacePath | string | optional, left out when empty |
{
"restoredTo": "example",
"renamed": true,
"done": true,
"spaceId": "k7Qm2sLp9vX4aB1c",
"spacePath": "projects/rush"
}
Errors. The body always has the shape in Errors. Match on code.
| Status | code | When |
|---|---|---|
| 404 | not_found | not in the caller's Trash |
| 409 | conflict | it is still being moved, or trash_no_access: the caller can no longer write where it was |
| 401 | unauthenticated | no key, or a key that is unknown, expired, revoked, or owned by a disabled account |
| 403 | forbidden | the key is valid but does not have the scope, or an administrator route was called by someone who is not an administrator |
| 402 | licence_required | the license does not include the REST API |
{
"error": {
"code": "not_found",
"message": "not found"
}
}