Skip to main content

Connect Snowflake

Enable effortless contact & data transfer and research updates with a one-way or two-way sync between Rally and Snowflake

Sophie avatar
Written by Sophie
Updated this week

πŸ’‘ Snowflake is an enterprise feature. Contact your Rally Sales Rep to enable!

With Rally's Snowflake integration, enriched participant data like company name, ARR, renewal date, customer health score, and custom properties can automatically sync data every 24 hours from Snowflake into Rally.

Rally can now send data like screener responses, last contact date, or participant properties back to Snowflake for deeper analysis, downstream workflows, and to share research insights in Snowflake automatically.

Connect Rally to up to 2 Snowflake tables and optionally set up two-way syncs with specific tables, so data flows exactly where you need it. Examples:

  • One-way sync Snowflake to Rally

  • One way sync Rally to Snowflake

  • Two-way sync between Rally and Snowflake

Configuring sync settings and property mappings can tailor the integration to your specific needs.

  • Benefits for Researchers: With enriched Snowflake data in Rally, researchers can create super targeted, niche segments of users + panels in Rally to recruit best fit customers for research on-demand β€” without relying on data science teams. For some of our customers, the time spent on recruiting for a study dropped from 4 weeks to just minutes after connecting Snowflake to Rally.

  • Benefits for Sales/CS team

    • This integration allows researchers to share valuable research insights β€” e.g. expansion/upsell signs or churn risk β€” directly into Snowflake, to support and collaborate with sales and CS reps.

How does the Snowflake Integration work?

Rally connects to your Snowflake instance through a standard OAuth connection to a Snowflake user.

After setting up a connection with Snowflake, you can set configuration settings and create Property mappings between Rally Properties and Snowflake Properties. Each of these Properties can be configured per Property to either sync data from Rally β†’ Snowflake, from Snowflake β†’ Rally, or use a two-way sync (see below for more details).

Once your Snowflake account has been connected and the integration has been configured, Rally will automatically sync data between Rally and Snowflake every 24 hours. You can pause the automatic syncs, delete the connection, or start a manual sync at any time by managing your Snowflake integration in Rally > Settings > Integrations.

When syncing, Rally uses the Identifier Field of the person to map data between Snowflake and Rally. If a record from Snowflake is not detected in Rally, Rally will either ignore or create a new person in Rally depending on the settings configured during the integration setup or management.

🚨 Snowflake refresh tokens expire after 90 days by default, but the Snowflake account administrator can request Snowflake to increase refresh token timeout.


Required User Permissions

🚨 Before configuring your Snowflake Integration with Rally, ensure you have the correct user permissions in both accounts.

Rally User Permissions

In Rally, you’ll need to be an Ops Manager, Developer, or Admin role type.

Snowflake User Permissions

Rally connects to your Snowflake instance through a standard OAuth connection via an individual user account. The Snowflake user will need to have at least the Snowflake user role of "Account Administrator" to set up new OAuth integrations.

Request Snowflake Refresh Token Timeout Increase

🚨 By default, Snowflake expires its refresh tokens after 90 days. A refresh token is an OAuth 2.0 object that allows an access token to renew. After the refresh token expires, the associated access token can no longer be used and a new access token must be created. This requires action in both Rally and Snowflake.

The Snowflake account administrator can request Snowflake Support to increase the refresh token timeout with the below consent request explained in the Snowflake FAQ.

<Your Organization's name e.g. ABC Ltd.> is requesting Snowflake extend the OAUTH_REFRESH_TOKEN_VALIDITY parameter

value to be set to a value of <1 year (31622400 in seconds) or lower value> for their account. This allows <ABC Ltd.> to set

the OAuth refresh token timeout to as long as <1 year> for the OAuth integrations defined in their Snowflake account.

Snowflake recommends a shorter duration for the OAuth refresh token timeout as a security best practice. <ABC Ltd.> acknowledges

that setting the OAuth refresh token timeout to <1 year> creates a risk that the client application can renew the user's session

during extended refresh token time period without user's involvement.

If you do not change the default timeout for refresh tokens, Rally strongly recommends setting a reminder to update your Snowflake access token every 90 days. If the refresh token expires, data syncs that use the Snowflake access token will stop until the access token is updated.

πŸ’‘ To reconnect, see the Manage the Snowflake Integration section below.


Set Up the Snowflake Integration

After you have the correct User Permissions, you can set up your Snowflake integration with Rally.

