API Reference
Base URL
Section titled “Base URL”https://api.opentusk.aiFor local development:
http://localhost:8000Authentication
Section titled “Authentication”All authenticated endpoints require a Bearer token in the Authorization header:
Authorization: Bearer tdp_your_api_keySee Authentication for details on API keys and other auth methods.
Request format
Section titled “Request format”- Request bodies use JSON (
Content-Type: application/json) - File uploads use presigned URLs (not multipart form data)
Error format
Section titled “Error format”All errors return a JSON object with an error field:
{ "error": "Vault not found"}Status codes
Section titled “Status codes”| Code | Meaning |
|---|---|
200 | Success |
201 | Created |
400 | Bad request — invalid input or validation error |
401 | Unauthorized — missing or invalid auth |
403 | Forbidden — valid auth but insufficient permissions |
404 | Not found |
409 | Conflict — duplicate resource |
429 | Rate limited |
500 | Internal server error |
Pagination
Section titled “Pagination”List endpoints support cursor-based pagination:
| Parameter | Type | Description |
|---|---|---|
limit | number | Items per page (default: 50, max: 100) |
cursor | string | Cursor from previous response for next page |
sortBy | string | Field to sort by (e.g., createdAt, name) |
order | string | asc or desc |
Response includes a nextCursor field when more results are available:
{ "files": [], "nextCursor": "eyJpZCI6Ij..."}Rate limits
Section titled “Rate limits”Rate limits vary by plan tier:
| Plan | Uploads/min | Downloads/min |
|---|---|---|
| Free | 5 | 20 |
| Developer | 30 | 100 |
| Scale | 100 | 500 |
| Enterprise | 300 | 2,000 |
When rate limited, the API returns 429 Too Many Requests.