In this page, you'll learn about access and environment objects is Cliq and their structure.

Table of Contents

Access Object

Access object in Cliq is of the map data type and contains user ID, chat ID and details of the web client used by the user. The access object carries the following arguments to it

AttributeDescription
user_idUser ID (unique string identifier)
user_agentDetails of the web client used by the user.
chat_idDetails of the chat where the internal component is executed.

Below is a sample access object 


{
  "user_id": "1234567",
  "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.109 Safari/537.36",
  "chat_id": "22326656503451932348"
}

 

Environment Object

Environment object in Cliq is of the map data type and contains details about the data center to which the user belongs. The access object carries the following arguments to it

AttributeDescription
data_centerDetails of the data center to which the user belongs. Values can be : US | EU | IN | CN | AU

Below is a sample environment object 


{
  "data_center": "US"
}