Prototype · Preview: every server in the official registry, synced every 30 minutes. Sign in with Google to write reviews.
PopNx MCPMCP servers for people who use AI · explained in plain words

X402 API

by fernsugiversion 1.0.5i★ 0iRuns on your computer
Registry nameio.github.fernsugi/x402-api

How to install

Overview

Description from the maker (original English)

Eight paid DeFi tools: prices, gas, swaps, token security, holders, yields, funding and wallets

What you can do with it

We have not written a plain-language summary for this one yet. Below are the facts we read from the registry.

  • Connection: Runs on your computer
  • Transport: stdio
  • Category: Crypto & blockchain
  • You need to fill in: X402_WALLET_PRIVATE_KEY

Install

Pick the AI app you use, then copy the settings.

Passed 2/2 checks · Runs on your computer

First: which AI do you use?

Pick your app and the steps appear below.

Works with Claude, with some setup first

You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone

  1. Install Node.js

    One time only; it works for every server that needs Node.js

    Open the Node.js download page ↗

  2. Sign up and create a X402 API key

    Open the maker’s site, sign up and create an API key for the next step. It may cost money.

    How to get a key is in the maker’s README below

  3. Open the Claude desktop app’s settings file

    SettingsDeveloperEdit Config

  4. Paste these settings and save the file

    {
      "mcpServers": {
        "x402-api": {
          "command": "npx",
          "args": [
            "-y",
            "@x402-api/mcp-server"
          ],
          "env": {
            "X402_API_BASE_URL": "your-value",
            "X402_WALLET_PRIVATE_KEY": "your-value",
            "X402_MAX_PER_CALL_USDC": "your-value",
            "X402_REFERRAL_SOURCE": "your-value",
            "X402_EXPECTED_PAY_TO": "your-value"
          }
        }
      }
    }

    Paste the key only into the app’s field, never into a chat or to anyone

  5. Quit Claude and open it again

  6. Try it

    Use X402 API and tell me what you can do for me, then show me one thing

    ✓ If Claude says it is using X402 API or shows a X402 API tool in the answer, you are connected

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

ChatGPT cannot connect X402 API yet

X402 API runs on your computer, but ChatGPT can only connect servers that run on the web

What you can do instead

A · Use an app that can connect X402 API

  • You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone
  • You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)
  • You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)
  • You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)

B · Others in Crypto & blockchain that work with ChatGPT

Picked from the most used in the same category, only ones that connect by address with no key

Works with Claude Code, with some setup first

You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)

  1. Install Node.js

    One time only; it works for every server that needs Node.js

    Open the Node.js download page ↗

  2. Sign up and create a X402 API key

    Open the maker’s site, sign up and create an API key for the next step. It may cost money.

    How to get a key is in the maker’s README below

  3. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: open PowerShell

  4. Paste this command and press Enter

    claude mcp add x402-api --env X402_API_BASE_URL=your-value --env X402_WALLET_PRIVATE_KEY=your-value --env X402_MAX_PER_CALL_USDC=your-value --env X402_REFERRAL_SOURCE=your-value --env X402_EXPECTED_PAY_TO=your-value -- npx -y @x402-api/mcp-server

    Replace “your-value” with your key before pressing Enter

    Paste the key only into the app’s field, never into a chat or to anyone

  5. Type /mcp in Claude Code

    You should see X402 API listed as connected

  6. Try it

    Use X402 API and tell me what you can do for me, then show me one thing

    ✓ If Claude Code says it is using X402 API or shows a X402 API tool in the answer, you are connected

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with Cursor, with some setup first

You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)

  1. Install Node.js

    One time only; it works for every server that needs Node.js

    Open the Node.js download page ↗

  2. Sign up and create a X402 API key

    Open the maker’s site, sign up and create an API key for the next step. It may cost money.

    How to get a key is in the maker’s README below

  3. Click this button to open Cursor

    Open in Cursor

    Cursor asks you to confirm; click Install

  4. Fill in your key

    In the X402 API settings, X402_API_BASE_URL, X402_WALLET_PRIVATE_KEY, X402_MAX_PER_CALL_USDC, X402_REFERRAL_SOURCE, X402_EXPECTED_PAY_TO is empty; add your key and save

    Paste the key only into the app’s field, never into a chat or to anyone

  5. Open the AI chat in Cursor in Agent mode

  6. Try it

    Use X402 API and tell me what you can do for me, then show me one thing

    ✓ If Cursor says it is using X402 API or shows a X402 API tool in the answer, you are connected

Menu names checked against Cursor’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with VS Code, with some setup first

