Topics covering webhook creation & management, event handling, Pub/Sub, and Eventbridge, in Shopify apps.
Hi,
is there any way of getting notified via a webhook when a return has been created? Or is there at least a way to check, if a return on an order has been created?
Just to clarify: I'm not talking about a refund but a return which is created by clicking on 'Return items' in the details page of a fulfilled order.
I don't see a webhook for this specific action, although you could subscribe to the orders/updated webhook and then parse the response body to determine if that action has taken place. Unless someone else can suggest a better angle.
Here is a thread that speaks to the return action and its accessibility via the API. I know it's not necessarily speaking to a webhook but still interesting --> https://community.shopify.com/c/Shopify-APIs-SDKs/Return-API/td-p/640771.
Thank you for your reply.
I already tried the orders/updated webhook. Unfortunately it does not fire for a created return. Also there is – as far as I know – no way of finding out which items have been included in the return, even if I would check the order via the GraphQL API manually, without a webhook.
I guess I will have to implement the whole return process into my app instead of using Shopify's 'Return items'-functionality
how i recognise if return create? i received orders/updated webhook but didn't found any status "return".
Not sure if you guys already fixed this but I had the same issue and realized they added soooo many more Webhooks to the Graph QL API. I missed it cuz I was looking in the admin panel where they only have a few (only REST I guess), but link below theres everything you'll need, just use the webhookSubscriptionCreate mutation
https://shopify.dev/docs/api/admin-graphql/2024-01/enums/WebhookSubscriptionTopic
But none of those are triggered whene there is a return created from an api
To trigger an event, you must use the Shopify admin interface.
The api has RETURNS_APPROVE and RETURNS_REQUEST. But sitll not RETURNS_CREATE.
Also the shopify cli seems to be unable to trigger return related webhooks at all. Even the graphql ones.
You can use Shopify’s GraphQL API to create a webhook subscription using the topic of RETURNS_APPROVE.
This event is triggered when creating a new return using the Shopify admin or when approving a self-served return request made by a customer.
To trigger an event, you must use the Shopify admin interface.