Integrations
Sources
Hightouch

How to integrate Hightouch with Knock

Learn how to power your Knock product notifications using synced data from your data warehouse using Hightouch.

Getting started

#

Knock integrates with Hightouch as a downstream destination to sync customer and event data from your data warehouse.

Use cases

#

You can use our Hightouch integration to:

  1. Sync customer data into Knock from your data warehouse (identify)
  2. Trigger workflows from records added, changed, or removed in your data warehouse
  3. Populate Audiences with data from your data warehouse. Audiences can be used to trigger workflows or power conditional logic during workflow execution.

Syncing customer data into Knock from Hightouch

#

You can use the HTTP request destination within Hightouch to sync your customer data from your data warehouse into Knock.

For this example, we're going to make a call to the Knock API users identify endpoint.

  1. Create a new HTTP request destination and select your model to query from
  2. Set an Authorization header, with the value set to Bearer <your Knock secret API key>. You can find your secret API key in your dashboard under Platform > API keys
  3. Name your destination "Knock API"
  4. Create a new sync with your Knock API destination
  5. Select the types of events that should trigger, the most common case here is "Rows added"
  6. Set the HTTP request method to PUT and the URL to https://api.knock.app/v1/users/{{ row.user_id }} where {{ row.user_id }} corresponds to the user identifier in the table
  7. Select a "JSON" payload and "Use the JSON editor" to craft the request
  8. Add at least a name, email, or phone_number field from your users table
  9. For the rate limit, you can specify 60 requests per second
  10. You'll likely want to "backfill" all of the available rows meaning that any existing data will also be synced to Knock
  11. Click "Continue"
  12. Select your sync frequency
  13. Click "Finish"

An example configuration for your sync may look something like this:

Syncing audiences into Knock from Hightouch

#

Hightouch models can be synced to Knock audiences by configuring Knock as an Embedded Destination in Hightouch. This integration does not require any additional configuration in the Knock dashboard once the following steps are completed in Hightouch.

Prerequisites

#
  1. Determine which Knock environment you want to sync your audience to. You most likely want to sync in the Production environment, unless you’re configuring a test sync.
  2. Create an audience in Knock that will serve as the target for your sync.
  3. Have your Knock environment’s secret API key ready. Each environment has its own unique set of API keys; you can find your secret API key in your dashboard under Platform > API keys. Be sure that the correct environment is selected in the switcher at the top of the page.

Configure Knock as a Hightouch Destination

#

Before you can sync audiences into Knock from Hightouch, you need to configure Knock as an Embedded Destination in Hightouch.

1

Add destination

Navigate to the Integrations > Destinations page in Hightouch’s sidebar, then click "Add destination."

Add destination
2

Select destination type

Under "Developer tools," select "Embedded Destination" and then click "Continue."

Select Embedded Destination
3

Configure the destination URI

Copy and paste the following into the URI field:


Add the following under Headers. Be sure to toggle the "Secret" setting for the value:

HeaderValue
AuthorizationBearer <your Knock secret API key>

Your completed URI configuration should look something like this:

Configure the destination URI

Click "Continue."

You'll be given the opportunity to configure alerts for this destination; if you don't need alerts, you can click "Continue" again.

4

Name your destination

Type in a name for your destination and click "Finish."

We recommend something like “Knock Production” so that its clear which environment the destination writes to.

Add a sync to your Knock destination

#

Once you have configured Knock as an Embedded Destination in Hightouch, you can add a sync to your destination.

1

Add a sync

Navigate to Activation > Syncs in the Hightouch sidebar, then click "Add sync."

Add a sync
2

Select your source data

You'll be prompted to select a model for your source data. Select the model for the audience that you want to sync to Knock.

3

Select a destination

Next, you'll select the Knock Embedded Destination that you created above.

Select a destination
4

Configure your sync

Select “Audiences” in the “Which object would you like to sync data to?” dropdown.

Configure your sync

Then, select a mode for the sync:

  • Insert only: Only new rows added to your model will be synced to Knock. Removing rows from your model will have no effect on your Knock audience.
  • Mirror: New rows in your model will be added to your audience and removed rows in your model will be deleted from your audience.
5

Configure your data mapping

Map your model’s fields to the audience fields.

You must map a model field to the audience "User ID" field. This field should correspond to the ID of the user in Knock.

If you’d also like to map a tenant field, click "Add mapping" and select the appropriate field from your model.

Configure your data mapping
6

Add the audience key

Next, add the key of the Knock audience that you want to sync to. Click "Continue."

Add the audience key
7

Finalize your sync

Finally, you'll set your sync to run manually, on a schedule, or with an automation.

You can now click "Finish" to add the sync and run it whenever you’d like. Refer to Hightouch’s documentation for more information on syncs.

You can verify that the sync is behaving as expected by:

  • Comparing total user counts in your model and the audience in your Knock dashboard.
  • Viewing the audience user list.
  • Viewing workflow run logs for the audience (if you have workflow audience triggers configured).