On This Page

{#jumplink-list}  
[Markdown](/docs/cybs/en-us/digital-accept-flex/developer/all/rest/digital-accept-flex/uc-intro/uc-pay-methods-intro/uc-pay-methods-obt/uc-pay-methods-obt-handle-response.md)  
Filter  
FILTER BY TAG

Handle Responses {#uc-pay-methods-obt-handle-response}
======================================================

When you process a payment using unifiedPayment.complete() in `Unified Checkout`, you must handle both successful responses and various errors. After the payment is complete, the completeResponse object contains information about the transaction outcome.  
When a payment is processed successfully, you must parse the response to confirm the payment status, update their order records, and trigger any post-payment workflows. Post-payment workflows include sending confirmation emails or updating inventory. See [JavaScript Example: Processing a Payment](/docs/cybs/en-us/digital-accept-flex/developer/all/rest/digital-accept-flex/uc-intro/uc-getting-started-cs-setup-intro/uc-getting-started-cs-js-library-intro/uc-getting-started-cs-js-payment-example.md "").  
Your error handling should account for specific cases such as `COMPLETE_TRANSACTION_CANCELED` and `COMPLETE_TRANSACTION_FAILED`. `COMPLETE_TRANSACTION_CANCELED` occurs when the user cancels the transaction and `COMPLETE_TRANSACTION_FAILED` indicates that the consumer's transaction failed.  
For PPRO-enabled online bank transfers, only cancellation errors are returned, and Tink Pay By Bank returns failure and cancellation errors. For information about possible errors that can occur when calling the complete API see [Class: AcceptError](/docs/cybs/en-us/digital-accept-flex/developer/all/rest/digital-accept-flex/uc-intro/uc-appendix-js-reference/uc-appendix-js-class-accept-error.md "").  
RELATED TO THIS PAGE

