m2mcent-sdk
OfficialClick on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@m2mcent-sdkwrap my API endpoint with a USDC payment gate"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🛰️ M2MCent SDK — x402 Payment Wrapper for AI Agents
Ultra-lightweight x402 payment interceptor for AI Agents and MCP Servers. Monetize any API in 3 lines of code.
🚀 Quick Start
npm install m2mcent-sdkimport { X402Handler } from 'm2mcent-sdk';
const x402 = new X402Handler({
rpcUrl: 'https://mainnet.base.org',
privateKey: process.env.RELAYER_PRIVATE_KEY!,
recipient: process.env.TREASURY_ADDRESS!
});
// Protect any Express endpoint with a USDC paywall
app.post('/api/analyze', x402.requirePayment("100000"), (req, res) => {
res.json({ result: "Premium analysis complete", receipt: req.paymentTx });
});Related MCP server: @arispay/payagent-mcp
📐 How It Works
M2MCent implements the x402 Payment Protocol — a machine-native payment standard inspired by HTTP 402:
Agent requests a protected endpoint
Server responds with
402 Payment Required+ payment metadata (Base64 encoded)Agent signs an EIP-712 typed data authorization (gasless for the payer)
Server settles atomically on-chain via the M2MCent Escrow contract
Agent receives the premium response + transaction receipt
Agent ──► API Server ──► 402 + metadata
Agent ◄── signs EIP-712 authorization
Agent ──► API Server + Payment-Signature header
└──► Escrow.settle() on Base L2
Agent ◄── Premium Response + tx hash⚙️ Configuration
Parameter | Description | Required |
| Base Mainnet RPC endpoint | ✅ |
| Relayer wallet private key (for settlement) | ✅ |
| Treasury address to receive payments | ✅ |
🔒 Security
Non-custodial: Funds flow directly from payer → treasury via on-chain escrow
Gasless for payers: Uses EIP-3009
transferWithAuthorization(USDC native)Zero-Leak: No agent data is retained after settlement
Atomic: Payment and service delivery happen in a single request cycle
🌐 Network Details
Parameter | Value |
Network | Base Mainnet (Chain ID: 8453) |
USDC Contract |
|
Escrow Contract |
|
Settlement | Atomic, sub-second finality |
🧩 MCP Server Integration
Perfect for Model Context Protocol servers:
import express from 'express';
import { X402Handler } from 'm2mcent-sdk';
const app = express();
const x402 = new X402Handler({
rpcUrl: process.env.BASE_RPC_URL!,
privateKey: process.env.RELAYER_PRIVATE_KEY!,
recipient: process.env.TREASURY_ADDRESS!
});
// Any MCP tool endpoint becomes monetizable
app.post('/api/tools/analyze', x402.requirePayment("50000"), async (req, res) => {
const result = await runMCPTool(req.body);
res.json({ ...result, paymentTx: req.paymentTx });
});📊 Ecosystem
M2MCent powers 100+ production MCP servers on Base Mainnet, processing real USDC micro-payments for AI-to-AI commerce.
📄 License
MIT © M2MCent
Available Tools
2 toolsexecute_m2mcent_toolB
Execute any of the 1,004 M2MCent microservices. Fee varies per node (e.g. $0.01 - $0.50 USDC).
| Name | Required | Description | Default |
|---|---|---|---|
| payload | Yes | JSON stringified payload or text query for the tool | |
| toolName | Yes | The exact name of the tool (e.g. 'defi-sentinel-mcp', '3d-meshweaver-mcp') |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It adds genuine value by disclosing the financial cost ($0.01-$0.50 USDC), which is a meaningful behavioral trait not inferable from the name. However, it omits other behavioral traits for a dispatcher tool: no mention of side effects, failure behavior for unknown toolNames, response format, or external network calls.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences with no filler: the first front-loads the primary purpose, the second adds the essential cost caveat. Every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
This is a high-complexity tool dispatching to 1,004 heterogeneous microservices, with no output schema and no annotations to lean on. The description does not address how an agent should discover the correct toolName, what errors occur on invalid input, or what the response looks like — leaving a large surface area under-documented.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. The description adds marginal context for toolName by noting that each microservice/node carries a varying fee, which helps agents weigh cost when selecting parameters. It adds nothing for payload beyond what the schema already states ('JSON stringified payload or text query').
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Execute') and resource ('1,004 M2MCent microservices'), making the dispatch role clear. It implicitly differentiates from the sibling search_m2mcent_catalog by framing this as the execution counterpart to discovery, though it never names the sibling explicitly.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The only usage guidance is the cost warning ('Fee varies per node'), which is a real consideration but not routing guidance. The description never tells the agent to use search_m2mcent_catalog first to identify a valid toolName, nor does it explain when to avoid execution or how to handle invalid tool names.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_m2mcent_catalogB
Search the M2MCent Universal Catalog of 1,004+ Agentic Services
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Keyword to search for in the catalog (e.g. 'pdf', 'crypto', 'vision') |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description bears the full burden of behavioral disclosure. It only says 'Search', which implies a read-only operation, but it does not state whether results are limited to the 1,004+ services, whether pagination exists, or what the response contains. Minimal behavioral context is added beyond the tool's name.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence that is front-loaded with the action and resource, with no redundant words or filler. Every part of the sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a one-parameter search tool, the description covers the invocation sufficiently: the agent knows what to search and where. However, there is no output schema and no mention of what the search returns, which creates a gap for an agent that needs to interpret results or select matching services to execute.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, and the query parameter already includes an explanatory description with examples ('pdf', 'crypto', 'vision'). The tool description itself adds no parameter detail beyond the schema, so the baseline score of 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Search') and a specific resource ('M2MCent Universal Catalog of 1,004+ Agentic Services'), making the tool's function immediately clear. It does not explicitly name the sibling execute_m2mcent_tool, but the search-vs-execute contrast is evident from the sibling's name.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no explicit when-to-use or when-not-to-use guidance, and no direct comparison to execute_m2mcent_tool. The only usage signal is the phrase 'Search the... Catalog', which implies this tool is for discovery before execution, but that remains an inference rather than stated guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
2 tool updates
v1.0.5- First observed
execute_m2mcent_tool - First observed
search_m2mcent_catalog
TDQS
Scored across 2 tools
The two tools have completely distinct purposes: one searches the catalog, the other executes a selected service. There is no overlap or ambiguity about which tool to use for a given task.
Both tools follow a clear verb_noun pattern with the shared 'm2mcent' prefix (search_m2mcent_catalog, execute_m2mcent_tool). The naming is predictable and consistent despite the slightly different second nouns.
For a gateway SDK exposing a catalog of 1,004+ services, two tools are exactly the right scope: search to discover and execute to invoke. Each tool earns its place, and adding more would overcomplicate the surface.
The core lifecycle of discover-then-execute is fully covered. Search returns catalog details, and execute runs the chosen microservice. No obvious gaps exist for the stated purpose of being a thin client to the M2MCent ecosystem.
Maintenance
Related MCP Connectors
Monetize any MCP server: x402 paywall, pay-per-call billing in USDC on Base, agent marketplace.
Pay for HTTP APIs and charge for your own: x402 micropayments in USDC on Base.
Pay-per-action access to APIs and MCP tools over Lightning L402 and Base USDC x402.
Pay-per-call tools for autonomous agents, settled in USDC on Base via x402.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceDrop-in x402 payment middleware for MCP servers. Charge AI agents per tool call using USDC on Base chain — Python and JavaScript SDKs, no payment processor, no KYC.MIT

@arispay/payagent-mcpofficial
AlicenseAqualityAmaintenanceEnables AI agents to call paid APIs and settle HTTP 402 payment challenges with USDC on Base, without private keys ever being involved.7168 npmMIT- FlicenseAqualityBmaintenanceMCP server for a live x402 payment gateway on Base (USDC). Lets AI agents discover, preview for free, then pay per call — with prepaid gasless payments, signed receipts, and delta delivery.7-
- AlicenseNot gradedqualityAmaintenancePlug-and-play monetization SDK for MCP tools and TypeScript APIs. Monetize AI agent workflows instantly with x402 V2 micropayments and Base revenue splits.435 npmMIT