Devanshu Kumar
Devanshu Kumar

Reputation: 11

Retrieving Payment Gateway from Transaction API of Shopify

We have an web hook being enabled on "Order Creation" event. The json response which we used to receive earlier gave a parameter "gateway" holding information about payment gateway being chosen by customer. But now for orders being created from last Friday 24th April 2015, we are not getting this parameter, instead we are getting a parameter "financial status" with value "pending". We need this payment gateway Method ex. "Paypal", "COD", "Bank Transfer", as we display this on on invoice being printed.

Suggestion from shopify team says "gateway" field is now deprecated in "Order Creation" and we should use now following link to fetch it. https://spskids.myshopify.com/admin/orders/315026241/transactions.json

We created an another webhook for payment gateway on "Order Payment" event and trying to call it from my 3rdy party website.

But issue is we want to call this from a third party website, When I do so it gives an error of unauthorized access. Please suggest how to fetch payment gateway.

Upvotes: 0

Views: 2221

Answers (1)

alexandresaiz
alexandresaiz

Reputation: 2766

Gateway parameter has recently been moved to transactions. And, transactions are not yet ready to be used with webhooks: https://docs.shopify.com/api/webhooks/using-webhooks

You should get the payment gateway by storing transaction resource on your end.

Upvotes: 0

Related Questions