Skip to main content
ME

Mercado Pago

v0.2.1OAuth2

Checkout Pro, Pix, boleto, card. Marketplace split. The LatAm-wide payments gateway that actually works across borders.

30 tools1 env vars🌎 LATAMstable on npm

What your agent can do

Mercado Pago gives your agent 30 tools it calls directly β€” pick the ones it needs, in Claude, Cursor, or any MCP client.

  • create_payment β€” Create a new payment
  • get_payment β€” Get payment details by ID
  • search_payments β€” Search payments with filters
Example call
// Your agent calls a tool directly β€” no glue code.
// CodeSpar's managed tier handles OAuth2, token rotation and rate limits.
const result = await session.call("create_payment", { /* ... */ });

Install

terminal
$ npm install @codespar/mcp-mercado-pago

Quickstart

Add this entry to your claude_desktop_config.json (or any MCP-compatible client config).

claude_desktop_config.json
{
  "mcpServers": {
    "mercado-pago": {
      "command": "npx",
      "args": [
        "-y",
        "@codespar/mcp-mercado-pago"
      ],
      "env": {
        "MERCADO_PAGO_ACCESS_TOKEN": "<your_mercado_pago_access_token>"
      }
    }
  }
}

After restart, your agent can call any of the 30 tools below β€” try create_payment first.

Environment variables Β· 1

Required to authenticate the server. Stored encrypted when using CodeSpar managed hosting.

MERCADO_PAGO_ACCESS_TOKEN
requiredsecret

API key/token for mercado-pago

Available tools Β· 30

Each tool is independent β€” your agent loads only what it needs to reduce context and response time.

WRITEcreate_payment
Create a new payment
WRITEget_payment
Get payment details by ID
WRITEsearch_payments
Search payments with filters
DELETEcreate_refund
Refund a payment (full or partial)
WRITEcreate_preference
Create a checkout preference for Checkout Pro
READget_preference
Get checkout preference by ID
WRITEcreate_customer
Create a customer
READlist_customers
List customers

Compatible frameworks

MCP is a protocol β€” any framework that speaks it can mount this server.

Claude Agent SDKAnthropic
OpenAI AgentsOpenAI
Vercel AI SDKVercel
LangChainLangChain
LlamaIndexLlamaIndex
CrewAICrewAI
MastraMastra
Any MCP clientProtocol

Frequently asked questions

Run `npx -y @codespar/mcp-mercado-pago` and add the config block above to your MCP client β€” Claude, Cursor, VS Code, or any MCP-compatible client. No build step, no SDK required. Prefer hosted? CodeSpar's managed tier runs it for you with auth handled.
Mercado Pago β€” MCP server Β· 30 tools | CodeSpar