Skip to main content

Integration quickstart

This guide walks through a basic CashXChain integration.

1. Get sandbox access

Create a sandbox account and generate a sandbox API key in the dashboard.

export CXC_API_KEY=sk_sandbox_...

2. Create a contact (beneficiary)

A contact is a saved recipient. For a bank account, use kind: "bank_account":

curl -X POST https://api.sandbox.cashxchain.com/v1/contacts \
-H "Authorization: Bearer $CXC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"kind": "bank_account",
"name": "Example Supplier Ltd",
"country": "US",
"currency": "USD",
"bank_name": "Example Bank",
"account_number": "000123456789",
"routing_number": "021000021"
}'

Listing contacts (GET /v1/contacts) returns rails masked to the last 4 (account_number_last4, iban_last4, routing_number_last4).

3. Request a quote

curl -X POST https://api.sandbox.cashxchain.com/v1/fx/quotes \
-H "Authorization: Bearer $CXC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from_currency": "EUR",
"to_currency": "USD",
"from_amount": "1000.00"
}'

4. Create a transfer

curl -X POST https://api.sandbox.cashxchain.com/v1/transfers \
-H "Authorization: Bearer $CXC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"amount": "1000.00",
"currency": "USD",
"recipient": {
"name": "Example Supplier Ltd",
"email": "[email protected]",
"bank": {
"bank_name": "Example Bank",
"account_number": "000123456789",
"routing_number": "021000021",
"country": "US",
"currency": "USD"
}
},
"note": "QS-001"
}'

The response returns a transfer_id and status.

5. Reconcile

Poll GET /v1/transactions (or GET /v1/transactions/{id}) for the completed status, and download statements to match transfers against your internal records. Customer-managed webhook subscriptions are planned — see Webhooks.

Production

Production access requires business verification, use-case review, partner enablement, and security validation.