Streams are communication channels used in Cirrusx, such as Chat, WhatsApp, SMS/Text, etc. In the Streams category of APIs, the channel is the focal point of the request, and the objects and users are the filtering aspects. See the Enums Section for available channels and their Cirrus code.
GET: Get Stream Availability
This API checks the availability of the stream (channel) and returns the channel’s state.
Enum:
Channel is not active = 0
Available (during business hours) = 1
Busy (Overload on agents during business hours) = 2
Unavailable (Off business hours or during a special day) = 3
Note: Path parameters include a Boolean regarding the automation function within that steam (since the bot is always available, the busy and unavailable states will not reflect)
True – Ignore automation
False – Include automation in the checking
(GET) /streams/STREAM_ID/streamavailability/ignoreAutomationExsistance
Example:
https://api.commbox.com/streams/STREAM_ID/streamavailability/false
path Parameters
STREAM_ID required
|
integer <int64>
Stream ID. is a Cirrus generated number for the channel |
query Parameters
ignoreAutomationExsistance required
|
boolean |
Response Schema: application/json
status | string
|
||
description | string
|
||
response_time | string
|
||
object
|
|||
|
GET: Get Stream Objects
This API returns information about all Objects (conversations) in the requested Stream (channel).
Required query params:
Note: Without limiting the request, the call will fail.
a)Time range - For all Objects within a range of time, enter both unixStartTime and unixEndTime (Unix Time Stamp format). Max: 100 objects – for larger data additional calls are required.
b) Specific user - For all Objects of a specific user, enter both identityStreamProviderId and IdentityStreamProviderType.
Parameters are found in the “identities” section of the Get Users API. Enter the data found in streamProviderId and StreamProviderType
c) Specific user - For all Objects of a specific user, enter the userIdentityId – the Id of the identity as it appears in the Get Users API (Not to be confused with the “userId” field)
Use the Sort, Order, etc. optional parameters to limit and organize the output.
Note: Object's children and activity logs are False by default.
GET /streams/{STREAM_ID}/objects
path Parameters
STREAM_ID required
|
integer <int64>
A Cirrus generated number for the channel |
query Parameters
userIdentityId | integer <int64>
A Cirrus generated number for the user. Returns objects created by this user |
identityStreamProviderId | string
To returns objects created by a user, enter the StreamProviderId found at the identity section. Must supply identityStreamProviderType as well. |
identityStreamProviderType | string <short>
See Enum. To returns objects created by a user, enter the StreamProviderType found at the identity section. Must supply identityStreamProviderId as well. |
unixStartTime | integer <int64>
Unix time stamp (UTC) of starting date and time of query. |
unixEndTime | integer <int64>
Unix time stamp (UTC) of ending date and time of query. |
subStream | integer <int64>
The subchannel Id (Optional, default 0) |
sort | string
Sort of return objects (optional, default desc). Possible values: desc, asc |
order | string
Order of return objects (optional, default createdtime). Possible values: createdtime, closedtime, prioritytime, updatedtime |
includeChilds | boolean
Return objects with their childs (optional, default false) |
includeActivityLog | boolean
Return objects with their activity log (optional, default false) |
timeFilter | string
Determines which object datetime field affects unixStartTime & unixEndTime (optional, relevant only for ElasticSearch) |
pageNumber | integer
Used for paging results (optional) |
pageSize | integer
Used for paging results (optional, default 100) |
status | string
ObjectStatusType - see Enums for code. |
Response Schema: application/json
status | string
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
description | string
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
response_time | string
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array of objects or objects
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
One of
|
GET: Get Streams Stats
https://api.commbox.io/stats/streams
Response Schema: application/json
status | string
|
||||||||||
description | string
|
||||||||||
response_time | string
|
||||||||||
Array of objects or objects
|
|||||||||||
Array
One of
|
GET: Get SLA Breach Summary
A service-level agreement (SLA) defines the service standards the provider is obligated to provide to the customer. The First Response time to the customer’s inquiry is an example of a typical SLA measured by Cirrus. After that time passes, the SLA is breached.
There are 2 SLA Warnings that can be set in the SLA settings page:
- A warning is activated after 50% (default settings) of the time allotted by the SLA past.
- A critical warning is activated when there is only 20% (default settings) of the time left before an SLA breach.
(For example, if the Service Level Agreement is 5 minutes, conversations waiting for the First Response will be painted in orange after 2.5 minutes and in red after 4 minutes.)
This API returns the number of SLA breaches for the entire account divided by communication channel Id, longest conversations, and specific agent/bot SLA.
Note:“Exceptions” refers to Breaches, and “SlaCritical” refers to the SLA critical warning.
https://api.commbox.io/stats/streamsSLAExceptions
Response Schema: application/json
status | string
|
||||||||||||||
description | string
|
||||||||||||||
response_time | string
|
||||||||||||||
Array of objects or objects
|
|||||||||||||||
Array
One of
|