Payment Statuses
Every payment has a status. Three of them are final. Once a payment reaches
a final status, it never changes again.
| Status | Meaning | Final | What your system should do |
|---|---|---|---|
| CREATED | Waiting for the customer to pay. | No | Keep the order pending. |
| PROCESSING | The customer is paying, and the provider hasn't answered yet. | No | Keep the order pending. |
| CAPTURED | Paid. | Yes | Mark the order paid and deliver it. |
| FAILED | The payment failed and can't be retried. | Yes | Offer the customer a new payment. |
| CANCELLED | The customer gave up on the checkout page. | Yes | Offer the customer a new payment. |
| EXPIRED | Nobody paid within 30 minutes. | Yes | Offer the customer a new payment. |
How a payment moves
CREATED ──► PROCESSING ──► CAPTURED
▲ │
└─────────────┘ a try failed (for example, a wrong PIN)
CREATED ──► CANCELLED the customer gave up
CREATED ──► EXPIRED 30 minutes passed
PROCESSING ──► FAILED failed for good
- A failed try isn't a failed payment. If the customer enters a wrong PIN,
the payment goes from PROCESSING back to CREATED,
and they can try again. Each try is listed in the payment's
attempts. After the third failed try, the payment becomes FAILED and BillPay sendsPaymentFailed. - Refunds don't change the status. A refunded payment stays
CAPTURED, and its
refundedamount goes up. - Only the customer can cancel. There's no API call for you to cancel a payment. If an order is cancelled on your side, leave the payment. It becomes EXPIRED after 30 minutes.
Which statuses send a webhook
| Status | Webhook |
|---|---|
| CAPTURED | PaymentCaptured |
| FAILED | PaymentFailed |
| CANCELLED | None yet |
| EXPIRED | None yet |
Since cancelled and expired payments don't send a webhook yet, check any order that's still pending after 30 minutes. See Check a Payment.