Home > OS >  How to set up redirect url for slack authorization with ngrok
How to set up redirect url for slack authorization with ngrok

Time:04-19

I have an express app running inside an electron app using http on port 6001 and used ngrok to connect to that port. My question is how can I set the redirect url in Slack's dashboard without knowing the first part of the url i.e https://xxxx.ngrok.io. Also, I'm planning to distribute my electron app, what happens when multiple users run the application?

CodePudding user response:

If you are running your Express App locally and exposing that to Slack using ngrok, then it must be for development only.

Using the ngrok free version, your endpoint will keep on changing every time you restart your desktop.

For development -> Update the Slack webhook with the new ngrok URL everytime it changes.

For production -> Deploy your Express app to a cloud based runtime and then expose that IP address as the URL for the Slack webhook

  • Related