API quickstart
Make your first Rokn API call in a few minutes: the base URL, an API key, a curl request, the rate-limit headers and the MCP server address.
The Rokn REST API lets a script or service read and change a workspace: clients, projects, tasks, time, invoices and more. This page takes you from nothing to a working request.
1. Know the base URL
Every request goes to https://app.rokn.dev/api/v1. Everything that belongs to a workspace lives under /workspaces/{slug}, where the slug is the first part of the workspace's address in the app. A record of another workspace is always answered with 404.
2. Create an API key
In the app, open Settings, then API keys, and choose Create key. Name it after what will use it, tick only the scopes it needs, and copy the key: Rokn shows it once. API access needs a plan that includes it; see pricing. The step-by-step version is the guide API keys and webhooks.
3. Make your first request
Send the key as a bearer token. This call lists the workspaces the key can reach, so you can read your slug.
curl "https://app.rokn.dev/api/v1/workspaces" \
-H "Authorization: Bearer $ROKN_API_KEY"Then read something from your workspace. Replace YOUR_WORKSPACE with the slug.
curl "https://app.rokn.dev/api/v1/workspaces/YOUR_WORKSPACE/clients" \
-H "Authorization: Bearer $ROKN_API_KEY"A 401 means the key is missing, expired or revoked. A 403 means its scopes do not cover the request. Every operation lists the scope it needs in the API reference.
4. Write safely
Send an Idempotency-Key header on a write you may retry: a replay with the same key returns the same result instead of creating a second record. Errors come back as RFC 9457 problem details with a stable code; see Errors.
Rate limits
Each API key, and each OAuth or MCP connection, has its own budget of requests per minute. The budget depends on your plan, so it is not the same for everyone: see pricing for what your plan allows. Every response carries X-RateLimit-Limit (the budget, or -1 for unlimited), X-RateLimit-Remaining and X-RateLimit-Reset (Unix seconds when the window resets). When the budget is spent the API answers 429 rate_limited with a Retry-After header: wait that many seconds, then retry.
Connect an AI agent over MCP
To let Claude or another MCP client work in your workspace, add the server address. The client opens a consent screen where you choose the workspace and scopes; no API key is needed. See Connect over MCP.
{
"mcpServers": {
"rokn": {
"url": "https://app.rokn.dev/api/mcp"
}
}
}Where to go next
Read Authentication for API keys against OAuth, then Scopes and permissions.