Next.js Discord

Discord Forum

Add Slack bot to workspace via NextAuth?

Unanswered
Sun bear posted this in #help-forum
Open in Discord
Sun bearOP
"How can I seamlessly integrate the process of adding a bot to a Slack workspace, obtaining the access token through Slack's OAuth, and then using that access token to facilitate a user login without requiring them to be redirected to the 'https://slack.com/openid/connect/authorize' endpoint, while still utilizing Next-auth's Slack Provider with JWT strategy in my application?"

5 Replies

Golden-winged Warbler
Do you mean you want users to log into your app with their Slack account?
Sun bearOP
Yes
I am using Next-auth with Slack provider for signing the user in with Slack.
We also have a user flow where the user can add the bot to Slack. This flow will follow the Oauth flow where the redirected url is provided with a code and use that code to get the access token. Once this process is completed, how can I log that user in without making them to visit the sign in flow again?
Sun bearOP
Folks, anyone has a solution for this?