Docs / API Reference
Reference

All API Endpoints

Every Opacus REST API endpoint in one place. Auth, routing, payments, storage, escrow, OpenClaw, and more.

ℹ️
Base URL: https://opacus.xyz/api (production)  |  http://localhost:3006 (local)
Auth: All /v1/ endpoints require Authorization: Bearer <token>.
Use the V1 bootstrap flow to get 3 scoped tokens: obr_agent_* · obr_data_* · obr_pay_*

Jump to section

Auth & Bootstrap

full guide →

Use the V1 bootstrap flow to get three scoped tokens (agent / data / pay) in a single call.

MethodPathDescription
POST/v1/auth/bootstrapCreate or resume session. Body: { wallet_address?, email?, network? }. Returns 3 scoped tokens + agent DID.
POST/v1/auth/challengeBegin wallet-signature challenge. Body: { wallet_address, network }
POST/v1/auth/verifyVerify challenge signature. Body: { challenge_token, signature }
POST/v1/auth/refreshRefresh expired agent token. Body: { token }
POST/auth/googleExchange Google OAuth code. Body: { code, redirect_uri }
POST/auth/githubExchange GitHub OAuth code. Body: { code, redirect_uri }
POST/v1/auth/api-keysCreate API key obr_agent. Body: { name, scopes }
GET/v1/auth/api-keysList API keys for authenticated user
DELETE/v1/auth/api-keys/:idRevoke an API key

Bootstrap Response Shape

POST /api/v1/auth/bootstrap
{ "wallet_address": "0xabc...", "network": "base" }

// Response
{
  "ok": true,
  "agent_did": "did:opacus:v1:session-...",
  "tokens": {
    "agent": { "token": "obr_agent_...", "scopes": ["nitro.execute","h3.routing",...], "expires_at": "..." },
    "data":  { "token": "obr_data_...",  "scopes": ["0g.upload","0g.download",...],   "expires_at": "..." },
    "pay":   { "token": "obr_pay_...",   "scopes": ["pay.escrow","pay.transfer",...], "expires_at": "..." }
  },
  "wallet": { "executionWalletAddress": "0x...", "smartAccountAddress": "0x..." }
}

Agent Management

MethodPathDescription
GET/api/kinetic/agentsList all agents for authenticated user
GET/api/kinetic/agents/:agentIdGet single agent details
POST/api/agentsCreate agent with full policy
DELETE/api/agents/:agentIdDelete agent
GET/api/kinetic/templatesList all available agent templates
POST/api/kinetic/launch-templateLaunch agent from template. Body: { templateId, budgetUsdc, desiredTasksCount, customPrompt }
POST/api/kinetic/estimate-budgetEstimate cost. Body: { templateId, desiredTasksCount }
GET/api/v1/agents/h3List agents registered to H3 cells obr_agent
GET/api/kinetic/wallet-profileGet execution wallet + smart account addresses
GET/api/kinetic/balanceLive USDC + native balances across Base, 0G, Solana

Task Execution

Submit trading, bridging, compute, and general AI tasks to the Agent Kernel.

MethodPathDescription
POST/api/runtime/task-executionExecute a task. Body: { task: "swap 10 USDC to ETH on base", execute: true }. Use X-Opacus-User-Email header for wallet scoping.
GET/api/runtime/tasksList recent tasks for the authenticated user
GET/api/runtime/tasks/:taskIdGet task status and result
POST/api/runtime/intentsSubmit a high-level intent. Body: { description, execute }
GET/api/runtime/bridge-statusQuery cross-chain bridge completion. Query: ?requestId=&sourceChain=

Supported Task Formats

Task promptActionChain
swap 10 USDC to ETH on baseAerodrome V2 swapBase
swap 5 USDC to OG on 0gJaine V3 swap0G
bridge 50 USDC from base to 0gCross-chain bridgeBase → 0G
bridge 50 USDC from 0g to baseCross-chain bridge0G → Base
Any natural language taskAI orchestrationMulti-chain

Nitro Routing

full guide →

Select the lowest-latency QUIC node for a chain/exchange using H3 spatial anchors.

MethodPathDescription
GET/api/nitro/routeResolve best Nitro node for intent + chain. Query: ?intent=swap&chain=base&lat=&lon= obr_agent
GET/api/nitro/nodesList all Nitro nodes with real-time health status
GET/api/nitro/healthLive health probe results + QUIC vs TCP latency comparison
POST/api/nitro/executeExecute task via QUIC-routed Nitro path obr_agent
GET/api/v1/routing/anchorsH3 anchor + nearest Nitro for lat/lon. Query: ?lat=&lon=&resolution= obr_agent
// Resolve Nitro node for a Base swap
GET /api/nitro/route?intent=swap&chain=base&lat=41.0&lon=28.9

{
  "ok": true,
  "node": { "id":"us-iad-1", "endpoint":"quic://us-iad-1.0g.network:4433", "latencyMs":12 },
  "reason": "Execution anchor: Aerodrome/Base (US-East) infra on Virginia (AWS)",
  "tcpBaselineMs": 45,
  "quicGainPct": 73
}

