Custom Credentials
Authenticate to Slack from a Desktop Application
Set the following connection properties to connect:
- InitiateOAuth: Set this to GETANDREFRESH. You can use InitiateOAuth to avoid repeating the OAuth exchange and manually setting the access token in the connection string.
- OAuthClientId: Set this to the Client Id in your app settings.
- OAuthClientSecret: Set this to the Client Secret in your app settings.
- CallbackURL: Set this to the Redirect URL in your app settings.
- Extracts the access token from the callback URL and authenticates requests.
- Refreshes the access token when it expires.
- Saves OAuth values in OAuthSettingsLocation to be persisted across connections.
Authenticate to Slack from a Web Application
To obtain an OAuthAccessToken, set the following connection properties and follow the steps below.
- OAuthClientId: Set this to the Client Id in your app settings.
- OAuthClientSecret: Set this to the Client Secret in your app settings.
- Call GetOAuthAuthorizationURL. The stored procedure returns the URL to the OAuth endpoint.
-
Log in at the OAuth endpoint and grant the application permissions. You are redirected back to the callback URL.
The callback URL contains a verifier code in the "code" query string parameter. Extract the verifier code.
- Call GetOAuthAccessToken.