REST API Reference
Nooterra exposes a REST API for programmatic access to the platform. The API follows the OpenAPI 3.0 specification and uses JSON-RPC conventions where applicable.OpenAPI Specification
The full OpenAPI spec is generated bysrc/api/openapi.js via the buildOpenApiSpec() function. It includes complete request/response schemas, authentication requirements, and error codes.
Base URL
The API base URL is configurable. The spec accepts an optionalbaseUrl parameter.
Required Headers
All API requests require the following headers:| Header | Required | Description |
|---|---|---|
x-proxy-tenant-id | Yes | Tenant scope for the request (e.g., tenant_default) |
x-nooterra-protocol | Yes | Client protocol version (major.minor). Required in production. |
x-request-id | No | Optional request ID, echoed in responses |
x-idempotency-key | Varies | Idempotency key. Required on mutation endpoints; optional on reads. If reused, request body must match. |
Endpoints
The following endpoint groups are defined in the OpenAPI spec:Action Intents
| Method | Path | Description |
|---|---|---|
| — | /v1/action-intents | Action intent operations |
| — | /v1/action-intents/{actionIntentId} | Single action intent |
| — | /v1/action-intents/{actionIntentId}/approval-requests | Approval requests for an action intent |
Approvals
| Method | Path | Description |
|---|---|---|
| — | /v1/approval-requests/{requestId} | Single approval request |
| — | /v1/approval-requests/{requestId}/decisions | Decisions on an approval request |
Agent Resolution
| Method | Path | Description |
|---|---|---|
| — | /v1/public/agents/resolve | Resolve agent identities |
Execution Grants
| Method | Path | Description |
|---|---|---|
| — | /v1/execution-grants/{executionGrantId} | Single execution grant |
| — | /v1/execution-grants/{executionGrantId}/revoke | Revoke an execution grant |
| — | /v1/execution-grants/{executionGrantId}/evidence | Evidence for an execution grant |
| — | /v1/execution-grants/{executionGrantId}/finalize | Finalize an execution grant |
Receipts
| Method | Path | Description |
|---|---|---|
| — | /v1/receipts/{receiptId} | Retrieve an execution receipt |
Disputes
| Method | Path | Description |
|---|---|---|
| — | /v1/disputes | List/create disputes |
| — | /v1/disputes/{disputeId} | Single dispute |
Integrations
| Method | Path | Description |
|---|---|---|
| — | /v1/integrations/install | Install an integration |
| — | /v1/integrations/{hostId}/revoke | Revoke an integration |
Federation
| Method | Path | Description |
|---|---|---|
| — | /v1/federation/invoke | Invoke a federated action |
| — | /v1/federation/result | Get federated action result |
Analytics & Trust
| Method | Path | Description |
|---|---|---|
| — | /v1/tenants/{tenantId}/analytics | Tenant analytics |
| — | /v1/tenants/{tenantId}/trust-graph | Tenant trust graph |
| — | /v1/tenants/{tenantId}/trust-graph/snapshots | Trust graph snapshots |
| — | /v1/tenants/{tenantId}/trust-graph/diff | Trust graph diff |
Key Schema Types
The API defines several versioned schema types:AuthorityEnvelope.v1— Defines the full authority context for an agent action: actor, principal, purpose, capabilities, data classes, side effects, spend envelope, delegation rights, risk class, reversibility, and evidence requirements.ApprovalRequest.v1— Links an action to an authority envelope for human approval.NooterraHumanApprovalDecision.v1— Records a human’s approve/deny decision with binding context.X402ExecutionProof.v1— Cryptographic execution proof (supports groth16, plonk, stark protocols).
Error Handling
The API uses federation-aware error codes (defined insrc/federation/error-codes.js). Standard HTTP status codes apply, with structured error responses:
SDK
The@nooterra/api-sdk package (packages/api-sdk/) provides a TypeScript/JavaScript client:
NooterraClient— main API clientNooterraHttpParityAdapter— HTTP parity adapterNooterraMcpParityAdapter— MCP parity adapterfetchWithNooterraAutopay— x402 autopay fetch wrapperverifyNooterraWebhookSignature— webhook signature verificationverifyNooterraWebhook— Express middleware for webhook verification
Webhook Verification
Note
This is a reference overview. The full OpenAPI specification with complete request/response schemas, HTTP methods, and parameter details is generated programmatically bybuildOpenApiSpec() in src/api/openapi.js. Consult the generated spec for the authoritative, machine-readable API definition.