1. Connect Snowflake to Rally

  1. In the top left corner of Rally, select your workspace name and select Settings.

  2. From the sidebar, select Integrations.

  3. To the right of Snowflake, select Connect and follow the steps below.

There are 3 steps to connecting Snowflake to Rally:

  1. Create an OAuth integration for Rally.

  2. Create a Role for the Rally integration to use.

  3. Configure the account URL, client ID, and client secret.

First, log into Snowflake and run the provided query to create an OAuth integration for Rally.

CREATE OR REPLACE SECURITY INTEGRATION RALLYUXR 
type = oauth
enabled = true
oauth_client = custom
oauth_client_type = 'PUBLIC'
oauth_redirect_uri = 'https://app.rallyuxr.com/auth/snowflake'
oauth_allow_non_tls_redirect_uri = true
oauth_issue_refresh_tokens = true
oauth_refresh_token_validity = 7776000;

--Use oauth_refresh_token_validity=31622400 if requested for refresh token timeout increase

Second, you must create a Snowflake Role for the Rally OAuth integration to use using the provided query. When running this command, make sure to enter the warehouse, database, schema, and table that Rally can read from.

CREATE ROLE IF NOT EXISTS RALLY_ROLE; 
GRANT ROLE RALLY_ROLE TO USER <current-user>;

Finally, you must retrieve the Account URL, Client ID, and Client Secret, enter them into Rally, and click "Connect".

Query for retrieving the Account URL:

SELECT CONCAT('https://', t.value:host::varchar) as account_url FROM TABLE(flatten(input => parse_json(SYSTEM$ALLOWLIST()))) as t WHERE t.value:type::varchar = 'SNOWFLAKE_DEPLOYMENT';

Query for retrieving the Client ID & Client Secret:

select system$show_oauth_client_secrets('RALLYUXR'); 

2. Linking to Snowflake table

After Snowflake is connected to Rally, follow these steps to link a Snowflake table:

  1. Add Table Information

    Provide the following details about your Snowflake table:

    • Warehouse: Enter the name of your Snowflake warehouse.

    • Database: Enter the name of your Snowflake database.

    • Schema: Enter the name of your Snowflake schema.

    • Table: Enter the name of your Snowflake table.

  2. Grant Read access to Role in Snowflake

    Open your Snowflake console and run the following SQL commands to grant read-only access to your table.

    Important: Before running these commands, ensure that the RALLY_ROLE has been created in your Snowflake environment.

    --Grants read_only access to a single table 
    GRANT USAGE ON WAREHOUSE test_warehouse TO ROLE RALLY_ROLE;
    GRANT USAGE ON DATABASE test_db TO ROLE RALLY_ROLE;
    GRANT USAGE ON SCHEMA test_db.test_schema TO ROLE RALLY_ROLE;
    GRANT SELECT ON TABLE test_db.test_schema.test_table TO ROLE RALLY_ROLE;
  3. [Optional] Grant Write Access to Role in Snowflake

    In the next step, if you plan on mapping Rally β†’ Snowflake and/or two-way sync functionality (allowing Rally to write data back to your Snowflake table), run the following additional SQL command in your Snowflake console to grant write access to the RALLY_ROLE.

    -- Grant write access to table if Rally to Snowflake sync is needed
    GRANT INSERT, UPDATE ON TABLE test_db.test_schema.test_table TO ROLE RALLY_ROLE;

3. Configure the sync

After Snowflake is connected to Rally, carefully configure the following sync settings.

  • Create new records in Snowflake during sync

    • Always selected, all Rally person that don't exist in Snowflake will be created in Snowflake. Rally uses the record's identifier field to check if a record exists.

    • Only takes effect, if one or more property mapping have sync direction Rally to Snowflake or Two way.

  • Delete records in Snowflake during sync

    • When selected, all Snowflake records that don't exist in Rally will be deleted from Snowflake. Rally uses the record's identifier field to check if a record exists.

    • If enabled, Create new people in Rally during sync preference is disabled as we would delete external records in Snowflake if it does not exist in Rally.

  • Create new people in Rally during sync

    • When selected, all Snowflake contacts that don't exist in Rally will be created in Rally. Rally uses the record's email or unique identifier field to check if a contact exists.

    • If enabled, select which Population to sync records to.

  • What should Rally do if a record exists in Rally but is missing in Snowflake?

    • When a person record exists in Rally but is missing in Snowflake (record was removed or deleted), you can determine what action Rally takes.

      • Do nothing

      • Opt out missing people in Rally

        • When selected, people missing from Snowflake will be marked as Opted Out in Rally so they cannot be contacted.

      • Delete missing people in Rally

        • When selected, people missing from Snowflake will be completely deleted from Rally, and all their historical data from Rally removed.

  • Trigger sync whenever a CSV is uploaded to Rally

    • When enabled, Rally will automatically trigger a sync any time a .csv file is uploaded to auto-fill missing data from Snowflake, so a researcher uploading a list of participants can be sure they get the latest, most complete participant records without the extra work.

    • Contact Rally to get this feature.

