Skip to main content
Glama

Foundry: prepaid AI compute in USDF

Pay an x402 URL

x402_pay

Calls a URL that asks for an x402 payment and pays it for you: the gateway pays the seller in USDC from its own float and charges this key in USDF the seller's amount and the payer's fee (never free credit), within the key's and its agent's limits. Needs an API key. Returns the seller's answer with the payment and its receipt; a payment is charged only once the chain shows it, and one that never settles costs nothing. quote: true answers what it would cost and pays nothing. Third-party tools to call this way are listed under marketplace in list_tools (GET /v1/tools?source=marketplace).

Input Schema

NameRequiredDescriptionDefault
urlYesThe seller's URL (https)
bodyNoThe request body: text, or JSON sent as application/json
quoteNoAnswer the price and pay nothing
methodNoDefault GET, or POST when a body is given
headersNoHeaders for the seller (the payment headers are the gateway's)
networkNoPay on this network only: its CAIP-2 id, one GET /v1/x402/payer lists
max_priceNoThe most to pay in USDF, the fee included ("0.05")

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / network / description
      Previous value: -"Pay on this network only"New value: +"Pay on this network only: its CAIP-2 id, one GET /v1/x402/payer lists"
    • removedInput schema / properties / network / enum
      Removed value: -[
      -  "base",
      -  "solana"
      -]
    • addedInput schema / properties / network / maxLength
      Added value: +64
  2. First observed

TDQS

A4.3/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare readOnly=false, openWorld=true, idempotent=false, destructive=false; the description adds substantial behavior beyond that — how billing works (USDF charge covering seller amount plus payer fee, never free credit), settlement semantics (charged only once the chain shows it, an unsettled payment costs nothing), and the return content (seller answer plus payment and receipt). This is exactly the kind of financial/consequence disclosure an agent needs before invoking a money-spending call.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and the payment model, then quote behavior, then discovery pointer — a sensible ordering. The single dense paragraph packs in a lot, and the closing list_tools pointer is slightly buried, but no sentence is filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description correctly describes the return ('the seller's answer with the payment and its receipt') and covers auth, billing, and settlement risk for a 7-parameter mutating tool. It leaves the caller to infer request-body/method edge behavior and error outcomes (e.g., what happens on insufficient balance).

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description explains the quote parameter's effect, but that largely restates the schema's own text ('Answer the price and pay nothing'), and it adds nothing for method, body, headers, network, or max_price — all of which are already documented in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a concrete verb and resource — 'Calls a URL that asks for an x402 payment and pays it for you' — and immediately clarifies the settlement model (gateway pays seller in USDC from float, charges the key in USDF). An agent can distinguish this from sibling tools like quote or balance without inspecting the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit conditions: 'quote: true answers what it would cost and pays nothing' and points to list_tools with the marketplace source for discovering callable third-party URLs. Prerequisites (needs an API key, operates within key and agent limits) are stated. It stops short of naming when to use the sibling quote/quote_tool tool instead of the quote parameter.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources