Personalize customer communications using real-time location data

In this recipe, you’ll learn how to use Segment to connect Radar (a location data infrastructure platform) and Customer.io (a marketing automation software) to personalize your customer communications.

Radar Made by Radar
Customer.io Made by Customer.io

What do you need?

  • Location data infrastructure platform - we're using Radar.io

  • Marketing Automation platform - we're using Customer.io

  • Team communication platform - we're using Slack

Personalize customer communications using real-time location data

With a huge integration catalog and plenty of no-code features, Segment provides easy-to-maintain capability to your teams with minimal engineering effort. Great data doesn't have to be hard work!

On this page

When used properly, location data helps companies deliver powerful, differentiated experiences to customers. In this recipe, you’ll learn how to use Segment to connect Radar (a location data infrastructure platform) and Customer.io (a marketing automation software) to personalize your customer communications.

To illustrate, let’s use the example of how Frank’s Fish restaurant is using location data and a robust messaging platform to deliver clear, personalized communication to a customer who’s placed an order for pick-up. 

To help you visualize how you can superpower your customer messaging experience with location data, we’ve chosen this bricks and mortar example. Still, these concepts can be applied regardless of your business model. 

To deliver this clear, personalized messaging, we’ll need a few different tools:

  • A messaging platform that can flexibly send personalized messaging, like Customer.io

  • A developer tool that makes customer location data actionable, like Radar

  • A way to seamlessly sync our data, in real-time across all tools, Segment

  • A platform to drive communication and collaboration within teams, Slack

Let’s dive in!  


At Frank’s Fish restaurant, the goal is to get food in customers’ hands fresh out of the fryer. The two main factors the restaurant team need to communicate are:

  1. To customers: where to park when they arrive

  2. To our team: when customers arrive

Since the Radar SDK is integrated with the customer’s mobile app, we’ll know when our customers are 6 minutes away. In this time, we want to: 

  1. To notify each customer where to park via Email, based on the restaurant location (there are 200 different locations across the US, and each one has a different curbside pick-up parking location)

  2. Alert the restaurant staff via Slack, when the customer arrives at the pick-up location

Step 1: Create geofences in Radar

Radar offers geofencing, trip tracking, and location API platform, all under one hood. Brands can create geofences and track how their app users are moving about the world with the Radar SDK, and call Radar’s APIs to power location-based search, distance, and ETAs, and geocoding. 

In order to create these geofences, we’ll log into Radar, select Geofences from the side menu, and select “New” to create a geofence. 

The source type of geofence we’ll create is by “Address”. From there we can enter the address of our store, and hit “Search”. To change the geofence from the default circular geofence, we can toggle the type of geofence to be “Isochrone ”(see picture below), with travel mode as “car” and duration as “6”.

 

Diagram of Twilio Segment and Radar integration.

 

Step 2: Connect Customer.io to Radar, via Segment

Once we’ve created a geofence boundary in Radar and generate “entry” events, we want to send these events to Customer.io to trigger messaging to customers. 

Since the rest of our customer data flows into Segment and Segment has pre-built integration with both Radar and Customer.io, this will be quick. Simply set up Radar as a source and Customer.io as a destination with Segment. 

We’ll start by adding Radar as a Source. To do this, you’ll need a Segment account (and you can get started for free here). Once you’re in Segment, navigate to connections > add source > search and select “Radar.” Copy the newly created write key. 

 

Creating a geofence in Radar.

 

Then, head back to Radar, where you’ll paste the write key. Within Radar’s dashboard, under Integrations, select “enabled” from the drop-down.

 

Setting up Radar as a source in Segment.

 

Once you save the source inside Radar, you’ll notice subsequent events start to populate in Segment.

 

Segment event debugger showing Radar events.

 

Next, set up your Customer.io destination. 

Select Customer.io from Segment’s destinations and make sure that Customer.io is set to receive data from Radar. Next, grab your Site ID and API Key by navigating to Account settings > API credentials > select or create new tracking API credentials and paste into Segments UI under “Customer.io Settings”. 

 

Configuring Customer.io as a Segment destination.

 

Finally, toggle the integration to active at the top of the UI. 

 

Customer.io campaign creation interface.

 

That's it! Your integration between Radar and Customer.io is set up.

 

Radar Customer.io Connection

 

Step 3: Create a location triggered campaign in Customer.io

Now that we have Radar’s data successfully flowing into Customer.io we can create a messaging experience based on an event sent to Customer.io. 

For this example, let's create an event triggered campaign that triggers off the event Geofence Entered.

 

Customer.io push notification setup

 

Next, create the campaign workflow. 

To start, create a push notification to the customer using data from the event-trigger to personalize the message with their parking instructions. 

Since each geofence will have a static parking location for pickup, we can store this information in a structured snippet in Customer.io and pull it into the message. You can learn more about using structured snippets here.

 

Customer.io push notification setup.

 

Next, we want to notify our staff when the customer is just about to arrive. Since Radar’s geofence is based on expected traffic times (in this example we set it for 6 minutes out from the location), we can add a time delay of 5 minutes to this campaign.

 

Customer.io workflow builder.

 

We also want to notify our staff that the order is ready to be picked up. This is a very tech-savvy establishment, so they use Slack. Whenever an order is ready to be picked up, we’ll let our staff know who the order is for so they can meet them outside.

 

Customer io Slack notification builder

 

The full campaign would look like this:

 

Customer.io notification workflow

 

Wrapping Up

Here’s what we’ve done in this recipe: 

  • Used Radar to create a Segment Source that provides location tracking and geofencing

  • Connected Radar and Customer.io together via Segment

  • Created a geofence that triggers a messaging campaign based on our customers’ location

  • Alert your team when a customer arrives at the pick-up location

This is a great example of how real-time location data from Radar can drive personalized messages from Customer.io. There are endless possibilities for the application of using real-time location data to personalize customer communications.

If you have any questions or want to work location-based messaging into your customer experience, please let us either one of our teams know and we’ll be happy to help. You can reach the Radar team at team@radar.io, and the Customer.io team at partners@customer.io and if you’re already a Segment customer or part of the Segment Startup Program, ask about our Segment partner discounts. We can’t wait to see what you build!

Getting started is easy

Start connecting your data with Segment.