🚨 The sync preference to automatically "delete people in Rally if deleted in Snowflake" is hidden by default and can be added to your workspace by contacting Rally. This is hidden by default to avoid issues with active or historical Participants accidentally being deleted from Rally.

4. Map Fields Between Rally and Snowflake

Next, map Snowflake fields to Properties in Rally and select the sync direction.

πŸ’‘ The Identifier Field is a unique string field used to map a Salesforce contact to a person in Rally. Only Unique Properties in Rally (such as email or username) can be used as an identifier field.

Property Mapping

Rally currently supports mapping the following field types from Snowflake to Rally:

Snowflake Field Type

Rally Field Type

ARRAY

multi-select*

checkbox

number

text; single-select*

TIMESTAMP_NTZ, TIMESTAMP_TZ, TIMESTAMP_LTZ, TIMESTAMP, DATE

date

*We only map up to 100 unique Property options per multi-select Property.

Property Level Sync Direction

Because Rally has read-only access to your Snowflake instance and cannot update data in Snowflake, only one sync direction is supported: Snowflake β†’ Rally.

Snowflake to Rally

This will sync data from Snowflake to Rally using the Identifier Field to find people in Rally. The sync will use the value from Snowflake to set the value in Rally. If a value for this Property already exists in Rally, it will be overwritten by the value in Snowflake. If a value was deleted or removed in Snowflake, it will be removed in Rally.

Rally to Snowflake

This will sync data from Rally to Snowflake using the Identifier Field to sync with people in Rally. The sync will use the value from Rally to set the value in Snowflake. If a value for this Property already exists in Snowflake, it will be overwritten by the value in Rally. If a value was deleted or removed in Rally, it will be removed in Snowflake.

Two-Way

This will sync data between both Snowflake and Rally using the Identifier Field to find people in Rally. This will update data in both Snowflake and Rally depending on the most recently updated Property. For example: if Two-Way sync was set on the First Name Property, when a First Name is updated in Rally, it will be updated in Snowflake on the next sync. Then, if that First Name was later updated within Snowflake, it will be updated in Rally on the next sync. If a value for this Property already exists in Rally or Snowflake, it will be overwritten by the most recently updated value for that Property. If a value was deleted or removed in Rally or Snowflake, it will be removed in Rally or Snowflake.


Manage the Snowflake Integration

  1. In the top left corner of Rally, select your workspace name and select Settings.

  2. From the sidebar, select Integrations.

  3. To the right of Snowflake, select Manage.

  4. Select the connection you want to view, edit or manage to open it.

    1. You can use Add Connection to set up a second connection (2 max) or Delete All to fully remove all Snowflake account connections.

  5. After selecting a connection to open, you can take the following actions:

    • Run Manual Sync

    • Pause or Resume Syncs

    • Delete Connection

  6. Select from the tabs to manage the integration:

    • Sync Configuration

    • Property Mapping

    • Sync History

  7. Learn more in the sections below.

Sync Configuration

Update your sync configurations at any time to better fit your needs.

Property Mapping

Add, update, or remove property mappings between Snowflake and Rally and configure their sync directions and conflict resolution setting.

Sync History

View a table of all previous syncs with a link to which people had data updated during the sync.

  • # of updated participants refers to only rows that have changed

  • We update when data in Snowflake is different than what we have stored in Rally

Start, Stop, or Delete Snowflake

Run Manual Sync

This will kick off a sync immediately, rather than waiting for the next sync interval.

Pause or Resume Syncs

This will pause your data from syncing between Rally and Snowflake until you select Resume.

Delete Connection

This will disconnect Rally and Snowflake and prevent any more syncs from occurring.

Reconnect

This option is only visible when data sync connection is disconnected. This will reinitiate the OAuth flow using the existing configuration. You can use this to update your refresh token and reset the expiry, without needing to reconfigure the entire connection.


If your Snowflake instance is disconnected from Rally due to an expired refresh token, Rally will notify Admins with instructions to restore the connection.

Did this answer your question?