AgentPay — trust routing + spend caps for x402 agents

v2.9.2
io.github.romudille-bit/agentpay Checked 3 hours ago Published 13 days ago

Buyer-side trust oracle + capped sessions for x402 agents: verified_route, receipts, 17 free tools.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

verified_route

Buyer-side trust oracle for the x402 marketplace: "I need X, budget $Y — which tool is real?" Vets Coinbase Bazaar (discover → drop stubs/factory clones → rank by real unique-payer usage → budget-gate). This MCP runs the FREE single-query PREVIEW: it returns the vetted pick (name + usage stats + why) and survivor count to PROVE a real provider exists, but WITHHOLDS the provider URL + ready-to-pay x402 challenge. To get those — plus the full multi-query sweep + usage-based sybil-collapse + trust allowlist — fund this install's wallet with USDC on Base and set AGENTPAY_ENABLE_PAID=1…

ParameterTypeDescription
need *stringWhat you need, e.g. "dex pair liquidity", "funding rates", "token security"
budget_usdnumberMax USDC the agent will pay the downstream tool per call (default 0.01).
chainstringOptional chain filter: "base", "arbitrum". Empty = all chains.

route

Legacy alias of the free verified_route preview (kept for back-compat). Vets one Coinbase Bazaar search for a need within a budget: drops stubs, down-ranks factory clones and one-wallet or one-call-per-wallet usage, ranks on distinct payers, and names a pick only above a confidence floor (otherwise verdict no_confident_pick). Returns the pick's name, usage stats and reason; the provider URL and ready-to-pay details are withheld, as in the preview. This is NOT the paid verified_route, which ranks the whole catalog with sybil collapse and delivery evidence. Advise-only — no payment happens her…

ParameterTypeDescription
need *stringWhat capability you need, e.g. "funding rates", "token security", "DeFi TVL"
budgetnumberMaximum USDC per call (default 0.01). Tools priced above this are excluded.

estimate_plan

Price a multi-tool plan BEFORE spending anything. Submits the tool calls an agent intends to make to the gateway's free /v1/plan/estimate and returns per-step cost, total, a fits-budget verdict, and a cheaper alternative per paid step. No payment, no wallet needed. Use when: planning a multi-step task with paid tools, "what would this cost", "does this plan fit my budget", or before committing a Session cap.

ParameterTypeDescription
steps *arrayTool names to price, in order, e.g. ["token_price", "dune_query", "session_create"]
budgetnumberOptional USDC budget for the fits_budget verdict, e.g. 0.05

session_cap

The hard spending cap of this AgentPay session and what has been spent so far, with the wallets that pay. Pass max_usd to LOWER the cap for this session (or restore it, up to the configured AGENTPAY_MAX_SPEND ceiling); raising the ceiling needs a restart. Call it before the first paid call so the user can confirm or change the cap, and whenever they ask what the agent may spend. Free, local.

ParameterTypeDescription
max_usdnumberNew session cap in USD, at most the configured ceiling and not below what is already spent.