Payment gateway overrides the status of an order that was completed using another payment method

Highlighted
New Member
5 0 0

Hello,

 

I'm maintaining a payment gateway for credit card payments on Shopify. Some merchants are experiencing a bug which unfolds as follows :

 

 1. The payer tries to pay by credit card and the payment fails on our gateway (because of insufficient fund for example). At this point, in the merchant's back-office, the order is marked as failed.

 

 2. The payer goes back in the payment process, and choses to pay with another payment method that is installed on the merchant's store (bank transfer, for example); this time the payment is successful. At this point, in the merchant's back-office, the same order switches to succeeded.

 

 3. Out gateway sends a notification (a bit delayed) about the credit card payment being failed. In the merchant's back-office, that makes the same order switch back to "failed", which is an incorrect information for the merchant, because this order has in fact succeeded thanks to the bank transfer (on which we have no visibility or control over).

 

I guess that with the Shopify API, I would be able to take into account the status of the order before sending the delayed notification, but so far I'm only implementing the payment gateway. Is it expected behavior that the gateway is able to override the status of an order that has in fact succeeded via a payment method that has nothing to do with the gateway? What is the recommended best practice on the gateway side to avoid this bug merchants are experiencing?

0 Likes
Highlighted
Shopify Staff
Shopify Staff
1040 140 165

Hey @_Valentin_,

 

Is this with the hosted payment SDK?

 

> At this point, in the merchant's back-office, the order is marked as failed.

I think I'm missing something - how are they doing this if an order hasn't been created yet?

0 Likes
Highlighted
New Member
5 0 0

Hello,

 

Thanks for your response.

 

This is indeed with the hosted payment SDK.

 

how are they doing this if an order hasn't been created yet?

In fact the order is created as soon as Shopify sends a request to our gateway. In the Shopify back-office, it stays in "Abandonned checkouts" while awaiting a response from our gateway for either success or failure (at which point it moves to the list of orders).

 

0 Likes