Make every agent call count.
Sonar is the independent reliability and routing layer for agent commerce. Before an agent pays an API, Sonar tells it which provider is most likely to work, what it costs, and why.
The problem
x402 solved payment, but not provider trust. Listings can be stale, prices can drift, and an agent cannot tell which endpoint is most likely to work.
The signal
Sonar independently measures reachability, 402 handshakes, latency, quoted prices, schemas, and historical outcomes.
The answer
Agents query one REST or MCP interface to find the best measured provider for a capability, budget, and preference.
The boundary
Sonar recommends providers. It does not proxy requests, custody user wallets, or spend money on behalf of callers.
Discover. Measure. Route.
The private worker ingests approved discovery sources, canonicalizes and deduplicates listings, then probes safe endpoints without payment. Rolling metrics are written to Neon and published through the read-only Next.js control plane.
Discovery sources → normalize + deduplicate → private prober → Neon PostgreSQL → Next.js UI / REST / MCP
Free probes use the 402 handshake as evidence. Paid probes are optional, budget-capped, and disabled by default.
Route by evidence.
Search by keyword, category, or use case. Choose `balanced`, `reliable`, `fastest`, or `cheapest` ranking and optionally provide a price ceiling.
GET /api/v1/route?capability=weather&prefer=reliable&max_price=0.01&n=3\n\nrecommendations[].endpoint\nrecommendations[].score\nrecommendations[].confidence\nrecommendations[].price_usd\nrecommendations[].why.success_24h\nrecommendations[].why.latency_p90_ms\nrecommendations[].why.price_drift_pct\nrecommendations[].why.schema_completeness
Use the catalog endpoints for browsing and the history endpoint when an agent needs to inspect the evidence behind a choice.
GET /api/v1/endpoints?q=translation&limit=100&offset=0\nGET /api/v1/endpoints/{id}\nGET /api/v1/endpoints/{id}/history\nGET /api/v1/statsGive agents a measured catalog.
Connect an MCP-compatible client to /api/mcp. Sonar exposes search, health inspection, and recommendations without invoking or paying providers.
POST /api/mcp\n\ntools/list\n search_services search the measured catalog\n get_service_health inspect health and probe history\n recommend_service rank providers for a capability\n preflight_payment check policy before signing\n get_incidents inspect provider incidents\n compare_services compare measured providers\n\nrecommend_service({ capability: "weather", prefer: "reliable", n: 3 })Claude Desktop
Add a remote MCP bridge to your Claude Desktop configuration:
{
"mcpServers": {
"sonar": {
"command": "npx",
"args": ["mcp-remote", "https://sonar.example.com/api/mcp"]
}
}
}Then ask: “Find the most reliable weather API under $0.01 and explain the evidence.”
ChatGPT and custom agents
When your ChatGPT workspace supports remote MCP, add the same endpoint. If it supports HTTP Actions instead, expose /api/v1/route, /api/v1/endpoints/{id}, and /api/v1/endpoints/{id}/history. Instruct the agent to query Sonar before recommending an x402 provider and explain uptime, latency, price drift, probe count, and confidence.
Understand the status.
unknown means no probes yet. live means strong recent handshake success. degraded indicates lower uptime, high latency, or price drift. down means low uptime with a recent success. dead requires enough history with no recent success.
Services with fewer than five probes expose confidence: low. Treat their status as provisional until more observations arrive.
One source of truth.
Neon stores the canonical catalog, probe history, rollups, scores, and source provenance. The private worker uses the writer role. Next.js, REST, and MCP use the reader role.
Private worker ── writer ──► Neon PostgreSQL ◄── reader ── Next.js
├─ UI
├─ REST
└─ MCPRun the complete Docker workflow with pnpm docker:up after configuring the Neon URLs. See machine-readable API docs and llms.txt for crawler and agent discovery.