Capx
Products / API
Private betaThe Capx API is available to private beta participants. Join the waitlist for access.

REST API reference.

Every action you can do in the dashboard, you can do via API. Companies, agents, tasks, playbooks, approvals, costs. Fully programmable.

Base URL (private beta)https://api.capx.ai/v1
AuthenticationAuthorization: Bearer capx_sk_live_a1b2c3d4...

Endpoint catalog

0 endpoints across 5 resources. Standard REST conventions, predictable URL patterns, typed request and response schemas.

Companies

POST/v1/companiesCreate a new company from template or config
GET/v1/companiesList all companies with status and metrics
GET/v1/companies/:idGet detailed company status
PATCH/v1/companies/:idUpdate company configuration
DELETE/v1/companies/:idDestroy company and release resources

Agents

GET/v1/companies/:id/agentsList company agents with budget and status
POST/v1/companies/:id/agents/:role/wakeTrigger an immediate agent heartbeat
POST/v1/companies/:id/agents/:role/pausePause agent, preserving state
GET/v1/companies/:id/agents/:role/logsStream agent logs (SSE)

Tasks

GET/v1/companies/:id/tasksList tasks with status filters
POST/v1/approvals/:id/approveApprove a pending task
POST/v1/approvals/:id/rejectReject a task with feedback

Playbooks

POST/v1/playbooks/runExecute a playbook with typed inputs
GET/v1/playbooks/:id/runsList playbook run history
GET/v1/playbooksList available playbooks

Activity

GET/v1/activityQuery activity feed with filters
GET/v1/activity/streamReal-time SSE activity stream
GET/v1/costsCost breakdown by agent and period
POST/v1/webhooksRegister a webhook endpoint

Create a company

Full request and response for the create-company flow. Every endpoint follows the same envelope pattern.

RequestPOST
POST /v1/companies HTTP/1.1
Host: api.capx.ai
Authorization: Bearer capx_sk_live_...
Content-Type: application/json

{
  "name": "acme-marketing",
  "template": "saas-agency",
  "governance": {
    "spend_cap": 500,
    "approval_required": [
      "publish",
      "outbound-email"
    ],
    "kill_switch": true
  },
  "agents": [
    {
      "role": "strategist",
      "adapter": "claude",
      "model": "claude-sonnet-4-6",
      "budget": 200
    }
  ]
}
Response201
HTTP/1.1 201 Created
Content-Type: application/json
X-Request-Id: req_a1b2c3d4

{
  "success": true,
  "data": {
    "id": "co_m4k9x2",
    "name": "acme-marketing",
    "status": "provisioning",
    "agents": [
      {
        "role": "strategist",
        "status": "initializing",
        "adapter": "claude",
        "model": "claude-sonnet-4-6",
        "budget": 200,
        "used": 0
      }
    ],
    "governance": {
      "spend_cap": 500,
      "approval_required": ["publish", "outbound-email"],
      "kill_switch": true
    },
    "created_at": "2026-05-25T10:30:00Z",
    "url": "acme-marketing.capx.ai"
  },
  "meta": {
    "credits_used": 0,
    "credits_remaining": 9995,
    "request_id": "req_a1b2c3d4"
  }
}

Rate limits

Limits exposed via X-RateLimit-* headers on every response. Build adaptive clients.

TierRateBurstConcurrent
Starter60 req/min10 req/s5
Pro300 req/min50 req/s20
EnterpriseCustomCustomCustom

Error codes

Standard HTTP status codes. Every error includes a machine-readable code and human-readable message.

CodeNameDescription
400Bad RequestInvalid parameters. Response includes field-level errors.
401UnauthorizedMissing or invalid API key.
403ForbiddenKey lacks required scope for this operation.
404Not FoundResource does not exist or is not accessible.
409ConflictIdempotency key collision. Previous request still processing.
422Governance BlockAction blocked by governance policy.
429Rate LimitedToo many requests. Retry-After header included.
500Server ErrorUnexpected error. Include request_id when reporting.

Explore the API.

RESTful, typed, documented. Full OpenAPI 3.1 spec for client generation in any language.