Skip to main content

API reference

The canonical API spec is the OpenAPI 3.1 document shipped with the project. It defines all paths, request/response schemas, and error shapes.

Base URL

  • Production: https://api.1claw.xyz
  • Dashboard proxy: https://1claw.xyz/api (proxies to the same API)

All endpoints are under /v1.


Public (no auth)

MethodPathDescription
GET/v1/healthService health
GET/v1/health/hsmHSM connectivity
GET/v1/share/:share_idAccess a shared secret (checks expiry + access count)

Authentication

MethodPathDescription
POST/v1/auth/signupSelf-service signup (email + password) → JWT
POST/v1/auth/tokenEmail/password → JWT
POST/v1/auth/agent-tokenAgent ID + API key → JWT
POST/v1/auth/api-key-tokenPersonal API key → JWT
POST/v1/auth/googleGoogle id_token → JWT
DELETE/v1/auth/tokenRevoke token
POST/v1/auth/change-passwordChange password

Account Management

MethodPathDescription
GET/v1/auth/meGet current user profile
PATCH/v1/auth/meUpdate profile (display name, marketing opt-in)
DELETE/v1/auth/meDelete account and all associated data

MFA (Two-Factor Authentication)

MethodPathDescription
GET/v1/auth/mfa/statusCheck MFA enrollment status
POST/v1/auth/mfa/setupBegin TOTP MFA enrollment
POST/v1/auth/mfa/verify-setupVerify TOTP code to complete setup
POST/v1/auth/mfa/verifyVerify MFA code during login (public)
DELETE/v1/auth/mfaDisable MFA (requires code or password)

Device Authorization (CLI Login)

MethodPathDescription
POST/v1/auth/device/codeRequest device authorization code
POST/v1/auth/device/tokenPoll for device authorization token
GET/v1/auth/device/code/:user_codeCheck device code status (public)
POST/v1/auth/device/approveApprove CLI device login
POST/v1/auth/device/denyDeny CLI device login

Personal API Keys

MethodPathDescription
POST/v1/auth/api-keysCreate API key
GET/v1/auth/api-keysList API keys
DELETE/v1/auth/api-keys/:key_idRevoke API key

Vaults

MethodPathDescription
POST/v1/vaultsCreate vault
GET/v1/vaultsList vaults
GET/v1/vaults/:vault_idGet vault
DELETE/v1/vaults/:vault_idDelete vault

CMEK (Customer-Managed Encryption Keys)

MethodPathDescription
POST/v1/vaults/:vault_id/cmekEnable CMEK on a vault
DELETE/v1/vaults/:vault_id/cmekDisable CMEK on a vault
POST/v1/vaults/:vault_id/cmek-rotateStart CMEK key rotation job
GET/v1/vaults/:vault_id/cmek-rotate/:job_idGet rotation job status

Secrets

