{"uid":"cap_ml9CR0TfgUkmN0ysRvrzk","slug":"x402-payment-gated-usdc-wallet-balance-preflight-b5be8baa","name":"x402 Payment-Gated USDC Wallet Balance Preflight","description":"Live Base wallet intelligence paid with USDC via x402","url":"https://nova5-x402.yesterdays-signal.workers.dev/x402-preflight","method":"GET","headers":{},"bodySchema":{"type":"object","required":["amount","address"],"properties":{"amount":{"type":"string","description":"Requested USDC payment amount"},"address":{"type":"string","description":"EVM wallet address"}}},"responseSchema":{"type":"object","properties":{"asset":{"type":"string"},"chain":{"type":"string"},"address":{"type":"string"},"can_pay":{"type":"boolean"},"network":{"type":"string"},"reasons":{"type":"array","items":{"type":"string"}},"service":{"type":"string"},"decision":{"enum":["PROCEED","FUND_USDC"],"type":"string"},"rpc_used":{"type":"string"},"timestamp":{"type":"string"},"provenance":{"type":"string"},"block_number":{"type":"number"},"asset_address":{"type":"string"},"available_usdc":{"type":"string"},"remaining_usdc":{"type":"string"},"requested_usdc":{"type":"string"}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_7-8tmUjqipA71oPLtkMIH","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Checks whether an EVM wallet on Base has sufficient USDC balance to cover a requested payment amount, returning a proceed/fund decision with balance details","exampleAgentPrompt":"Before we proceed with the payment, check if wallet address 0xAbC123...def456 has enough USDC to cover a $0.05 charge — tell me whether it can pay or needs to be funded.","exampleUseCases":[{"title":"Pre-payment wallet sufficiency check","prompt":"Before charging the user, check if their wallet 0x1234567890abcdef1234567890abcdef12345678 has enough USDC to cover a 0.10 payment — I need to know if they should be prompted to add funds first."},{"title":"Agent auto-routing before x402 call","prompt":"My agent is about to make an x402-gated API call that costs 0.01 USDC. Can you check if wallet 0xdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef has sufficient balance so I know whether to proceed or ask the user to top up?"},{"title":"Live balance snapshot for wallet dashboard","prompt":"Pull the current USDC balance and payment readiness status for wallet address 0xaabbccddeeff00112233445566778899aabbccdd on Base, assuming we want to make a 0.05 USDC payment."}],"resultDescription":"Returns a JSON object with: the wallet's available USDC balance, remaining USDC after the requested deduction, a boolean 'can_pay' flag, a decision enum of either PROCEED or FUND_USDC, the asset and chain identifiers, the RPC endpoint used, current block number, timestamp, and a list of human-readable reasons explaining the decision.","failureModes":["Invalid or malformed EVM address returns an error or empty result","Amount field missing or non-numeric causes a validation failure","RPC node unavailable may cause a timeout or empty block_number","Wallet with zero USDC returns can_pay: false and decision: FUND_USDC","Payment for the preflight itself (0.01 USDC) fails if calling agent lacks funds"],"whenToPreferThis":"Use this endpoint when you need a live, on-chain preflight check of an EVM wallet's USDC balance on Base before initiating any payment flow — especially within x402-gated agent pipelines. Prefer this over static balance reads when you need a decision signal (PROCEED vs FUND_USDC) with reasoning, not just a raw balance number. Best suited for automated agent workflows that need to gate downstream actions on payment feasibility.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-16T00:30:34.075Z","isFirstParty":false}