Agents API
Agents are autonomous goal-driven workers: you set a goal + budget + deadline, and the agent plans and executes a multi-step strategy. Approvals can be required for risky actions.
Endpoints
| Method | Path | Description |
|---|---|---|
| GET | `/api/v1/agents` | List with aggregate metrics |
| POST | `/api/v1/agents` | Create |
| GET | `/api/v1/agents/:id` | Detail (includes recent logs + pending approvals) |
| POST | `/api/v1/agents/:id/start` | Start execution |
| POST | `/api/v1/agents/:id/pause` | Pause |
| POST | `/api/v1/agents/:id/stop` | Stop |
| GET | `/api/v1/agents/:id/log` | Execution log (paginated) |
| DELETE | `/api/v1/agents/:id` | Delete |
Approvals
| Method | Path | Description |
|---|---|---|
| GET | `/api/v1/agents/:id/approvals` | Pending approvals |
| POST | `/api/v1/agents/:id/approvals/:approvalId/approve` | Approve a step |
| POST | `/api/v1/agents/:id/approvals/:approvalId/reject` | Reject |
Templates
| Method | Path | Description |
|---|---|---|
| GET | `/api/v1/agents/templates` | List templates |
| POST | `/api/v1/agents/templates` | Create |
Every response uses the standard envelope:
{
"success": true,
"data": { /* resource or array */ },
"meta": { "total": 100, "cursor": "...", "hasMore": true },
"error": { "code": "ERROR_CODE", "message": "Human readable" }
}error is omitted on success; meta is omitted when not paginating.
Rate Limits
Subject to the standard 200 req/min/tenant authenticated limit. See [Rate Limits](/docs/api-reference/rate-limits) for full details and the per-endpoint overrides.