Skip to main content
M

MoonPay

@codespar/mcp-moonpay Β· v0.2.2

🌐 GlobalCryptoAuth · API Keybeta20 tools6 env vars

Fiat↔crypto on/off-ramp. Broader coverage than UnblockPay (100+ assets, 160+ countries) including BR Pix onramp. Sell-side flows enable agents paying out in crypto.

Get started Β· freeView docs

MIT Β· runs locally with your own credentials

Limitations

  • Hosted calls with a test key are not available: the runtime has not recorded this provider's test behaviour (test venue unclassified).
Package
@codespar/mcp-moonpay
Version
0.2.2
npm dist-tag
latest
Category
Crypto
Auth
API Key
Country
🌐 Global
License
MIT
Transport
stdio Β· streamable-http

Quickstart

Install, set the credentials, make the first call.

Pick your client. The server runs locally over stdio, with your own credentials.

Add the server to your clientOne config entry. No build step, no SDK required.
Set the environment variables6 variables read by this server's code, listed below.
Restart and make the first callThe agent can call any of the 20 tools. Try get_buy_quote first.
terminal
# Claude Code claude mcp add moonpay -e MOONPAY_API_KEY=… -e MOONPAY_BASE_URL=… -e MOONPAY_BUY_WIDGET_URL=… -e MOONPAY_PUBLISHABLE_KEY=… -e MOONPAY_SECRET_KEY=… -e MOONPAY_SELL_WIDGET_URL=… -- npx -y @codespar/mcp-moonpay@0.2.2 # then: /mcp to confirm the server is connected
Environment variables6 variables
MOONPAY_API_KEYMoonPay REST API key (sandbox or production β€” the key selects the environment)requiredsecret
MOONPAY_BASE_URLMoonPay API base URL. Defaults to https://api.moonpay.com.optional
MOONPAY_BUY_WIDGET_URLMoonPay buy widget base URL. Defaults to https://buy.moonpay.com.optional
MOONPAY_PUBLISHABLE_KEYMoonPay publishable key used as `apiKey` in signed widget URLs (required for sign_buy_url / sign_sell_url).optional
MOONPAY_SECRET_KEYMoonPay secret key used to HMAC-SHA256 sign widget URLs (required for sign_buy_url / sign_sell_url).optionalsecret
MOONPAY_SELL_WIDGET_URLMoonPay sell widget base URL. Defaults to https://sell.moonpay.com.optional

Names read from the package code (@codespar/mcp-moonpay@0.2.2). Descriptions and flags come from its manifest. Self-hosted, you hold the credentials.

First call demoget_buy_quote

"Preview a fiat -> crypto buy quote in real time. Use this before create_buy_transaction to show the end user the exact crypto amount, fees, and effective rate"

tools/callget_buy_quoteresult returned

Tools

What your agent can call.

20 tools, as the package's tools/list returns them.

get_buy_quote

Preview a fiat -> crypto buy quote in real time. Use this before create_buy_transaction to show the end user the exact crypto amount, fees, and effective rate.

create_buy_transaction

Create a buy transaction (fiat -> crypto). The returned object contains status plus β€” depending on method β€” redirect URL for hosted checkout, Pix QR data, or card auth next steps.

get_buy_transaction

Retrieve a buy transaction (fiat -> crypto) by its MoonPay id. Returns current status and settlement detail.

list_buy_transactions

List buy transactions with optional filters. Used for reconciliation and agent-driven monitoring.

get_sell_quote

Preview a crypto -> fiat sell quote in real time. Use this before create_sell_transaction to show the end user the exact fiat amount, fees, and effective rate.

create_sell_transaction

Create a sell transaction (crypto -> fiat). Used for agents that need to pay out in local fiat after receiving crypto.

get_sell_transaction

Retrieve a sell transaction (crypto -> fiat) by its MoonPay id.

refund_sell_transaction

Request a refund on an off-ramp (sell) transaction. Used when the destination bank rejects payout or the user disputes the trade. Reason codes are MoonPay-defined.

create_customer

Create a MoonPay customer (KYC'd end user). Required before creating transactions that must be tied to an identified individual.

get_customer

Retrieve a MoonPay customer by id.

get_customer_kyc_status

Fetch KYC verification status (and any pending document requirements) for a MoonPay customer. Use to gate flows that require an approved customer before transacting.

list_customer_transactions

List all transactions (buy + sell) tied to a single MoonPay customer. Convenience wrapper for unified history / reconciliation by user.

Names and descriptions come from the package's tools/list (@codespar/mcp-moonpay@0.2.2). A kind (read, write, delete) is shown only when the package annotates its tools or each tool was verified one by one; neither exists for this server yet.

Compatibility

MCP is a protocol. Any client that speaks it can mount this server.

codespar_discover lists this server's tools, but a project with a test key cannot call them yet: the runtime has not recorded what this provider does in test mode, and refuses rather than guess.

Protocol

Any MCP client

stdio Β· streamable-http

Questions

Before you install.

How do I install the MoonPay MCP server?

Run npx -y @codespar/mcp-moonpay@0.2.2 and add the config block above to your MCP client: Claude Code, Cursor, Claude Desktop, VS Code, or any MCP-compatible client. No build step, no SDK required.

What can my agent do with MoonPay?

MoonPay exposes 20 tools for crypto. Your agent calls them directly; the full list is above.

How does MoonPay authenticate, and how are credentials stored?

MoonPay uses API Key. Self-hosted, you hold the credentials: the server reads them from its environment variables.

How does MoonPay handle upstream API changes?

Every server is versioned independently on npm. The command on this page pins 0.2.2, the version whose tools are listed here; your agent keeps running it until you change the version.

Is MoonPay open source? How do I report a bug?

Yes. MoonPay is MIT-licensed and published on npm as @codespar/mcp-moonpay, source on GitHub (link in the Details panel). Report issues on the package repository; security issues go to security@codespar.dev, and we respond within 24 hours.

Start in seconds.

Add the config above, set the variables, and your agent calls the tools.

Start in seconds demo
Add the server to your client with the config above.
Set the environment variables listed above.
Ask your agent for the first call.
MoonPay β€” MCP server Β· 20 tools | CodeSpar