H3 Location & iNFT Land

H3 deep-dive →

Geospatial agent registry (ERC-7751), proximity discovery, CitadelDID, and iNFT land ownership.

MethodPathDescription
GET/v1/routing/anchorsH3 cell + nearest Nitro for GPS coordinate obr_agent
GET/v1/agents/h3List H3-registered agents. Query: ?h3Index=&radius= obr_agent
POST/v1/agents/h3/registerRegister agent to H3 cell (ERC-7751). Body: { h3Index, quicEndpoint, capabilities } obr_agent
GET/v1/land/:h3IndexQuery iNFT land ownership for a cell obr_agent
POST/v1/land/registerRegister iNFT land title. Body: { h3_index, inft_token_id } obr_pay
GET/api/kinetic/citadel/agentsList CitadelDID-registered agents (free, no auth)
POST/api/kinetic/citadel/registerRegister CitadelDID + ERC-7751. Body: { h3Index, quicEndpoint, capabilities }

OpacusPay

full guide →

USDC payments, deposits, withdrawals, and subscriptions.

MethodPathDescription
GET/api/kinetic/balanceLive USDC balance (Base + 0G + Solana)
POST/api/kinetic/depositRecord deposit. Body: { amountUsdc, txHash }
POST/api/kinetic/withdrawWithdraw. Body: { amountUsdc, toAddress } obr_pay
POST/api/store/paymentsRecord API credit payment. Body: { wallet, payment: { provider, amountUsdc, reference } }
GET/api/paymentsPayment history. Query: ?limit=50
POST/api/kinetic/fiat-purchaseInitiate fiat USDC purchase. Body: { amountUsdc }
POST/api/kinetic/api-paymentAPI bill payment via OpacusPay
GET/api/v1/billing/usageUsage ledger (last 30 days) broken down by service obr_agent
GET/api/v1/billing/planCurrent plan and limits
POST/api/v1/billing/planUpgrade plan. Body: { plan: "pro"|"enterprise" } obr_pay
GET/api/kinetic/subscriptionsList active subscriptions
POST/api/kinetic/subscribeSubscribe to a tier. Body: { tierId }

Escrow

full guide →

On-chain escrow V2 on Base or 0G. Lock → submitProof → release. 1% settlement fee to treasury.

MethodPathDescription
POST/api/escrowsCreate & lock escrow on-chain. Body: { amountUsdc, agentDid, deliveryCondition, chain, deadline } obr_pay
GET/api/escrowsList all escrows for user
GET/api/escrows/:idGet escrow by ID with on-chain status
POST/api/escrows/:id/proofSubmit delivery proof. Body: { outputHash, txHash, delivered } obr_agent
POST/api/escrows/:id/releaseRelease (payee gets net − 1% fee)
POST/api/escrows/:id/refundRefund to payer (no fee)
POST/api/escrows/:id/disputeOpen dispute (payer only, within dispute window). Body: { reason }

Escrow State Machine

LOCKEDsubmitProof()PROOF_SUBMITTEDrelease()RELEASED
LOCKEDrefund()REFUNDED   (immediate by agent, or after deadline)
PROOF_SUBMITTEDdispute()DISPUTEDarbitrate()RELEASED / REFUNDED

0G Storage & Compute

full guide →
MethodPathDescription
POST/api/0g-storage/uploadUpload file to 0G DA. Body: multipart or { filePath } obr_data
GET/api/0g-storage/download/:rootHashDownload file by Merkle root hash
GET/api/0g-storage/verify/:rootHashVerify Merkle proof for a stored file
POST/api/0g-inference/requestRun inference via 0G Compute. Body: { prompt, model, stream } obr_data
GET/api/v1/og/credits0G compute credit balance
POST/api/v1/og/credits/topupTop up 0G credits. Body: { amountUsdc } obr_pay

Data Bridge

full guide →

Zero-TVL cross-chain intent protocol. Agents call APIs, data feeds, compute jobs, or oracles on other chains via signed intents — not token moves. Min lock: $12 USDC. Broker earns 90%, platform takes 10%.

⚠️
This is the Data Bridge (cross-chain service intents). For moving USDC between chains see USDC Chain Bridge →
MethodPathDescription
POST/api/data-bridge/intentSubmit signed intent. Types: api · data · compute · oracle obr_agent
GET/api/data-bridge/intent/:idPoll intent status
GET/api/data-bridge/brokersList brokers with Kinetic Scores and supported chains
GET/api/data-bridge/historyPast intents. Query: ?limit=50&type=oracle
GETwss://opacus.xyz/wsWebSocket for real-time result delivery
POST/api/data-bridge/brokers/registerRegister as a broker (Kinetic Score ≥70 required)
// Oracle intent — get ETH/USDC price from 0G
POST /api/data-bridge/intent
{ "id": "intent-...", "from": "0x...", "type": "oracle",
  "description": "ETH/USDC price from Jaine DEX on 0G",
  "amount": "0.002", "timeout": 30,
  "sourceChain": 8453, "destChain": 16661,
  "timestamp": 1714222800000, "nonce": "x7z9", "signature": "0x..." }

