Real MCP server (stdio + @modelcontextprotocol/sdk) that exposes x402-paywalled HTTP endpoints as MCP tools. Drop into Claude Desktop, Cursor, or any MCP client.
This MCP server exposes a single dynamically-registered tool 'dynamic_paid_tools' that acts as a passthrough bridge to x402-paywalled HTTP endpoints. The tool definition is extremely sparse: it has a generic name that violates verb-noun conventions, a high-level description that explains the bridge's purpose but not the tool's actionable behavior, and a schema with only two parameters (tool_name and params) lacking detailed type information, constraints, and per-parameter descriptions. The input schema uses an ambiguous generic 'params' object without documenting what fields it should contain or how they vary by endpoint. No output schema is documented. Error handling is absent, no guidance on what happens when tool invocation fails, whether errors are retryable, or how the LLM should recover. The tool violates composition principles by bundling all paid endpoints into one generic passthrough rather than exposing discrete named tools. No security documentation regarding payment flow, failure modes, or auth/secret handling is visible in the tool definition itself. This design forces the LLM to guess at tool semantics and parameter requirements for each dynamically-loaded endpoint, violating the principle that tool names and descriptions must be self-documenting.
Dynamically registered x402-paywalled HTTP endpoints exposed as MCP tools. Tool list populated from AGENTICPAY_BRIDGE_TOOLS environment variable containing JSON array of paid endpoints.
Tool name 'dynamic_paid_tools' violates verb-noun convention and does not reflect a single clear action. Names like 'dynamic_paid_tools' are generic and ambiguous, the LLM cannot infer what happens when called without reading extensive documentation. Should be a verb phrase like 'invoke_paid_tool' or 'call_paid_endpoint'.
Input schema lacks per-parameter descriptions. The 'tool_name' parameter has a description, but 'params' is documented only as 'Tool-specific parameters as defined in the tool's inputSchema', this is a circular reference that does not explain what fields are expected, how they vary by endpoint, or what format they should take. LLMs cannot infer valid parameter structure from this.
No output schema documented. The tool description does not specify what the response contains, what fields are present, or how results are structured. LLMs cannot plan downstream operations or extract relevant data without knowing the output shape.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | F | 31 | 2025-06-18+ | v2 |
Generic 'params' object in schema has type 'object' with no properties defined, no additionalProperties constraint, and no validation rules. This allows the LLM to pass arbitrary fields, inviting malformed requests and API failures. Should enumerate valid parameters for each endpoint or at least document the expected structure.
No error handling guidance. The tool definition does not explain what happens when tool invocation fails (payment rejected, endpoint unavailable, invalid parameters), whether errors are retryable, or how the LLM should respond. Error messages will be raw HTTP/x402 failures.
Tool violates composition principle by bundling all paid endpoints into a single generic passthrough. Agents cannot see endpoint names, capabilities, or parameters until runtime, this forces exploration behavior and prevents proper tool selection reasoning. Each endpoint should be a discrete named tool with its own schema, or the bridge should expose a discovery tool to list available endpoints and their signatures.
Tool description conflates the bridge's implementation with the tool's behavior. It explains that endpoints are 'populated from AGENTICPAY_BRIDGE_TOOLS environment variable' (operational detail), not what the tool does when called. The description should state: 'Invokes a paid x402-paywalled endpoint. You must provide the endpoint name and its required parameters. Payment is processed via Solana USDC.' Include what fields are expected in the response.
No parameter constraints or format documentation. 'tool_name' accepts any string but available values are only known at runtime from environment configuration. 'params' has no type constraints. Without enums or format patterns, the LLM will guess at valid tool names and parameter structures, causing repeated failures.
Missing documentation of payment flow and security implications. The tool description does not explain that calls are paid (user should know this affects budget), what payment errors look like, whether calls are idempotent, or how to handle failed payments. This is critical for agent-initiated spending.