Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kentico/xperience-module-intercom

Kentico Xperience integration with the Intercom chat service.
https://github.com/kentico/xperience-module-intercom

integration intercom kentico-xperience

Last synced: about 14 hours ago
JSON representation

Kentico Xperience integration with the Intercom chat service.

Awesome Lists containing this project

README

        

# Kentico Xperience Intercom modules
[![Stack Overflow](https://img.shields.io/badge/Stack%20Overflow-ASK%20NOW-FE7A16.svg?logo=stackoverflow&logoColor=white)](https://stackoverflow.com/tags/kentico)

| | Package |
| ------------- |:-------------:|
| Administration | [![NuGet](https://img.shields.io/nuget/v/Kentico.Xperience.Intercom.Admin.KX13.svg)](https://www.nuget.org/packages/Kentico.Xperience.Intercom.Admin.KX13) |
| Live site - ASP.NET Core | [![NuGet](https://img.shields.io/nuget/v/Kentico.Xperience.Intercom.KX13.svg)](https://www.nuget.org/packages/Kentico.Xperience.Intercom.KX13) |

[Intercom integration](https://www.intercom.com/) for [Kentico Xperience](https://xperience.io/)

This repository contains the source code for modules that integrate Kentico Xperience with the Intercom chat service.

## Description

The Intercom integration modules provide the following features:
* Synchronization of Xperience contact data to contacts in your Intercom organization. Depending on your site's personal data policy, this synchronization can be disabled, or conditionally applied only to contacts who agree with a specific consent.
* Transfer of data submitted through the Intercom chat to corresponding contact attributes in Xperience.
* Logging of custom activities in Xperience when users perform specified actions in the Intercom chat.
* HtmlHelper API that helps developers generate scripts that add the Intercom chat interface on the pages of your live site.

The project consists of two modules:
* **Administration** - Adds the *Intercom* application to the Xperience administration interface. The application is used to set up the integration and allows you to toggle the Intercom functionality on or off.
* **Live site** - Provides an HtmlHelper API to simplify generating of scripts that add the Intercom chat interface to your site's pages. Adds endpoints that recieve requests from Intercom webhooks, which are used to update contacts and log activities.

## Compatibility
* *Kentico Xperience 13.0.0* or newer.
* Only the **ASP.NET Core** development model for the live site is supported.

## Requirements and prerequisites

* **Xperience Enterprise** license edition for your site's domain, as the integration uses on-line marketing features (contacts and activities).
* Your Xperience administration application must run using the secured **HTTPS** protocol.
* The *Enable on-line marketing* setting needs to be selected in the Xperience *Settings* application.
* You need to have an *Intercom* account, workspace and app created. You can register a free developer account at [https://www.intercom.com/](https://www.intercom.com/). For more information, see the [Intercom Developer Hub Docs](https://developers.intercom.com/building-apps/docs/welcome).
* **Important**: The integration optionally synchronizes contact data from Xperience to your Intercom workspace. As a result, the **personal data** of visitors may be exported to a third party. If necessary, update your website's personal data policy and any related consents.

## Setup (Developers)
The setup of the Intercom integration consists of the following steps:
1. [Install the administration package](#install-the-administration-package)
2. [Install the live site package](#install-the-live-site-package)
3. [Add Intercom webhook endpoints](#add-intercom-webhook-endpoints)
4. [Add Intercom Messenger to your website](#add-intercom-messenger-to-your-website)
5. [Configure Intercom and Xperience](#configure-intercom-and-xperience)

### Install the administration package
1. Open the solution with your Xperience administration project (*~/WebApp.sln*).
1. Navigate to the *NuGet Package Manager Console*.
1. Run `Install-Package Kentico.Xperience.Intercom.Admin.KX13 -Version 1.0.0`
1. Rebuild the CMSApp project.

### Install the live site package
1. Open the solution with your live site project (e.g., *~/DancingGoatCore.sln*).
1. Navigate to the *NuGet Package Manager Console*.
1. Run `Install-Package Kentico.Xperience.Intercom.KX13 -Version 1.0.0`
1. Rebuild your live site project.

### Add Intercom webhook endpoints

To allow Intercom to update the data of contacts and log custom activities in Xperience, your live site application needs to process webhook requests. Add endpoints for these requests to your website:
1. Edit your live site project's startup class (*Startup.cs* by default).
1. Add the following using statement: `using Kentico.Xperience.Intercom;`
1. Within the `ConfigureServices` method, call `services.AddHttpClient();`
1. Register the Intercom endpoints in the `Configure` method:
```
app.UseEndpoints(endpoints =>
{
endpoints.Kentico().MapRoutes();

// Registers endpoints that process requests from Intercom webhooks
endpoints.MapKenticoIntercomRoutes();
...
```

Your live site application can now process Intercom webhook requests using the following routes:
* **https://{live_site_url}/kentico.xperience.intercom/updatecontact**
* **https://{live_site_url}/kentico.xperience.intercom/logactivity**

### Add Intercom Messenger to your website

To add Intercom Messenger (chat interface) onto your website's pages, use the `@Html.IntercomScripts()` HtmlHelper provided by the installed live site module. The method generates the required intercom scripts using the configuration provided in the Xperience administration.

Place the scripts before the closing `