Braze
How We Work Together
Together, Foursquare and Braze (formerly Appboy) are powering the future of location-based engagement. Foursquare’s Movement SDK delivers a hyper-accurate understanding of where your users go, and our integration with Braze means you can seamlessly personalize your users’ experiences and drive deeper engagement. Foursquare will provide real-time event triggering based upon your users’ location in the physical world, allowing you to harness our powerful geotargeting capabilities and take action with Braze.
Examples of What You Can Do
Integrating w/ Braze opens up a variety of powerful use-cases to help you personalize your users’ experiences:
- Send customers a notification when they arrive at or leave a particular location based upon Foursquare contextual data, such as a concert venue or Home.
- Trigger coupons or promotions for high-value customers when they arrive at a location.
- Gather key demographic or behavioral data over time for richer retargeting.
Example JSON Payloads
{
"userId": "{String}",
"context": {
"traits": {},
"localeactions": "en",
"device": {
"advertisingId": "{String}"
}
},
"event": "placeHistorical",
"properties": {
"visitType": "historical",
"probability": "{Double}",
"confidence": "{String}",
"lat": "{Double}",
"lng": "{Double}",
"locationType": "{String}",
"visitId": "{String}",
"timestamp": "{YYYY-MM-DDTHH:MM:SS.XXXZ}",
"venueName": "{String}",
"venueId": "{String}",
"primaryCategoryName": "{String}",
"primaryCategoryId": "{String}",
"primaryChainName": "{String}",
"primaryChainID": "{String}",
"address": "{String}",
"crossStreet": "{String}",
"city": "{String}",
"state": "{String}",
"zipCode": "{String}",
"country": "{String}",
"supervenueId": "{String}",
"supervenueName": "{String}",
"supervenuePrimaryCategoryId": "{String}",
"supervenuePrimaryCategoryName": "{String}",
"supervenuePrimaryChainId": "{String}",
"supervenuePrimaryChainName": "{String}"
},
"type": "track"
}
{
"EventDefinitionKey": "pilgrimArrivalEntrySource",
"ContactKey": "{String}",
"Data": {
"visitType": "departure",
"confidence": "{ConfidenceLevel}",
"lat": "{lat}",
"lng": "{long}",
"locationType": "venue",
"visitId": "{VisitID}",
"timestamp": "{Timestamp}",
"venueName": "{VenueName}",
"venueId": "{VenueID}",
"primaryCategoryName": "{PrimaryCategoryName}",
"primaryCategoryId": "{PrimaryCategoryID}",
"address": "{Address}",
"crossStreet": "{Cross Street}",
"city": "{CityName}",
"state": "{StateCode}",
"zipCode": "{ZipCode}",
"country": "{CountryCode}",
"ContactKey": "{String}",
"userId": "{String}"
}
}
{
"EventDefinitionKey": "pilgrimArrivalEntrySource",
"ContactKey": "{String}",
"Data": {
"visitType": "arrival",
"confidence": "{ConfidenceLevel}",
"lat": "{lat}",
"lng": "{long}",
"locationType": "venue",
"visitId": "{VisitID}",
"timestamp": "{Timestamp}",
"venueName": "{VenueName}",
"venueId": "{VenueID}",
"primaryCategoryName": "{PrimaryCategoryName}",
"primaryCategoryId": "{PrimaryCategoryID}",
"address": "{Address}",
"crossStreet": "{Cross Street}",
"city": "{CityName}",
"state": "{StateCode}",
"zipCode": "{ZipCode}",
"country": "{CountryCode}",
"ContactKey": "{String}",
"userId": "{String}"
}
}
{
"EventDefinitionKey": "pilgrimArrivalEntrySource",
"ContactKey": "{String}",
"Data": {
"geofenceEventType": "exit",
"geofenceLat": "{Double}",
"geofenceLng": "{Double}",
"radius": "{Double}",
"venueId": "{String}",
"categoryIds": "{String}",
"venueChainIds": "{String}",
"partnerVenueId": "{String}",
"eventLat": "{Double}",
"eventLng": "{Double}",
"geofenceId": "{String}",
"geofenceName": "{String}",
"geofenceProperties": {},
"ContactKey": "{String}",
"userId": "{String}"
}
}
{
"userId": "{String}",
"eventName": "geofenceEnter",
"createdAt": 1646691428,
"dataFields": {
"geofenceEventType": "entrance",
"geofenceLat": "{Double}",
"geofenceLng": "{Double}",
"radius": "{Double}",
"venueId": "{String}",
"categoryIds": "{String}",
"venueChainIds": "{String}",
"partnerVenueId": "{String}",
"eventLat": "{Double}",
"eventLng": "{Double}",
"geofenceId": "{String}",
"geofenceName": "{String}"
}
}
{
"userId": "{String}",
"eventName": "geofenceDwell",
"createdAt": 1646691515,
"dataFields": {
"geofenceEventType": "dwell",
"geofenceLat": "{Double}",
"geofenceLng": "{Double}",
"radius": "{Double}",
"venueId": "{String}",
"categoryIds": "{String}",
"venueChainIds": "{String}",
"partnerVenueId": "{String}",
"eventLat": "{Double}",
"eventLng": "{Double}",
"geofenceId": "{String}",
"geofenceName": "{String}"
}
}
Integration Details
- Make sure both Braze and the Movement SDK SDKs are properly setup.
- In order to properly map the Braze and Foursquare SDKs, you will need to set the same user ID in both systems using the
changeUser
method in the Braze SDK and thesetUserId method
ofUserInfo
in the Movement SDK. - Enter your Braze REST API Key and (optionally) App IDs in to your app's Foursquare Developer Console.
- Once you have configured the Developer Console, the Movement SDK will automatically track location events and forward them to Braze, allowing you to retarget and segment your customers.
- See the Braze developer documentation for more details.
Updated over 1 year ago