Skip to main content
Glama

x402 Envelope Inspector

agentbit.x402_inspect
Read-onlyIdempotent

Lint any x402 endpoint or payment header against the v2 spec and real CDP facilitator behavior: CAIP-2 network ids, atomic amounts, the EIP-712 domain-name trap ('USD Coin' on Base mainnet vs 'USDC' on Sepolia — wrong name = every settlement fails), the extensions echo Coinbase Bazaar requires for indexing, expired authorizations. Findings as error/warning/info with what will actually break. Built by a seller that debugged all of these in production. Pay-per-call via x402 (USDC, Base).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "agentbit.x402_inspect"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoA paid x402 endpoint to probe live (GET, expects the 402 envelope)
_paymentNoOptional base64 x402 PAYMENT-SIGNATURE payload. Omit to receive payment requirements.
payment_payloadNoBase64 PAYMENT-SIGNATURE header value to lint the client payload (optionally alongside payment_required)
payment_requiredNoBase64 PAYMENT-REQUIRED header value to lint offline

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, openWorld, non-destructive, so the safety profile is covered. The description adds real value beyond that: it discloses output semantics (error/warning/info findings), the live-probe vs offline-lint distinction, and the pay-per-call cost model (x402, USDC, Base), which is important for an agent budgeting calls.

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 concrete checks, which earns its space by being specific rather than generic. The closing line ("Built by a seller that debugged all of these in production") is marketing that does not help an agent invoke the tool, a minor waste in an otherwise dense passage.

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

Completeness5/5

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

There is no output schema, but the description explains the finding structure (error/warning/info) and the failure framing, and it covers the cost model of a paid endpoint. For a read-only linting tool with full schema coverage, an agent has everything needed to call it correctly.

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 every parameter (url, _payment, payment_payload, payment_required) is already documented with its header semantics. The description mentions "endpoint or payment header" but adds no syntax or format detail beyond the schema — baseline 3 is appropriate when the schema does the heavy lifting.

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 uses a specific verb ("lint") and precise resource ("x402 endpoint or payment header") and enumerates exactly what is checked: CAIP-2 network ids, atomic amounts, EIP-712 domain-name trap, extensions echo, expired authorizations. It is very clear what the tool does, but it never distinguishes itself from the sibling agentbit.x402_intelligence, so an agent must guess between the two.

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?

Usage is only implied: the linting framing and "what will actually break" suggest pre-settlement debugging, and the schema notes live-probe vs offline modes. There is no explicit when-to-use statement, no exclusion of cases, and no routing to or away from x402_intelligence or the other x402-adjacent siblings.

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.