Skip to main content
Glama

x420_receipt_verify

Read-onlyIdempotent

X420 receipt verify: Verifies an X420-style signed receipt: recomputes sha256 of the canonical deliverable, checks it against the receipt, verifies the ed25519 signature, and checks the payee id against the key. The key is the one you pass or the receipt_signing_key on the seller's /.well-known/agent.json. Pure cryptography. Not professional, legal, insurance, engineering, medical, financial or tax advice. Price: $0.002 USDC per call (x402 on Base). This hosted tool does NOT pay and does NOT return the deliverable: it validates the input and returns payment instructions (pay_to, network, price and the x402 URL to pay at). GET the url; read PAYMENT-REQUIRED from the 402; retry with PAYMENT-SIGNATURE (x402 v2). Or run the local x420-mcp server with your own wallet key to pay automatically. Deliverable once paid: JSON: valid, reasons[], checks{signature_valid, deliverable_hash_matches, payee_matches_key}, key{agent_id, source}.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "receipt": "<receipt>",
      "deliverable": "<deliverable>"
    },
    "name": "x420_receipt_verify"
  }
}

Input Schema

NameRequiredDescriptionDefault
receiptYesthe receipt object as a JSON string
agent_urlNoseller origin whose /.well-known/agent.json holds the key (default https://signature-theme.com)
deliverableYesthe deliverable object as a JSON string
payee_public_key_hexNoseller's ed25519 SPKI key, 88 hex chars (default: read from the agent card)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.9/5.0
Behavior5/5

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

Annotations only declare readOnly/openWorld/idempotent/non-destructive; the description adds substantial context beyond that: it explicitly states the hosted tool does NOT pay and does NOT return the deliverable, discloses the $0.002 USDC per-call price and network, describes the x402 handshake, and explains the local-wallet alternative. It also pre-announces the paid deliverable's JSON shape (valid, reasons[], checks{}, key{}), which is exactly the behavioral disclosure an agent needs before invoking.

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?

The purpose and the key verification steps are front-loaded, and the payment/output paragraphs are ordered sensibly. It runs long for a single tool, and the boilerplate 'not professional, legal, insurance…' disclaimer plus the repeated payment mechanics could be compressed without losing information.

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 carries the burden of describing returns and mostly does: it lists the immediate payment-instruction fields (pay_to, network, price, x402 URL) and the post-payment result fields. The one residual ambiguity is whether the '$0.002 USDC per call' applies to this hosted call itself or only to the deliverable, given the very next sentence says it does not pay.

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 coverage is 100%, so all four parameters are already documented, including defaults and the 88-hex-char format. The description adds only a modest clarification of key resolution (the key you pass, else receipt_signing_key from the seller's /.well-known/agent.json), which is close to what the schema already states — the baseline 3 applies.

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?

Names a specific verb and resource and enumerates the exact verification steps (sha256 of the canonical deliverable, hash comparison, ed25519 signature check, payee-id-vs-key check), so the agent knows precisely what work happens. It stops short of distinguishing itself from the sibling x420_verify_signature, which an agent could easily confuse with this composite receipt check.

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

Usage Guidelines3/5

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

It gives a usable procedural path for the hosted mode (GET the url, read PAYMENT-REQUIRED from the 402, retry with PAYMENT-SIGNATURE) and points to the local x420-mcp server for auto-pay, which is real usage guidance. However, there is no statement of when to choose this over x420_verify_signature or x420_verify_domain-txt, and no explicit preconditions (e.g. what a malformed receipt yields).

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