MCP Integration
Overview
Section titled “Overview”x402 Relay provides a native MCP (Model Context Protocol) server that exposes the catalog as tools for Claude, OpenClaw, and other MCP-compatible agents.
Claude Desktop
Section titled “Claude Desktop”Add to claude_desktop_config.json:
{ "mcpServers": { "x402-relay": { "command": "node", "args": ["/path/to/x402-relay/dist/mcp-server.js"] } }}OpenClaw
Section titled “OpenClaw”Add to your skill configuration:
{ "transport": "stdio", "command": "node /path/to/x402-relay/dist/mcp-server.js"}Available Tools
Section titled “Available Tools”search_services
Section titled “search_services”Search x402-enabled services by keyword or category.
| Parameter | Type | Required | Description |
|---|---|---|---|
query | string | No | Search keyword |
category | string | No | Category ID filter |
limit | number | No | Max results (default: 20) |
get_service_detail
Section titled “get_service_detail”Get detailed information about a specific service.
| Parameter | Type | Required | Description |
|---|---|---|---|
serviceId | string | Yes | Service ID |
list_categories
Section titled “list_categories”List all service categories with counts. No parameters.
check_service_status
Section titled “check_service_status”Check the current status and trust score of a service.
| Parameter | Type | Required | Description |
|---|---|---|---|
serviceId | string | Yes | Service ID |
why_this_api
Section titled “why_this_api”Get an AI-generated explanation of why a specific API is recommended for a query.
| Parameter | Type | Required | Description |
|---|---|---|---|
serviceId | string | Yes | Service ID |
query | string | No | Original search context |
Example Conversation
Section titled “Example Conversation”User: Find me an API for image generation that accepts crypto payments
Agent: [calls search_services with query="image generation"] Found 3 services. Let me check the top result... [calls get_service_detail with serviceId="svc-neural-api-1"] [calls check_service_status with serviceId="svc-neural-api-1"]
NeuralAPI offers image generation at $0.003/request via USDC on Base. Trust Score: 85/100 (verified). Uptime: 99.2%.