> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hightouch.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Sprig

> Empower your team to run surveys with AI feedback.

## Overview

Sprig is a product experience platform that helps teams collect in-context user feedback through surveys, session replays, heatmaps, and AI-powered analysis. Use Hightouch to sync user attributes from your data warehouse to Sprig so you can target studies to the right audiences, filter responses by user properties, and keep your Sprig user profiles enriched with up-to-date data.

## Supported syncing

| Sync type | Description | Supported sync modes | API reference |
| - | - | - | - |
| [**Users**](#syncing-users) | Sync user profiles and attributes to Sprig | Upsert | [V2 Users API](https://docs.sprig.com/reference/post-user-v2-1) |

For more information about sync modes, refer to the [sync modes](https://docs.hightouch.com/syncs/types-and-modes.md#sync-modes) docs.

## Connect to Sprig

Go to the [**Destinations** overview page](https://app.hightouch.com/destinations?from=docs) and click the **Add destination** button. Select **Sprig** and click **Continue**.

![Selecting Sprig in the Hightouch destination catalog](https://mintcdn.com/hightouch-3c037897/L_vQfA0JQEpeGUUo/images/destinations/sprig/sprig-create-destination.png?fit=max\&auto=format\&n=L_vQfA0JQEpeGUUo\&q=85\&s=ac97213e2d7f0a89913077fd2b5ad785)

### API key

To authenticate, you need a Sprig API key. Sprig uses the [Data Import API](https://docs.sprig.com/docs/apis) key for server-side integrations.

To find your API key in Sprig:

1. In the Sprig navigation pane, click **Integrations**.
2. Under **Sources**, click **Enrichment**.
3. Click **Data Import API**.
4. Copy the API key for the environment you want to sync to (Production or Development).

![Locating the Data Import API in Sprig's Integrations page](https://mintcdn.com/hightouch-3c037897/L_vQfA0JQEpeGUUo/images/destinations/sprig/sprig-data-import-api.png?fit=max\&auto=format\&n=L_vQfA0JQEpeGUUo\&q=85\&s=bde3f4a3caa8dec93dc7665e06e9465a)

Paste your API key into the **API Key** field in Hightouch and click **Test connection** to verify the credentials.

![Entering the Sprig API key in Hightouch and testing the connection](https://mintcdn.com/hightouch-3c037897/L_vQfA0JQEpeGUUo/images/destinations/sprig/sprig-test-connection.png?fit=max\&auto=format\&n=L_vQfA0JQEpeGUUo\&q=85\&s=13607c0dfe3557b783bd27bd089b5047)

> [!TIP]
>
> Sprig provides separate API keys for Production and Development environments.
> Make sure you use the key that matches the environment you want to sync data to.
> Refer to the [Sprig API documentation](https://docs.sprig.com/docs/apis#find-your-api-keys) for details.

Configure any default sync alerts for this destination, then click **Continue** to finalize.

![Configuring default alerts for the Sprig destination](https://mintcdn.com/hightouch-3c037897/L_vQfA0JQEpeGUUo/images/destinations/sprig/sprig-configure-alerts.png?fit=max\&auto=format\&n=L_vQfA0JQEpeGUUo\&q=85\&s=2e8fd1dca7375faaf85a04c3a8f4dd43)

## Sync configuration

Once you've set up your Sprig destination and have a [model](https://docs.hightouch.com/getting-started/concepts.md#models) to pull data from, you can set up your sync configuration to begin syncing data. Go to the [**Syncs** overview page](https://app.hightouch.com/syncs?from=docs) and click the **Add sync** button to begin. Then, select the relevant model and the Sprig destination you want to sync to.

### Syncing users

Sync user profiles and attributes to Sprig. Hightouch uses the [Sprig V2 Users API](https://docs.sprig.com/reference/post-user-v2-1) to upsert user records. When a matching user exists in Sprig, Hightouch updates their attributes. When no match is found, Hightouch creates a new user profile.

#### Record matching

To match rows from your model to users in Sprig, select a model column to map to the Sprig **User ID** field. This is the unique identifier Sprig uses to track individual users across your product.

The User ID should be a stable, unique identifier for each user, such as an internal user ID or database primary key. This must match the User ID you use in your [Sprig SDK installation](https://docs.sprig.com/docs/web-javascript) so that synced attributes are associated with the correct user profiles.

#### Field mapping

Hightouch lets you sync user attributes via [field mapping](https://docs.hightouch.com/syncs/mapping-data.md). You can map data from any of your model columns to Sprig user attributes.

Sprig supports attributes with string, numeric, and boolean values. Attributes synced through Hightouch appear in Sprig and can be used to:

* **Filter study audiences**: Target surveys and feedback prompts to users with specific attribute values.
* **Filter study responses**: Drill into collected responses based on user attributes.

Any attribute key you sync that doesn't already exist in Sprig is created automatically. Refer to the [Sprig Attributes documentation](https://docs.sprig.com/docs/attributes) for more details on how attributes work.

> [!WARNING]
>
> Sprig does not support deleting individual attributes from a user profile.
> If you sync an attribute in error, you can overwrite its value but you cannot remove the key entirely unless you delete the user's data.

## Tips and troubleshooting

To see the exact API requests and responses from each sync run, use the [live debugger](https://docs.hightouch.com/syncs/debugger.md). To get notified by Slack, PagerDuty, SMS, or email when a sync fails, set up [sync alerts](https://docs.hightouch.com/syncs/alerting.md). If you run into an issue this page doesn't cover, [contact support](#pylon-chat).

### Rate limits

Enterprise Sprig customers have an API rate limit of 1,000 requests per second. If you're on a Starter or Free plan, API access may be limited. Refer to the [Sprig API documentation](https://docs.sprig.com/docs/apis#rate-limiting) for current rate limit details.

### Environment mismatch

Make sure the API key you use in Hightouch corresponds to the correct Sprig environment (Production or Development). Using a Development key will sync data to your Development environment, which won't affect your live studies or production user profiles.

## Common errors

| Error | Cause | Fix |
| - | - | - |
| `401 Unauthorized` | The API key is invalid or has been revoked. | Generate a new API key in Sprig under **Integrations > Enrichment > Data Import API** and update the destination in Hightouch. |
| `429 Too Many Requests` | You've exceeded the Sprig API rate limit. | Reduce sync frequency or contact Sprig to increase your rate limit. |
