# HuggyIntegrations Object
Huggy provides a set of information about customer service directly in the browser through the huggyIntegrations
object.
With this feature, you can expand the capabilities of your operation by developing customized solutions.
For example, it is possible to offer agents a Huggy-integrated browser extension that sends information to a CRM during service.
# How to Use
With the global Huggy Integrations object, you have access to the logged-in user, contact, and current chat data from the Huggy platform via JavaScript.
To view this object in the browser, open a chat and type huggyIntegrations
in the console.
An object with the following information will be displayed:
{
“contact”: {
“id”: 123456789,
“name”: "john Doe",
“email”: "john@doe.com",
“phone”: "551133333333",
“mobile”: "5511999999999"
},
“chat”: {
“id”: 987654321,
“agent”: {
“id”: 456789,
“name”: "Charlie Eduard",
“email”: "charlie@eduard.com"
}
},
“user”: {
“id”: 123456,
“name”: "Mary Smith",
“email”: "mary@smith.com"
}
}
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Object Properties
Field | Description | Type |
---|---|---|
chat | Object containing information about the current service | object |
chat.id | Service identifier | integer |
chat.agent | User who is performing the current service | object |
contact | Contact currently being viewed | object |
contact.id | Contact ID at Huggy | integer |
contact.name | Contact name | string |
contact.email | Contact email | string |
contact.mobile | Contact mobile | string |
contact.phone | Contact phone | string |
user | User connected to Huggy | object |
user.email | User email | string |
user.id | User identifier | integer |
user.name | User name | string |
Field: chat
Object containing information about the current service
objectField: chat.id
Service identifier
integerField: chat.agent
User who is performing the current service
objectField: contact
Contact currently being viewed
objectField: contact.id
Contact ID at Huggy
integerField: contact.name
Contact name
stringField: contact.email
Contact email
stringField: contact.mobile
Contact mobile
stringField: contact.phone
Contact phone
stringField: user
User connected to Huggy
objectField: user.email
User email
stringField: user.id
User identifier
integerField: user.name
User name
string