Wirex BaaS Platform Overview
Introduction
Wirex BaaS (Banking-as-a-Service) is a blockchain-native financial services platform that enables partners to embed comprehensive financial capabilities into their applications through REST APIs. The platform bridges traditional finance and decentralized infrastructure, providing a unified interface for:
- Account Abstraction (AA) Wallets -- Smart contract wallets deployed on-chain with gasless transactions, social recovery, and multi-signature support. Each user gets a deterministic wallet address derived from their identity.
- KYC Verification -- Identity verification flows supporting document checks, liveness detection, and regulatory compliance across 88+ countries. Powered by third-party providers with webhook-based status updates.
- Visa Card Issuance -- Virtual and physical Visa card provisioning, lifecycle management, transaction controls, and Apple Pay / Google Pay tokenization. Cards are funded from user wallets.
- Crypto Asset Management -- Multi-chain token support (USDC, USDT, EURC, WUSD, WEUR) with on-chain balances, transfers, and exchange operations across Base and Stellar networks.
- Fiat Banking (SEPA/ACH) -- Bank account creation, inbound/outbound transfers, and currency conversion. SEPA covers 28 European countries; ACH covers 34+ countries including all US states.
All services are accessed through a consistent REST API layer with OAuth2 authentication, standardized error handling, and blockchain transaction management.
Integration Flow
Integrating with Wirex BaaS follows five sequential steps:
Step 1: Partner Setup
Wirex provisions your partner account and issues credentials:
- client_id -- UUID identifying your application
- client_secret -- Secret string for OAuth2 token exchange
- partner_id -- 16-byte hex identifier used in on-chain operations (e.g.,
0x00000000000000000000000000000007)
You receive access to the Sandbox environment for development and testing.
Step 2: Authentication
Establish server-to-server authentication using OAuth2 client credentials:
POST /api/v1/token
Content-Type: application/json
{
"client_id": "<your-client-id>",
"client_secret": "<your-client-secret>",
"grant_type": "client_credentials"
}
The returned access_token is valid for 48 hours and is required as a Bearer token on all subsequent API calls.
Step 3: On-Chain Configuration
Configure your on-chain environment:
- Query the Contract Registry to discover deployed contract addresses (Accounts, FundsManagement, ExecutionDelayPolicy, TokensRegistry).
- Verify token addresses and decimals from the TokensRegistry contract.
- Set up webhook endpoints for asynchronous event notifications (transaction confirmations, KYC status changes, card events).
Step 4: API Registration
Register your first user through the API:
- Call
POST /api/v1/user or POST /api/v2/user to create a user record.
- The platform deploys an Account Abstraction wallet on the configured chain.
- Obtain a user-scoped token via
POST /api/v1/user/authorize for user-specific operations.
Step 5: Operations
With authentication and user registration complete, you can:
- Initiate KYC verification flows
- Issue virtual or physical Visa cards
- Execute crypto transfers and exchanges
- Create bank accounts and process fiat transfers
- Query balances, transactions, and account status
Environments
Wirex BaaS provides separate environments for development and production use.
Core API Environments
| Environment |
Base URL |
Purpose |
| Sandbox |
https://api-baas.wirexapp.tech |
Development and testing with test data |
| Production |
https://api-baas.wirexapp.com |
Live operations with real funds |
PCI-Compliant Card Environments
Card-related operations that handle sensitive PAN data use dedicated PCI DSS-compliant endpoints, specifically for card tokenization in push-to-card transfers:
| Environment |
Base URL |
Purpose |
| PCI Sandbox |
https://wx-acquiring-card-manager-uat.wirexapp.com |
Card testing |
| PCI Production |
https://wx-acquiring-card-manager.wirexapp.com |
Live card operations |
Helper API
| Environment |
Base URL |
Purpose |
| Helper API |
https://ramc.wirexapp.tech |
Utility services and auxiliary operations |
Blockchain Networks
Wirex BaaS operates on the following blockchain networks:
Production Networks:
| Network |
Chain ID |
Description |
| Base |
8453 |
Ethereum L2 (Coinbase) -- primary EVM chain |
| Stellar |
9223372036854775806 |
Stellar network for cross-border payments |
Sandbox Networks:
| Network |
Chain ID |
Description |
| Base Sepolia |
84532 |
Base testnet for development |
| Stellar Testnet |
9223372036854775806 |
Stellar testnet (same chain ID as production) |
Note: The Stellar chain ID is the same value (9223372036854775806) in both sandbox and production. The environment base URL determines which Stellar network is used.
Credentials
Partners receive three credentials upon onboarding:
| Credential |
Format |
Description |
| client_id |
UUID string |
Uniquely identifies your partner application. Passed in the token request body. |
| client_secret |
Opaque string |
Used alongside client_id to authenticate token requests. Must be stored securely and never exposed in client-side code. |
| partner_id |
16-byte hex string |
On-chain identifier for your partner account (e.g., 0x00000000000000000000000000000007). Used as the parentEntity parameter when registering user wallets in the Accounts smart contract, and in some API headers. Not secret but should be validated against expected value. Can be stored in application configuration. |
Security Requirements
- Store
client_secret in a secrets manager or encrypted environment variable. Never commit it to source control.
- Rotate credentials immediately if a compromise is suspected.
- Use separate credentials for Sandbox and Production environments.
API Basics
Protocol and Security
- HTTPS only -- All API communication uses HTTPS with TLS 1.2 or higher. Plain HTTP requests are rejected.
- Content-Type -- All request and response bodies use
application/json.
- Timeout -- A 30-second timeout is recommended for all API calls. Some blockchain operations may take longer; use webhooks for async confirmation.
Required Headers
Every API request must include the following headers:
| Header |
Required |
Description |
Authorization |
Yes |
Bearer token from /api/v1/token (e.g., Bearer eyJhbGciOi...) |
X-Chain-Id |
Yes |
Blockchain network identifier. Must match your target chain (e.g., 84532 for Sandbox Base Sepolia, 8453 for Production Base). Required for all requests. |
Content-Type |
Yes (for POST/PUT) |
application/json |
Additional headers for user-specific operations:
| Header |
When Required |
Description |
X-User-Address |
User-specific calls |
User's EOA (Externally Owned Account) address — NOT the Smart Wallet address |
X-User-Email |
User-specific calls |
Email address of the user |
X-User-Id |
User-specific calls |
Internal user identifier |
Exactly one of X-User-Address, X-User-Email, or X-User-Id is required for endpoints that operate on a specific user. Providing multiple user identity headers in the same request is rejected with an error. User-agnostic endpoints (token, config, user creation) do not require these headers.
User-Agnostic Endpoints
The following endpoints do not require user identity headers:
POST /api/v1/token -- Authentication
POST /api/v1/user -- User creation
POST /api/v2/user -- User creation (v2)
GET /api/v1/config -- Platform configuration
GET /api/v1/validation/rules -- Validation rules
MCP Server
Wirex BaaS provides a Model Context Protocol (MCP) server for AI-assisted development. The MCP server gives AI tools direct access to API documentation, endpoint specifications, and code generation assistance.
MCP Server URL: https://docs.wirexapp.com/mcp
The MCP server supports:
- API Documentation Access -- Query endpoint specifications, request/response schemas, and usage examples.
- Documentation Search -- Search across the full Wirex BaaS documentation corpus.
- Real-Time Data -- Access current API status, supported tokens, and configuration values.
- Code Generation Assistance -- Generate integration code snippets for common workflows.
For detailed setup instructions across different tools (Claude Code, Cursor, Claude Desktop, Windsurf), see the MCP Setup Reference.
Supported Countries
Wirex BaaS supports operations in 77 countries across five regions:
| Region |
Country Count |
Examples |
| Europe |
35 |
United Kingdom, Germany, France, Spain, Italy, Netherlands, Sweden, Switzerland, Poland, Austria, and 25 more |
| Asia-Pacific |
10 |
Singapore, Japan, Hong Kong, Australia, Indonesia, Malaysia, Taiwan, Thailand, Vietnam, and more |
| Latin America |
7 |
Brazil, Mexico, Argentina, Chile, Colombia, Peru, Ecuador |
| Rest of World |
24 |
UAE, South Africa, Israel, Turkey, Nigeria, Saudi Arabia, South Korea, and 17 more |
| United States |
1 |
Full coverage across all 50 states + DC |
For the complete list with ISO country codes, see the Supported Regions Reference.
Bank Account Availability
Fiat banking services are available through two networks:
- SEPA (Single Euro Payments Area) -- 28 European countries. Supports EUR-denominated transfers with T+1 settlement.
- ACH (Automated Clearing House) -- 34+ countries including all US states and territories. Supports USD-denominated transfers.
Availability depends on the user's country of residence and completed KYC level.
Error Handling
All API errors follow a consistent JSON format:
{
"error_reason": "ErrorInvalidField",
"error_description": "The provided X-Chain-Id header value is not supported.",
"error_category": {
"category": "CategoryValidationFailure",
"http_status_code": 400
},
"error_details": [
{ "key": "field", "details": "X-Chain-Id" },
{ "key": "issue", "details": "unsupported_value" }
]
}
Error Fields
| Field |
Type |
Description |
error_reason |
string |
PascalCase error code (e.g., ErrorInvalidField, ErrorPermissionDenied, ErrorNotFound, ErrorExpired, ErrorMissingField, ErrorAlreadyExists, ErrorNotSupported, ErrorConfigurationInvalid) |
error_description |
string |
Human-readable explanation of the error |
error_category |
object |
Error classification object containing category (string) and http_status_code (integer) |
error_details |
array |
Array of objects, each with key (string) and details (string) providing additional context |
Error Categories
| Category |
HTTP Status |
Description |
Recommended Action |
CategoryValidationFailure |
400 |
Invalid request parameters, missing headers, malformed data |
Fix the request and retry |
CategoryUnauthorized |
401 |
Invalid or expired token, insufficient permissions |
Re-authenticate and retry |
CategoryInternalFailure |
500 |
Server-side error |
Retry with exponential backoff; contact support if persistent |
CategoryTransientFailure |
429 |
Rate limit exceeded or temporary service degradation |
Retry after the delay indicated in Retry-After header |
Error Handling Best Practices
- Always check the
error_category to determine retry strategy.
- Implement exponential backoff for
CategoryTransientFailure and CategoryInternalFailure errors.
- Do not retry
CategoryValidationFailure errors without modifying the request.
- Refresh tokens proactively -- cache tokens and refresh 5 minutes before expiry to avoid
CategoryUnauthorized errors.
- Log
error_reason and error_description for debugging and support escalations.
References
- Environments Reference -- Full environment URLs, chain IDs, contract addresses, and token configurations
- MCP Setup Reference -- MCP server configuration for all supported AI tools
- Supported Regions Reference -- Complete country list with ISO codes and bank availability
1---2name: wirex-baas-overview3description: Wirex BaaS platform overview and getting started guide — start here for integration basics. Covers what Wirex BaaS is, the 5-step integration flow, API environments (sandbox and production URLs), sandbox test credentials, required headers (Authorization, X-Chain-Id), error handling, blockchain networks (Base, Stellar), canonical token and contract registry addresses, MCP server setup, and supported countries (77) with SEPA/ACH bank availability.4license: Apache-2.05---67# Wirex BaaS Platform Overview89## Introduction1011Wirex BaaS (Banking-as-a-Service) is a blockchain-native financial services platform that enables partners to embed comprehensive financial capabilities into their applications through REST APIs. The platform bridges traditional finance and decentralized infrastructure, providing a unified interface for:1213- **Account Abstraction (AA) Wallets** -- Smart contract wallets deployed on-chain with gasless transactions, social recovery, and multi-signature support. Each user gets a deterministic wallet address derived from their identity.14- **KYC Verification** -- Identity verification flows supporting document checks, liveness detection, and regulatory compliance across 88+ countries. Powered by third-party providers with webhook-based status updates.15- **Visa Card Issuance** -- Virtual and physical Visa card provisioning, lifecycle management, transaction controls, and Apple Pay / Google Pay tokenization. Cards are funded from user wallets.16- **Crypto Asset Management** -- Multi-chain token support (USDC, USDT, EURC, WUSD, WEUR) with on-chain balances, transfers, and exchange operations across Base and Stellar networks.17- **Fiat Banking (SEPA/ACH)** -- Bank account creation, inbound/outbound transfers, and currency conversion. SEPA covers 28 European countries; ACH covers 34+ countries including all US states.1819All services are accessed through a consistent REST API layer with OAuth2 authentication, standardized error handling, and blockchain transaction management.2021---2223## Integration Flow2425Integrating with Wirex BaaS follows five sequential steps:2627### Step 1: Partner Setup2829Wirex provisions your partner account and issues credentials:3031- **client_id** -- UUID identifying your application32- **client_secret** -- Secret string for OAuth2 token exchange33- **partner_id** -- 16-byte hex identifier used in on-chain operations (e.g., `0x00000000000000000000000000000007`)3435You receive access to the Sandbox environment for development and testing.3637### Step 2: Authentication3839Establish server-to-server authentication using OAuth2 client credentials:4041```42POST /api/v1/token43Content-Type: application/json4445{46 "client_id": "<your-client-id>",47 "client_secret": "<your-client-secret>",48 "grant_type": "client_credentials"49}50```5152The returned `access_token` is valid for 48 hours and is required as a Bearer token on all subsequent API calls.5354### Step 3: On-Chain Configuration5556Configure your on-chain environment:57581. Query the **Contract Registry** to discover deployed contract addresses (Accounts, FundsManagement, ExecutionDelayPolicy, TokensRegistry).592. Verify token addresses and decimals from the TokensRegistry contract.603. Set up webhook endpoints for asynchronous event notifications (transaction confirmations, KYC status changes, card events).6162### Step 4: API Registration6364Register your first user through the API:65661. Call `POST /api/v1/user` or `POST /api/v2/user` to create a user record.672. The platform deploys an Account Abstraction wallet on the configured chain.683. Obtain a user-scoped token via `POST /api/v1/user/authorize` for user-specific operations.6970### Step 5: Operations7172With authentication and user registration complete, you can:7374- Initiate KYC verification flows75- Issue virtual or physical Visa cards76- Execute crypto transfers and exchanges77- Create bank accounts and process fiat transfers78- Query balances, transactions, and account status7980---8182## Environments8384Wirex BaaS provides separate environments for development and production use.8586### Core API Environments8788| Environment | Base URL | Purpose |89|---|---|---|90| **Sandbox** | `https://api-baas.wirexapp.tech` | Development and testing with test data |91| **Production** | `https://api-baas.wirexapp.com` | Live operations with real funds |9293### PCI-Compliant Card Environments9495Card-related operations that handle sensitive PAN data use dedicated PCI DSS-compliant endpoints, specifically for card tokenization in push-to-card transfers:9697| Environment | Base URL | Purpose |98|---|---|---|99| **PCI Sandbox** | `https://wx-acquiring-card-manager-uat.wirexapp.com` | Card testing |100| **PCI Production** | `https://wx-acquiring-card-manager.wirexapp.com` | Live card operations |101102### Helper API103104| Environment | Base URL | Purpose |105|---|---|---|106| **Helper API** | `https://ramc.wirexapp.tech` | Utility services and auxiliary operations |107108### Blockchain Networks109110Wirex BaaS operates on the following blockchain networks:111112**Production Networks:**113114| Network | Chain ID | Description |115|---|---|---|116| Base | `8453` | Ethereum L2 (Coinbase) -- primary EVM chain |117| Stellar | `9223372036854775806` | Stellar network for cross-border payments |118119**Sandbox Networks:**120121| Network | Chain ID | Description |122|---|---|---|123| Base Sepolia | `84532` | Base testnet for development |124| Stellar Testnet | `9223372036854775806` | Stellar testnet (same chain ID as production) |125126> **Note:** The Stellar chain ID is the same value (`9223372036854775806`) in both sandbox and production. The environment base URL determines which Stellar network is used.127128---129130## Credentials131132Partners receive three credentials upon onboarding:133134| Credential | Format | Description |135|---|---|---|136| **client_id** | UUID string | Uniquely identifies your partner application. Passed in the token request body. |137| **client_secret** | Opaque string | Used alongside `client_id` to authenticate token requests. Must be stored securely and never exposed in client-side code. |138| **partner_id** | 16-byte hex string | On-chain identifier for your partner account (e.g., `0x00000000000000000000000000000007`). Used as the `parentEntity` parameter when registering user wallets in the Accounts smart contract, and in some API headers. Not secret but should be validated against expected value. Can be stored in application configuration. |139140### Security Requirements141142- Store `client_secret` in a secrets manager or encrypted environment variable. Never commit it to source control.143- Rotate credentials immediately if a compromise is suspected.144- Use separate credentials for Sandbox and Production environments.145146---147148## API Basics149150### Protocol and Security151152- **HTTPS only** -- All API communication uses HTTPS with TLS 1.2 or higher. Plain HTTP requests are rejected.153- **Content-Type** -- All request and response bodies use `application/json`.154- **Timeout** -- A 30-second timeout is recommended for all API calls. Some blockchain operations may take longer; use webhooks for async confirmation.155156### Required Headers157158Every API request must include the following headers:159160| Header | Required | Description |161|---|---|---|162| `Authorization` | Yes | Bearer token from `/api/v1/token` (e.g., `Bearer eyJhbGciOi...`) |163| `X-Chain-Id` | Yes | Blockchain network identifier. Must match your target chain (e.g., `84532` for Sandbox Base Sepolia, `8453` for Production Base). **Required for all requests.** |164| `Content-Type` | Yes (for POST/PUT) | `application/json` |165166Additional headers for user-specific operations:167168| Header | When Required | Description |169|---|---|---|170| `X-User-Address` | User-specific calls | User's EOA (Externally Owned Account) address — **NOT the Smart Wallet address** |171| `X-User-Email` | User-specific calls | Email address of the user |172| `X-User-Id` | User-specific calls | Internal user identifier |173174> Exactly **one** of `X-User-Address`, `X-User-Email`, or `X-User-Id` is required for endpoints that operate on a specific user. Providing multiple user identity headers in the same request is **rejected with an error**. User-agnostic endpoints (token, config, user creation) do not require these headers.175176### User-Agnostic Endpoints177178The following endpoints do not require user identity headers:179180- `POST /api/v1/token` -- Authentication181- `POST /api/v1/user` -- User creation182- `POST /api/v2/user` -- User creation (v2)183- `GET /api/v1/config` -- Platform configuration184- `GET /api/v1/validation/rules` -- Validation rules185186---187188## MCP Server189190Wirex BaaS provides a Model Context Protocol (MCP) server for AI-assisted development. The MCP server gives AI tools direct access to API documentation, endpoint specifications, and code generation assistance.191192**MCP Server URL:** `https://docs.wirexapp.com/mcp`193194The MCP server supports:195196- **API Documentation Access** -- Query endpoint specifications, request/response schemas, and usage examples.197- **Documentation Search** -- Search across the full Wirex BaaS documentation corpus.198- **Real-Time Data** -- Access current API status, supported tokens, and configuration values.199- **Code Generation Assistance** -- Generate integration code snippets for common workflows.200201For detailed setup instructions across different tools (Claude Code, Cursor, Claude Desktop, Windsurf), see the [MCP Setup Reference](references/MCP-SETUP.md).202203---204205## Supported Countries206207Wirex BaaS supports operations in 77 countries across five regions:208209| Region | Country Count | Examples |210|---|---|---|211| **Europe** | 35 | United Kingdom, Germany, France, Spain, Italy, Netherlands, Sweden, Switzerland, Poland, Austria, and 25 more |212| **Asia-Pacific** | 10 | Singapore, Japan, Hong Kong, Australia, Indonesia, Malaysia, Taiwan, Thailand, Vietnam, and more |213| **Latin America** | 7 | Brazil, Mexico, Argentina, Chile, Colombia, Peru, Ecuador |214| **Rest of World** | 24 | UAE, South Africa, Israel, Turkey, Nigeria, Saudi Arabia, South Korea, and 17 more |215| **United States** | 1 | Full coverage across all 50 states + DC |216217For the complete list with ISO country codes, see the [Supported Regions Reference](references/SUPPORTED-REGIONS.md).218219### Bank Account Availability220221Fiat banking services are available through two networks:222223- **SEPA (Single Euro Payments Area)** -- 28 European countries. Supports EUR-denominated transfers with T+1 settlement.224- **ACH (Automated Clearing House)** -- 34+ countries including all US states and territories. Supports USD-denominated transfers.225226Availability depends on the user's country of residence and completed KYC level.227228---229230## Error Handling231232All API errors follow a consistent JSON format:233234```json235{236 "error_reason": "ErrorInvalidField",237 "error_description": "The provided X-Chain-Id header value is not supported.",238 "error_category": {239 "category": "CategoryValidationFailure",240 "http_status_code": 400241 },242 "error_details": [243 { "key": "field", "details": "X-Chain-Id" },244 { "key": "issue", "details": "unsupported_value" }245 ]246}247```248249### Error Fields250251| Field | Type | Description |252|---|---|---|253| `error_reason` | string | PascalCase error code (e.g., `ErrorInvalidField`, `ErrorPermissionDenied`, `ErrorNotFound`, `ErrorExpired`, `ErrorMissingField`, `ErrorAlreadyExists`, `ErrorNotSupported`, `ErrorConfigurationInvalid`) |254| `error_description` | string | Human-readable explanation of the error |255| `error_category` | object | Error classification object containing `category` (string) and `http_status_code` (integer) |256| `error_details` | array | Array of objects, each with `key` (string) and `details` (string) providing additional context |257258### Error Categories259260| Category | HTTP Status | Description | Recommended Action |261|---|---|---|---|262| `CategoryValidationFailure` | 400 | Invalid request parameters, missing headers, malformed data | Fix the request and retry |263| `CategoryUnauthorized` | 401 | Invalid or expired token, insufficient permissions | Re-authenticate and retry |264| `CategoryInternalFailure` | 500 | Server-side error | Retry with exponential backoff; contact support if persistent |265| `CategoryTransientFailure` | 429 | Rate limit exceeded or temporary service degradation | Retry after the delay indicated in `Retry-After` header |266267### Error Handling Best Practices2682691. **Always check the `error_category`** to determine retry strategy.2702. **Implement exponential backoff** for `CategoryTransientFailure` and `CategoryInternalFailure` errors.2713. **Do not retry** `CategoryValidationFailure` errors without modifying the request.2724. **Refresh tokens proactively** -- cache tokens and refresh 5 minutes before expiry to avoid `CategoryUnauthorized` errors.2735. **Log `error_reason` and `error_description`** for debugging and support escalations.274275---276277## References278279- [Environments Reference](references/ENVIRONMENTS.md) -- Full environment URLs, chain IDs, contract addresses, and token configurations280- [MCP Setup Reference](references/MCP-SETUP.md) -- MCP server configuration for all supported AI tools281- [Supported Regions Reference](references/SUPPORTED-REGIONS.md) -- Complete country list with ISO codes and bank availability