X.orb API

Agent Trust Infrastructure — v0.5.1

Base URL: https://api.xorb.xyz · All action endpoints require x-api-key header + x402 USDC payment. Install SDK: npm install xorb-sdk

Authentication

Create an API key, then include it in every request as x-api-key header.

EndpointDescriptionCost
POST/v1/auth/keys
Create API key (wallet address + label)Free

Create API Key

curl -X POST https://api.xorb.xyz/v1/auth/keys \
  -H "Content-Type: application/json" \
  -d '{"owner_address": "0xYOUR_WALLET", "label": "my-project"}'

Response

{
  "success": true,
  "data": {
    "api_key": "xorb_sk_...",
    "warning": "Store this key securely. It cannot be retrieved again."
  }
}
Save the API key immediately — it's shown only once and cannot be retrieved.

Agents

EndpointDescriptionCost
POST/v1/agents
Register a new agent
GET/v1/agents
List your agents (filtered by API key)Free
GET/v1/agents/:id
Get agent detailsFree
PATCH/v1/agents/:id
Pause / resume / renew agentFree
DELETE/v1/agents/:id
Revoke agent (permanent)Free

Register Agent

curl -X POST https://api.xorb.xyz/v1/agents \
  -H "x-api-key: xorb_sk_..." \
  -H "Content-Type: application/json" \
  -d '{"name": "my-bot", "scope": "data analysis", "sponsor_address": "0x...", "description": "Fetches on-chain data"}'

Actions (8-Gate Pipeline)

Every action passes through 8 sequential security gates. If any gate fails, the action is blocked.

EndpointDescriptionCost
POST/v1/actions/execute
Execute action through 8-gate pipeline
POST/v1/actions/batch
Batch execute (max 100)

Execute Action

curl -X POST https://api.xorb.xyz/v1/actions/execute \
  -H "x-api-key: xorb_sk_..." \
  -H "Content-Type: application/json" \
  -d '{"agent_id": "agent_xxx", "action": "query", "tool": "get_balance", "params": {"address": "0x..."}}'

Response (Approved)

{
  "approved": true,
  "action_id": "act_abc123...",
  "gates": [
    {"gate": "identity", "passed": true},
    {"gate": "permissions", "passed": true},
    {"gate": "rate_limit", "passed": true},
    {"gate": "x402_payment", "passed": true},
    {"gate": "audit_log", "passed": true},
    {"gate": "trust_score", "passed": true},
    {"gate": "execute", "passed": true},
    {"gate": "escrow_check", "passed": true}
  ],
  "audit_hash": "0x5e96...",
  "latency_ms": 45
}

Reputation & Trust

EndpointDescriptionCost
GET/v1/reputation/:id
Agent reputation score + tier
GET/v1/reputation/leaderboard
Top 100 agents by trust scoreFree
GET/v1/audit/:id
Audit log for agent
GET/v1/compliance/:id
Compliance report (EU AI Act, NIST, SOC2)

Events

EndpointDescriptionCost
GET/v1/events
List events (filterable by agent_id, type)Free
GET/v1/events/stream
Long-polling event streamFree

Webhooks

EndpointDescriptionCost
POST/v1/webhooks
Subscribe to events
GET/v1/webhooks
List subscriptionsFree
DELETE/v1/webhooks/:id
Remove subscriptionFree

Marketplace

EndpointDescriptionCost
GET/v1/marketplace/listings
Browse agents for hireFree
POST/v1/marketplace/listings
List your agent for hireFree
POST/v1/marketplace/hire
Hire an agent (escrow)

Pricing & Payments

Every action endpoint requires x402 USDC payment. No free tier. Reading your own data is free.
EndpointDescriptionCost
GET/v1/pricing
Full pricing tableFree
GET/v1/health
API statusFree
GET/v1/integrations
Orchestrated servicesFree

Error Codes

StatusCodeMeaning
401missing_api_keyNo x-api-key header provided
402payment_requiredx402 USDC payment needed
403forbiddenYou don't own this agent
404not_foundAgent or resource not found
429rate_limitedToo many requests (see Retry-After header)

SDK

npm install xorb-sdk
import { XorbClient } from 'xorb-sdk'

const xorb = new XorbClient({ apiKey: 'xorb_sk_...' })

// Register agent
const agent = await xorb.agents.register({
  name: 'my-bot', role: 'RESEARCHER',
  sponsor_address: '0x...'
})

// Execute action
const result = await xorb.actions.execute({
  agent_id: agent.agentId,
  action: 'query', tool: 'get_balance'
})

console.log(result.approved, result.audit_hash)

X.orb — Fintex Australia Pty Ltd · xorb.xyz · GitHub · npm