You need a X402 API key (sign up on the maker’s site, may cost money) · Install Node.js on your computer first (one time)

  1. Install Node.js

    One time only; it works for every server that needs Node.js

    Open the Node.js download page ↗

  2. Sign up and create a X402 API key

    Open the maker’s site, sign up and create an API key for the next step. It may cost money.

    How to get a key is in the maker’s README below

  3. Click this button to open VS Code

    Open in VS Code

    VS Code asks you to confirm; click Install

  4. Fill in your key

    In the X402 API settings, X402_API_BASE_URL, X402_WALLET_PRIVATE_KEY, X402_MAX_PER_CALL_USDC, X402_REFERRAL_SOURCE, X402_EXPECTED_PAY_TO is empty; add your key and save

    Paste the key only into the app’s field, never into a chat or to anyone

  5. Open the AI chat in VS Code in Agent mode

  6. Try it

    Use X402 API and tell me what you can do for me, then show me one thing

    ✓ If VS Code says it is using X402 API or shows a X402 API tool in the answer, you are connected

Menu names checked against VS Code’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Other apps that use MCP, such as Windsurf, Zed or Gemini CLI, each add servers differently. See how in the app list.

See every app that uses MCP →

JSON settings are under “For developers” below

Stuck? Ask people who use X402 API💬 Discussion →
For developers: Terminal commands and JSON settings

Installed on your computer

Claude Code

claude mcp add x402-api --env X402_API_BASE_URL=your-value --env X402_WALLET_PRIVATE_KEY=your-value --env X402_MAX_PER_CALL_USDC=your-value --env X402_REFERRAL_SOURCE=your-value --env X402_EXPECTED_PAY_TO=your-value -- npx -y @x402-api/mcp-server

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "x402-api": {
      "command": "npx",
      "args": [
        "-y",
        "@x402-api/mcp-server"
      ],
      "env": {
        "X402_API_BASE_URL": "your-value",
        "X402_WALLET_PRIVATE_KEY": "your-value",
        "X402_MAX_PER_CALL_USDC": "your-value",
        "X402_REFERRAL_SOURCE": "your-value",
        "X402_EXPECTED_PAY_TO": "your-value"
      }
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "x402-api": {
      "command": "npx",
      "args": [
        "-y",
        "@x402-api/mcp-server"
      ],
      "env": {
        "X402_API_BASE_URL": "your-value",
        "X402_WALLET_PRIVATE_KEY": "your-value",
        "X402_MAX_PER_CALL_USDC": "your-value",
        "X402_REFERRAL_SOURCE": "your-value",
        "X402_EXPECTED_PAY_TO": "your-value"
      }
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "x402-api": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@x402-api/mcp-server"
      ],
      "env": {
        "X402_API_BASE_URL": "your-value",
        "X402_WALLET_PRIVATE_KEY": "your-value",
        "X402_MAX_PER_CALL_USDC": "your-value",
        "X402_REFERRAL_SOURCE": "your-value",
        "X402_EXPECTED_PAY_TO": "your-value"
      }
    }
  }
}