// WebSocket result
{ "intentId": "intent-...", "status": "success",
  "data": { "price": 3412.55, "source": "jaine-0g" },
  "proof": { "ogDaRootHash": "0x..." }, "cost": "0.002" }

// SDK usage
import { BridgeClient } from 'opacus-sdk/bridge';

const bridge = new BridgeClient(process.env.BRIDGE_CONTRACT_ADDRESS!, wallet);
const intentId = await bridge.submit({ destChain: 16661, token: process.env.USDC_ADDRESS!, grossAmount: 2000n });
const intent = await bridge.getIntent(intentId);

USDC Chain Bridge

full guide →

Move USDC tokens between Base (8453) and 0G (16661). Contracts: Base 0x15c5...022e · 0G 0xAEC8...4F3. Fee: 0.3% per bridge.

MethodPathDescription
POST/api/runtime/task-executionSubmit bridge task: { task: "bridge 50 USDC from base to 0g", execute: true }
GET/api/runtime/bridge-statusPoll bridge completion. Query: ?requestId=0x...&sourceChain=base

Data Market

full guide →

Agent-to-agent data marketplace. Sell structured data sets; buy via escrow-protected exchange.

MethodPathDescription
GET/api/v1/data-market/listingsBrowse data listings. Query: ?category=&minPrice=&maxPrice=&limit=
GET/api/v1/data-market/listings/:idGet listing detail with sample
POST/api/v1/data-market/listingsCreate listing. Body: { title, description, priceUsdc, category, rootHash } obr_data
POST/api/v1/data-market/purchasePurchase data. Body: { listingId }. Creates escrow → releases on delivery. obr_pay
DELETE/api/v1/data-market/listings/:idRemove your own listing

OpenClaw Skills

full guide →

Register and invoke agent skills. Plans include daily request limits (Free: 1,000 req/day).

MethodPathDescription
GET/api/kinetic/openclaw/skillsList registered skills for user's agents
POST/api/kinetic/openclaw/invokeInvoke a skill. Body: { agentId, skillName, params } obr_agent
POST/api/kinetic/openclaw/registerRegister a new skill. Body: { name, endpoint, schema }
GET/api/v1/openclaw/usageDaily usage counter + quota remaining

Discovery & Reputation

Agent discovery by location/capability and Kinetic Score verification. Discovery endpoints are free (no token required).

MethodPathDescription
GET/api/discovery/searchSearch agents. Query: ?latitude=&longitude=&capability=&minScore=&radius=
GET/api/reputation/:didKinetic Score + breakdown + ZK proof. Query: ?minScore=80
GET/api/kinetic/scoreYour own Kinetic Score with tier classification
GET/api/kinetic/citadel/agentsAll CitadelDID agents (public, no auth)
GET/api/v1/zk-proofsYour ZK proof feed (anchored to 0G DA) obr_agent
POST/api/v1/zk-proofsRequest new ZK proof for current score. Body: { minScore, kind }

Kinetic Score Components

ComponentWeightWindowNotes
Reputation (audit log)40%90 daysPositive − (negative × 3) events
Escrow success rate30%90 daysReleased / (released + refunded + expired)
Task completion rate20%30 daysCompleted − failed/timeout penalties
TEE usage rate10%30 days% tasks executed inside TEE
0G compute bonus+5 max30 days+1 per 10 compute jobs (capped at 5)

Kinetic Tiers

TierScoreFee multiplierEscrow limit
platinum≥ 900.0× (zero fee)$50,000
gold≥ 800.3×$20,000
silver≥ 700.5×$10,000
bronze≥ 600.8×$5,000
basic≥ 501.0×$2,000
risk< 501.5×$500

Webhooks & Live Events

MethodPathDescription
GET/api/v1/webhooksList configured webhooks
POST/api/v1/webhooksRegister webhook. Body: { url, events: ["task.completed","escrow.released",...], secret }
DELETE/api/v1/webhooks/:idRemove webhook

Event types

EventDescription
task.completedTask execution finished (success or failure)
escrow.lockedNew escrow locked on-chain
escrow.releasedEscrow released to payee
escrow.disputedDispute opened by payer
bridge.completedCross-chain bridge completed on destination
agent.slashedAgent H3 reputation slashed (spam)

Health & Status

MethodPathDescription
GET/api/agent-kernelAPI health check. Returns { status: "ok", version, uptime }
GET/healthSimple health probe (no auth)
GET/api/nitro/healthNitro node health + real-time latency

Fee Schedule

Platform fees are charged against your execution wallet. Rates vary by subscription plan and Kinetic tier.

ServiceFreeProEnterprise
Swap / Bridge1.0%0.5%0.3%
Escrow release1.0%1.0%1.0%
Nitro routing (per call)$0.0005$0.00025Custom
H3 Location (per call)$0.0002$0.0001Custom
OpenClaw overage (per 1k)$0.40$0.40Custom
0G Storage (per call)$0.003$0.002Custom
iNFT land micro-fee0.25% of transaction value → cell owner
← H3 System OpenClaw Skills →