Sitefinity Insight
Learn how to personalize the conversation with Sitefinity Insight.
Insight object in the conversation context
When you publish your chatbot on a Sitefinity website with a configured Sitefinity Insight connector, you will notice additional data in the context of the conversations coming from that website. The additional data has the following format:
{
...
"_systemTracking": {
"insight": {
"apiKey": "yourInsightApiKey",
"datasource": "yourInsightDataSource",
"subject": "theSubjectIdentifier",
"canTrackCurrentUser": "subjectConsent"
}
}
...
}
- apiKey The API key of the data center as configured in Sitefinity.
- datasource The name of the data source where the subject is reported as configured in Sitefinity.
- subject The subject ID of the visitor as identified in Sitefinity.
- canTrackCurrentUser Visitor consent preference. For more information, refer to Tracking consent article.
Log an interaction in Sitefinity Insight
You can use Sitefinity Insight REST API » Data collection with Sitefinity Insight API v2 to log an interaction using a webhook step:
{
"steps": [
...
{
"type": "webhook",
"entity": "interactionResponse",
"data-source": {
"endpoint": "https://api.insight.sitefinity.com/collect/v2/data-centers/{{_systemTracking.insight.apiKey}}/datasources/{{_systemTracking.insight.datasource}}/interactions",
"method": "POST",
"payload": {
"S": "{{_systemTracking.insight.subject}}",
"P": "Chatbot Interaction",
"O": "chatbotConversationCompleted"
}
}
...
]
}
Personalize the conversation
You can use Sitefinity Insight REST API » Endpoint: GET /analytics/v2/scorings/leads/in to get information about the lead scoring types the visitor is associated with using a webhook step:
{
"steps": [
...
{
"type": "webhook",
"entity": "userScoring",
"data-source": {
"endpoint": "https://api.insight.sitefinity.com/analytics/v2/scorings/leads/in",
"method": "GET",
"headers": {
"Authorization": "authorizationHeader",
"x-dataintelligence-datacenterkey": "{{_systemTracking.insight.apiKey}}",
"x-dataintelligence-datasource": "{{_systemTracking.insight.datasource}}",
"x-dataintelligence-subject": "{{_systemTracking.insight.subject}}"
}
}
}
...
]
}
For information how to authorize a secured Insight endpoint, refer to Sitefinity Insight REST API » Authorization.
Somethings missing or not clear?
Ask a question in our community forums or submit a support ticket.