Interactions
The Lipscore integration allows data to be sent to Engage using an interaction. Data sent this way can be viewed in the Engage UI and also stored and used for segmentation.
See here for more information about interactions.
1 - Creating the interaction schema
Interactions in Engage are defined by a schema. This is the structure of the schema used for the Lipscore integration:
{ "jsonSchema": { "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "ratingId": { "type": "integer", "displayName": "Rating ID", "showInContactCard": "false" }, "rating": { "type": "integer", "displayName": "Rating", "showInContactCard": "true" }, "comment": { "type": "string", "displayName": "Comment", "showInContactCard": "true" }, "productSku": { "type": "string", "displayName": "Sku", "showInContactCard": "true" }, "name": { "type": "string", "displayName": "Name", "showInContactCard": "true" }, "brand": { "type": "string", "displayName": "Brand", "showInContactCard": "true" }, "type": { "type": "string", "displayName": "Type", "showInContactCard": "true" } } }, "id": "completedProductRating", "displayName": "Completed product rating" }
To create the Interaction, this schema is sent to the endpoint:
POST api/v2/interactionschemas
Tip
Lipscore will set up the schema on their end.
2 - Sending the interaction
Once the schema has been created and posted, you can send interactions of this type. In the case of the schema above, the interactions you'll send looks like this:
{ "contactId": "930dca46-7ed5-4761-84f5-b18d010f031b", "schemaId": "completedProductRating", "payload": { "ratingId": 6028323, "rating": 4, "comment": "This is sooooooooo cool..", "productSku": "", "name": "The Collection Snowboard: Liquid", "brand": "Hydrogen Vendor", "type": "productReview" } }
Important
The schemaId (is this case "completedProductRating") must match the one used in the schema definition payload.
The attribute "type" can have the following values:
productReview: The first time this contact reviews this product
productRating: The first time this contact rates this product
serviceReview: The first time this contact reviews this service
serviceRating: The first time this contact rates this service
updated_productReview: Contact updates an existing product review
updated_productRating: Contact updates an existing product rating
updated_serviceReview: Contact updates an existing service review
updated_serviceRating: Contact updates an existing service rating
This payload is sent to the interactions endpoint:
POST api/v2/interactions
3 - Using the interaction data
An interaction is picked up in Engage by either the "New Interaction" or "New specific interaction" automation triggers. It can then be used to start an automation.
Use the "New specific interaction" trigger here since it allows you to pick certain values inside the interaction to decide whether to trigger the automation or not.
Interaction data will turn up on the contact card (in the "Interactions" tab).
The data received from interactions can also be used for segmentation.
4 - Updating an existing review
When a product review is updated through an interaction, the “type” in the payload will be set to "updated_productReview". By specifying in your automation trigger which values of "type" will trigger the automation (for example, "productReview" and "serviceReview") you can prevent the automation from running in cases like this. For example, you might just want to send a mail when the review is first sent, and not when it is updated.
Note
If such an update is sent to Engage, Lipscore will remove the original review and create a new one, since existing interactions can't be updated.