Uninstalled Webhook not firing

Solved
TezWingfield83
Tourist
14 0 1

Hi Bill,

It's always great to "rubber duck" the flow.

 

Yes, so I create an app in shopify - fill in the necessary fields.

 

1. Click the app

s-app.png

 2, Select a store

locate-app.png

 3, Click and Install

dav.png

 At this point it goes through all typical OAuth process, On the call back using the redirect uri I begin to create the app/uninstalled webhook.

db-h.png

 I also log the resp

 

h-resp.png

 And I can also see the resp when getting all webhooks for that account

ps-resp.png

The app is most certainly "installed"

app-inst.png

 Looking at the same screenshot, I click the Delete button being the uninstalled process, even tried when clicking into the app.

 

 I've tested my own endpoint to simulate what shopify is attempting to do and it works:

ps-self.png

End result my local server is still running and not being hit:

 

l-serv.png

 

I've used the same hook endpoint stored in hook resp, my config tbl, postman etc... The url works.

 

Other process, ngrok running locally with a developers account - nothing out of the ordinary.

 

Regards,

 

0 Likes
_JB
Shopify Staff
Shopify Staff
809 95 176

Hey @TezWingfield83,

If you provide the id for your app I'll check our logs to confirm the webhook is being sent, and confirm the response we're seeing from your endpoint. Bill's advice is great and there's isn't anything else I'd add, but I can at least confirm the behaviour in our logs to give a bit more confidence while you troubleshoot. The app id is the last set of digits in the URL when you're viewing the app in the partner dashboard.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

0 Likes
TezWingfield83
Tourist
14 0 1

Hi JB, Bill,

 

Thank you.

Here's the Id: 5175689

Regards,

 

0 Likes
_JB
Shopify Staff
Shopify Staff
809 95 176

This is an accepted solution.

@TezWingfield83,

The logs confirm a webhook is indeed firing, but your endpoint is responding with a 503 error. They're being sent to https://[removed].ngrok.io/Shopify/Uninstall . Hopefully that helps with troubleshooting.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

0 Likes
TezWingfield83
Tourist
14 0 1

Hi JB, Bill.

Awesome that's something to go on.

503 Service unavailable implies, I guess more of a network issue. I'm able to hit that endpoint locally using ngrok with no issues.

To confirm a network related issue, I'll aim to deploy a serverless http func to see if that resolves it - just makes it impossible to debug locally.

Thank you for your time all.

I'll report back later.

Regards,

TezWingfield83
Tourist
14 0 1

Hi @HunkyBill @_JB 

 

Thank you again, I know it's been a challenge. I'm pleased it's not a developer mistake, I.E bug / config. 

JB, would it be possible just to confirm whether you're now receiving a 200. I've quickly deployed a serverless func, and can see an execution on my tracer but don't have any logs yet due to a quick temp release to test the theory.

 

Having said that, I'm still not quite sure why shopify cannot reach my ngrok instance. baffling.

 

Regards,

 

0 Likes
HunkyBill
Shopify Expert
4472 45 484

I would still bundle any issues you have with your service as a config problem. Whether it be with ngrok, or other aspects, those all get lumped in... Shopify is sending the webhook. That action generates a non-200 OK response... therefore that is a config issue. But yes, it is also that you have not made a typo of otherwise introduced some kind of bug yourself. Good luck, and hopefully your can sort out your ngrok issues soon!

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
_JB
Shopify Staff
Shopify Staff
809 95 176

Hey @TezWingfield83,

Confirmed, I'm seeing 4 200 - OK responses in the past hour. Note that Shopify automatically retries failed webhook deliveries, so some of those may be from previous failed delivery attempts.

JB | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

TezWingfield83
Tourist
14 0 1

Hi @HunkyBill 

Thanks for the info, does come off a little iffy/sarcastic haha but appreciate the honesty.

I use the same configuration through various WMS systems, I'm confident in the approach but non the less shall investigate the configuration.

Again, thank you for the time taken.

Regards,

0 Likes
TezWingfield83
Tourist
14 0 1

Hi @_JB 

Fantastic, Thank you.

I truly appreciate the time taken.

Regards,

0 Likes