Quickstart
From zero to a paid deep decision in five minutes — free snapshot first, then x402 with USDC on Base.
Five minutes, two steps, zero accounts: a free market snapshot (no key, no wallet), then a paid deep decision settled with USDC on Base through the standard x402 flow.
GIVE YOUR AGENT CRYPTO INTELLIGENCE. Pay per decision with USDC. No account. No API key.
0. Requirements
- A shell with
curl— nothing else for step 1. - For the paid step: an Ethereum-style private key holding USDC on Base (the x402
exactscheme signs an EIP-3009transferWithAuthorization; you never create an account anywhere). - Node.js 22+ if you use the TypeScript SDK.
1. Free market snapshot (no key)
The market snapshot is the open-data carve-out — it is free, always, with no key:
curl https://api.tollbridge.app/v1/market/BTCResponse (shape; every field shown actually appears on the wire — values vary per call. The
timestamp/received_at fields are ISO-8601 with millisecond precision; state, probabilities,
confidence, horizon, and freshness are empty for the open data snapshot and carry values for
paid decisions; replace … with the server's actual numbers).
{
"data": {
"asset": "BTC",
"venue": "hyperliquid",
"quote": {
"price": 82094.5,
"bid": 82094,
"ask": 82095,
"mark": 82078,
"index": 82109.8,
"volume_24h": 1910574361.77
},
"derived": { "mid": 82094.5, "spread_bps": 0.12 },
"provenance": {
"source": "hyperliquid.rest.info",
"provider": "hyperliquid-rest",
"timestamp": "2026-10-19T00:00:33.284Z",
"received_at": "2026-10-19T00:00:34.277Z",
"age_ms": 993,
"quality": "real"
}
},
"meta": {
"request_id": "req_abc123",
"timestamp": "2026-10-19T00:00:34.277Z",
"state": {},
"probabilities": null,
"confidence": null,
"freshness": [],
"horizon": null,
"data_sources": ["hyperliquid-rest"],
"methodology_version": "1.0.0",
"pricing": null
}
}The same snapshot is also the free MCP tool tollbridge_market_state.
2. Read a recorded decision (free)
Decision records are append-only and publicly readable — no payment for the ledger read:
curl https://api.tollbridge.app/v1/decisions/<decision_id>Unknown ids return 404 DECISION_NOT_FOUND — an honest miss, never a synthesized record.
3. Set up a wallet (one time)
Payments are EIP-3009 transferWithAuthorization of USDC on Base (eip155:8453), signed by your
own key. There is no account, no API key, no deposit flow — the agent holds its own funds and pays
per call. Any viem signer works:
import { privateKeyToAccount } from 'viem/accounts';
// Any EVM account holding USDC on Base (eip155:8453).
export const account = privateKeyToAccount('0x<your private key>');Fund it with USDC on Base — running a decision starts at $1 (1,000 credits; long-window questions $2, account questions $5 — see Pricing). Your first 3 entry-tier questions are free per payer address (S01 Market regime, S05 Volatility expansion, S06 Funding anomaly), and a refusal never spends one of them. Reading stays free.
4. Paid deep decision via x402
The TypeScript SDK performs the full x402 flow (challenge → sign → retry → receipt) for you:
import { Tollbridge } from '@tollbridge/sdk-typescript';
import { privateKeyToAccount } from 'viem/accounts';
import { account } from './wallet';
const paying = new Tollbridge({
baseUrl: 'https://api.tollbridge.app',
x402: {
signer: account, // viem Account — signs EIP-3009 over USDC on Base
maxAmountAtomic: '1000000', // defensive cap = the $1 entry tier (1000000 atomic);
// raise it to 2000000 / 5000000 for $2 / $5 questions
},
});
// Deep decision: run any catalog signal through the engine (PAID).
const decision = await paying.decision({ asset: 'BTC', question_id: 'S06_funding_anomaly' });
decision.data.probability; // the recorded probability
decision.data.confidence; // jev-derived confidence
decision.data.decision; // publish | monitor | escalate | suppress | …
decision.payment; // the typed PAYMENT-RESPONSE settlement receiptWithout an x402 signer the identical call throws PaymentRequiredError carrying the decoded
challenge — the agent decides whether to pay. Nothing is ever signed implicitly. For that
entry-tier S06 question the challenge quotes "amount": "1000000" — that is $1, USDC on
eip155:8453 — and the amount you receive is always authoritative (never a price you
hardcode).
5. Or hand the whole thing to MCP
Point an MCP client at the server and call the tool catalog directly (see MCP):
{
"mcpServers": {
"tollbridge": {
"type": "http",
"url": "https://api.tollbridge.app/mcp"
}
}
}