What is Hightouch?

Hightouch is a platform that enables businesses to sync data between different systems, databases, or applications, often associated with data integration and synchronization. It facilitates the movement of data between various sources and destinations, allowing companies to streamline their operations, automate processes, and ensure that different tools or databases remain up-to-date with the most recent information.

All this data can be easily sent to Hyperline to collect your customer’s usage and automate usage-based billing and invoicing.

Send usage from Hightouch to Hyperline

Configure a data source

The first thing you need to create in Hightouch is a source.

1

Go to the Sources page

2

Click on Add source

3

Select and configure the data source

The source can be of any type (spreadsheet, database, warehouse, etc).

Create a HTTP Request destination

Hyperline uses HTTP requests to ingest usage. Setting up this destination in Hightouch takes only a few clicks:

1

Go to the Destinations page

2

Click on Add destination and select HTTP Request

3

Select and configure the request

You need to add two headers:

  • Authorization with Bearer <your API key> as a secret value
  • Content-Type with application/json as value

Create a model

After saving the destination, you need to create a model representing the entity you want to sync (represented as event in Hyperline).

1

Go to the Models page

2

Click on Add model

3

Select a source and configure a model

Put a name and select a primary key from the source fields.

After finishing the model, you can also configure more settings on it like columns types, descriptions, etc.

Create a sync

The last step you need to configure is a sync. Syncs declare how you want query results from a model to appear in your destination (Hyperline).

1

Go to the Syncs page

2

Click on Add sync

3

Select your model and the HTTP Request destination

Put a name and select a primary key from the source fields.

Select Row added and Row updated triggers, POST HTTP request method, don’t change the URL, JSON as type of payload with Use JSON editor.

Here is an example of JSON payload that can be sent to the Hyperline ingest API.

{
  "customer_id": "{{ row.customerId }}",
  "event_type": "{{ row.eventType }}",
  "timestamp": "{{ row.timestamp }}",
  "record": {
    "id": "{{ row.eventId }}",
    "my_property": "{{ row.customProperty }}", // add any custom properties you want to ingest in Hyperline
  },
}

Hightouch supports Liquid template language to insert variables from your source to your JSON payload. These variables are created following this syntax: {{ row.variable }}, variable being the column name of your source.

Verify your synchronization by using a data sample. A new event should appear on your events explore page within Hyperline.

When you’re ready, activate this sync and specify a periodic trigger.