Have your say in Community Polls: What was/is your greatest motivation to start your own business?
Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Re: Can't create a webhook that points to a subdomain

Can't create a webhook that points to a subdomain

modaltb
Tourist
4 0 2

I'm tying to have a webhook point to a server that is setup with a subdomain DNS record, in this fake example, call it bar.FOO.com.
When trying to save the webhook, I'm getting:

  • Address cannot be in domains: shopify.com, myshopify.com, FOO.myshopify.com, shop.FOO.com, store.FOO.com, www.FOO.com, FOO.com

Is there anyway around this?

Replies 12 (12)

modaltb
Tourist
4 0 2

Adding some clarification to above:
The DNS for the Shopify store is setup on www.FOO.com, store.FOO.com and shop.FOO.com
When adding the webhook, I'm using something like bar.FOO.com

sitkashares
Tourist
7 0 47

I have the same problem, although I'll add this seems to be recently changed behavior. I have existing webhooks that work fine pointed at a subdomain, but when trying to add new webhooks to the same subdomain, i get this validation error. 

_JB
Shopify Staff (Retired)
836 100 223

Hey @sitkashares @modaltb,

Can you provide the request_id from your calls which are failing validation?

I've tested but am unable to replicate any issues when creating webhooks pointing to a subdomain. I believe we only preform validation to ensure the word shopify isn't present in the root domain, and that the https:// protocol has been specified in the address. If you can provide some examples we'll investigate further.

JB | Solutions Engineer @ Shopify 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

sitkashares
Tourist
7 0 47

i can't save my new webhooks due to the validation to help... but if you want to move to DM, i can jump in a call or email string

modaltb
Tourist
4 0 2

Hi @_JB ,

I can't get to any request IDs to provide any more details on that, but if I had to guess I think it's likely a bug in the "Add a webhook" logic from: 
  https://[store_x].myshopify.com/admin/settings/notifications

Here's the error string:

  • Address cannot be in domains: shopify.com, myshopify.com, modalai.myshopify.com, shop.modalai.com, store.modalai.com, www.modalai.com, modalai.com

 I'm trying to point to something similar to this URL for the webhook:

   https://coolwebhook.modalai.com/shopify/order

If I try:
   https://coolwebhook.modalai.net/shopify/order

The "Add a webook" logic allows me to save the end point.

 

_JB
Shopify Staff (Retired)
836 100 223

Hey @modaltb @sitkashares,

Thanks for clarifying. Our developers are aware of the issue and are working on a fix as we speak, I'll post back here to confirm when the fix ships.

JB | Solutions Engineer @ Shopify 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

sitkashares
Tourist
7 0 47

Thanks! Just hit save and the webhook went through! looks to be resolved. 

modaltb
Tourist
4 0 2

Thanks for quick fix, nice product, I'm enjoying using shopify  😉

_JB
Shopify Staff (Retired)
836 100 223

Glad to hear it's working now. Confirming the fix has shipped, and you won't see validation errors as long as the root domain doesn't contain the word `shopify`, and doesn't resolve to a Shopify IP address.

JB | Solutions Engineer @ Shopify 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

jvclement
Visitor
1 0 0

So i'm not sure if there was ever a solution mentioned, but if none of the domains work, then how do you connect the webhook?

Message i am getting:

 

There is 1 error:
Vify
Visitor
1 0 0

I have same problem. Any solution at the moment?

cannot be any of the domains: vify-pdf-invoice-customizer.myshopify.com, pdfinvoice.vify.io
MikhailZhuro
Visitor
1 0 0

I have the same problem right now, any help, please 
I can't create a webhook for a subdomain that connected to an external host that I use for my API code.