What it is
The NTX Pay sandbox lets your integration exercise cash-in, cash-out, refund, and webhooks without moving real money. Unlike simplistic mocks, the full accounting pipeline (TigerBeetle balance, limit validation, fee charging, statement generation, webhook delivery via outbox) is exercised intact. Only the external provider (SPEI/Banxico) is simulated.Every NTX Pay integration starts in sandbox. The endpoints, payloads, and webhooks described in this documentation are the final ones — when production is enabled for your company, the same code works by just swapping credentials.
How to enable
Your API credentials are structurally the same as those you would use in production. The difference lives at the account level: accounts withmainProvider: "sandbox" route every SPEI call internally to the NTX simulator. To create a sandbox account, contact your Account Manager or write to contact@ntxpay.com — onboarding is instant and KYC is auto-approved.
Base URL
| Environment | URL |
|---|---|
| Sandbox | https://sandbox.mx.ntxpay.com |
/api/auth/token, /api/spei/cash-in, /api/spei/cash-out, /api/transactions, /api/webhooks-config) are available exactly at this host.
Test scenarios
You control the behavior of each call via theX-Sandbox-Scenario HTTP header. Without the header, the sandbox returns success by default. See Scenarios for the full list of supported error, success, and delay scenarios.
Webhooks
Register yourwebhookUrl on the sandbox account exactly as you would in production — via POST /api/webhooks-config. Events are delivered by the same outbox engine we use in prod, with the same signatures, headers (X-NTXPay-Delivery), and retry policy.
Differences vs Production
| Aspect | Sandbox | Production |
|---|---|---|
| Base URL | https://sandbox.mx.ntxpay.com | Provided at onboarding |
| Provider | sandbox (simulated) | Real bank (Banxico/SPEI) |
| Balance | Simulated | Real funds |
| SPEI cash-in confirmation | Immediate (~1s) | Real (seconds to minutes) |
X-Sandbox-Scenario | Supported | Rejected with 400 |
| Cost | Free | Per contract |
Next steps
Authentication
How to obtain the JWT in sandbox using your credentials.
Scenarios
Full list of scenarios available via
X-Sandbox-Scenario.Cash-in
Receive via SPEI in sandbox.
Cash-out
Send via SPEI in sandbox.
Webhooks
How the sandbox delivers webhooks and how to test dedupe.
Support
support@ntxpay.com