API reference

Use it from your IDE, CI or services

The same agent that runs in the app is available over HTTP. Create an API key under API keys after your account is approved, then send it as a Bearer token.

Endpoints

POST/designStart a design, review, stack recommendation or interview. Returns 202 and a design id.
GET/designs/:idStatus, progress, estimated time left, and the finished document.
GET/designsList your saved designs.
POST/knowledgeSearch your uploaded library. Body: { query, limit }.

Modes: design, review, stack, interview.

1. Start a design

curl -X POST https://sda.corbetai.com/api/public/v1/design \
  -H "Authorization: Bearer sda_..." \
  -H "Content-Type: application/json" \
  -d '{ "prompt": "Design a multi-region feature flag service", "mode": "design" }'

# → 202 { "designId": "...", "jobId": "...", "pollUrl": "/api/public/v1/designs/..." }

2. Poll until ready

A full design document takes several minutes. Poll every few seconds.

curl https://sda.corbetai.com/api/public/v1/designs/<designId> \
  -H "Authorization: Bearer sda_..."

# → { "design": { "status": "running" | "ready" | "failed", "content": "..." },
#     "progress": { "percent": 40, "stage": "drafting", "remainingMs": 180000 } }

Or stream it live

curl -N -X POST https://sda.corbetai.com/api/public/v1/design \
  -H "Authorization: Bearer sda_..." \
  -H "Content-Type: application/json" \
  -d '{ "prompt": "Review this architecture: ...", "mode": "review", "stream": true }'

# Server-Sent Events: design.started → delta … → design.completed

Limits and errors

  • Each API key can run up to 3 requests at once; extra requests wait their turn.
  • 401: missing or revoked key. 403: account not approved yet. 400: invalid body.
  • Requests can be cancelled or resubmitted from the Request log in the app.