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.

ngrok Update App url and redirect url via API

ngrok Update App url and redirect url via API

TheFlyingCoder
Shopify Partner
8 0 9

Pretty simple question that I can't seem to find the solution for anywhere.

During development, every restart of ngrok free version requires an update of the app URL and redirect url's.

I noticed the Shopify CLI can do this automatically, but I can't find the documentation for it?

I'm rolling a custom framework and want to embed the functionality in my server script like so:

  if (MODE === "development") {
    HOST = await ngrok.connect(port);
    console.log("ngrok tunnel live at ", HOST);
    open(HOST);
    //Update the app URL and redirect urls
    await setAppUrlAndWhitelist(HOST)
  }

 

Replies 4 (4)

rohanrajpal
Shopify Partner
40 0 13

+1 for this, it's a pain to set the app URL every time ngork restarts. Can anyone please help?

Founder | Spur Feel free to reach out to me at @rohanrajpal98 on Twitter

damdafayton
Shopify Partner
1 0 0

this is very important question. why shopify didnt answer it still?? what a stupid app!

webx47
Shopify Partner
5 0 1

were you able to solve this thing?

 

ShopifyDevSup
Shopify Staff
1453 238 525

Hey @webx47 - we don 't have specific documentation for how the CLI integrates ngrok at the moment. That said, the source code for the implementation is publicly available here. 


We can't offer support for implementations outside of our official libraries at the moment, but this is definitely something I'll note on my end and bring to my colleagues. I can see the need for a wider support experience, especially when you're in the early stages of developing for Shopify. I can't guarantee anything - but I would like to use this thread as an example on my end that I can show to my colleagues as an example of where we can help further.


 

Hope this helps!

 

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us 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