Documents (REST)
Documents, folders, links, and e-sign requests — read:documents / write:documents scopes. Send Authorization: Bearer ak_... and entityId (query, JSON body, or x-entity-id header). Browser sessions use withTenant the same way as CRM/Sales.
Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidWith linkableId, filter to documents linked to this record type
With linkableType, filter to documents linked to this record id
uuidResponse Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"[
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
]{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidTypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/documents?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "action": "link", "documentId": "4704590c-004e-410d-adf7-acb7ca0a7052", "linkableType": "string", "linkableId": "7cca18e0-f038-48b8-a601-8542a34fb1d9" }'null{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X DELETE "https://example.com/api/documents?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "documentId": "4704590c-004e-410d-adf7-acb7ca0a7052" }'{
"ok": true
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z",
"links": [
{}
]
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/api/documents/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{}'{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
application/json
curl -X DELETE "https://example.com/api/documents/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/octet-stream
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/497f6eca-6276-4993-bfeb-53cbbbba6f08/file?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08""string"{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
multipart/form-data
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/documents/upload?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -F file="string"{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/dashboard?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"totalDocuments": 0,
"folders": 0,
"pendingSignatures": 0,
"completedSignatures": 0,
"recentDocuments": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"filename": "string",
"mimeType": "string",
"sizeBytes": 0,
"blobUrl": "string",
"description": "string",
"folderId": "5b6379a4-2a6c-4085-b184-45838a3b8e7e",
"tags": null,
"status": "string",
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
]
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuiduuidResponse Body
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/document-links?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08&linkableType=string&linkableId=497f6eca-6276-4993-bfeb-53cbbbba6f08"[
{}
]{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/documents/document-links?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "documentId": "4704590c-004e-410d-adf7-acb7ca0a7052", "linkableType": "string", "linkableId": "7cca18e0-f038-48b8-a601-8542a34fb1d9" }'{}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuiduuidResponse Body
application/json
application/json
application/json
application/json
curl -X DELETE "https://example.com/api/documents/document-links?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08&id=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"deleted": true
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/folders?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"[
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"name": "string",
"description": "string",
"parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43",
"color": "string",
"icon": "string",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
]{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/documents/folders?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "name": "string" }'{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"name": "string",
"description": "string",
"parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43",
"color": "string",
"icon": "string",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/api/documents/folders/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{}'{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"entityId": "156e622c-6cdf-4c27-9bc9-2f2db69919f5",
"name": "string",
"description": "string",
"parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43",
"color": "string",
"icon": "string",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
curl -X DELETE "https://example.com/api/documents/folders/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{
"deleted": true
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidFilter by workflow status
Response Body
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/signature-requests?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"[
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"title": "string",
"status": "string",
"documentId": "string",
"documentName": "string",
"dueDate": "string",
"completedAt": "2019-08-24T14:15:22Z",
"createdAt": "2019-08-24T14:15:22Z"
}
]{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Query Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/documents/signature-requests?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "documentId": "string", "title": "string" }'{}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidResponse Body
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/api/documents/signature-requests/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08"{}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}Authorization
bearerAuth Create keys under Settings → API keys. Prefix ak_. Send as Authorization: Bearer ak_....
In: header
Path Parameters
uuidQuery Parameters
Entity UUID; must match the API key’s entity when using Bearer auth.
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/api/documents/signature-requests/497f6eca-6276-4993-bfeb-53cbbbba6f08?entityId=497f6eca-6276-4993-bfeb-53cbbbba6f08" \ -H "Content-Type: application/json" \ -d '{ "action": "send" }'{}{
"error": "string"
}{
"error": "string"
}{
"error": "string"
}