How to handle "Pending" transactions

What is the PENDING state ?

When a payment transaction post payment init is forwarded to a bank, then Tarabut is waiting for the bank to give a response which helps Tarabut understand if that particular payment was settled or rejected.

Sometimes the bank does not give a response back to Tarabut within the response cutoff limits. At such times the payment transaction is stuck at the "Pending" state.

What should a merchant do when this happens ?

When such an event takes place, merchant can follow 2 implementation patterns.

Keep Polling

  1. Show an interim payment page to the user letting the user know that the order has been placed but yet to be confirmed. The confirmation of the order can happen once the payment status is moved from pending to settled.
  2. The merchant in this case can keep polling Tarabut every 3 mins to check the status of the payment transaction and once the transaction has moved to the settled state then the merchant can confirm the same to the user.

Automate Refunds

  1. Let the end user know that the payment transaction was not confirmed due to some error at the bank's end.
  2. If the end user's account has been debited then let them know that a full refund will be initiated for the same amount with a refund reference id for the same.
  3. Wait for the status to move to settled or rejected. If the status moves to rejected then the merchant does not need to do anything.
  4. If the status moves to settled, then the merchant has to initiate a refund to Tarabut for that payment id.
  5. This logic can be set in the merchant's back end and be automated to keep a uniform user experience on the merchant's application or platform.