Get started
Testing
Test cards, amounts and scenarios that trigger declines, authentication, disputes and payout failures in test mode.
Test mode lets you run every flow end to end without moving money. Use your sk_test_ key, then use the cards and values on this page to trigger specific outcomes.
This is preview documentation for a prototype. Endpoints, fields and keys are illustrative.
Test cards
Use any future expiry date, any three-digit CVC (four for American Express) and any postal code.
| Card number | Brand | Result |
|---|---|---|
4242 4242 4242 4242 | Visa | Succeeds |
5555 5555 5555 4444 | Mastercard | Succeeds |
3782 822463 10005 | American Express | Succeeds |
4000 0000 0000 3220 | Visa | Requires 3-D Secure authentication |
4000 0000 0000 0002 | Visa | Declined: card_declined |
4000 0000 0000 9995 | Visa | Declined: insufficient_funds |
4000 0000 0000 0069 | Visa | Declined: expired_card |
4000 0000 0000 0259 | Visa | Succeeds, then opens a dispute |
4000 0000 0000 5126 | Visa | Succeeds, but refunds fail |
Cards by country
To test local acquiring and country-specific methods, use a card issued in the shopper's country.
| Card number | Issuing country |
|---|---|
4000 0027 6000 0016 | Germany |
4000 0082 6000 0000 | United Kingdom |
4000 0039 2000 0003 | Japan |
4000 0007 6000 0002 | Brazil |
Trigger outcomes with amounts
For methods without card numbers, such as wallets and bank transfers, the order amount decides the outcome.
| Amount ends in | Result |
|---|---|
00 | Succeeds |
01 | Fails with payment_method_declined |
02 | Stays in processing for 2 minutes, then succeeds |
03 | Stays in processing for 2 minutes, then fails |
For example, an order for 10001 minor units with a bank transfer will fail.
Authentication
Card 4000 0000 0000 3220 opens a test 3-D Secure page. Choose Complete to succeed or Fail to decline. The order moves to requires_action while the shopper is on that page, and you receive payment.requires_action.
Payouts
Use these bank details in test mode to simulate payout outcomes:
| Detail | Result |
|---|---|
IBAN DE89370400440532013000 | paid |
IBAN DE62370400440532013001 | failed with account_closed |
Account holder name Test Mismatch | failed with name_mismatch |
Trigger events directly
You don't have to create a real flow to test your webhook handler. The CLI sends a realistic event to your endpoint:
io trigger payment.failed
io trigger dispute.opened
io trigger payout.failed
See Webhooks for how to forward events to your machine.
Landed-cost quotes
In test mode, quotes use fixed illustrative rates so results are repeatable. Any destination postal code works. To test a non-guaranteed quote, leave out hs_code on an item.
Moving to live
Before you switch to sk_live_ keys:
- Handle
order.paidfrom a webhook, not the browser redirect. - Handle
payment.failedand show the shopper a clear message. - Verify webhook signatures.
- Send an
Idempotency-Keyon everyPOST. - Check your error handling against the error reference.