Skip to content

Configuration

Lime Chat needs to be configured in these places:

Runtime Config

Use Lime Admin to configure the Runtime Config. Each config parameter is described in Lime Admin and validated upon save.

Configure Multiple Instances Targeting the Same Topic

Creating multiple limeobjects per sent conversation is not supported right now. Therefore, it is not possible to configure several instances with the same Userlike topic.

Identify the Contact in Lime CRM

To identify the contact as a person in Lime CRM, a personRelation node has to be configured. The key in the payload where the contact information could be found needs to be configured as identificationKey. The lookup is then made on the property that is configured as propertyIdentifier. The lookup is made using one "person relation rule" at the time, in the order as they are specified in the configuration. If a rule results in a match, then the searching is ended.

Configure Default Values on the Created Limeobject

You can configure default values for all properties on the limeobject that is created when the chat is sent to Lime CRM. This is done under properties for each mapping object. You can configure hard coded values as defaultValue, and you can use dynamic values from the chat by configuring the key in Userlike's payload as userlikeKey. A full example of Userlike's payload can be found here (look at the chat_session_end example).

Example Configuration

We provide two examples, one that is targeting the helpdesk limetype and one that is targeting the deal limetype.

Helpdesk

This is an example that is targeting the helpdesk limetype.

{
    "instances": [
        {
            "name": "Helpdesk",
            "limetype": "helpdesk",
            "relationCoworker": "coworker",
            "relationCompany": "company",
            "relationHistory": "history",
            "relationConversation": "ulconversation",
            "relationDocument": "document",
            "linkType": "Web client",
            "baseUrl": "https://userlike.com/en/umc#/conversation/",
            "includeNotifications": false,
            "importMediaFiles": true,
            "document": {
                "limetype": "document",
                "propertyComment": "comment",
                "propertyDocument": "document",
                "propertyMessageId": "ul_messageid",
                "propertyType": "type",
                "optionKeyForMediaFiles": "other"
            },
            "history": {
                "limetype": "history",
                "propertyNote": "note",
                "propertyType": "type",
                "relationPerson": "person",
                "relationCompany": "company",
                "relationCoworker": "coworker",
                "optionKeyForChat": "comment",
                "optionKeyForNote": "internalcomment"
            },
            "personRelations": [
                {
                    "limetype": "person",
                    "propertyIdentifier": "email",
                    "identificationKey": "contact.email",
                    "relationCompany": "company",
                    "propertyName": "name",
                    "relationMainLimetype": "helpdesk",
                    "relationHistory": "history"
                }
            ],
            "coworker": {
                "limetype": "coworker",
                "propertyIdentifier": "email",
                "propertyName": "name",
                "identificationKey": "operator_assigned_to_email"
            },
            "conversation": {
                "limetype": "ulconversation",
                "propertyConversationId": "conversationid",
                "propertyLink": "link",
                "propertyContactId": "contactid",
                "propertyStartedTime": "startedtime",
                "propertyContactFirstMessageTime": "contactfirstmessagetime"
            },
            "mappings": [
                {
                    "topics": ["support"],
                    "properties": [
                        {
                            "limeProperty": "title",
                            "defaultValue": "New ticket from Userlike"
                        },
                        {
                            "limeProperty": "description",
                            "defaultValue": "The complete chat transcript is stored in the history flow."
                        },
                        {
                            "limeProperty": "source",
                            "defaultValue": "chat"
                        },
                        {
                            "limeProperty": "created",
                            "userlikeKey": "contact_first_message_sent_at"
                        },
                        {
                            "limeProperty": "email",
                            "userlikeKey": "contact.email"
                        }
                    ]
                }
            ]
        }
    ]
}

Deal

This is an example that is targeting the deal limetype.

{
    "instances": [
        {
            "name": "Lead",
            "limetype": "deal",
            "relationCoworker": "coworker",
            "relationCompany": "company",
            "relationHistory": "history",
            "relationConversation": "ulconversation",
            "relationDocument": "document",
            "linkType": "Web client",
            "baseUrl": "https://userlike.com/en/umc#/conversation/",
            "includeNotifications": false,
            "importMediaFiles": true,
            "document": {
                "limetype": "document",
                "propertyComment": "comment",
                "propertyDocument": "document",
                "propertyMessageId": "ul_messageid",
                "propertyType": "type",
                "optionKeyForMediaFiles": "other"
            },
            "history": {
                "limetype": "history",
                "propertyNote": "note",
                "propertyType": "type",
                "relationPerson": "person",
                "relationCompany": "company",
                "relationCoworker": "coworker",
                "optionKeyForChat": "comment",
                "optionKeyForNote": "internalcomment"
            },
            "personRelations": [
                {
                    "limetype": "person",
                    "propertyIdentifier": "email",
                    "identificationKey": "contact.email",
                    "relationCompany": "company",
                    "propertyName": "name",
                    "relationMainLimetype": "deal",
                    "relationHistory": "history"
                }
            ],
            "coworker": {
                "limetype": "coworker",
                "propertyIdentifier": "email",
                "propertyName": "name",
                "identificationKey": "operator_assigned_to_email"
            },
            "conversation": {
                "limetype": "ulconversation",
                "propertyConversationId": "conversationid",
                "propertyLink": "link",
                "propertyContactId": "contactid",
                "propertyStartedTime": "startedtime",
                "propertyContactFirstMessageTime": "contactfirstmessagetime"
            },
            "mappings": [
                {
                    "topics": ["lead"],
                    "properties": [
                        {
                            "limeProperty": "name",
                            "defaultValue": "New lead from Userlike",
                            "userlikeKey": "subject"
                        }
                    ]
                }
            ]
        }
    ]
}

Application Config

Lime Chat is using the application level configuration in order to configure secrets to Userlike's API, which is used to fetch resources from Userlike. Information about how you can access Userlike's API and where you can find the API key can be found under the Authentication title here.

Windows on-premise Installations

For Windows on-premise installations, the application level configuration is expressed in the file %ProgramData%\Lundalogik\LIME Pro Server\application_config.yaml and shared by all services. If it does not already exist, just create it. Add the following to the file:

<application-display-name>:
  secrets:
    limepkg-userlike:
      userlike_api_token: <userlikeapikey>

Restart the web server and the task handler.

Cloud

For Cloud installations, the application level configuration is configured in CAFE (Lime CRM Cloud Administration).

Add following to the Secret box in the application configuration in CAFE:

limepkg-userlike:
  userlike_api_token: <userlikeapikey>