Sandbox & Testing
The sandbox is a complete copy of the StablePay API for building and testing your integration. It behaves exactly like production — same endpoints, same request/response shapes — but nothing is real: no money moves, no payouts are sent, no live KYC/AML checks run. Every outcome is deterministic, so you can test success and failure paths reliably.Sandbox keys are prefixed
pk_sandbox_ and production keys pk_live_. A sandbox
key only works against the sandbox URL, and vice-versa. StablePay issues your
sandbox key — reach out to get one for your account.Test values
Drive specific outcomes with these inputs:The payout outcome keys off the cents of the amount you send (the USD deposit
amount for a
sell, or the INR amount for a payout) — not the converted total,
which depends on the live rate.Simulating a deposit
In production, asell transaction waits for the user’s on-chain crypto deposit.
The sandbox has no real blockchain, so you trigger the deposit yourself with a
sandbox-only endpoint. It drives the transaction through its full lifecycle —
deposit detected → confirmed → converted → paid out — firing the same webhooks
production would.
The transaction ID returned by
POST /v2/transactions.Override the deposit amount. Defaults to the transaction’s expected amount.
Confirmations to report. Defaults high enough to confirm immediately; pass a low
number to leave the deposit merely detected (unconfirmed).
When
true (default), drives the transaction all the way to a terminal payout.
Set false to stop at deposit_confirmed. No-op for pre_settlement
transactions, whose payout already fired at creation.This endpoint exists only in the sandbox, and only supports
sell /
pre_settlement deposit flows. For payout-type transactions there is no
deposit to simulate — they pay out immediately on creation.End-to-end walkthrough
A full offramp in the sandbox, using thesell flow:
https://api.stablepay.global and
your pk_live_ key — no other code changes are needed.