- Print
- DarkLight
- PDF
General Overview
CommBox redefines the way businesses interact with their customers by providing seamless interactions between different communication modalities, deep integration with customer relations management platforms, and innovative business solutions to improve agents’ productivity and service abilities, all while saving time by reducing manual efforts via our automation.
The articles in this segment provide the information needed for developers to use CommBox’s resources, whether server-based or client-side.
The CommBox Developers platform lets you access CommBox data and functionality using code instead of the user interface enabling actions such as creating a WhatsApp template, sending follow-up SMS/text reminders, or receiving Webhooks based on pre-set triggers in CommBox.
CommBox Omnichannel Structure:
Security and Authentication
The CommBox REST API is only served over HTTPS.
In addition, all requests must pass Bearer Token (BearerAuth) for authentication, where the token is predetermined and provided by CommBox.
All requests are logged and validated.
All parameters must be URL-encoded.
- Security Scheme Type: HTTPS
- HTTP Authorization Scheme: bearer
Obtaining an API Key / Access Token
Note: Admin privileges are required to obtain the Access Token / API Key.
A Bearer Token must be set in the Authorization header of every API call.
In the CommBox console, navigate to Settings > API (in the Settings & Features section):
- Click the View icon next to the API Key.
- Click the Copy icon on the right.
- At the request Authorization tab of the collaboration platform (e.g. Postman), select Bearer Token from the Type dropdown list.
- At the Token field, paste your Access Token / API Key value.
Warning: API tokens can pose a security risk to your organization if used by an unauthorized person. Make sure to keep them secure. Delete old keys and replace them in your system if you suspect any security breach.
Replacing/Rotating API Tokens
API Keys rotate automatically in a pre-set schedule. To reset that schedule or obtain a new key, follow the steps below:
- Navigate to Settings > API.
- Click the Revoke icon at the far right of the existing API Key. A new dialog box will inform you of having a 30-day grace period to replace the old key with the new one. Click the Revoke Key button.
- At the new dialog box, determine how long the new key will be active. You may copy it to other locations from there or do so later within your 30-day grace period.
- Finish the process by clicking Done.
The New API key is displayed above the old one. After 30 days, the old API key will expire. - You may delete the Revoked/Expired key by clicking the Trash Bin icon.
Authentication Modules
CommBox offers several options for authentication and silent login into our systems in addition to our standard user/password login process.
Directory Services
We allow login for our management site using Directory Services (DS) providers (such as Active Directory).
To set it up, the Single Sign-On module must be active, and the domain, username, and password (optional) must be set in the Module Settings tab. Furthermore, every user who wishes to log in using Directory Services must also set the Username field on the Users Management page.
Once configured, the system will try to validate the username and password fields input on the login page against the DS server. If successful, the user will be automatically signed into the system. Otherwise, the system will try to validate the user/password field using the standard CommBox credentials.
Ticket Authentication
Our authentication system allows users to log in to the management site and chat application using a custom-signed ticket. This ticket is generated through our Ticket API by providing the necessary query parameters. Upon successful request, the API returns a session cookie (ticket) that can be appended to the login URL to bypass it as an agent, or appended to the Chat login URL to facilitate authentication as a customer.
Note:
To log in to our management site, the ticket must include the business account name (brand), an active username of an agent (for agent login), and a strong identifier (email or phone number).
To log in to our app as a customer, tickets must include the business account name (brand), the channel code, and all the body parameters needed for that specific app. (FirstName, LastName, Phone, email address, etc.)
Obtaining a STREAM ID
A STREAM ID is required for every communication channel (Chat, WhatsApp, etc.).
If you don’t know the Stream ID, substitute it with the encrypted version (called StreamProviderId):
- At the CommBox console, navigate to Settings and select the communication channel.
- Click on the communication channel of your choice from the listed channels. The ID number issued by CommBox is right underneath the channel name.
- Place this code wherever you see the {STREAM_ID} section of the API.
Example:
https://api.commbox.io/streams/{STREAM_ID}/objects
https://api.commbox.io/streams/hNyRN_fLUy7rrOrN9jLpipA%3d%3d/objects
Customization
We provide customization of our functionalities to be tailored to the client’s needs.
An iFrame on 3rd party Assets
We enable our site to be embedded on other web-based platforms as an iFrame. Such integrations enable agents to work within the CRM or Contact platforms and utilize CommBox for communication with customers. Data records are created and updated seamlessly between the two platforms.
Available CRM integrations include Salesforce, Microsoft Dynamics, SAP C4C and more.
Widgets
We provide several premade widgets for embedding our Inbox or Object (conversation) in your Dashboards or CRM. These widgets isolate the Object from the rest of the platform, allowing CommBox clients to incorporate them into their 3rd party system.
To only view the dialog box of the CommBox platform, use this URL:
https://manange.commbox.io
To only view a specific Object (conversation), use this URL with the Conversation Id:
https://manange.commbox.io/widget/object/{Object_Id}
To obtain the Object Id, click on the 3-vertical-dots menu at the top left corner of the main pane. The Id is displayed at the bottom of that window.
Desktop Management Customization
CommBox allows CSS customization for most page elements and specific JavaScript code elements for client-side events. Contact us for more information.
CommBox REST APIs
CommBox utilizes the REST APIs principles, allowing developers to perform queries to the CommBox platform. We support GET, POST, PATCH, and DELETE requests.
- GET request retrieves information
- POST request creates or updates an entity
- PATCH request makes partial updates (where applicable)
- DELETE request removes an entity
After receiving the request, the API sends back an HTTP code as a response in JSON format.
Access Token
All API requests require an Access Token to validate authenticity to indicate to the system what modules, operations, and resources the user can access. See more detailed information in the Security and Authentication section of this documentation.
Base URI
All URLs referenced in the documentation have the following base: https://api.commbox.io
When using the API in your organization, substitute “commbox.io” for your brand name’s login URL
Request
- The request must include the module and operation in the URI.
For example, to access an operation called Send SMS in the SMS module, make an HTTPS POST request to /sms/sendsms/ - To receive specific information regarding a resource, use the provided parameters in the URI.
For example, to access information about a specific agent, make an HTTPS GET request to /managers/{MANAGER_ID} - Some requests require data location, such as stream (channel) to be added.
For example, make the HTTPS DELETE request to delete a specific tag from a conversation (object) in a specific stream (channel) /streams/{STREAM_ID}/objects/{OBJECT_ID}/tags/{TAG_ID}
Response
Property | Description |
---|---|
status | The HTTP status code for the response |
description | A more informative message |
response_time | UTC Timestamp for the operation |
data | (Optional) Additional output data which varies by the operation |
Possible Response Status Codes
Status Code | Description | Notes |
---|---|---|
200 | OK | The request was successful |
206 | Partial success / non-API related issue or problem | Applicable to WhatsApp APIs (e.g. “Missing Template parameter”, “Some messages failed”, “Provider returned failure”) |
400 | Bad Request | The request could not be understood by the server. Incoming parameters might not be valid |
401 | Unauthorized | The supplied credentials, if any, are not sufficient to access the resource |
404 | Not Found | The requested resource was not found |
429 | Too Many Requests | Too many requests have been made in a short period of time (Throttling) |
500 | Server Error | The server could not return the representation due to an internal server error |
501 | Not Implemented | The requested operation is not supported (e.g. supports GET but not POST etc.) |
Data structures
This section outlines the data structures recognized and transmitted by the API.
Objects represent conversations between automation bot or agents and the customers. Each segment within a conversation is referred to as a Child. Every conversation is associated with a designated Stream — a communication channel such as chat, email, SMS, etc. where the interaction takes place.
In the Objects category, the focus is on a specific conversation, with the stream serving as part of its identifying attributes. Conversely, in the Streams category, the communication channel itself is the primary focus, while objects and users act as filtering criteria for the request.
Object
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | Object ID. A CommBox generated number for the conversation. | |
StreamId | int64 | Stream ID to which the object is connected | |
SubStreamId | int64 | Sub Stream ID to which the object is connected | |
Type | short | The type of the object | |
StatusId | string | Current status ID of the conversation | |
CreatedTime | datetime | When the object was created | In UTC time |
FirstResponseTime | datetime | When the first response to the object was registered | In UTC time |
UpdatedTime | datetime | When the object was last updated | In UTC time |
PriorityTime | datetime | When the object is currently prioritized | In UTC time |
NumChilds | int | Number of child objects relating to this parent object | |
IsManager | bool | Indicates whether this object was created by an agent (true) or a customer (false) | |
NumTags | int | Number of tags assigned to this object | |
Message | string | The text containing the object’s primary message | |
Content | JSON string | String containing extended properties of the object | |
User | object | The user that created the object |
Object Child
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | Child ID. A CommBox generated number for the message | |
Type | short | The type of the child | |
IsManager | bool | Indicates whether this child was created by an agent (true) or a customer (false) | |
CreatedTime | datetime | When the child was created | In UTC time |
Message | string | The text containing the child’s primary message | |
Content | JSON string | String containing extended properties of the child | |
User | object | The user that created the child |
Object Activity Log
Property | Value | Description | Notes |
---|---|---|---|
Text | string | Text content in the activity log | |
Source | string | The source of the activity log (optional) | |
ManagerId | Int64 | The manager (agent) who initialized the activity log (optional) |
Tag
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | Tag ID. This is a CommBox generated number |
User
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | User ID. A CommBox generated number for the agent/customer etc. | |
UniqueId | string(50) | User’s unique identifier. This can be an email, social security number or any other type of unique string determined by the brand administrators | |
Phone1 | Numeric string(20) | User’s phone number | Always contains country code and without leading + or 00 |
Phone2 | Numeric string(20) | User’s additional phone number | Always contains country code and without leading + or 00 |
string (255) | User’s email address | ||
FirstName | string (100) | User’s first name | |
LastName | string (100) | User’s last name | |
Gender | string (1) | User’s gender | ‘M’ for male, ‘F’ for female |
Locale | object | User’s locale | |
Birthday | date | User’s birthday | Date only |
NumIdentities | int | Number of active identities that are connected to this user | |
IsManager | bool | Indicates whether this user is a agent or an admin (true) or a customer (false) | |
Remarks | string | Free text containing general remarks about the user | Identity | object | Identity object that is connected to the user |
User Identity
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | Identity ID. This is a CommBox generated number and used throughout all the updates | |
StreamProviderId | string(255) | Identity’s unique identifier as it appears at the original provider | |
StreamProviderType | int64 | Type of the original provider | |
StreamProviderEmail | string(255) | Identity’s email as it appears at the original provider | |
UserName | string (100) | Identity’s user name as it appears at the original provider | |
FirstName | string (100) | Identity’s first name as it appears at the original provider | |
LastName | string (100) | Identity’s last name as it appears at the original provider | |
ThumbnailUrl | string (255) | Link to the identity’s profile image | |
NumObjects | int | Number of objects connected to this identity |
Manager
Property | Value | Description | Notes |
---|---|---|---|
Id | int64 | Manager (agent) ID. This is a CommBox generated number and used throughout all the updates | |
AsyncAssignedNoResponse | int | Current number of assigned asynchronous objects awaiting response | |
AsyncAssignedInProccess | int | Current number of assigned asynchronous objects that are being addressed by the manager | |
SyncAssignedNoResponse | int | Current number of assigned synchronous objects awaiting response (Chat/messenger conversations) | |
SyncAssignedInProccess | int | Current number of assigned synchronous objects that are being addressed by the manager (Chat/messenger conversations) | |
FaceToFaceStatus | bool | Returns true if the manager is busy with a face to face object (Voice/Video call) | |
TotalAsyncAssigned | int | Total number of currently assigned objects | |
TotalSyncAssigned | int | Total number of currently assigned synchronous objects (Chat/messenger conversations) |
Object Custom Indicator
Property | Value | Description | Notes |
---|---|---|---|
IndicatorId | string | Indicator id (unique name) – to allow updating/ deleting existing indicator | |
DisplayClass | string | Indicator class. Mandatory only if Icon has not provided | You must provide DisplayClass or an Icon, or both |
Icon | string | An icon for the indicator. Supports URL. Mandatory only if Icon has not provided (not relevant for DELETE operation) | |
Title | string | A title for the indicator (not relevant for DELETE operation) |
Webhooks
A webhook sends an HTTP POST request to a specified URL responding to a trigger (an “event”) in CommBox. For example, every time a new user is created or deleted, CommBox will send a notification to the callback URL provided by the client. The webhook system of notification and updates eliminates continuous or periodic requests when changes haven’t occurred.
Note: We strongly recommend using an HTTPS callback URL with a strong encrypted certificate.
To register for this service, contact your CommBox CS.
Webhook Structure
All updates contain a wrapper called “Event,” which indicates the subscription source and name of the trigger event. Inside the wrapper will be the actual data relevant to this update.
Note: Notifications can be transferred as XML objects.
Xml Example:
For a new object that was received on commbox’s servers, an “OnNew” event will be triggered and posted to the client callback URL:
<Event Subscription="Object" Name="OnNew">
<Object Id="123456" StreamId="1" SubStreamId="1" Type="0" StatusID="1" CreateDate="2024-09-23 12:39:11">
<Message>New status from facebook, Hello world!</Message>
<Content>{"num_likes":5,"user_likes":false,"num_shares":2}</Content>
<User Id="123" UniqueID="123" Phone1="972526444555" Phone2="" Email="fred.lee@gmail.com" FirstName="Fred"
LastName="Lee" Gender="M" NumIdentities="3" Locale="en_US" Birthday="1951-10-10"
Remarks="User remarks">
<Identity Id="12345" StreamProviderId="11111111" StreamProviderType="1"
StreamProviderEmail="fred.lee@gmail.com" UserName="fredl" FirstName="Fred"
LastName="Lee" ThumbnailUrl="//graph.facebook.com/11111111/picture" NumObjects="13">
</Identity>
</User>
</Object>
</Event>
Object Events Subscriptions
OnNew
This event is triggered by creating a new object (conversation).
Example:
<Event Subscription="Object" Name="OnNew" Brand="commbox">
<Object Id="123456" StreamId="1" SubStreamId="1" Type="5"
StatusID="1" CreateDate="2024-09-23 12:39:11"
StreamProviderId="CAEooBmqRVHRrfRmOcCSzSsYMUHUu5NY+NA@mail.gmail.com" StreamProviderType="Mail">
<Message>New status from facebook, Hello world!</Message>
<Content>{"num_likes":5,"user_likes":false,"num_shares":2}</Content>
<ManagerId>0</ManagerId>
<Snippet>Hello</Snippet>
<User Id="123" UniqueID="123" Phone1="972501111111" Phone2=""
Email="fred.lee@gmail.com" FirstName="Fred" LastName="Lee"
Gender="M" NumIdentities="3" Locale="en_US" Birthday="1951-10
10" Remarks="User remarks" NumObjects="13">
<Content>{}</Content>
<Identity Id="12345" StreamProviderId="11111111"
StreamProviderType="1"
StreamProviderEmail="fred.lee@gmail.com"
UserName="Fredl" FirstName="Fred" LastName="Lee"
ThumbnailUrl="//graph.facebook.com/11111111/picture">
</Identity>
</User>
</Object>
</Event>
OnNewChild
This event is triggered by creating a new child object (message in a conversation).
Example:
<Event Subscription="Object" Name="OnNewChild" Brand="commbox">
<Object Id="901730" StreamId="71" SubStreamId="0">
<Children>
<Child Id="2099753" CreateDate="26-03-2023 06:36:15"
Type="0" StreamProviderId="CAEooBmqRVHRrfRm5NY+NA@mail.gmail.com" StreamProviderType="Mail">
<Message>Hello</Message>
<ManagerId>0</ManagerId>
<Content>{"sessionId":133}</Content>
<Snippet>Hello</Snippet>
<User Id="1798715" Phone1="97243434343" Phone2=""
UniqueID="" Email="" FirstName="michael"
LastName="kantz" NumIdentities="1" Locale=""
Remarks="" NumObjects="1">
<Content>{}</Content>
<Identity Id="2191863"
StreamProviderId="43434343"
StreamProviderType="5"
StreamProviderEmail="michael.k@gmail.com"
UserName="" FirstName="michael"
LastName="kantz"
ThumbnailUrl="//graph.facebook.com/146582153
/picture"/>
</User>
</Child>
</Children>
</Object>
</Event>
OnNewActivity
The following events can be triggered by the creation of a new activity:
(a) New remark activity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901738" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565533" Type="1" CreateDate="27-03-2023 06:29:59">
<User Id="433178">
<Identity Id="16982" />
</User>
<Data>{"text":"New remark"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(b) Status change activity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901731" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565420" Type="2"
CreateDate="26-03-2023 06:57:33">
<User Id="433178">
<Identity Id="16982" />
</User>
<Data>{"statusId": 8}</Data>
</Activity>
</Activities>
</Object>
</Event>
(c) Object forward activity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901738" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565534" Type="3" CreateDate="27-03-2023 06:29:59">
<User Id="433178">
<Identity Id="16982" />
</User>
<Data>{"message":"forward object","recipients":["john.k@gmail.com"],
"allowEmailReply":true,"allowCustomerDetails":true}
</Data>
</Activity>
</Activities>
</Object>
</Event>
(d) Reply to forwarded object activity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901738" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565532" Type="4" CreateDate="27-03-2017
06:29:59">
<User Id="123" />
<Data>{"message":"test
test","recipients":["john.k@gmail.com"],
"attachments":"{}"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(e) Object stream change
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901738" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565533" Type="5" CreateDate="27-03-2023
06:29:59">
<User Id="123" />
<Data>{"oldObjectSubstreamName":"old_stream_name","oldObjectStreamName":"old_sub_stream_name",
"newObjectStreamName":"new_stream_name", "newObjectSubstreamName":"new_sub_stream_name"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(f) New manager assignment
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="6" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"managerId":4342094,"assignedManagerId":4342094}</Data>
</Activity>
</Activities>
</Object>
</Event>
(g) Update object tag
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="7" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"tagId":11,"objectId":4342094,"isRemoveTag":false,"name":"tag1","group_name":"group1"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(h) Follow up object activity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="8" CreateDate="26-03-2023
08:45:50">
<User Id="433178">
<Identity Id="16982" />
</User>
<Data>{"text": "test follow up" ,
"scheduledTime": "03/28/2017 05:30:00"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(i) Update object intent
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="9" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"intentIds":[11],"objectId":4342094,"isRemoveIntent":false,"names":["tag1"]}</Data>
</Activity>
</Activities>
</Object>
</Event>
(j) Update object attachments
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="10" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"objectId":4342094,"managerId":452224,
"attachments":{"attachments":[{"href":"/media/Brands/test//5-17/test_image.png","name":"test_image"}]},
"attachmentType":"videoCapture"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(k) Object routed
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="11" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"originalStreamId":12222,"destStreamId":114444,"destSubStreamId":11,"changedStatusId":4,
"tagId":353,"tagName":"plus_tag"}}</Data>
</Activity>
</Activities>
</Object>
</Event>
(l) Update object publicity
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="13" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"changePublicityToPublic":false}</Data>
</Activity>
</Activities>
</Object>
</Event>
(m) Unvalid extension file
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="15" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"fileName":"3c3b71_IMG_1988.jpeg","status":"failed",
"description":"Unsupported file type: image/heic extension: jpeg","unValidActivity":15,
"fileExtension":"jpeg"}</Data>
</Activity>
</Activities>
</Object>
</Event>
(n) Unvalid file size
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="16" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"status":"failed","description":"File is too big","maxFileSizeAllow": 10,
"unValidActivity":16}</Data>
</Activity>
</Activities>
</Object>
</Event>
(o) Unallowed file upload
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="17" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"status":"failed","description":"media dos not enabled","unValidActivity":17}</Data>
</Activity>
</Activities>
</Object>
</Event>
(p) Inactivity logout
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="18" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{}</Data>
</Activity>
</Activities>
</Object>
</Event>
(q) Participants change
Example:
<Event Subscription="Object" Name="OnNewActivity" Brand="commbox">
<Object Id="901733" StreamId="71" SubStreamId="0">
<Activities>
<Activity Id="565443" Type="19" CreateDate="26-03-2023
08:45:50">
<User Id="4342094">
<Identity Id="16982" />
</User>
<Data>{"action":"addParticipant","performingAgentId":192229,"isAgent":true,
"addedParticipantName":"tomer_b"}</Data>
</Activity>
</Activities>
</Object>
</Event>
OnUpdateTag
These events are triggered by an update of a tag relating to the object (conversation tag):
(a) Add
Example:
<Event Subscription="Object" Name="OnUpdateTag" Brand="commbox">
<Object Id="901731" StreamId="71" SubStreamId="0">
<Tags>
<Tag Id="1608" Action="Add" />
</Tags>
</Object>
</Event>
(b) Remove
Example:
<Event Subscription="Object" Name="OnUpdateTag" Brand="commbox">
<Object Id="901731" StreamId="71" SubStreamId="0">
<Tags>
<Tag Id="1611" Action="Remove" />
</Tags>
</Object>
</Event>
User Events Subscriptions
Events in this section indicate a change that occurred in CommBox monitored user(s). The change may be the creation of a new user or an update of an existing one. All updates must contain the surrounding “Event” property and a “User” property and may contain additional properties.
OnNew
This event is triggered by the creation of a new user.
Example:
<Event Subscription="User" Name="OnNew" Brand="commbox">
<User Id="1798714" Phone1="97252570000" Phone2="" UniqueID="" Email="john.doe@gmail.com"
FirstName="michaeli" LastName="" NumIdentities="1" Locale="en_US" Remarks="" NumObjects="0">
<Content>{}</Content>
<Identity Id="2191862" StreamProviderId="kantzmichaeli@gmail.com" StreamProviderType="4"
StreamProviderEmail="" UserName="michaelk" FirstName="michaeli" LastName="kantz" ThumbnailUrl="" />
</User>
</Event>
OnUpdate
This event is triggered by an update of a user.
Example:
<Event Subscription="User" Name="OnUpdate" Brand="commbox">
<User Id="1710055" Phone1="97252570000" Phone2="972525757054" UniqueID="206064"
Email="kantzmichael@gmail.com" FirstName="michael" LastName="kantz" Gender="M" NumIdentities="1"
Locale="" Remarks="New user details">
<Content>{}</Content>
</User />
</Event>
OnUpdateTag
This event is triggered by an update of a tag relating to the user.
Example:
<Event Subscription="User" Name="OnUpdateTag" Brand="commbox">
<User Id="1798718" Phone1="972525757054" Phone2="972525757054"
UniqueID="" Email="michael.k@gmail.com" FirstName="michael"
LastName="" NumIdentities="1" Locale="" Remarks=""
Content="{}">
<Tags>
<Tag Id="1073" Action="Add" />
</Tags>
</User>
</Event>
Satisfaction Events Subscriptions
This section contains events that describe customer satisfaction reports. Updates must contain a surrounding “Event” property and a “Satisfaction” property.
OnSubmit
This event is triggered by a submission of a satisfaction report relating to some object (conversation).
Example:
<Event Subscription="Satisfaction" Name="OnSubmit" Brand="commbox">
<Satisfaction ObjectId="901733">
<Score>100</Score>
<Description>excellent</Description>
</Satisfaction>
</Event>
Form Events Subscriptions
This section contains events that occurred when a form is created or changed. Updates must contain a surrounding “Event” property and a “Form” property.
OnSubmit
This event is triggered when a customer submits a form, and the form PDF file is saved on the disk.
Example:
<Event Subscription="Form" Name="OnSubmit" Brand="commbox">
<Form
<ObjectId>901733</ObjectId>
<FormUrl> https://apps.commboxdev.io/form...</FormUrl>
<Properties>{“field_0”:”Jhon”,”my_own_param”:”1234”}</Properties>
</Form>
</Event>
Chat Events Subscriptions
This section contains events that occurred when the user closes the chat window or disconnects.
OnUserExit
This event is triggered when the user closes the chat window or disconnect.
Example:
<Event Subscription="Chat" Name="OnUserExit" Brand="commbox">
<Chat>
<User id="901733"></User>
<Object id="901735"></Object>
</Chat>
</Event>
Enums
ObjectType
Text = 0
Link = 1
Photo = 2
Video = 3
Conversation = 4
Mail = 5
Audio = 6
Location = 7
voice = 8
Review = 9
Form = 10
System Message = 11
Option = 12
InputData = 13
Contacts = 14
Album = 15
TemplateMessage = 16
CampaignMessage = 17
SurveyMessage = 18
ObjectStatusType
Open = 1
Resolved = 2
Forward = 3
Irrelevant = 4
Deleted = 5
Forward Reply = 6
Draft = 7
In Process = 8
Scheduled = 9
Follow Up = 10
Automated = 11
Sent = 13
Archive = 14
Pending = 15
StreamProviderType
Commbox = 0
Facebook = 1
Twitter = 2
YouTube = 3
Mail = 4
Telephone = 5
Anonymous = 6
WhatsApp = 7
Web = 8
AppleAppStore = 9
Instagram= 10
Google = 11
Telegram = 12
GoogleMyBusiness = 13
Microsoft365 = 14
Gmail = 15
WhatsAppCloud = 16
Salesforce = 17
ObjectActivityType
Remark = 1
StatusChange = 2
Forward = 3
ForwardReply = 4
StreamChange = 5
AssignChange = 6
UpdateObjectTag = 7
FollowUp = 8
UpdateObjectIntent = 9
Attachment = 10
RuleExecuted = 11
Custom = 12
UpdateObjectPublicity = 13
Debug = 14
InvalidExtensionFile = 15
InvalidFileSize = 16
DisallowedFileUpload = 17
inactivityLogout = 18
ParticipantChange = 19
TargetStreamChange = 20
ConversationSummary = 21
LogError = 22
RedactChild = 23
ModuleType
GENERAL = 0
CUSTOMER_SERVICE = 1
FACEBOOK_PAGE_CONNECTOR = 3
STATIC_CONTENT = 4
MAILBOX_CONNECTOR = 6
YOUTUBE_CONNECTOR = 7
TWITTER_CONNECTOR = 8
CHAT = 9
WEB_SYNDICATION_CONNECTOR = 10
FACEBOOK_MONITOR_CONNECTOR = 11
WHATSAPP = 13
SMS = 14
VOICE = 15
SSO = 16
MANAGE_CLIENT_CUSTOMIZATIONS = 17
APPLE_APPSTORE_REVIEWS = 18
GOOGLE_PLAY_REVIEWS = 19
INSTAGRAM_CONNECTOR = 20
CONTACT_US = 21
CUSTOMER_SATISFACTIONS = 22
AUTOMATION_SCRIPT = 23
INTENTS = 24
INTERACTIVE_NAVIGATOR = 25
WEBRTC_VIDEO_CHAT = 26
WEBRTC_AUDIO_CHAT = 27
FORMS = 28
CUSTOMER_VERIFICATION = 29
DYNAMICS_CRM_CONNECTOR = 31
CUSTOM_FIELDS = 32
RIGHTNOW_CRM = 33
RULES = 34
EXTERNAL_CONTACTS = 35
WORKING_HOURS = 36
CUSTOM = 37
FACEBOOK_MESSENGER = 38
MAINTENANCE = 39
PRIVACY_AND_SECURITY = 40
AUTO_ASSIGN = 41
TWO_FACTOR_AUTHENTICATION = 42
THEMES = 43
TELEGRAM = 44
GOOGLE_MY_BUSINESS = 45
SAP_CRM = 46
SLA = 47
PUSH_NOTIFICATIONS = 48
SYS_AID = 49
WORKFLOW = 50
GOOGLE_TRANSLATE = 51
PRIORITY = 53
JIRA = 54
GOOGLE_BUSINESS_MESSAGES = 55
BI_CUSTOM_REPORTS = 57
SALESFORCE = 58
AI_ASSISTANT = 59
API = 60
Zendesk = 61
Teams = 65
Hubspot = 71
Presence Types
Active = 1
Busy = 2
Away = 3
User Permission Types
Unauthorized user = 0
Normal - Customer communicating with agent = 1
Agent = 2
Admin = 3
Bot = 5
Tags Types
Tag = 1
Goal = 2
Miss = 3
Support Tag = 4
Topics Tag = 5
Intents = 100
Customer Satisfaction = 101
SLA = 102
Customer Satisfaction Open Answer = 103
Trying Out CommBox API:
Clients with an active CommBox account can test the API's functionality before integrating it into their organization's production code.
Note:
Some APIs will require settings configuration as a prerequisite for the API testing, such as setting up business hours, creating tag groups, creating forms, etc.