Helper API Reference
API reference for sandbox test event simulation.
Before You Start
Read the following guides before proceeding:
| Guide | Why |
|---|---|
| Getting Started | Platform overview and setup |
| Api Basics | Required headers and request configuration |
| Authentication | How to obtain access tokens |
| Onboarding | User and wallet registration |
| KYC | KYC verification requirements |
Overview
The Sandbox Helper API at https://ramc.wirexapp.tech provides endpoints to simulate external events for testing. All endpoints use the user's email address to identify accounts.
Interactive API documentation is available at https://ramc.wirexapp.tech/api-docs/.
Mint Test Tokens
Mint test tokens directly to a user's wallet for testing purposes.
Endpoint
POST /account/retail/mint
Request
{
"chainId": "84532",
"token": "0x7Af7cDbd557eD302F7538Db1e3d094C8BBcA665c",
"to": "0xAAFF0821A09A1Aac28B72dD3Ff410A7ea5FEb874",
"amount": "250000000"
}| Field | Type | Required | Description |
|---|---|---|---|
chainId | string | Yes | Chain ID (84532 for Base Sepolia) |
token | string | Yes | Token contract address |
to | string | Yes | The user's smart wallet address |
amount | string | Yes | Amount in the token’s smallest unit — multiply the decimal amount by 10^decimals |
The amount is in the smallest unit, not whole tokens. Mint the base token: USDC and EURC have 6 decimals, so
250 USDC is "250000000". On a registered smart wallet USDC arrives 1:1 as WUSD and EURC as WEUR. The balance
can take more than a minute to appear.
See Credentials for sandbox token addresses.
Response
{
"ok": "Hell yeah!"
}Wallet Helpers
Helpers for creating sandbox wallets and moving test tokens. Transfer helpers take the owner's private key in
the request body — use them only with keys generated for the sandbox.
| Endpoint | Description |
|---|---|
GET /account/generate?chainId=84532 | Returns a fresh key pair: { "address", "privateKey" }. Nothing is deployed |
POST /account/retail | Deploys a smart wallet for a fresh owner key and registers it under your company. Body: { "chainId": "84532", "companyId": "0x…" }. Returns wallet (owner EOA), privateKey and account (smart wallet) |
GET /account/retail/balance?chainId=84532&account={address}&token={token}&decimals={decimals} | Reads a token balance. Send the token's own decimals — the default is 18 on EVM and Tron, 7 on Stellar |
POST /account/retail/transfer/request | Requests a token transfer from a smart wallet. Body: chainId, account, privateKey, token, to, amount (smallest unit). Returns { "hash", "call" } |
POST /account/retail/transfer/execute | Executes the requested transfer. Body: chainId, account, privateKey and the call from the request |
POST /account/retail/unwrap/transfer/request | As transfer/request, but debits the synthetic token (unwrapToken, unwrapAmount) and sends the base token (token, amount). Execute with transfer/execute |
Mint to and transfer from account, the smart wallet. Register the user with the owner (wallet) as described
in Onboarding.
SEPA Operations
Simulate SEPA Deposit
Simulate an incoming SEPA EUR deposit to a user's account.
Endpoint
POST /bank/sepa/deposit
Request
{
"region": "GB",
"email": "[email protected]",
"amount": 250.00
}| Field | Type | Required | Description |
|---|---|---|---|
region | string | No | Region code (GB or EEA). Always use GB for now. |
email | string | Yes | User's email address |
amount | number | Yes | Amount in EUR |
Response
{
"success": true
}This triggers a /v2/webhooks/activities webhook with type Sepa and direction Inbound.
Get Pending SEPA Transfers
List pending outbound SEPA transfers waiting for completion.
Note: In sandbox environment, all outbound SEPA transfers remain in pending state indefinitely. Use
completeorrevertendpoints to simulate the external banking system processing the transfer.
Endpoint
GET /bank/sepa/transfers/pending
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
region | string | No | Region code (GB or EEA). Always use GB for now. |
email | string | Yes | User's email address |
Response
[
{
"id": "txn_abc123def456",
"transactionId": "OP-12345",
"status": "RELEASED",
"type": "PAYOUT",
"amount": {
"currency": "EUR",
"value": 150.00
}
}
]Use the id value, not transactionId, in transfer completion, cancel and revert requests. A payout is listed only
once the user's SEPA account has received at least one deposit.
Complete SEPA Transfer
Mark a pending outbound SEPA transfer as completed.
Endpoint
POST /bank/sepa/transfer/complete
Request
{
"region": "GB",
"email": "[email protected]",
"transactionId": "txn_abc123def456"
}| Field | Type | Required | Description |
|---|---|---|---|
region | string | No | Region code (GB or EEA). Always use GB for now. |
email | string | Yes | User's email address |
transactionId | string | Yes | Transaction ID from pending list |
Response
{
"success": true
}This triggers a /v2/webhooks/activities webhook with status Completed.
Cancel SEPA Transfer
Cancel a pending outbound SEPA transfer. The payout ends Failed and the debit is refunded.
Endpoint
POST /bank/sepa/transfer/cancel
The request body is the same as for Complete SEPA Transfer.
Revert SEPA Transfer
Simulate a returned SEPA transfer. This can only be called after a transfer has been completed. Creates an inbound reversal transaction that credits the funds back to the user's account.
Endpoint
POST /bank/sepa/transfer/revert
Request
{
"region": "GB",
"email": "[email protected]",
"transactionId": "txn_abc123def456"
}Response
{
"success": true
}This triggers a /v2/webhooks/activities webhook with type Sepa, direction Inbound, representing the reversal credit.
ACH Operations
Activate ACH Customer
Activate a user's ACH account. Required before ACH deposits can be simulated.
Note: In sandbox environment, ACH accounts remain in pending state indefinitely after creation. Call this endpoint to simulate the external ACH provider activating the account.
Endpoint
POST /bank/ach/customer/activate
Request
{
"email": "[email protected]"
}| Field | Type | Required | Description |
|---|---|---|---|
email | string | Yes | User's email address |
Response
{
"success": true
}Simulate ACH Deposit
Simulate an incoming ACH USD deposit to a user's account.
Endpoint
POST /bank/ach/deposit
Request
{
"email": "[email protected]",
"amount": 500.00
}| Field | Type | Required | Description |
|---|---|---|---|
email | string | Yes | User's email address |
amount | number | Yes | Amount in USD |
Response
{
"success": true
}This triggers a /v2/webhooks/activities webhook with type AchPush and direction Inbound.
Simulate Fedwire and FedNow Deposits
Simulate an incoming wire or FedNow credit to the user's USD account. Both take the same body as
Simulate ACH Deposit and need an Active ACH account.
POST /bank/fedwire/deposit
POST /bank/fednow/deposit
{
"email": "[email protected]",
"amount": 500.00
}The user is credited the same amount in WUSD, and the feed shows an Inbound activity of type Fedwire
or FedNow that reaches Completed / credit_done.
Complete ACH Transfer
Mark a pending outbound ACH transfer as completed.
Note: In sandbox environment,
achcorridor payouts endFailedby themselves within minutes and the debit is
refunded; they never reach the bank simulator, socompleteandrevertanswerNo transfer found.
Use thefedwirecorridor to test settlement:completeandrevertsettle afedwirepayout with its
transfer_idasexternalId.
No transfer foundright after initiate is a timing error. The payout reaches the simulator a few
seconds after its activity readsPending/awaiting_payment. Retry for up to a minute.
Endpoint
POST /bank/ach/transfer/complete
Request
{
"externalId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}| Field | Type | Required | Description |
|---|---|---|---|
externalId | string | Yes | Activity ID from Wirex BaaS transfer response |
Response
{
"success": true
}Revert ACH Transfer
Simulate a returned ACH transfer. This can only be called after a transfer has been completed. Creates an inbound reversal transaction that credits the funds back to the user's account.
Endpoint
POST /bank/ach/transfer/revert
Request
{
"externalId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}Response
{
"success": true
}Card Transaction Operations
Simulate card transactions for testing card payment flows. Each endpoint runs a complete ISO-8583 message flow (authorization, clearing, reversal, refund, etc.) against a card and triggers the corresponding activity webhooks.
Single-Message Simulators
The simplest way to create a card transaction. The body is { "cardId", "amount" }; the amount is in GBP.
| Endpoint | Simulates |
|---|---|
POST /card/transaction/pos | In-store purchase |
POST /card/transaction/epos | Card-not-present purchase |
POST /card/transaction/atm | ATM cash withdrawal |
POST /card/transaction/credit | Original Credit (funds pushed to the card) |
The response carries success and the ISO 8583 responseCode. A decline is still 200: an amount the wallet
cannot cover answers "success": false, "responseCode": "51".
Common Parameters
All card flow endpoints accept the same base request format:
{
"cardId": "550e8400-e29b-41d4-a716-446655440000",
"amount": 25.50,
"currency": "GBP",
"settlementAmount": 25.50,
"settlementCurrency": "GBP",
"merchantCountry": "GBR",
"paymentProvider": "Visa"
}| Field | Type | Required | Description |
|---|---|---|---|
cardId | string (UUID) | Yes | Card ID from Wirex BaaS |
amount | number | Yes | Transaction amount |
currency | string | Yes | Transaction currency (ISO 4217, e.g. GBP) |
settlementAmount | number | Yes | Settlement (billing) amount |
settlementCurrency | string | Yes | Settlement currency (ISO 4217) |
merchantCountry | string | No | Merchant country (ISO 3166 alpha-3, e.g. GBR) |
paymentProvider | string | No | Visa, MasterCard, or VisaEFunds |
For a same-currency purchase, set settlementAmount/settlementCurrency equal to amount/currency. To simulate FX, use different values.
POST /card/auth-and-multi-clearing additionally requires clearingAmounts (array of numbers) — the per-clearing local amounts whose sum equals the auth amount. Other flows that need an extra amount (reversalAmount, refundAmount, clearingAmount, secondAuthAmount, adjustmentAmount) answer 400 {"error": "<field> is required"} without it.
Every flow answers 200; the decision is in the body. A declined authorization carries auth.response.responseCode: "51" and the flow stops.
Common Response
Each flow returns the ISO messages it produced. Fields are present only when the flow generates them.
{
"transactionIdentifier": "a1b2c3d4-0000-0000-0000-000000000000",
"auth": { },
"clearing": { },
"refund": { },
"reversal": { },
"representment": { },
"adjustment": { },
"auths": [ ],
"clearings": [ ]
}| Field | Type | Description |
|---|---|---|
transactionIdentifier | string | Identifier linking the messages in this flow |
auth | object | Authorization message (when produced) |
clearing | object | Clearing/settlement message (when produced) |
refund | object | Refund message (when produced) |
reversal | object | Reversal message (when produced) |
representment | object | Representment message (when produced) |
adjustment | object | Adjustment message (when produced) |
auths | array | Multiple authorizations (multi-auth flows) |
clearings | array | Multiple clearings (multi-clearing flows) |
Common Flows
| Purpose | Endpoint |
|---|---|
| In-store purchase (auth + clearing) | POST /card/auth-and-clearing |
| E-commerce / card-not-present purchase | POST /card/epos-auth-and-clearing |
| ATM cash withdrawal | POST /card/atm-auth-and-clearing |
| Standalone refund | POST /card/standalone-refund |
| Push funds to card (Original Credit) | POST /card/original-credit |
| Balance inquiry | POST /card/balance-inquiry |
Example — Purchase (auth + clearing)
POST /card/auth-and-clearing
Request:
{
"cardId": "550e8400-e29b-41d4-a716-446655440000",
"amount": 25.50,
"currency": "GBP",
"settlementAmount": 25.50,
"settlementCurrency": "GBP",
"merchantCountry": "GBR",
"paymentProvider": "Visa"
}Response:
{
"transactionIdentifier": "a1b2c3d4-0000-0000-0000-000000000000",
"auth": { },
"clearing": { }
}This triggers /v2/webhooks/activities webhooks with type CardTransaction.
All Flow Endpoints
| Endpoint | Description |
|---|---|
POST /card/auth-and-clearing | Authorization + clearing (standard purchase) |
POST /card/epos-auth-and-clearing | E-commerce (card-not-present) auth + clearing |
POST /card/atm-auth-and-clearing | ATM auth + clearing |
POST /card/fuel-dispenser-auth-and-clearing | Fuel dispenser (full reversal + delayed auth) + clearing |
POST /card/multi-auth-and-clearing | Multiple authorizations + clearing |
POST /card/auth-and-multi-clearing | One auth + multiple partial clearings (clearingAmounts) |
POST /card/auth-partial-reversal | Auth + partial reversal |
POST /card/auth-full-reversal | Auth + full reversal |
POST /card/auth-reversal-clearing | Auth + reversal + clearing |
POST /card/standalone-reversal | Standalone reversal |
POST /card/standalone-clearing | Standalone clearing |
POST /card/standalone-refund | Standalone refund |
POST /card/original-credit | Original Credit Transaction (push funds to card) |
POST /card/auth-clearing-full-refund | Auth + clearing + full refund |
POST /card/auth-clearing-partial-refund | Auth + clearing + partial refund |
POST /card/check-refund | Check refund |
POST /card/auth-clearing-refund-representment | Auth + clearing + refund + representment |
POST /card/auth-clearing-partial-refund-representment | Auth + clearing + partial refund + representment |
POST /card/auth-clearing-full-reversal-representment | Auth + clearing + full reversal + representment |
POST /card/auth-clearing-partial-reversal-representment | Auth + clearing + partial reversal + representment |
POST /card/auth-chargeback-clearing | Auth + chargeback advice + clearing |
POST /card/auth-clearing-with-correction | Auth + clearing with correction |
POST /card/credit-adjustment | Credit adjustment |
POST /card/debit-adjustment | Debit adjustment |
POST /card/balance-inquiry | Balance inquiry |
3DS Challenge Simulation
No card transaction simulation raises a 3DS challenge — POST /card/transaction/epos and the /card/*
flow endpoints above authorize and clear, but never produce a pending 3DS request. Use
POST /card/3ds/initiate to raise a standalone in-app confirmation challenge on a card, then approve or
decline it through the Wirex BaaS API exactly as in production. See
3DS Authentication for the approve/decline endpoints.
Initiate 3DS Challenge
Endpoint
POST /card/3ds/initiate
Request
{
"cardId": "64120850-73a1-4df5-a074-d463258c9deb",
"transactionCurrency": "USD"
}| Field | Type | Required | Description |
|---|---|---|---|
cardId | string (UUID) | Yes | Card ID from Wirex BaaS — the id returned by card issuance |
transactionCurrency | string | No | Challenge currency, ISO 4217 alphabetic code (e.g. USD, EUR). Defaults to USD |
Response
{
"bin": "442601",
"transactionId": "14be186b-872c-41f4-9e5b-c1dc226e78a0",
"currency": "USD"
}| Field | Type | Description |
|---|---|---|
transactionId | string (UUID) | Challenge identifier. Appears as transaction_id in GET /api/v1/cards/3ds/requests and is the {transactionId} path parameter of the approve/decline endpoints |
currency | string | Challenge currency, ISO 4217 alphabetic code |
bin | string | First 6 digits of the card number |
The amount and merchant are generated by the simulator and are not in this response. Read them from the
pending request in GET /api/v1/cards/3ds/requests.
Test Flow
- Call
POST /card/3ds/initiatewith the card ID. SavetransactionId. - Call
GET /api/v1/cards/3ds/requestswith the card owner's token. The challenge is listed with
transaction_idequal to the savedtransactionIdand the card'scard_last_4. In sandbox it is listed immediately after step 1 returns. - Call
POST /api/v1/cards/3ds/requests/{transactionId}/approveor.../declinewith an empty body.
Returns200with{}and the challenge leaves the pending list.
A second approve or decline on the same transaction_id returns 400:
{
"error_reason": "ErrorNotFound",
"error_description": "No active 3DS request for this transaction",
"error_category": {
"category": "CategoryValidationFailure",
"http_status_code": 400
},
"error_details": [
{ "key": "field", "details": "transaction_id" },
{ "key": "issue", "details": "not_found" }
]
}An undecided challenge expires 5 minutes after it is created and drops out of the pending list, same
as in production.
Errors
| HTTP Status | Body | Cause | Resolution |
|---|---|---|---|
| 400 | {"error": "cardId is required"} | cardId missing from the body | Send the card ID |
| 500 | {"error": "3DS initiation failed: ..."} | The card ID is not a Wirex BaaS card in sandbox | Use the id returned by card issuance |
Code Examples
JavaScript
const HELPER_API = 'https://ramc.wirexapp.tech';
// Simulate SEPA deposit
async function simulateSepaDeposit(email, amount) {
const response = await fetch(`${HELPER_API}/bank/sepa/deposit`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
region: 'GB',
email,
amount
})
});
return response.json();
}
// Complete SEPA transfer
async function completeSepaTransfer(email, transactionId) {
const response = await fetch(`${HELPER_API}/bank/sepa/transfer/complete`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
region: 'GB',
email,
transactionId
})
});
return response.json();
}
// Raise a 3DS challenge; approve it via GET/POST /api/v1/cards/3ds/requests
async function initiate3dsChallenge(cardId, transactionCurrency = 'USD') {
const response = await fetch(`${HELPER_API}/card/3ds/initiate`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ cardId, transactionCurrency })
});
return response.json(); // { transactionId, currency, bin }
}
// Simulate card purchase (auth + clearing)
async function simulateCardPurchase(cardId, amount, currency = 'GBP') {
const response = await fetch(`${HELPER_API}/card/auth-and-clearing`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
cardId,
amount,
currency,
settlementAmount: amount,
settlementCurrency: currency,
paymentProvider: 'Visa'
})
});
return response.json();
}Python
import requests
HELPER_API = 'https://ramc.wirexapp.tech'
def simulate_sepa_deposit(email: str, amount: float) -> dict:
response = requests.post(
f'{HELPER_API}/bank/sepa/deposit',
json={
'region': 'GB',
'email': email,
'amount': amount
}
)
return response.json()
def complete_sepa_transfer(email: str, transaction_id: str) -> dict:
response = requests.post(
f'{HELPER_API}/bank/sepa/transfer/complete',
json={
'region': 'GB',
'email': email,
'transactionId': transaction_id
}
)
return response.json()
def initiate_3ds_challenge(card_id: str, transaction_currency: str = 'USD') -> dict:
response = requests.post(
f'{HELPER_API}/card/3ds/initiate',
json={
'cardId': card_id,
'transactionCurrency': transaction_currency
}
)
return response.json() # transactionId, currency, bin
def simulate_card_purchase(card_id: str, amount: float, currency: str = 'GBP') -> dict:
response = requests.post(
f'{HELPER_API}/card/auth-and-clearing',
json={
'cardId': card_id,
'amount': amount,
'currency': currency,
'settlementAmount': amount,
'settlementCurrency': currency,
'paymentProvider': 'Visa'
}
)
return response.json()Go
package main
import (
"bytes"
"encoding/json"
"net/http"
)
const helperAPI = "https://ramc.wirexapp.tech"
type SepaDepositRequest struct {
Region string `json:"region"`
Email string `json:"email"`
Amount float64 `json:"amount"`
}
type CardTransactionRequest struct {
CardID string `json:"cardId"`
Amount float64 `json:"amount"`
Currency string `json:"currency"`
SettlementAmount float64 `json:"settlementAmount"`
SettlementCurrency string `json:"settlementCurrency"`
PaymentProvider string `json:"paymentProvider"`
}
type ThreeDsInitiateRequest struct {
CardID string `json:"cardId"`
TransactionCurrency string `json:"transactionCurrency,omitempty"`
}
type ThreeDsChallenge struct {
TransactionID string `json:"transactionId"`
Currency string `json:"currency"`
Bin string `json:"bin"`
}
func simulateSepaDeposit(email string, amount float64) error {
body, _ := json.Marshal(SepaDepositRequest{
Region: "GB",
Email: email,
Amount: amount,
})
_, err := http.Post(
helperAPI+"/bank/sepa/deposit",
"application/json",
bytes.NewBuffer(body),
)
return err
}
func initiate3dsChallenge(cardID string, transactionCurrency string) (ThreeDsChallenge, error) {
body, _ := json.Marshal(ThreeDsInitiateRequest{
CardID: cardID,
TransactionCurrency: transactionCurrency,
})
var challenge ThreeDsChallenge
resp, err := http.Post(
helperAPI+"/card/3ds/initiate",
"application/json",
bytes.NewBuffer(body),
)
if err != nil {
return challenge, err
}
defer resp.Body.Close()
err = json.NewDecoder(resp.Body).Decode(&challenge)
return challenge, err
}
func simulateCardPurchase(cardID string, amount float64, currency string) error {
body, _ := json.Marshal(CardTransactionRequest{
CardID: cardID,
Amount: amount,
Currency: currency,
SettlementAmount: amount,
SettlementCurrency: currency,
PaymentProvider: "Visa",
})
_, err := http.Post(
helperAPI+"/card/auth-and-clearing",
"application/json",
bytes.NewBuffer(body),
)
return err
}Error Handling
All endpoints return errors in this format:
{
"error": "User not found for email: [email protected]"
}| HTTP Status | Description |
|---|---|
| 400 | Missing required parameters |
| 500 | Operation failed (user not found, API error, etc.) |
Updated 15 days ago

