Test and Live Mode
Get to know your environment
The Pinch platform offers an advanced testing platform, custom built into our production systems. As a developer, this means you get bespoke behaviour for the test environment, and no dodgy sandbox environment with separate logins.
API Base URLs
- Test:
https://api.getpinch.com.au/test/ - Live:
https://api.getpinch.com.au/live/
Credentials
Your Merchant ID and Secret Key (or Application ID and Secret) from the Pinch Developer Portal work in both environments; the base URL is what determines test vs live. No separate sandbox account is needed.
Test Mode
Test Mode allows you to perform every single action that you can in production, without actually going to the bank. Better yet, we've implemented Time Travel to let you pretend it's whatever time/date you want. Very useful for instantly testing what would normally take a week in real-time.
Time Travel
Direct debit payments are processed overnight and take several business days to clear, which makes manual testing slow. Time Travel lets you simulate the passage of time by adding a Time-Travel header to any test request:
Time-Travel: 2026-08-01T09:45:59ZThis tells Pinch to treat the request as if it arrived at that date and time, triggering any scheduled payments or settlement logic that would normally run overnight.
The best way to explore Time Travel is to use the Dev Portal and watch what headers it sends back and forth.
Testing a direct debit end-to-end
- Create a payer with a test bank account (see below)
- Schedule a payment for today's date
- Add a
Time-Travelheader set to a time after the scheduled processing window (e.g. the next morning) - The payment will be processed and a
bank-resultsevent will fire with the result - Advance the date further to trigger settlement and a
transferevent
Valid Test Cards
These card numbers can be used with the Sandbox environment with any expiry date in the future and any CVC value.
| Card Number | Card Type | Country |
|---|---|---|
4242424242424242 | Visa | Australia |
4000000360000006 | Visa | Australia |
4012888888881881 | Visa | Australia |
378282246310005 | AMEX | Australia |
4111111111111111 | Visa | New Zealand |
5105105105105100 | Mastercard | New Zealand |
4000005540000008 | Mastercard | New Zealand |
371449635398431 | AMEX | New Zealand |
4000056655665556 | Visa | USA |
5200828282828210 | Mastercard | USA |
5555555555554444 | Mastercard | USA |
Valid Test Bank Accounts
Use any of the following Australian bank account details when tokenising a bank account source in test mode. These will be accepted by the test environment without going to a real bank.
| BSB | Account Number | Description |
|---|---|---|
000-000 | 0000000000 | Generic test bank account |
000-001 | 1234567890 | Alternate test bank account |
Any BSB / account number combination will be accepted in test mode; the values above are provided for convenience. Use realistic-looking values (6-digit BSB, 5–9 digit account number) to test your UI validation.
Triggering Dishonour Codes in Tests
To test specific failure scenarios, add a dishonour code (prefixed with #) anywhere in the payment description field, or in the payer's firstName:
description: "Monthly membership #insufficient-funds"
This will cause the payment to fail with that specific dishonour code. See Dishonour Codes for all available codes.
Live Mode
When you're ready to switch to production, swap your test API base URL for the live one:
https://api.getpinch.com.au/live/
Your credentials remain the same; just update the base URL. Real payments will be processed against real bank accounts and cards.
Double-check thatTime-Travelheaders are not being sent in production requests. They will be ignored in live mode, but it is good practice to remove them entirely before go-live.
Updated 13 days ago
