Skip to content
plugmcp
DirectorySkillsCategoriesBlog
EN/中文
Sign inSign up
Home/Servers/MCP Agentic Wallet — Open Source Session Management For X402

MCP Agentic Wallet — Open Source Session Management For X402

I
by io.github.MCPVOT

Open-source EIP-2612 Permit-based wallet sessions for AI agents using MCP.

Power your agent

Add this server

Install from the publisher. Not a PlugMCP endpoint.

No packaged release in the registry yet. Follow the repository README.

Provider
Step-by-step: add this in Claude

Remote URL or a command on your machine? How the two installs differ

Run on PlugMCP

Host a copy with our keys and logs.

A new server you create. It is not this listing's official endpoint. Use the publisher install when you want their URL and their credentials.

Launch

Related MCP

View more
  • Firecrawl🔥 Official Firecrawl MCP Server - Adds powerful web scraping and search to Cursor, Claude and any other LLM clients.
  • N
    NotionToken-auth Notion MCP: pages, databases, blocks, comments, files. Runs headless in CI and agents.
  • Context7Context7 Platform -- Up-to-date code documentation for LLMs and AI code editors

Related skills

View all
  • reaReverse engineer anything with agents, from app behavior down to native binaries.
  • rea-changelog-updatePrepare or rewrite REA release changelogs and GitHub release notes from pinned Git history, with verified contributor thanks and Release Please synchronization.
  • rea-tool-designDesign or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics.

Open-source EIP-2612 Permit-based wallet sessions for AI agents using MCP.

MCP Agentic Wallet

Open-source EIP-2612 Permit-based wallet sessions for AI agents. The reference implementation for paid MCP servers — verify signatures, manage sessions, settle on-chain. No API keys. No recurring charges.

What This Is

A human connects their crypto wallet, signs a one-time EIP-2612 Permit (gasless — no transaction fee), and receives a session token. AI agents use this token in MCP requests to pay for tool calls with USDC on Base. The server settles each call on-chain via transferFrom.

No API keys. No recurring charges. No per-call wallet signatures. The permit is the policy.

This is the reference implementation used by mcpvot.xyz — an x402 payment facilitator for MCP servers. The open-source core (@mcp-agentic-wallet/core) is framework-agnostic and works with any MCP server or Next.js app.

Quick Start

1. Install the core library

npm install @mcp-agentic-wallet/core viem

2. Use in your MCP server

import { InMemoryStore, settleCall } from '@mcp-agentic-wallet/core';

const store = new InMemoryStore();

// In your MCP tool handler:
const token = req.headers.get('Session-Token');
const session = store.getSession(token);
if (!session) return new Response('Payment required', { status: 402 });

// Consume budget ($0.005 = 5000 atomic USDC units)
const result = store.consumeBudget(token, 5000n);
if (!result.ok) return new Response('Insufficient budget', { status: 402 });

// Settle on-chain
await settleCall(session.humanAddress, 5000n, {
  treasuryAddress: process.env.TREASURY_ADDRESS!,
  hotWalletKey: process.env.HOT_WALLET_PRIVATE_KEY,
});

return Response.json({ result: 'your data' });

3. Run the reference server

git clone https://github.com/MCPVOT/mcp-agentic-wallet.git
cd mcp-agentic-wallet
npm install
cp .env.example .env.local  # Configure your treasury + hot wallet key
npm run dev

Visit http://localhost:3000/wallet to connect a wallet and authorize a session.

How It Works

Human                          Server                        Agent
  │                              │                              │
  │── connect wallet ──────────►│                              │
  │── sign EIP-2612 Permit ───►│                              │
  │   (gasless, 1-time)           │── verify signature ──────►│ (on-chain)
  │                              │── submit permit() ────────►│ (on-chain, gas)
  │                              │── create session ──────────┐│
  │◄─ return session token ─────│◄───────────────────────────┘│
  │                              │                              │
  │                              │◄── Session-Token header ────│
  │                              │── consume budget ───────────┐│
  │                              │── transferFrom() ──────────►││ (on-chain, gas)
  │                              │── return tool data ─────────┘│
  │                              │◄──────────────────────────────│

