Skip to main content
Glama

x402ti (v2)

Deterministic x402 V2 pay-per-request trading, macro, prediction-market & Solana intelligence API on Base Mainnet (eip155:8453, USDC)—built for autonomous agents with zero API keys, zero subscriptions, and strict Pay-Only-On-Success settlement.

Informational market/security data only; not financial advice.


Endpoints & Pricing (8 Paid Resources — Base Mainnet USDC)

Multi-Asset Scanners

Method & Path

Price (USD)

Optional Query Params

What It Returns

GET /v1/perps/screener

$0.01

min_oi_usd (default 1000000), limit (1–25)

Scans all ~180+ Hyperliquid perps: market breadth, median funding APR, and top leaderboards for funding extremes, basis dislocations & turnover

GET /v1/perps/funding-arb

$0.015

min_oi_usd (default 100000 per leg), limit (1–25), coin

Live 3-venue funding spread scanner comparing Hyperliquid vs. dYdX v4 vs. Kraken Futures annualized funding rates, bottleneck leg OI & mark spreads

GET /v1/predictions/scanner

$0.015

venue (all/polymarket/kalshi), query, min_volume_24h_usd, limit (1–25)

Live Polymarket + Kalshi scanner: implied probabilities, bid-ask spreads, 24h volume/liquidity ratios, keyword search & high-conviction annualized carry-to-expiry

GET /v1/solana/trending

$0.015

limit (1–8, default 5), max_risk_score (0–100)

Live trending Solana pools pre-screened in parallel with RugCheck deterministic risk scores, authority flags, liquidity & 24h trader flow

Deep-Dive Derivatives, Macro & Security Briefs

Method & Path

Price (USD)

Query Params

What It Returns

GET /v1/options/surface

$0.015

currency (BTC default, or ETH)

Distills hundreds of live Deribit options into ATM IV term structure, contango/backwardation slope, OTM put-call skew, put/call OI ratios, exact Max Pain strike & top Call/Put OI walls

GET /v1/macro/liquidity

$0.01

lookback_obs (2–20, default 5)

Combines 5 official US Treasury & NY Fed primary feeds: exact US public debt, TGA cash balance & flows, ON RRP balance, EFFR/SOFR funding stress spread (bps) & net USD liquidity impulse (-ΔTGA - ΔRRP)

GET /v1/perps/snapshot

$0.005

coin (req, e.g. BTC, ETH, kPEPE)

Mark/oracle basis (bps), hourly & annualized funding, open interest USD, volume/OI turnover, spread (bps), top-5 L2 depth imbalance & $10k buy/sell VWAP slippage (bps)

GET /v1/solana/safety

$0.01

mint (req, Base58 SPL mint)

Deterministic 0–100 risk score, tier (LOW/MODERATE/ELEVATED/CRITICAL), RugCheck risks, authority booleans (mint/freeze/mutable), lp_locked_pct & liquidity/FDV ratios

Pay-Only-On-Success Guarantee: Unpaid requests return HTTP 402 with x402 V2 PAYMENT-REQUIRED terms. Only HTTP 200 settles—400, 404, 502, and 503 are never settled.


Related MCP server: x402-bazaar-mcp

Quickstart for AI Agents & Developers

1. Discover with AgentCash CLI

npx -y @agentcash/discovery@latest discover https://x402ti.malwowar.workers.dev --json

2. Multi-Signal Agent Workflow with @x402/fetch (TypeScript, with Spend Cap)

import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";

const account = privateKeyToAccount(process.env.BUYER_PRIVATE_KEY as `0x${string}`);
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.05" });
registerExactEvmScheme(client, { signer: account });

const fetchWithPay = wrapFetchWithPayment(fetch, client);

// 1. Check US Macro USD Liquidity Impulse ($0.01)
const macro = await fetchWithPay(
  "https://x402ti.malwowar.workers.dev/v1/macro/liquidity?lookback_obs=5"
).then((r) => r.json());

// 2. Check BTC Options Volatility Surface, Skew & Max Pain ($0.015)
const opts = await fetchWithPay(
  "https://x402ti.malwowar.workers.dev/v1/options/surface?currency=BTC"
).then((r) => r.json());

// 3. Scan Polymarket + Kalshi high-conviction carry opportunities ($0.015)
const preds = await fetchWithPay(
  "https://x402ti.malwowar.workers.dev/v1/predictions/scanner?venue=all&limit=5"
).then((r) => r.json());

3. Drop-In Agent Skill & Standalone MCP Server

  • Agent Skill: Copy skills/x402ti/SKILL.md into your agent's skills folder (Claude Code, Cursor, Antigravity, OpenClaw, Codex) to teach your agent all 8 endpoints.

  • MCP Server Wrapper: See mcp/README.md to expose all 8 paid endpoints + /health as native MCP tools with a configurable per-call USDC spend cap.


Architecture & Self-Hosting

  • Runtime: Cloudflare Workers (nodejs_compat) + Cloudflare D1 + Hono + strict TypeScript ($0 infrastructure)

  • Payments: Strict x402 V2 (@x402/hono, @x402/core, @x402/evm, @x402/extensions, @coinbase/x402) lazily initialized only on /v1/*

  • 2-Tier Caching & Resilience: Bounded 500-entry in-isolate TTL Map cache + best-effort Cloudflare Edge Cache (caches.default, automatically PoP-shared once a custom domain is attached), 3.5s AbortController timeouts, 3-tier keyless Solana market fallback, graceful partial-venue fallbacks (2-of-3 perps, 1-of-2 prediction venues, 3-of-5 official US macro feeds), and strict refusal to score missing RugCheck data as safe

  • Operator Console: Embedded dark-mode dashboard at /dashboard (constant-time SHA-256 Bearer auth, CSP/anti-clickjacking headers, D1 telemetry, clickable BaseScan links, and a D1-backed Start/Stop 503 API pause gate)

Local Development

npm install
cp .dev.vars.example .dev.vars   # fill CDP_API_KEY_ID, CDP_API_KEY_SECRET, DASHBOARD_TOKEN
npm run db:migrate:local
npm test
npm run dev

See SPEC.md for the engineering specification.

License

MIT — see LICENSE.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      Eight crypto and DeFi data tools for AI agents: prices, gas, one ParaSwap route quote, GoPlus token security and top-holder samples, DefiLlama yields, Hyperliquid/dYdX funding, and observed wallet balances. Inspect prices free; pay 0.001–0.008 USDC per call on Base through x402. No API key or subscription.
      8
      87 npm
      MIT
    • A
      license
      B
      quality
      B
      maintenance
      MCP server exposing x402 Bazaar's paid Base APIs (token risk/honeypot, prices, gas, wallet intel, tx decode + AI utilities) as agent tools. Your agent pays per call in USDC over x402 — no API keys, no signup.
      17
      123 npm
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server that provides AI agents with pay-per-call access to a suite of tools (honeypot check, token market, DeFi yields, etc.) via USDC on Base using the x402 protocol.
      MIT