All requests below will use this key. Your API key is sent directly to api.cueapi.ai and never stored by the docs site.

API Overview

Base URL, authentication, rate limits, and error format.

Base URL

https://api.cueapi.ai

All API endpoints are prefixed with /v1/ except health checks.

Authentication

Most endpoints require a Bearer token in the Authorization header:

Authorization: Bearer cue_sk_YOUR_API_KEY

Endpoints that do not require authentication:

  • GET /health — system diagnostics
  • GET /status — lightweight health check
  • POST /v1/auth/device-code — create device code
  • POST /v1/auth/device-code/poll — poll device code
  • POST /v1/auth/device-code/submit-email — submit email
  • GET /v1/auth/verify — magic link verification

Rate limits

Requests are rate-limited per plan using a sliding window:

PlanLimit
Free60 req/min
Pro200 req/min
Scale500 req/min

Rate limit headers are included on every response:

X-RateLimit-Limit: 60
X-RateLimit-Remaining: 58
Retry-After: 12          (only on 429)

When exceeded, the API returns 429 Too Many Requests.

Error format

All errors follow a consistent JSON structure:

json
{
  "error": {
    "code": "cue_not_found",
    "message": "Cue not found: cue_abc123def456",
    "status": 404
  }
}

See Error Codes for the complete list.

Request limits

  • Body size: 2 MB maximum (returns 413 Payload Too Large)
  • Webhook timeout: 30 seconds
  • Outcome metadata: 10 KB maximum

Endpoints

Cues

MethodPathDescription
POST/v1/cuesCreate a cue
GET/v1/cuesList cues
GET/v1/cues/{cue_id}Get cue detail
PATCH/v1/cues/{cue_id}Update cue
DELETE/v1/cues/{cue_id}Delete cue

Executions

MethodPathDescription
GET/v1/executions/claimableList claimable (worker)
POST/v1/executions/{id}/claimClaim execution (worker)
POST/v1/executions/{id}/outcomeReport outcome

Auth

MethodPathDescription
GET/v1/auth/meCurrent user info
POST/v1/auth/key/regenerateRegenerate API key
GET/v1/auth/webhook-secretGet webhook secret
POST/v1/auth/webhook-secret/regenerateRotate webhook secret

Billing

MethodPathDescription
POST/v1/billing/checkoutStart Stripe checkout
POST/v1/billing/portalOpen billing portal

Usage

MethodPathDescription
GET/v1/usageUsage statistics

Worker

MethodPathDescription
POST/v1/worker/heartbeatWorker liveness

Health

MethodPathDescription
GET/healthFull diagnostics
GET/statusSimple status