Core Library (@mcp-agentic-wallet/core)

Class/FunctionDescription
InMemoryStoreSession store (in-memory, pluggable for KV/Redis)
verifyPermit()Verifies EIP-712 Permit signature on-chain via viem
settleCall()Executes transferFrom(human, treasury, amount) on Base
submitPermit()Submits the permit() transaction to USDC contract
checkAllowance()Reads on-chain USDC allowance for an owner→spender pair
checkRateLimit()Simple rate limiter (per-wallet)
toSessionInfo()Converts session to safe client-facing info (no permit signature)

Security

See SECURITY.md for the full threat model.

Key features:

  • EIP-712 signature verification — server verifies every permit signature on-chain before creating a session
  • Allowance cap — max $100 USDC per session (configurable)
  • Deadline cap — max 30 days
  • Rate limiting — 5 authorizations per wallet per hour
  • Session revocation — humans can revoke anytime
  • Settlement debt tracking — sessions suspended after 3 failed settlements
  • Spender verification — EIP-712 verification inherently checks spender === treasury

Documentation

  • ARCHITECTURE — system diagram, payment flow, design decisions
  • MCP Integration — step-by-step guide for adding to any MCP server
  • Security Policy — threat model, attack vectors, production checklist
  • Contributing — dev setup, guidelines, PR process
  • Donations — support the project

Tech Stack

  • EIP-2612 (Permit) — gasless approval via typed data signature
  • EIP-712 — typed data signing and verification
  • USDC (FiatTokenV2) on Base Mainnet (chainId 8453)
  • viem — TypeScript Ethereum library
  • Next.js — reference server implementation
  • Model Context Protocol — MCP 2025-11-25 spec

Use Case: iRacing + Blockchain

MCPVOT uses this wallet to power on-chain sim-racing events:

  1. Host creates event — deploys an escrow smart contract on Base with entry fee + prize pool
  2. Drivers connect wallet — sign EIP-2612 Permit via this library, get a session token
  3. Drivers pay entry fee — transferFrom settles the entry to the escrow contract
  4. Race happens in iRacing — server polls iRacing Data API for finish order
  5. Smart contract auto-disburses — verified winners receive USDC/SOL from the prize pool

The iRacing MCP tools (get_race_results, lookup_driver, search_hosted_races) are available at mcpvot.xyz and use the same session-token flow for payment.

Configuration

Env VarRequiredDefaultDescription
TREASURY_ADDRESSYes—Address that receives USDC payments
HOT_WALLET_PRIVATE_KEYYes—EOA private key for gas (never commit to git!)
BASE_RPC_URLNohttps://mainnet.base.orgBase Mainnet RPC
NEXT_PUBLIC_TREASURY_ADDRESSYes—Treasury shown in wallet UI

License

MIT — see LICENSE

How do I install MCP Agentic Wallet — Open Source Session Management For X402?
Copy the stdio config for Cursor, Claude Desktop, Claude Code, or VS Code on this page. It uses the publisher's install, not a PlugMCP proxy.
Does MCP Agentic Wallet — Open Source Session Management For X402 need an API key?
No required environment variable is listed on this record.
What transport does MCP Agentic Wallet — Open Source Session Management For X402 use?
MCP Agentic Wallet — Open Source Session Management For X402 runs locally over stdio.
When was MCP Agentic Wallet — Open Source Session Management For X402 last checked?
Last checked 2026-10-16. Open-source EIP-2612 Permit-based wallet sessions for AI agents using MCP.

No tool list yet. Remote servers get one after the first health check.

plugmcp

Plug any tool into any agent. MCP servers for people who do not write servers. Gateway for volume, n8n for apps.

  • github.com/TODO
  • x.com/TODO
  • linkedin.com/company/TODO

PlugMCP, 2026

Product
  • Browse
  • Install
  • Host your own
  • Voice mode
  • Browser
Directory
  • All MCP servers
  • Agent skills
  • Categories
  • New
  • Voice
  • Submit a server
Developers
  • Docs
  • Blog
  • What is MCP
  • What is WebMCP
  • Status
Company
  • About
  • Contact
  • Terms
  • Privacy
  • DPA