Key Information
Payment status life cycle
GreenBanana handles the complex functionality of a comprehensive payments flow through the Payments object that transitions through multiple states during its payments lifecycle. Given below are the various statuses a payment can have:
Payment Status | Description |
---|---|
requires_payment_method | Once you create a payment through payments/create endpoint with no payment method attached to it, the payments object transitions to ‘requires_payment_method’. |
requires_confirmation | After attaching a payment method through payments/update endpoint, the payments object requires you to confirm the payment. |
requires_customer_action | Once the payment is confirmed through payments/confirm endpoint, if additional authentication is required, the payments object transitions to this state. |
requires_capture | If you want to do separate authorize and capture, setting capture field to ‘manual’ during payments/create or confirm call will transition the payment object to this state after customer action succeeds. |
processing | In case of automatic capture, the payments object transitions to processing state post confirm call and subsequent customer authentication if available. |
succeeded | The payments object reaches success state post confirmation of successful processing from the payment processor. |
failed | The payments object transitions to a failed state when the payment processor confirms the processing failure. |
expired | You can expire the payments object while it is in any state except when it is under ‘processing’ or ‘succeeded’ state. |