Snowflake

How does the Snowflake Integration work

Rally is able to connect to your Snowflake instance through a standard OAuth connection to a Snowflake user.

After setting up a connection with Snowflake, you are able set configuration settings and create property mappings between Rally Properties and Snowflake Properties. Each of these properties can be configured per property to sync data from Snowflake → Rally.

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 anytime by going into your Snowflake Integration settings in Rally.

When syncing, Rally uses the email address of the person to map data between Snowflake and Rally. If an email address from Snowflake is not detected in Rally, Rally will either ignore or create a new person in Rally depending on how you configured the integration.

User Permissions

Before you start configuring your Snowflake Integration with Rally, you need to make sure you have the correct user role permissions in your Rally and Snowflake accounts.

Rally User Permissions

In Rally, you’ll need to be either an Ops Manager or a Super Admin.

Snowflake User Permissions

Rally connects to your Snowflake instance through a standard OAuth connection via an individual user account.

The Snowflake user will need at least to have the Snowflake user role of "Account Administrator" in order to setup new OAuth integrations.


Setting up the Snowflake Integration

After you have the correct User Permissions, you can now set up your Snowflake integration with Rally. To get started, you can navigate to Settings > Data Connections , find "Snowflake", click “Connect”, and follow these steps.

1. Connect Snowflake to Rally

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, you must login to 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;

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_ACCOUNT;

--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;

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. Configure the sync

After Snowflake is connected to Rally, you can configure the following sync settings:

  • Create new people in Rally during sync
  • Delete people in Rally if deleted in Snowflake.

As noted before, Rally will check the peron's email address when determining whether to create a new contact or delete a contact in Rally.

3. Map fields between Rally and Snowflake

The next step is to map Snowflake fields to properties in Rally and select the sync direction.

Property Mapping

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

Snowflake Field TypeRally Field Type
arraymulti-select*
booleanboolean
number/int/double/float/decimalnumber
stringtext
data, datetimedate

*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, only 1 sync direction is supported: Snowflake to Rally.

  • Snowflake to Rally: This will sync data from Snowflake to Rally using the Contact or Lead’s email address 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.

Managing the Snowflake Integration

To manage the Snowflake integration, go to Settings > Data Connections and click “Manage Connection”.

When managing your Snowflake connection, you can update your sync configurations at any time. You can also see a table view of all previous syncs with a link to which people had data updated during the sync.

Lastly, you can take the following actions:

  • Start Manual Sync: This will kick off a sync immediately rather than waiting for the next sync interval.
  • Pause/Resume: This will pause you data from syncing between Rally and Snowflake until you hit resume.
  • Disconnect: This will disconnect Rally and Snowflake and prevent any more syncs from occurring.