Skip to main content
This guide shows you how to configure an OAuth integration in Snowflake to obtain credentials (client ID & secret). These are required to let your users grant your app access to their Snowflake account.
1

Create an OAuth integration in Snowflake

Run the following SQL in your Snowflake worksheet as an ACCOUNTADMIN (or a role with the CREATE INTEGRATION privilege):
CREATE SECURITY INTEGRATION <integration_name>
    TYPE = OAUTH
    ENABLED = TRUE
    OAUTH_CLIENT = CUSTOM
    OAUTH_CLIENT_TYPE = 'CONFIDENTIAL'
    OAUTH_REDIRECT_URI = 'https://api.nango.dev/oauth/callback'
    OAUTH_ISSUE_REFRESH_TOKENS = TRUE
    OAUTH_REFRESH_TOKEN_VALIDITY = 86400;
Replace <integration_name> with a name for your integration.
2

Get your client ID and secret

Run these queries to retrieve your credentials:
SELECT SYSTEM$SHOW_OAUTH_CLIENT_SECRETS('<integration_name>');
Note your OAuth client ID and OAuth client secret.
3

Configure scopes

Assign the correct role/scope to the OAuth integration so the token has the right permissions. See Snowflake OAuth scopes for details.
4

Next

Follow the Quickstart.
For more on the Snowflake OAuth flow, see the Snowflake OAuth API reference.