About mcp-mercado-pago
An MCP server for the Mercado Pago payment platform, aimed at payment and checkout workflows in Latin America. It exposes 30 tools covering payments, Checkout Pro, PIX, refunds, subscriptions and merchant orders.
Key features
- 01Payment creation, lookup and search
- 02Full or partial refunds
- 03Checkout Pro preference management
- 04PIX payment creation
- 05Subscription (preapproval) management
- 06Marketplace split payments and chargeback evidence upload
Use cases
- 01Creating PIX or card payments from an agent
- 02Generating Checkout Pro links for an online store
- 03Handling refunds and chargeback disputes
MCP support
This is an MCP server that exposes 30 tools to MCP clients for calling the Mercado Pago API. It authenticates with a Bearer access token set in MERCADO_PAGO_ACCESS_TOKEN.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y @codespar/mcp-mercado-pagoMERCADO_PAGO_ACCESS_TOKENSecretAPI key/token for mercado-pagoLocal servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
30Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| token | string | No | Card token (for credit card payments) |
| amount | number | Yes | Payment amount |
| description | string | Yes | Payment description |
| payer_email | string | Yes | Payer email address |
| installments | number | No | Number of installments (default 1) |
| payment_method_id | string | Yes | Payment method ID (e.g. pix, credit_card, bolbradesco) |
Details
From the project README@codespar/mcp-mercado-pago
MCP server for Mercado Pago, the leading payment platform in Latin America
Quick Start
Claude Desktop
Add to ~/.config/claude/claude_desktop_config.json:
{
"mcpServers": {
"mercado-pago": {
"command": "npx",
"args": ["-y", "@codespar/mcp-mercado-pago"],
"env": {
"MERCADO_PAGO_ACCESS_TOKEN": "APP_USR-..."
}
}
}
}
Claude Code
claude mcp add mercado-pago -- npx @codespar/mcp-mercado-pago
CLI
# Set your access token
export MERCADO_PAGO_ACCESS_TOKEN="APP_USR-..."
# Run via stdio
npx -y @codespar/mcp-mercado-pago
# Run via HTTP
MCP_HTTP=true MCP_PORT=3000 npx -y @codespar/mcp-mercado-pago
Tools (30)
| Tool | Purpose |
|---|---|
create_payment | Create a new payment |
get_payment | Get payment details by ID |
search_payments | Search payments with filters |
create_refund | Refund a payment (full or partial) |
create_preference | Create a checkout preference for Checkout Pro |
get_preference | Get checkout preference by ID |
create_customer | Create a customer |
list_customers | List customers |
get_payment_methods | List available payment methods |
create_pix_payment | Create a PIX payment |
get_merchant_order | Get merchant order by ID |
get_balance | Get account balance |
create_subscription | Create a recurring subscription (preapproval) |
get_subscription | Get subscription (preapproval) details by ID |
cancel_subscription | Cancel a subscription (preapproval) |
create_card_token | Tokenize a card for secure payments |
get_payment_method_details | Get details of a specific payment method by ID |
create_store | Create a store (physical location or POS group) |
list_stores | List stores |
create_pos | Create a point of sale (POS) linked to a store |
update_subscription | Update a subscription (preapproval): amount, status, reason, card token, etc. |
oauth_token_exchange | Exchange an authorization code for a seller access token (marketplace onboarding). |
create_advanced_payment | Create a marketplace split payment with per-recipient disbursements (application_fee, money_release_days, c... |
get_advanced_payment | Get an advanced (split) payment by ID |
get_chargeback | Get chargeback details by ID |
upload_chargeback_evidence | Upload documentation/evidence for a chargeback dispute. |
get_identification_types | Get document/identification types available per country (CPF, CNPJ, DNI, RUT, etc.). |
get_payment_methods_by_site | List available payment methods for a specific Mercado Pago site (MLB=Brazil, MLA=Argentina, MLM=Mexico, MLC... |
create_settlement_report | Manually generate a settlement (account money) report for a date range. |
search_merchant_orders | Search merchant orders with filters (last 90 days). |
Environment Variables
| Variable | Required | Description |
|---|---|---|
MERCADO_PAGO_ACCESS_TOKEN | Yes | Access token from Mercado Pago dashboard |
MCP_HTTP | No | Set to "true" to enable HTTP transport |
MCP_PORT | No | HTTP port (default: 3000) |
Authentication
Uses Bearer token authentication. Set this environment variable before launching the server:
MERCADO_PAGO_ACCESS_TOKEN(required, secret): access token for Mercado Pago
Issue credentials at the Mercado Pago Developers dashboard.
API Reference
Enterprise
Need governance, budget limits, and audit trails for agent payments? CodeSpar Enterprise adds policy engine, payment routing, and compliance templates on top of these MCP servers.
License
MIT
Comments
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.