Values you fill in

  • X402_API_BASE_URL env
    x402 API base URL (default: https://x402-api.fly.dev)
  • X402_WALLET_PRIVATE_KEY secret env
    Base wallet private key for optional EIP-3009 auto-pay. Default mode inspects payment requirements without paying.
  • X402_MAX_PER_CALL_USDC env
    Maximum USDC allowed per automatic tool call (default: 0.01)
  • X402_REFERRAL_SOURCE env
    Optional referral label: github, glama, nohumans, bazaar, mcp, eliza, demo or test. Default mcp.
  • X402_EXPECTED_PAY_TO env
    Expected payment recipient; defaults to the official x402-api wallet. Change only when using a trusted alternative deployment.

These settings are generated from the maker’s registry entry. If the README says otherwise, follow the README.

At a glance

Downloads per weeki
119/wk
Licencei
No licence stated
Connection
Runs on your computer
Latest versioni
1.0.5
Published to registryi
Sep 30, 2026
Code last changedi
Sep 30, 2026
Maker
fernsugi
Packages
npm: @x402-api/mcp-server
Registry status
Active

Which apps can use it

Based on how this server connects and on each app’s own docs, checked Nov 10, 2026.

Run on your computer in

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

All apps, with pros and cons →

Related guides

What it can do

Runs on your computer; the tool list appears in your AI app after you install it.

Basic checksi

We check information anyone can see; we have not read the code. Checks that do not apply are left out of the count. · Checked Nov 11, 2026

  • ✓ Pass

    Maker matches the repo

    The registry name was verified with the GitHub account fernsugi, which owns the repo

  • ✓ Pass

    Still maintained

    Code last changed 42 days ago

  • … Not checked yet

    Has a licence

    We have not read this repo from GitHub yet

  • – Not applicable

    Endpoint responds

    This one runs on your computer; there is no internet endpoint

  • – Not applicable

    Sign-in with OAuth

    Runs on your computer and uses local settings instead

  • … Not checked yet

    No hidden instructions in tool descriptions

    Runs on your computer; we can only read tool lists from internet endpoints

Discussion

Ask, share a tip or report that it does not work. Sorted by what people marked helpful.

No posts yet. Be the first to ask or share.

Posts here are written by users, not the PopNx team.

Sign in with Google to post

User reviews

No reviews yet

Sign in with Google to write a review

Compared with others in Crypto & blockchaini

  • More stars than 0% of the other 1643 servers in this category
  • Published to the registry more recently than 54% of the other 1643 servers in this category
  • Basic checks equal to or better than 100% of the other 1643 servers in this category

Compared with every active server in this category in the registry. Stars count only when the publisher owns the repo.

Common questions

Is X402 API safe?

It passed 2 of 2 applicable basic checks. We have not read the code. Before adding a key or token, see what access the server asks for and use a key with only the permissions you need.

What keys or codes does it need?

You need to fill in: X402_WALLET_PRIVATE_KEY

Does it run on my computer or in the cloud?

It runs on your computer. Your AI app starts it when needed, and data does not pass through the maker’s servers (unless it calls an online service itself).

Is it still maintained?

The GitHub repo last changed 42 days ago, and the latest version (1.0.5) reached the registry 42 days ago.

Which apps can use it?

Apps that support MCP, such as Claude Desktop, Claude Code, Cursor and VS Code. You also need Node.js on your computer.

What can I use instead?

In the same category: Solana MCP by Vybe, Oracle3 prediction-market arbitrage checks, Polymarket Paper Trader

Alternatives

Servers in the same category from other makers, sorted by stars.

Reading a card:↓ Downloads per weeki★ GitHub starsiThree pillars: reviews · checks · usageiUpdated = latest version published to the registryi

Solana MCP by Vybe

Solana MCP developer toolkit: wallets, trades, markets, PnL, transfers, onchain, swaps & API tools.

by vybenetworkWidely used★ 2.6K Stars for the whole repoUpdated 6 months ago

Runs in the cloud

Polymarket Paper Trader

Polymarket paper trading for AI agents: $10k paper money, real order books, official fees.

by agent-nextGrowing↓ 226/wk★ 504Updated 26 days ago

Runs on your computer

README from the maker

Open the README

Copied from the maker’s repo as written. PopNx MCP has not reviewed or endorsed it. HTML, images and scripts are removed. Links lead off this site.

@x402-api/mcp-server

MCP server that gives Claude, ChatGPT, and any MCP-compatible AI agent access to pay-per-call crypto/DeFi data via the x402 protocol.

8 tools. No API keys. AI agents pay USDC micropayments on Base, per request.

Find this service: Official MCP Registry · Glama · Agent discovery manifest · OpenAPI.

  ██╗  ██╗██╗  ██╗ ██████╗ ██████╗

╚██╗██╔╝██║ ██║██╔═══██╗╚════██╗ ╚███╔╝ ███████║██║ ██║ █████╔╝ ██╔██╗ ╚════██║██║ ██║██╔═══╝ ██╔╝ ██╗ ██║╚██████╔╝███████╗ ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚══════╝

Tools

ToolAPI EndpointCostDescription
get_crypto_pricesGET /api/price-feed0.001 USDCBTC/ETH/SOL + top 24h movers
get_gas_pricesGET /api/gas-tracker0.001 USDCMulti-chain gas (ETH, Base, Polygon, Arbitrum)
get_dex_quotesGET /api/dex-quotes0.002 USDCOne ParaSwap aggregate route
scan_tokenGET /api/token-scanner0.003 USDCGoPlus security flags and heuristic
track_whalesGET /api/whale-tracker0.005 USDCTop-holder sample and supply share
scan_yieldsGET /api/yield-scanner0.005 USDCDefiLlama pool APYs and TVL
get_funding_ratesGET /api/funding-rates0.008 USDCHyperliquid and dYdX hourly rates
profile_walletGET /api/wallet-profiler0.008 USDCObserved Blockscout balances; partial coverage

Quick Start

Option A: Inspect mode (no payment needed)

Just run it — any 402 responses will return human-readable payment instructions:

npx @x402-api/mcp-server

Claude will tell you what's needed when a tool requires payment.

Option B: Auto-pay mode (fully autonomous)

Install optional payment deps and set your wallet key:

npm install -g @x402-api/mcp-server

npm install -g viem export X402_WALLET_PRIVATE_KEY=0x x402-api-mcp

The MCP server signs Base USDC EIP-3009 authorizations only when the API advertises that settlement mode. The default payment cap is 0.01 USDC per call. Fund the wallet with USDC on Base; the API operator sponsors gas in direct settlement mode.


Claude Desktop Integration

Add to your claude_desktop_config.json:

Without auto-pay (inspect mode)
{

"mcpServers": { "x402-api": { "command": "npx", "args": ["@x402-api/mcp-server"] } } }

With auto-pay
{

"mcpServers": { "x402-api": { "command": "npx", "args": ["@x402-api/mcp-server"], "env": { "X402_WALLET_PRIVATE_KEY": "0x " } } } }

Config file location:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

Environment Variables

VariableRequiredDescription
X402_WALLET_PRIVATE_KEYOptionalBase wallet private key for EIP-3009 automatic payment. Requires viem.
X402_MAX_PER_CALL_USDCOptionalPer-call cap, default 0.01 USDC.
X402_API_BASE_URLOptionalOverride API URL (default: https://x402-api.fly.dev)

How x402 Payments Work

This API uses the x402 protocol — HTTP 402 Payment Required:

  1. Agent calls tool → MCP server makes API request
  2. Server returns 402 with payment details (amount, USDC address, Base network)
  3. Auto-pay mode: this client signs an EIP-3009 authorization and retries; the API settles it on Base
  4. Inspect mode: MCP returns 402 details without signing or paying

Payment details:

  • Token: USDC on Base mainnet
  • Address: 0x60264c480b67adb557efEd22Cf0e7ceA792DefB7
  • Chain: Base (chain ID 8453)
  • Amount: 0.001–0.008 USDC per call (< 1 cent USD)

Tool Reference

get_crypto_prices

No parameters. Returns current prices for BTC, ETH, SOL + top 24h movers.

Cost: 0.001 USDC
get_gas_prices

No parameters. Returns gas prices for Ethereum, Base, Polygon, Arbitrum — slow/standard/fast tiers.

Cost: 0.001 USDC
get_dex_quotes

Get one ParaSwap aggregate route. No independent comparison between DEX venues.

ParameterTypeRequiredDescription
fromstring✅Input token (e.g. "ETH", "0x...")
tostring✅Output token (e.g. "USDC")
amountstring✅Amount to swap (e.g. "1.5")
Cost: 0.002 USDC
scan_token

Token security scan — detects rug-pull flags, honeypot patterns, mint authority, etc.

ParameterTypeRequiredDescription
tokenstring✅Contract address or symbol (e.g. "PEPE")
Cost: 0.003 USDC
track_whales

Top-holder sample from GoPlus. Gini and recent transfer history unavailable.

ParameterTypeRequiredDescription
tokenstring✅Contract address or symbol
Cost: 0.005 USDC
scan_yields

Top DeFi yield opportunities across Aave, Compound, Morpho, Lido, Pendle, etc.

ParameterTypeRequiredDescription
chainstring❌Filter by chain: "ethereum", "base", "arbitrum", "polygon"
min_tvlnumber❌Minimum TVL in USD (e.g. 1000000)
Cost: 0.005 USDC
get_funding_rates

Hourly perpetual funding from Hyperliquid and dYdX v4. Spreads are indicative.

ParameterTypeRequiredDescription
assetstring❌Asset symbol (e.g. "BTC", "ETH"). All assets if omitted.
Cost: 0.008 USDC
profile_wallet

Observed priced wallet balances and available transaction counts. DeFi positions, PnL and risk score unavailable.

ParameterTypeRequiredDescription
addressstring✅Ethereum/Base wallet address (0x...)
Cost: 0.008 USDC

Development

git clone https://github.com/fernsugi/x402-api-mcp-server

cd x402-api-mcp-server

npm install npm run build npm start

To test without a payment wallet, simply run and see the 402 responses:

node dist/index.js

Links


License

MIT

Three runnable workflows

WorkflowToolsTotal USDC
Token checkscan_token + track_whales0.008
ETH fundingget_funding_rates0.008
Swap quote + gasget_dex_quotes + get_gas_prices0.003

Runnable Node examples start in inspect mode. Each demo has inputs, recorded provider output, coverage limits, a spending cap, and an agent prompt.

Optional X402_REFERRAL_SOURCE labels requests for first-party aggregate attribution (default mcp). It is a hint, not verified caller identity. The API journals no raw payer wallets, IP addresses, or signatures. X402_EXPECTED_PAY_TO pins the payment recipient to the official wallet by default. Tools advertise that auto-pay can spend money and repeated calls can incur another charge.

Cursor / other local MCP clients

Use the same mcpServers configuration shown above. For Cursor, put it in .cursor/mcp.json in your project. Inspect mode needs no wallet. Set X402_MAX_PER_CALL_USDC before enabling auto-pay; repeated calls spend again. Keep wallet credentials in local environment settings, outside Git.

Registry publication

The Publish MCP Registry GitHub workflow validates the matching npm version, then publishes server.json using GitHub OIDC. It runs on a published GitHub release or a manual dispatch from main. No npm token, GitHub PAT, or wallet key is stored in CI. Actions and official publisher source are pinned to verified commits. npm publication still happens separately before creating the release.