Skip to main content
Glama

Agent Payment Preflight

agent_can_pay
Read-onlyIdempotent

Free pre-payment policy decision. Agents ask whether an x402 endpoint should be paid under strict, standard, or permissive policy. The free result is sufficient by default; set require_audit_receipt only when a settlement-backed receipt is required.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
endpointYesPublic x402 endpoint to evaluate before payment; never include credentials or private query parameters.
max_usdcNoCaller-approved per-call spending ceiling in decimal USDC, for example 0.01. This check never spends funds.
agent_policyNoReadiness policy to apply. Use strict unless the operator explicitly permits a different policy.
require_audit_receiptNoExplicitly request the optional paid receipt handoff after an allow decision. This does not submit payment.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
reportNo
reasonsNo
decisionYes
endpointNo
max_usdcNo
decision_codeYes
recommendationsNo
declared_price_usdcNo
report_integrity_okNo
verification_age_hoursNo
decision_schema_versionYes
auditable_paid_continuationNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and non-destructive behavior. The description adds useful context that this is a free pre-payment check and reinforces that no actual spending occurs, which aligns with the annotations. No contradiction exists.

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

Conciseness5/5

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

Two compact sentences, front-loaded with the core purpose. Every clause contributes to understanding the tool or its default usage, with no filler or repetition.

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?

Given the rich annotations, 100% schema coverage, and presence of an output schema, the description is largely complete for invoking the tool correctly. The only gap is the lack of explicit guidance distinguishing this preflight decision from sibling tools like x402_readiness_verify.

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 schema carries the parameter meaning. The description adds marginal value by clarifying the default result and when to set require_audit_receipt, but most parameter semantics are already fully documented in the schema.

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

Purpose4/5

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

The description clearly identifies the tool as a pre-payment policy decision for an x402 endpoint, using specific policy categories (strict, standard, permissive). It is distinct from the sibling tools in topic, though it does not explicitly name a counterpart to differentiate against.

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?

The description gives clear context for when to use the tool—before paying an x402 endpoint—and provides a concrete default behavior: the free result is sufficient unless a settlement-backed receipt is required. It does not explicitly mention alternatives or when not to use the tool, so it stops short of a 5.

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.