API docs

Every write endpoint returns an unsigned payload. Nothing accepts a private key. Your SDK or agent host signs locally.

Risks and limits

  • Each venue liquidates independently.
  • Legging risk is yours.
  • A trade-only key can still trade and liquidate its account.
  • Not available in refused regions.
  • Receipts prove what Capstan did, not venue fill quality.

REST (Capstan API 1.0.0)

Non-custodial multi-venue perps API. Every write endpoint returns an unsigned payload; nothing accepts a private key. Each venue liquidates independently.

Base URL: https://api.get-capstan.com/v1

REST endpoints
MethodPathWhat it doesAuthPrice
GET/v1/accountYour plan, limits and creditsAPI keyFree
POST/v1/account/keysCreate a Capstan API key for your wallet (shown once)Owner signatureFree
POST/v1/agents/policyStore an agent policy signed by your main walletOwner signatureFree
POST/v1/agents/{agentRef}/killStop an agent on the Capstan relay and get the venue revocation steps for your walletOwner signatureFree
GET/v1/alerts/webhooksYour alert webhooks and their stateOwner signatureFree
POST/v1/alerts/webhooksRegister a webhook for your alerts: liquidation distance, unhedged spread plans, approval expiry, policy refusalsOwner signatureFree
DELETE/v1/alerts/webhooks/{id}Remove one of your alert webhooksOwner signatureFree
GET/v1/creditsYour premium-call credit balanceAPI keyFree
POST/v1/credits/topup/100Buy $100 of premium-call creditsx402 payment$100
POST/v1/credits/topup/20Buy $20 of premium-call creditsx402 payment$20
POST/v1/credits/topup/5Buy $5 of premium-call creditsx402 payment$5
GET/v1/eligibilityWhether orders on a venue are available from your regionNoneFree
GET/v1/fundingLatest observed funding per venue for an asset, data-only venues includedNoneFree
GET/v1/funding/forecastNext 8 funding settlements per market (an estimate from observed rates)x402 payment$0.01
GET/v1/healthLiveness checkNoneFree
GET/v1/history/fundingFunding history rows, $0.05 per 1,000 rows, pages of 10,000x402 payment$0.05
GET/v1/marketsMarkets across venues, each with its own contract details and whether it is executableNoneFree
GET/v1/markets/{id}/bookOrder book for one market (top levels, newest cached)NoneFree
POST/v1/onboarding/buildBuild the onboarding steps your main wallet signs (agent approval, builder fee approval, declaration)Owner signature or API keyFree
GET/v1/onboarding/preflightWhat onboarding on a venue needs for this wallet: free agent slots, builder approval, current agentsNoneFree
POST/v1/onboarding/submitSubmit the signed onboarding steps; the venue records the agent and the builder approvalOwner signature or API keyFree
GET/v1/openapi.jsonThe OpenAPI 3.1 document for this APINoneFree
POST/v1/orders/buildBuild an unsigned order payload for your delegated key to signOwner signature or API keyFree
POST/v1/orders/cancel/buildBuild an unsigned cancel payloadOwner signature or API keyFree
POST/v1/orders/close-all/buildBuild reduce-only close payloads for every position of your active agentsOwner signature or API keyFree
POST/v1/orders/submitSubmit a signed envelope through the relayOwner signature or API keyFree
GET/v1/positionsYour open positions on each venue, each with its own liquidation priceOwner signatureFree
GET/v1/quoteQuote every venue side by side (query form)NoneFree
POST/v1/quoteQuote every venue side by side: venue fee, builder fee, slippage and observed fundingNoneFree
GET/v1/receiptsYour receipts, newest first (needs your signature)Owner signatureFree
POST/v1/receipts/claimClaim the receipt for an order you sent to the venue directlyOwner signature or API keyFree
GET/v1/receipts/{id}One receipt by idNoneFree
GET/v1/receipts/{id}/proofMerkle proof of a receipt in its hourly anchored rootNoneFree
GET/v1/receipts/{id}/verifyFull check of a receipt: signature, leaf, proof and the on-chain rootNoneFree
GET/v1/riskYour risk view: every venue's account and liquidation price on its ownOwner signatureFree
POST/v1/risk/ingestIngest an Aster account read signed by your own agent keyOwner signatureFree
GET/v1/risk/liq-heatmapLiquidation heatmap per venue for one asset, from public account samplesx402 payment$0.02
POST/v1/risk/snapshotRisk snapshot for any addresses from public venue reads (Aster needs the owner's own signed read)x402 payment$0.01
POST/v1/spreads/planPlan a funding-rate spread trade (at-risk; legging risk is yours). The plan must be acknowledged before it runs on your sideOwner signatureFree
GET/v1/spreads/scanFunding-rate spread trades (at-risk) across reviewed equivalent markets, with cost, breakeven and both liquidation pricesx402 payment$0.02
GET/v1/spreads/{id}A spread plan and its eventsOwner signatureFree
POST/v1/spreads/{id}/ackAcknowledge a spread plan with your wallet or your agent keyOwner signatureFree
POST/v1/spreads/{id}/eventsReport a step of a spread plan run on your sideOwner signatureFree
GET/v1/venuesVenue capabilities: execution, key type, delegation, builder fee rail and collateralNoneFree

MCP tools

Streamable HTTP. Read only unless a write tool is called. No tool accepts a key: builds return unsigned payloads that your host signs with the SDK.

MCP tools
ToolInputOutput
capstan_markets{ venue?, asset?, executableOnly? }{ markets: Market[] }
capstan_funding{ asset }FundingSnapshot[] for every venue, data-only venues included
capstan_quoteQuoteRequest (canonicalAsset or marketIds (10 at most), side, sizeBase or notionalUsd, leverage, holdHours, orderType, limitPx?, owner?)RouteQuote with a per-venue cost table
capstan_onboarding_build{ venue, owner, agentAddress or lighterPubKey, builderMaxBps?, policy? }OnboardingBundle: the steps your main wallet signs, one plain sentence each
capstan_build_order{ owner, agentRef, intent, mode }UnsignedVenuePayload with its preview (sign it locally)
capstan_submit{ buildId, signedEnvelope } only{ order, receiptId }
capstan_cancel_build{ owner, agentRef, venueOrderId }UnsignedVenuePayload
capstan_positions{ owner, venues?, ownerRead }your positions per venue, each with its own liquidation price
capstan_risk{ owner, ownerRead } or { addresses }RiskView per venue; free for your own, paid (x402, $0.01) for other addresses
capstan_spread_scan{ asset?, minBreakevenHours? }ranked pairs (x402, $0.02)
capstan_spread_plan{ owner, equivalenceId, sizeBase, leverage, hedgeFailurePolicy }SpreadPlan with riskLabel and ackRequired: true
capstan_plan_status{ planId }the plan and its events
capstan_set_policy{ policy, ownerSig }{ policyId }
capstan_kill{ agentRef, sig, message, closeAll? }relayBlocked: true, the venue revocation steps and, when asked, reduce-only close payloads
capstan_get_receipt{ receiptId }Receipt
capstan_verify_receipt{ receiptId } or { receipt }{ valid, checks } (signature, leaf, proof, on-chain root)
capstan_eligibility{ venue? }{ allowed, code }; when refused the text is "Not available in your region."
✦

Coming soon

We’re getting this corner of Capstan ready. Check back soon!