MethodPathDescription
GET/v1/vaults/:vault_id/secretsList secrets (metadata only)
PUT/v1/vaults/:vault_id/secrets/*pathCreate or update secret
GET/v1/vaults/:vault_id/secrets/*pathGet secret value (decrypted)
DELETE/v1/vaults/:vault_id/secrets/*pathSoft-delete secret

Policies

MethodPathDescription
POST/v1/vaults/:vault_id/policiesCreate policy
GET/v1/vaults/:vault_id/policiesList policies
PUT/v1/vaults/:vault_id/policies/:policy_idUpdate policy
DELETE/v1/vaults/:vault_id/policies/:policy_idDelete policy

Agent Self-Enrollment (Public)

MethodPathDescription
POST/v1/agents/enrollSelf-enroll an agent; credentials emailed to human (no auth required)

Agents

MethodPathDescription
POST/v1/agentsRegister agent
GET/v1/agentsList agents
GET/v1/agents/meGet calling agent's own profile (includes created_by)
GET/v1/agents/:agent_idGet agent
PATCH/v1/agents/:agent_idUpdate agent (name, description, intents_api_enabled)
DELETE/v1/agents/:agent_idDeactivate agent
POST/v1/agents/:agent_id/rotate-keyRotate agent API key

Sharing

MethodPathDescription
POST/v1/secrets/:secret_id/shareCreate share (creator, user, agent, external_email, anyone_with_link)
GET/v1/shares/outboundList shares you created
GET/v1/shares/inboundList shares sent to you
POST/v1/shares/:share_id/acceptAccept an inbound share
POST/v1/shares/:share_id/declineDecline an inbound share
DELETE/v1/share/:share_idRevoke share (creator only)

Chains (public, no auth)

MethodPathDescription
GET/v1/chainsList supported blockchain chains
GET/v1/chains/:identifierGet chain by ID or chain_id

Transactions (Intents API)

Requires intents_api_enabled: true on the agent. When enabled, the agent is also blocked from reading private_key and ssh_key type secrets through the standard secrets endpoint — it must use the proxy to sign transactions.

MethodPathDescription
POST/v1/agents/:agent_id/transactionsSubmit a transaction (supports simulate_first flag)
GET/v1/agents/:agent_id/transactionsList agent transactions
GET/v1/agents/:agent_id/transactions/:tx_idGet transaction details
POST/v1/agents/:agent_id/transactions/simulateSimulate a transaction via Tenderly (no signing)
POST/v1/agents/:agent_id/transactions/simulate-bundleSimulate a bundle of sequential transactions (approve + swap)

Billing & Usage

MethodPathDescription
GET/v1/billing/usageUsage summary (current period)
GET/v1/billing/historyUsage history

Billing V2: Subscriptions & Credits

MethodPathDescription
POST/v1/billing/subscribeStart subscription checkout (Stripe)
POST/v1/billing/portalOpen Stripe customer portal
GET/v1/billing/subscriptionFull subscription + usage + credits summary
POST/v1/billing/credits/topupStart credit top-up checkout (Stripe)
GET/v1/billing/credits/balanceCredit balance + expiring credits
GET/v1/billing/credits/transactionsPaginated credit transaction ledger
PATCH/v1/billing/overage-methodToggle overage method (credits or x402)
POST/v1/billing/webhooksStripe webhook handler (no auth — signature verified)

Audit

MethodPathDescription
GET/v1/audit/eventsQuery audit events

Organization

MethodPathDescription
GET/v1/org/membersList org members
POST/v1/org/inviteInvite member by email
PATCH/v1/org/members/:user_idUpdate member role
DELETE/v1/org/members/:user_idRemove member

Security (IP Rules)

MethodPathDescription
GET/v1/security/ip-rulesList IP allow/block rules
POST/v1/security/ip-rulesCreate IP rule
DELETE/v1/security/ip-rules/:rule_idDelete IP rule

Admin

Admin endpoints are for platform operators only. They are not documented in detail here; see your internal operations documentation.

MethodPathDescription
GET/v1/admin/settingsList all settings
PUT/v1/admin/settings/:keyUpdate a setting
DELETE/v1/admin/settings/:keyDelete a setting
GET/v1/admin/x402Get x402 payment config
PUT/v1/admin/x402Update x402 payment config
GET/v1/admin/usersList all users (super-admin)
DELETE/v1/admin/users/:user_idDelete user (cascade; platform admin only)
GET/v1/admin/chainsList chains (admin view)
POST/v1/admin/chainsCreate chain
PUT/v1/admin/chains/:chain_idUpdate chain
DELETE/v1/admin/chains/:chain_idDelete chain
GET/v1/admin/orgs/:org_id/limitsGet org limits
PUT/v1/admin/orgs/:org_id/limitsUpdate org limits
PUT/v1/admin/orgs/:org_id/billing-tierSet org billing tier (free/pro/business)

Notes

  • The API expects email and password for /v1/auth/token (not username).
  • Secret paths are wildcard routes — e.g. api-keys/openai, config/prod/db.
  • POST /v1/auth/refresh exists but returns 400 with "Refresh tokens not yet implemented". Use token issuance (e.g. POST /v1/auth/token or POST /v1/auth/agent-token) instead.
  • Request processing order (rate limit, auth, billing, handler) and how to interpret 401, 402, 403, 429: see Request pipeline.
  • Intents API routes additionally require the intents_api_enabled claim in the JWT.
  • See Authentication for details on obtaining JWTs.