Slack Oauth Authorize
GET
/api/auth/slack/authorize
const url = 'https://example.com/api/auth/slack/authorize';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/auth/slack/authorizeLegacy GET variant — redirects to Slack’s authorization page directly.
Retained for backward compatibility with cached frontend bundles that still
link to this endpoint with ?returnTo= in the query string. New code
should POST to this endpoint instead (see slack_oauth_authorize_post).
Optional query param: returnTo: relative path to navigate to after successful login (validated and stashed in the same cookie as the POST variant)
Responses
Section titled “ Responses ”Successful Response
Media type application/json
Example generated
example