End-to-end test walkthrough¶
TL;DR - A complete dry run in dev: create a customer, approve KYC, watch the account activate, inject a deposit, add a recipient, send a fiat payout, watch it settle, download the receipt. About ten minutes, no real money.
create customer ► approve KYC ► account active ► inject deposit
► add recipient ► send payout ► completed ► receipt
Before you start¶
- An operator login on
https://dev.magma.builderswith the operate or admin role and MFA enrolled - see Your first login. - A terminal with
curland a bearer token for step 4 - everything else works from the dashboard and the verification page. See Simulation API reference for auth.
Step 1 - Create the customer¶
Follow Create a customer. The customer
lands in created.
Step 2 - Approve KYC¶
Open the KYC link from the amber notice on the customer detail page and
click Approve - mark Verified, or make the API call - both in
Simulate KYC / KYB. The customer moves to verified.
Step 3 - Wait for the virtual account¶
A few seconds later the virtual account
provisions and activates on its own, and the customer goes active.
Refresh the customer page - the amber notice is gone and the account
coordinates are visible.
Step 4 - Fund the balance¶
Grab the virtual account id and inject a deposit - see Simulate deposits:
curl -X POST \
"https://dev.magma.builders/api/v1/sandbox/virtual-accounts/{vaId}/deposit" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"amount": 2500, "sender_name": "Acme Inc"}'
The customer dashboard now shows a $2,500 balance and a completed
deposit_fiat transaction.
Step 5 - Add a fiat recipient¶
Follow Add a fiat recipient - any plausible bank details work in dev.
Step 6 - Send the fiat payout¶
Run the wizard in Fiat payouts: pick the customer
and recipient, enter an amount within the balance, review the fee
breakdown. At the OTP step, type any 6-digit code (000000 works). The
payout is created in pending.
Step 7 - Watch it settle¶
With auto-advance on (the dev default) the payout walks
pending → processing → completed by itself within seconds - watch the
status change in the transactions list. On
a manually-driven sandbox, advance it yourself - see
Simulate payout settlement.
Step 8 - The paper trail¶
Open the completed transaction and download the PDF receipt; run a CSV or PDF export if you want the bulk view - see Export & receipts. That's the full loop: onboarding to receipt without a single real dollar.
Variations¶
- Crypto-to-fiat payout - create it per
Crypto-to-fiat payouts; the sandbox simulates
the customer's crypto arriving at the deposit address
(
deposit_received), then settles. Manual lever: advance the payout. - On-ramp - register a wallet per On-ramp,
then inject a deposit on the paired crypto account and watch the
in_transit → in_destinationsteps - Simulate deposits. - Failure paths - reject KYC (
result=failed), watch a payout fail for a blocked customer, or forcefailed/expiredon a payout - mind the auto-advance race explained in Simulate payout settlement.
What's next¶
- Sandbox overview - the levers at a glance.
- Simulation API reference - wire these calls into your own test suite.