{"name":"verify402","description":"Machine-payable truth service. /preflight is the free pre-signing gate: validate an x402 payment request or a chain transaction and get PASS / CAUTION / BLOCK with typed reasons and a short-lived receipt. /verify measures whether a cross-venue arbitrage round trip is profitable; /safety is a pre-trade gate that tells an agent whether a token is safe to buy before it risks capital. All quotes come from Uniswap's canonical QuoterV2 and each venue's own router, never from our own reimplementation of venue mathematics. The MCP server (verify402-mcp) exposes the gate and the five checks as native tools; install at /mcp.","prices":{"preflight":"free","preflight_verify":"free","verify":"$0.05","safety":"$0.10","route":"$0.03","quotecheck":"$0.05","depth":"$0.05"},"usage":{"path":"/usage","price":"free","scope":"this process instance; resets on restart or deploy","note":"Anonymous free-gate call counts. Not a unique-agent count; paid settlements are the identity-backed signal."},"payment":{"protocol":"x402","scheme":"exact","acceptsExample":{"scheme":"exact","price":"$0.05","network":"eip155:8453","payTo":"0xAeEF086DD4e436c69d6d0F684b4c9F43392df9cb"}},"chains":[{"chainId":1,"name":"ethereum","tokens":["USDC","WETH","WBTC","DAI","USDT"],"venues":["uni-v3-0.01%","uni-v3-0.05%","uni-v3-0.3%","uni-v3-1%","uniswap-v2","sushiswap"]},{"chainId":8453,"name":"base","tokens":["USDC","WETH","cbBTC","DAI"],"venues":["uni-v3-0.01%","uni-v3-0.05%","uni-v3-0.3%","uni-v3-1%"]},{"chainId":42161,"name":"arbitrum","tokens":["USDC","WETH","WBTC","USDT","ARB"],"venues":["uni-v3-0.01%","uni-v3-0.05%","uni-v3-0.3%","uni-v3-1%","uniswap-v2","sushiswap"]}],"endpoints":[{"method":"POST","path":"/preflight","price":"free","body":{"kind":"payment","payment":{"scheme":"exact","network":"eip155:8453","asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","amount":"10000","payTo":"0xAeEF086DD4e436c69d6d0F684b4c9F43392df9cb","resource":"https://verify402.onrender.com/verify","maxTimeoutSeconds":60},"from":"0x...","policy":{"maxAmountUsd":0.25,"allowedPayTo":["0x..."]}},"response":{"verdict":"PASS | CAUTION | BLOCK","reasons":"[{ code, severity, message }]","checked":"[what was actually checked]","notChecked":"[what was deliberately not checked]","receipt":"{ spec, id, verdict, intentHash, blockNumber, blockHash, issuedAt, expiresAt, signature }"},"use_when":"an agent is about to sign ANY x402 payment request or chain transaction; free and fail-closed"},{"method":"POST","path":"/preflight/verify","price":"free","body":{"receipt":"{...the receipt returned by /preflight...}"},"response":{"valid":"boolean","reason":"null | missing_receipt | unknown_spec | missing_signature | bad_signature | bad_expiry | expired"},"use_when":"an executor verifies a preflight receipt before allowing a signature"},{"method":"POST","path":"/verify","price":"$0.05","body":{"chainId":1,"target":"WETH","base":"USDC","size":100000},"response":{"verdict":"edge | no_edge | no_edge_costs_ate_it","gross":"{ human, bps }","net":"{ human, bps }","costs":"{ flashLoanPremiumBps, gasUsd, ... }","evidence":"per-venue quotes for both legs, at the reported block"},"use_when":"an agent is about to execute a specific arbitrage that someone (or something) claims is profitable"},{"method":"POST","path":"/safety","price":"$0.10","body":{"chainId":1,"tokenAddress":"0x95aD61b0a150d79219dCF64E1E6Cc01f0B64C4cE","intendedUsd":500,"offeredPriceUsd":0.00002},"response":{"verdict":"TRUST | CAUTION | AVOID","reasons":["why it is not TRUST"],"notes":["what checked out"],"checked":["contract","market","sellability","liquidity","price-sanity"],"evidence":"contract facts, market data, sell-probe venues, round-trip cost, price comparison"},"use_when":"an agent is about to BUY a token and needs to know it can exit and the price is real"},{"method":"POST","path":"/route","price":"$0.03","body":{"chainId":1,"tokenIn":"USDC","tokenOut":"WETH","amountIn":"1000000000"},"response":{"best":"{ venue, kind, amountOut(raw) } | null","book":"every venue (direct + WETH-routed), best first, one pinned block","unavailable":["venues that could not quote the size"]},"use_when":"an agent wants the chain's own answer for what a swap should pay, before trusting any counterparty's number"},{"method":"POST","path":"/quotecheck","price":"$0.05","body":{"chainId":1,"tokenIn":"USDC","tokenOut":"WETH","amountIn":"1000000000","quotedOut":"326259300000000000","venueClaimed":"who-gave-you-this"},"response":{"verdict":"fair | overpaying | too_good_to_be_true | unknown","notes":["why"],"evidence":"offered quote, chain best, full venue book, ratio, shortfallBps"},"use_when":"an agent was OFFERED a quote by a broker/aggregator/bot and is about to sign it"},{"method":"POST","path":"/depth","price":"$0.05","body":{"chainId":1,"tokenAddress":"WETH","baseSymbol":"USDC","sizesUsd":[100,1000,10000,100000],"maxRoundTripPct":1},"response":{"capacityUsd":"largest rung with round-trip cost <= maxRoundTripPct","ladder":"per size: impactPct, roundTripCostPct, buyVenue, sellVenue, impliedPriceUsd","notes":["the honest caveats, block-pinned"]},"use_when":"an agent is ABOUT TO CHOOSE A SIZE and needs to know what the pool will really give it"}],"unpayable":"A request without payment returns HTTP 402 with instructions in the payment-required header.","preflight":{"spec":"verify402/preflight@1","receiptSpec":"verify402/preflight-receipt@1","price":"free","defaultTtlSeconds":90,"limits":{"perMinutePerIp":60,"maxInFlight":8},"intents":["payment","transaction"],"paymentNetworks":"EVM (1, 42161, 8453, 84532, 11155111) + Solana mainnet/devnet","transactionChains":[1,8453,42161],"verdicts":{"PASS":"every check in `checked` passed at this fresh pinned block","CAUTION":"at least one check needs a decision; read `reasons`","BLOCK":"at least one hard check failed; do not sign"},"blockFreshness":{"cautionAfterSeconds":30,"blockAfterSeconds":120,"noTimestamp":"503, no receipt","note":"EVM only; the response carries block.timestamp and block.ageSeconds"},"binding":"sha256 of the canonical normalized intent, a fresh pinned block where the chain is readable, and an expiry (default 90s, max 300s)","failClosed":"if the chain cannot be read, /preflight returns 503 and issues no receipt; an executor should refuse to sign without a verifiable PASS or an explicitly acknowledged CAUTION","receiptSigning":"hmac-sha256 with PREFLIGHT_SECRET","verify":"POST /preflight/verify","mcpTool":"preflight_gate","doesNotCheck":["recipient reputation","sanctions screening","contract audits","balance-delta simulation","MEV/sandwich protection","payment signature / signed payload","gas price/limit chosen by the signer","raw signed-transaction binding","facilitator settlement","counterparty identity / tool metadata","prompt injection / hidden Unicode in tool output"],"note":"A PASS is not a guarantee or a counterparty audit. It means the listed checks passed at this block; `notChecked` lists what was not examined, including tool metadata and response content."},"mcp":{"package":"verify402-mcp","version":"1.0.3","license":"Apache-2.0","transport":"stdio","install":"https://verify402.onrender.com/mcp","freeTool":"preflight_gate","paidTools":["verify_arbitrage","check_token_safety","get_best_route","verify_quote_fairness","get_trade_depth"],"freeOnlyWithoutWallet":true,"note":"Start with no EVM_PRIVATE_KEY to expose only the free gate. Paid tools use a dedicated hot wallet, cap each payment at MAX_PAYMENT_USD, and only pay an allowlisted network/payee. The bridge signs x402 payments only, never a trade."},"recovery":{"header":"x-idempotency-key","behavior":"Send this header on the FIRST call of an operation. If the response is lost after settlement, retrying with the same header returns the SAME verdict within the TTL without requiring payment again. Records are promoted to replayable ONLY after your settlement is confirmed by the facilitator: a failed or pending settlement leaves no free replay (fail-closed).","ttlMinutes":10,"maxReplays":3,"maxReplaysNote":"the cap is per operation, shared between the caller key and the content-hash companion key","doubleKeying":"verdicts are also recorded under a hash of the canonical request content, so a retry that mints a fresh id still replays free within the window","afterWindow":"expired verdicts leave a tombstone holding the previous responseHash for 6 hours; a retry re-measures with the paywall re-armed and the response carries recovery.remeasured + previousResponseHash so agents can branch instead of guessing","delegatedSpend":"the caps here are client-side for the signer that constructs the payment; spend through wallets delegated to OTHER agents is outside this contract and governed by the delegating owner's own controls","warn":"The key is the caller's secret: whoever presents it can replay the verdict for free. Do not log it publicly."},"evidence_bundle":{"spec":"verify402/evidence-bundle@1","included":"evidence_bundle: { requestHash, responseHash, pinnedBlock, mode, createdAt, payment.in }","requestHash":"sha256 of the canonical JSON { route, body } (keys sorted recursively, no whitespace)","responseHash":"sha256 of the canonical JSON of the response body excluding evidence_bundle, recovery, cache, elapsedMs","verifier":"use src/recovery.mjs canonicalStable() as reference, or key-sort and stringify with no whitespace, then sha256"},"honesty":["No profit is promised. The measured answer for mainstream pairs is usually no_edge.","If a response says edge, verify before acting; the service reports what it measured, not what it guarantees.","Safety verdicts are measured evidence (live contract calls, actual venue quotes, market data), not a paid audit or a score from folklore.","A preflight PASS is not a guarantee: it means the listed checks passed at that block; `notChecked` names what was not examined.","Not financial advice."]}