About mcp-airwallex
mcp-airwallex is an MCP server for Airwallex, covering cross-border collection, global accounts, FX conversion and payouts to beneficiaries. It is aimed at LatAm sellers who collect USD, EUR or GBP from abroad and settle locally. It runs in the opposite direction to mcp-ebanx, so the two can be used together.
Key features
- 01Payment intent creation, confirmation, capture and cancellation
- 02Refunds and customer management
- 03Beneficiary creation and cross-border transfers
- 04FX conversion and wallet balance retrieval
- 05Required request_id on create tools for idempotent retries
Use cases
- 01Collecting foreign-currency payments from overseas buyers
- 02Sending cross-border transfers to overseas beneficiaries
- 03Checking wallet balances and converting between currencies
MCP support
The server exposes Airwallex payment, beneficiary, transfer and balance operations to MCP clients as tools. Authentication uses a token flow that the server caches in memory and refreshes automatically.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y @codespar/mcp-airwallexAIRWALLEX_CLIENT_IDAirwallex client id (sent as x-client-id on /authentication/login)AIRWALLEX_API_KEYSecretAirwallex API key, secret (sent as x-api-key on /authentication/login)AIRWALLEX_ENVAirwallex environment. 'demo' (default, https://api-demo.airwallex.com) or 'production' (https://api.airwallex.com).Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
20Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| order | object | No | Order detail (products, shipping, type). Structure per Airwallex /pa/payment_intents/create. |
| amount | number | Yes | Amount in major units (e.g. 10.50 = 10.50 USD) |
| currency | string | Yes | ISO-4217 currency code (USD, EUR, GBP, etc) |
| metadata | object | No | Free-form metadata key/value pairs |
| descriptor | string | No | Statement descriptor shown on buyer's statement |
| request_id | string | Yes | Idempotency key (UUID recommended). Agents control idempotency — do not reuse. |
| return_url | string | No | Browser return URL after hosted flow |
| customer_id | string | No | Optional Airwallex customer id (from create_customer) to attach the intent to a saved customer |
| merchant_order_id | string | Yes | Merchant-side order reference |
Details
From the project README@codespar/mcp-airwallex
MCP server for Airwallex — embedded finance for cross-border collection and payouts.
EBANX lets global platforms collect FROM LatAm and settle to USD. Airwallex is the inverse: LatAm sellers collect FROM abroad (USD, EUR, GBP) into global accounts, convert FX, and pay beneficiaries out across 150+ countries. Together the two servers bracket the cross-border flow both ways.
Tools (20)
| Tool | Purpose |
|---|---|
create_payment_intent | Create an Airwallex payment intent (pay-in). |
confirm_payment_intent | Confirm a previously-created payment intent with a payment method. |
retrieve_payment_intent | Retrieve a payment intent by id. |
cancel_payment_intent | Cancel a payment intent that has not yet been captured. |
capture_payment_intent | Capture a previously-authorized payment intent (two-step auth + capture flow). |
list_payment_intents | List payment intents with optional filters (status, merchant_order_id, date range). |
create_refund | Refund a captured payment intent (full or partial). |
retrieve_refund | Retrieve a refund by id. |
create_customer | Create an Airwallex customer for saved payment methods and recurring charges. |
retrieve_customer | Retrieve a customer by id. |
update_customer | Update fields on an existing customer (email, phone, address, metadata). |
create_beneficiary | Create a transfer beneficiary (recipient) with bank details. |
retrieve_beneficiary | Retrieve a beneficiary by id. |
list_beneficiaries | List beneficiaries. |
create_transfer | Send a cross-border transfer to a pre-created beneficiary. |
retrieve_transfer | Retrieve a transfer by id. |
cancel_transfer | Cancel a transfer that has not yet settled. |
list_transfers | List transfers with optional filters (status, date range). |
create_conversion | Execute an FX conversion between wallet currencies (e.g. |
retrieve_balance | Retrieve the current wallet balance for every currency the account holds. |
Install
npm install @codespar/mcp-airwallex
Environment
AIRWALLEX_CLIENT_ID="..." # x-client-id header on /authentication/login
AIRWALLEX_API_KEY="..." # x-api-key header on /authentication/login (secret)
AIRWALLEX_ENV="demo" # 'demo' (default) or 'production'
Base URLs:
demo→https://api-demo.airwallex.com/api/v1production→https://api.airwallex.com/api/v1
Authentication
Token flow. On first call the server POSTs to /authentication/login with headers x-client-id and x-api-key (no body). Airwallex returns { token, expires_at } (JWT, ~30 min lifetime). The server caches the token in memory and refreshes it 60 seconds before expiry. Every subsequent call sends Authorization: Bearer <token>.
Idempotency
Every create_* tool takes a required request_id parameter. Airwallex uses this as the idempotency key. The server never auto-generates it — agents must pass a stable UUID per logical operation so retries are safe.
Run
# stdio (default — for Claude Desktop, Cursor, etc)
npx @codespar/mcp-airwallex
# HTTP (for server-to-server testing)
MCP_HTTP=true MCP_PORT=3000 npx @codespar/mcp-airwallex
Positioning vs EBANX
| Flow | Use |
|---|---|
| Global platform collecting from LatAm buyers, settling to USD | @codespar/mcp-ebanx |
| LatAm seller collecting from global buyers in USD/EUR/GBP, settling locally | @codespar/mcp-airwallex |
Pair both for bidirectional cross-border coverage.
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.