Refunds are being download double by Shopify API

Webgility1
Shopify Partner
58 1 9

We are Webgility and have mutual customers. We are consuming the Shopify order download API in our Webgility application.

Our mutual customers are experiencing an issue while downloading the Orders and their refunds.As we checked in api response and we are getting two records for refunds but in store it is showing only once.

 

Endpoints we are using are as below:-

a) https://rickshaw-boots.myshopify.com/admin/api/2020-01/orders/2580820983967.json

    1. It is giving two refunds.

b) https://rickshaw-boots.myshopify.com/admin/api/2020-01/orders/2827294441631.json

    1. It is giving two refunds.

 

Content-Type:-  application json

X-Shopify-Access-Token:- 01177b1668a49515b59bdfc6f9bae218



Please let us know if it requires any information from our side.

Replies 7 (7)

Webgility1
Shopify Partner
58 1 9

Hi,

Please let me know  if there is any update .

Webgility1
Shopify Partner
58 1 9

Hi,

Please let me know  if there is any update.

Webgility1
Shopify Partner
58 1 9

@Shopify Team, 

Can we get a Quick Update here.

Webgility1
Shopify Partner
58 1 9

Hi Shopify ,

Our mutual customers are getting this issue continues.
Please look on it as priority.

Thanks

Webgility1
Shopify Partner
58 1 9

Hi Shopify ,

Our mutual customers are getting this issue continues.
Please look on it as priority.

Thanks

Webgility1
Shopify Partner
58 1 9

Hi Shopify, Our mutual customers are getting this issue continues.

Please look at it as priority.

Thanks

GrahamS
Shopify Staff (Retired)
193 36 53

Hello @Webgility1 ,

This would be an expected outcome in some situations where a refund is initially pending, and later successful. The transactions json log will contain 2 entries for the refund, one marked as "pending" and one marked as "successful", as these are handled as individual transactions/API calls rather than a singular event.

In the example links you provided, you or your client could navigate to: "https://rickshaw-boots.myshopify.com/admin/orders/2580820983967/transactions.json" to see the transactions log in detail, and confirm the above stipulation.

You would need to modify your API call to filter for "status: successful" or another parameter of that nature in order to prevent the unnecessary pending entry from being downloaded.

Best,

To learn more visit the Shopify Help Center or the Community Blog.