You need a Builder plan or higher to use connectors in your app.
What you can do
Use your warehouse data to answer questions and keep your team informed.Query warehouse data
Run SQL against your Snowflake warehouse and show the results in your app.
Build analytics dashboards
Display warehouse results in charts, tables, and dashboards.
Automate data workflows
Use Snowflake queries in workflows, such as sending an alert to a Slack channel when a metric drops.
Setting up OAuth in Snowflake
Snowflake OAuth uses a security integration. Create it in Snowflake before you register the connector in Base44.1
Get the Base44 callback URL
Get the Base44 callback URL from Registering callback URLs. The SQL below registers it as
OAUTH_REDIRECT_URI.2
Create the OAuth security integration
Use This sets refresh tokens to 90 days, Snowflake’s default and maximum value.If View redirect URIs lists additional URLs for existing connections, add every one to
ACCOUNTADMIN or a role with the global CREATE INTEGRATION privilege. This example uses ACCOUNTADMIN. If you use another role, replace the first statement.OAUTH_ALTERNATE_REDIRECT_URIS in this CREATE SECURITY INTEGRATION statement.If you choose another integration name, use it in the remaining SQL statements.3
Get your connection details
Read your Client ID and Client Secret.Use the cell’s copy button for both values. The Client ID often ends in
=, and omitting that character breaks the connection.Get the Snowflake account identifier you’ll enter in Base44.4
Prepare the Snowflake identity
Use a regular Snowflake identity with a
DEFAULT_ROLE and DEFAULT_WAREHOUSE set. Its role needs access to the databases and objects your app queries and permission to use the warehouse.Snowflake blocks ACCOUNTADMIN, SECURITYADMIN, ORGADMIN, and GLOBALORGADMIN from using this integration by default. This is a Snowflake security default, not a Base44 restriction.Already have an OAuth integration?
Already have an OAuth integration?
Use If View redirect URIs shows URLs for existing connections, include all additional URLs in
ALTER to change an existing integration. CREATE OR REPLACE deletes and recreates it, so don’t use it for a redirect URI change.If the integration already exists and only the callback URL needs updating, run this instead.OAUTH_ALTERNATE_REDIRECT_URIS. Keep any alternate URLs that are already registered.Connecting Snowflake
Connect Snowflake so your app can query your warehouse.Before you begin:
- Snowflake OAuth integration: Create a Snowflake OAuth security integration so you have a Client ID and Client Secret. See Setting up OAuth in Snowflake.
- Snowflake account identifier: In the Snowflake web UI, click your account name in the bottom left, select Copy account URL, and use the part before
.snowflakecomputing.com. You can also get the identifier with the SQL in Setting up OAuth in Snowflake. - Base44 workspace access: You must be a workspace owner or admin to register the connector in Base44.
- Snowflake access: Each person who connects needs access to the databases you want to query.
- Click Connectors in your workspace sidebar.
- Click Add connector.
- Search for Snowflake and click it.
- Enter a Connector name.
- Enter the Client ID and Client Secret from your Snowflake OAuth integration.
- Keep refresh token under Scopes and leave Additional scopes empty. See Scopes and permissions.
- Enter your Snowflake Account identifier under Connection Configuration in
orgname-account_nameformat, for examplenzajreo-sp04035. Don’t include.snowflakecomputing.comor use the legacy account locator. - Click Add Connector.
- Open your app in the app editor.
- Ask the AI chat to add a Snowflake feature.
- Authorize the account when prompted.
Scopes and permissions
Your Snowflake permissions determine which warehouse data your app can query.1
Base44 adds
refresh_token: Refreshes the connection without another sign-in
2
You configure
- Leave Additional scopes empty. Snowflake rejects unsupported values, such as
account:read, with The requested scope is invalid. - Don’t add
session:role:<role>.
Access: Snowflake uses the default role and permissions of the identity that authorizes the connection.
Using Snowflake in a backend function
Once Snowflake is connected, your backend functions can retrieve an access token and query your warehouse. Base44 handles the OAuth flow and credential storage.- App user connector
Connectors (developer docs)
Retrieve a connection, read its details, and call the service API from a backend function.
Troubleshooting
Check roles, warehouse access, and callback URLs if Snowflake can’t connect or run queries.Queries fail with a warehouse or access error
Queries fail with a warehouse or access error
Check the connected Snowflake identity’s
DEFAULT_ROLE and DEFAULT_WAREHOUSE. The role needs USAGE on the warehouse, database, and schema, plus SELECT on the tables or views your app queries. For an app user connection, check each person’s Snowflake role and grants.The connection fails with a redirect URI mismatch
The connection fails with a redirect URI mismatch
For the general fix, see redirect URI errors. In Snowflake, check that the integration is enabled and compare its registered redirect URIs with the URLs your connection uses.Confirm that every URI Base44 shows is registered as
OAUTH_REDIRECT_URI or in OAUTH_ALTERNATE_REDIRECT_URIS. Snowflake matches redirect URIs character for character.The connection fails because your role is blocked
The connection fails because your role is blocked
You signed in with a privileged role. Snowflake blocks
ACCOUNTADMIN, SECURITYADMIN, ORGADMIN, and GLOBALORGADMIN from using the integration by default. Sign in with a regular Snowflake user instead.