When you’re building your integration, you may wish to simulate events so you can test how your integration responds.
You can trigger events using our dashboard-triggered or name-triggered scenario simulators.
Dashboard-triggered scenario simulators
Dashboard-triggered scenarios are started from your Dashboard. Just head to the "Developers" tab on the left-hand side, and then click "Simulate a scenario".
Choose a simulator from the dropdown (for example "Payment paid out"), and then you'll see more information about that scenario, detailing exactly what will happen and anything you need to know before you can use it (for example, some scenario simulators are not compatible with every scheme.
Enter the ID of the resource you want to run the simulator on, and then click "Simulate scenario". If there's any problem, for example we can't find the resource or it isn't compatible with the scenario you've chosen, we'll let you know.
You can use Dashboard-triggered scenarios to try all of the cases supported by the name-triggered scenarios below, plus a few extras (for example creditor verification status, which may be useful if you’re building a partner integration).
Resource type |
Scenario action |
Resource state required |
Schemes supported |
---|---|---|---|
Creditor |
Update creditor to ‘action_required’ verification status |
No requirements |
Bacs, BECS, SEPA, Autogiro |
Update creditor to ‘in_review’ verification status |
|||
Update creditor to ‘successful_verification’ status |
|||
Mandate |
Activated |
Mandate must must start in the `pending_submission` state |
Bacs, BECS, Autogiro |
Expired |
Bacs, BECS, SEPA |
||
Failed |
Bacs, BECS, Autogiro |
||
Transferred |
Bacs |
||
Payment |
Charged back |
Payment must start in the `pending_submission` state, and its mandate must be in the `activated` state (unless it is a SEPA payment, in which case the mandate may be `pending_submission`, since SEPA mandates are submitted with their first payment). |
Bacs, SEPA, Autogiro |
Failed |
Bacs, SEPA, Autogiro |
||
Late failed |
Bacs, SEPA |
||
Late failure settled |
Bacs, SEPA |
||
Paid out |
Bacs, SEPA, Autogiro |
Name-triggered scenario simulators
Where possible, you should use Dashboard-triggered scenarios, since they are more reliable and support a wider range of cases.
Name-triggered scenarios are scenarios started by using special customer names. For example, if you create a customer with the given_name “Successful”, their mandate will be activated immediately, and their payments will be paid out straight away.
These customer names take effect only on payments created as an individual payment, not those created through a subscription. However, they will be run on the first payment created by a subscription.
All the relevant events and webhooks will be created and sent for these simulators.
Customer |
Description |
What happens on mandate creation |
What happens on payment creation |
Schemes supported |
---|---|---|---|---|
Successful |
The customer’s payment is collected successfully and paid out to you. |
The mandate is marked as submitted, then activated. |
The payment is marked as submitted, then confirmed. If you’ve set up a creditor bank account, it is thenpaid_out and a payout is created. |
Bacs, BECS, SEPA Core and Autogiro |
Penniless |
The customer’s payment can’t be collected, for example because they don’t have enough money in their account. |
The mandate is marked as submitted, then activated. |
The payment is marked as submitted, then failed. |
Bacs, BECS, SEPA Core and Autogiro |
Fickle |
The customer’s payment is collected successfully, but is then charged back by the customer disputing it with their bank. |
The mandate is marked as submitted, then activated. |
The payment is marked as submitted, then confirmed. If you’ve set up a creditor bank account, it is thenpaid_out and a payout is created. Finally, the payment is marked ascharged_back. |
Bacs, BECS, SEPA Core and Autogiro |
Late |
The customer’s payment can’t be collected, but the bank informs us of the failure later than normal. |
The mandate is marked as submitted, then activated. |
The payment is marked as submitted, then confirmed, then failed. |
Bacs, BECS, SEPA Core and Autogiro |
Invalid |
The customer’s mandate can’t be set up because their bank details are rejected by the banks as invalid. |
The mandate is marked as submitted, then failed. |
N/A |
Bacs, BECS and Autogiro |