Skip to main content

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 with mainProvider: "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

EnvironmentURL
Sandboxhttps://sandbox.mx.ntxpay.com
All documented routes (/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 the X-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 your webhookUrl 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

AspectSandboxProduction
Base URLhttps://sandbox.mx.ntxpay.comProvided at onboarding
Providersandbox (simulated)Real bank (Banxico/SPEI)
BalanceSimulatedReal funds
SPEI cash-in confirmationImmediate (~1s)Real (seconds to minutes)
X-Sandbox-ScenarioSupportedRejected with 400
CostFreePer 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