mcpField
X
x402 Research

x402 Research

Local
x402-research-iota.vercel.appFinance0Updated 3d ago

About x402 Research

x402 Research is an MCP server for pay-per-call crypto research and Base address risk checks. It defaults to Base Sepolia testnet and caps spending per call and per session.

Key features

  1. 01Query asset signals and briefs
  2. 02Batch-query up to 10 assets
  3. 03Check address risk and approvals
  4. 04Decode invoices and check settlement
  5. 05Preview payment terms and set price limits
  6. 06Cap per-call and session spending

Use cases

  1. 01Retrieve crypto asset signals or briefs
  2. 02Review Base address risk and token approvals
  3. 03Preview x402 payment terms before paying

MCP support

This stdio MCP server exposes tools that call the x402 Research API. It uses Base Sepolia by default; when a wallet key is configured, payments are signed by the local process and subject to configured caps.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"kevinm222-x402-research": {
"command": "npx",
"args": [
"-y",
"@agentfirm402/x402-research-mcp"
],
"env": {
"X402_NETWORK": "<X402_NETWORK>",
"X402_BUYER_PRIVATE_KEY": "<X402_BUYER_PRIVATE_KEY>"
}
}
}
}
Run commandnpx -y @agentfirm402/x402-research-mcp
Environment variables to set
X402_NETWORKNetwork: eip155:84532 (Base Sepolia, default) or eip155:8453 (Base mainnet)
X402_BUYER_PRIVATE_KEYSecretBuyer wallet key that pays per call (capped 0.10 USDC/call, 0.50/session on mainnet)

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npm@agentfirm402/x402-research-mcp0.5.0

Tools

9

Saved tool list · updated 3d ago

ParameterTypeRequiredDescription
assetenumYesbtc | eth | sol | xrp | doge | ada | avax | link | dot | ltc | bch | uni | aave | xlm | hbar | shib | sui | near | atom | fil
previewbooleanNotrue = return the 402 terms without paying
max_price_usdcnumberNoRefuse if the offer exceeds this (can only lower X402_MAX_PRICE_USDC)

Details

From the project README

x402-research-mcp

MCP (stdio) server for the x402-research pay-per-call API. Testnet (Base Sepolia) by default. Base mainnet only if you explicitly set X402_NETWORK=eip155:8453. The publisher never holds keys: payments come from your wallet key, supplied by you via env var, and are capped per call and per session.

Warning

Use a dedicated, low-balance wallet: never your main wallet. Create a fresh key just for this server and fund it with only a few USDC (on mainnet, a little more than your session cap). Anyone or anything that can read your MCP client config or this process's environment can spend that wallet's funds. The caps limit what this server signs, not what a leaked key can do.

Tools (prices per call, USDC on Base, from /llms.txt)

toolrouteprice
signal(asset)GET /api/signal/{asset}0.003
signal_batch(assets[≤10])GET /api/signal-batch?assets=0.02
brief(asset)GET /api/brief/{asset}0.03
risk_snapshot(address)GET /api/firm/risk-snapshot?address=0.03
invoice_decode(header)POST /api/x402/invoice-decode0.02
settlement_status(tx)GET /api/x402/settlement-status?tx=0.02
approval_enumerate(address)GET /api/x402/approval-enumerate?address=0.03
preflight(address, invoice?)GET /api/x402/preflight?address=[&invoice=]0.05
session_status()localfree

Assets: btc eth sol xrp doge ada avax link dot ltc bch uni aave xlm hbar shib sui near atom fil. Every paid tool also accepts preview: true (return the 402 terms, pay nothing) and max_price_usdc.

Safety

  • Preview mode is on whenever X402_BUYER_PRIVATE_KEY is unset or X402_PREVIEW=1: tools return the decoded 402 terms and never sign.
  • Per-call max X402_MAX_PRICE_USDC (default 0.10). A tool's max_price_usdc can only lower it.
  • Session cap X402_SESSION_CAP_USDC (default 0.50). A call that would push spend over the cap is refused before signing. Spend is counted when a signed payment is sent. It resets when the server process restarts.
  • Offers are refused if they're above the advertised price, on another network, not the exact scheme, or in a non-canonical USDC asset.
  • payTo allowlist (hardcoded): signal, signal_batch and brief pay only 0xacfca8bc6567e7db35ad8c814756695dad1cfb30. risk_snapshot, invoice_decode, settlement_status, approval_enumerate and preflight pay only 0xa26f179e42836bc4ae0cea997fdfc9602d5b8147. Any other recipient is refused, even if X402_RESEARCH_URL points elsewhere.
  • The server never logs its environment or the key, and error messages don't echo config.
  • There is no way to pass in a pre-signed payment: every payment is signed by this server under the caps above.
  • Use a dedicated hot wallet holding only a few USDC. The key stays in the local process and is never logged or returned.

Config

vardefault
X402_NETWORKeip155:84532 (Base Sepolia). Set eip155:8453 for Base mainnet
X402_RESEARCH_URLhttps://x402-research-iota.vercel.app (mainnet-only; testnet needs a Sepolia deployment)
X402_BUYER_PRIVATE_KEYunset → preview only
X402_MAX_PRICE_USDC / X402_SESSION_CAP_USDC0.10 / 0.50
X402_PREVIEWunset (1 forces preview)

Install

Claude Desktop (claude_desktop_config.json) or Cursor (~/.cursor/mcp.json):

{
  "mcpServers": {
    "x402-research": {
      "command": "npx",
      "args": ["-y", "@agentfirm402/x402-research-mcp"],
      "env": {
        "X402_NETWORK": "eip155:8453",
        "X402_PREVIEW": "1"
      }
    }
  }
}

Start in preview. To pay, remove X402_PREVIEW and add "X402_BUYER_PRIVATE_KEY": "0x…" (a dedicated low-balance wallet, never your main one), and optionally "X402_SESSION_CAP_USDC": "0.25".

Tests

npm test runs offline against local mocks with throwaway keys and no funds. It covers unit refusals for each check, preview with no key, and a stdio leak test that greps all stdout and stderr for /0x[0-9a-fA-F]{64}/. npm run test:mainnet-preview makes live mainnet 402 calls in preview mode and pays nothing.

Release

Dependencies are pinned exactly, with a committed lockfile. Publishing happens only through .github/workflows/mcp-publish.yml (manual dispatch, npm publish --provenance).

Informational only. Not financial advice. MIT.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.