Skip to content

Developer API

The developer API lets you access the platform programmatically using a scoped API token.

https://api.prettycode.dev

Every endpoint in this reference is versioned under /v1 — for example, GET /api/v1/me.

Requests authenticate with a bearer token you generate from your dashboard. Send it on every request:

Authorization: Bearer YOUR_TOKEN

See Authentication for how to create a token and what each scope grants.

Your organization’s plan must include API access. If it doesn’t, the API responds with 403 Forbidden.

The API accepts up to 120 requests per minute for each organization by default. Every token of an organization shares that budget, so creating another token doesn’t raise it. Tokens have no monthly cap.

A request over the limit gets 429 Too Many Requests with a Retry-After header — the number of seconds to wait before sending the next one. The JSON body carries the same number as retry_after:

{ "message": "Too many attempts. Please try again in 42 seconds.", "errors": [], "retry_after": 42 }

Wait that long, then retry. If your integration keeps hitting the limit, spread its requests out or cache what it reads. Need a higher limit? Contact us.

Errors return the matching HTTP status code and a JSON body:

{ "message": "A human-readable description of what went wrong." }
StatusMeaning
401 UnauthorizedMissing or invalid token.
403 ForbiddenPlan doesn’t qualify, or the token lacks the required scope.
404 Not FoundThe requested resource doesn’t exist.
429 Too Many RequestsToo many requests this minute — wait the seconds in the Retry-After header.

Endpoints are grouped by the resource they act on.