Rokn developer docs:
API, MCP and webhooks.

Build on your workspace. Connect your tools to the same clients, projects and invoices your team already works with.

Shell
curl "https://app.rokn.dev/api/v1/workspaces/atelier-nord/clients" \
  -G -d search=hallberg \
  -H "Authorization: Bearer $ROKN_API_KEY"

200 OKResponseExample data

Content-Type: application/json
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1763049660

{
  "items": [
    {
      "id": "k3v9q0w2f8h1m5r7t4y6u2pa",
      "name": "Hallberg Studio",
      "type": "company",
      "email": "hello@hallberg.example",
      "phone": null,
      "website": "https://hallberg.example",
      "address": null,
      "notes": null,
      "currency": "EUR",
      "vatId": null,
      "locale": null,
      "archivedAt": null,
      "fields": {},
      "createdAt": "2026-10-02T09:14:00.000Z",
      "updatedAt": "2026-11-12T16:40:00.000Z",
      "primaryContact": {
        "id": "p8w1e6r3t5y7u9i2o4a0s6dq",
        "name": "Mira Hallberg",
        "role": "Founder",
        "phone": null,
        "email": "mira@hallberg.example"
      }
    }
  ],
  "fields": [],
  "nextCursor": null
}

Over MCP, list_clients calls this same route and returns this body.

Three ways in

One data model behind all three: the clients, projects and invoices your team already works in. API access, the MCP server and webhooks come with the Business plan.

REST API Business plan

JSON over HTTPS. A workspace API key or an OAuth token as the bearer; the workspace is in the path, and a record of another workspace is a 404.

  • An Idempotency-Key makes a retried write return the first result, never a second record.
  • Errors are RFC 9457 problem details with a stable code.
  • Every response carries the rate-limit headers; a spent budget answers 429 with Retry-After.
API quickstart
Create a client, safe to retry
curl -X POST "https://app.rokn.dev/api/v1/workspaces/atelier-nord/clients" \
  -H "Authorization: Bearer $ROKN_API_KEY" \
  -H "Idempotency-Key: import-hallberg-2026-11" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Hallberg Studio", "type": "company" }'

MCP server Business plan

Claude or any MCP client works in your workspace through more than 150 tools. Each tool calls one REST route, with that route’s scope check.

  • Add the server address; the client opens Rokn’s consent screen to choose the workspace and scopes. No API key.
  • A token never does more than the member’s role allows.
  • A draft stays a draft: sending an invoice is its own tool, and it can’t be undone.
Connect over MCP

Claude · connected to Roknworkspace: "atelier-nord"

ScopesClients: readInvoices: write

  1. You

    Draft an invoice for Hallberg Studio: 12 hours of design review at €85.

  2. list_clients

    { "workspace": "atelier-nord", "search": "Hallberg" }
  3. One client found: Hallberg Studio.

  4. create_draft_invoiceNeeds a scope this connection has

    {
      "workspace": "atelier-nord",
      "clientId": "k3v9q0w2f8h1m5r7t4y6u2pa",
      "lineItems": [
        { "description": "Design review", "quantity": 12, "unitPriceCents": 8500 }
      ]
    }
  5. Draft created, with no number yet. It reaches the client only when you send it.

Webhooks Business plan

Rokn POSTs a JSON event to your HTTPS endpoint, signed with that endpoint’s own secret.

  • A 2xx ends a delivery. Network errors, timeouts, 5xx, 408 and 429 are retried; any other 4xx stops the retries.
  • An endpoint receives only what the member who set it up may read, checked when the event is published and again at delivery.
Webhooks
One invoice.paid delivery, as your endpoint receives it
POST /webhooks/rokn HTTP/1.1Content-Type: application/jsonUser-Agent: Rokn-Webhooks/1X-Rokn-Event: invoice.paidX-Rokn-Signature: t=1763049600,v1=5d0c8e…e91a {  "id": "r2x7c4n9b1v6m3k8j5h0g2fq",  "name": "invoice.paid",  "occurredAt": "2026-11-13T15:20:00.000Z",  "organizationId": "c5n8m2b6v9x1z4l7k0j3h5gw",  "payload": {
    "invoiceId": "w4e7r1t9y3u6i0o2p5a8s1dz",
    "invoiceNumber": "INV-2026-014",
    "clientId": "k3v9q0w2f8h1m5r7t4y6u2pa",
    "amountPaidCents": 102000,
    "totalCents": 102000,
    "currency": "EUR"
  }}
  1. t Unix seconds, signed together with the body, so a captured request can’t be replayed under a new time.

  2. v1 Hex HMAC-SHA256 of t, a dot and the exact raw body, with the endpoint’s secret. Compare in constant time, and parse only after.

  3. X-Rokn-Event The event name, the same as the body’s name.

  4. id Deliveries can repeat: keep the IDs you have handled and skip a repeat.

Verify, then parse (Node.js)
import { createHmac, timingSafeEqual } from 'node:crypto'

const { t, v1 } = Object.fromEntries(
  req.headers['x-rokn-signature'].split(',').map((part) => part.split('=')),
)
const mac = createHmac('sha256', process.env.ROKN_WEBHOOK_SECRET)
  .update(`${t}.${rawBody}`)
  .digest('hex')
const valid = mac.length === v1.length && timingSafeEqual(Buffer.from(mac), Buffer.from(v1))

Scopes, area by area

Give an integration only what it needs. An OAuth token never does more than the member who authorized it; an API key acts with its creator’s current role.

clients:readclients:writeEvery area has a read and a write scope. Write covers read.

Clients and sales

  • clients
  • leads
  • quotes
  • communications
  • campaigns
  • calendar

Projects and time

  • projects
  • tasks
  • time_tracking
  • capacity
  • leave
  • utilization

Money

  • invoices
  • expenses
  • services
  • reports

Documents and support

  • documents
  • contracts
  • templates
  • tickets
  • assets
  • credentials

Workspace

  • org.settings
  • org.team
  • org.roles
  • trash
  • audit
  • notifications
  • customization

Integrations

  • api.keys
  • webhooks
  • code_hosts

mcp:tools and the sign-in scopes are for OAuth clients only: an API key never holds them. Scopes and permissions

Build with Rokn.

Start

Concepts

Resources

openapi.jsonOpenAPI 3.1

Every operation with its parameters, bodies and scope, and the payload of every webhook event, in one file. Fetching it needs no key.

Something you can’t find?

Talk to us