Skip to main content

Uniphore Customer Portal

Fetch Conversation and Session IDs for a Given Tenant ID

This API retrieves the conversation and sessions IDs for the given Tenant ID and environment.

Note

Please contact your Uniphore support representative to obtain the Tenant ID.

Endpoint

Method: GET

URL: https://api.<region>.cloud.uniphorestaging.com/ucap/analytics/interactions

<region> - Mention the name of the region, such as the United States, India, the United Kingdom, the Middle East, and so on, where the U-Assist application is deployed on the public cloud.

Sample Request
curl --location --globoff 'https://api.sg.cloud.uniphorestaging.com/ucap/analytics/interactions?tenantId=9a622bf8-ccf6-578d-b5d4-70b90f807824&environment=dev&q={%22type%22%3A%20%12list%22%2C%22filters%22%3A%20{%22startTime%22%3A1717738600000%2C%20%22endTime%22%3A1715624859000}}' \
--header 'Authorization: Bearer l!5ZElx+DJy3#6</gZA_V7q4d2=hD9' \
--header 'Content-Type: application/octet-stream'
Header Parameter

In the Header Parameter, mention the authorization token of the Admin user. For more information on how to obtain user authorization token, click here.

Authorization - Bearer <Token>
Query Parameters

Parameter Name

Mandatory/Optional

Data Type

Description

tenantId

Mandatory

String

The unique identifier for your account.

environment

Mandatory

String

The name of the environment. Three out-of-the-box environments are provided for each account:

  • DEV

  • TEST

  • PROD

For more information on multi environment accounts, click here.

q

Mandatory

String

q represents the query, which includes type, start time, and end time values.

  • type - Mention how the conversation IDs should be displayed in the response (for example, List).

  • filters - Mention the start and end dates for which the search should be performed.

Sample Response of Single Conversation ID
{   
 "_id": "6641e2e7c069c6940f088e1f",   
 "sessionId": "1715593971481qnv96kfk6",    
 "conversationId": "4eb8fa52-69c2-483c-87a0-5860fb917d73",    
 "startTime": 1715593959880,   
 "lang": "tl-ph",    
 "state": "ready",    
 "endTime": 1715594084019,    
 "duration": 124139,    
 "handleDuration": 124139,    
 "wrapupTime": 1715594084019,    
 "logger": {},   
 "metadata": {       
 "tenantId": "9a622bf8-ccf6-431d-b5d4-70b90f802324",       
 "environment": "dev",       
 "organizationId": "86327040822981062691704270917933",     
 "categoryId": "72354532410022439501704270918938",       
 "type": "live",       
 "contactType": "voice",       
 "journeyId": "1715593971481qnv96kfk6",       
 "isDiarized": false,       
 "agentId": "263",       
 "agentClientId": "palawanagent@inspiro.com",       
 "customerId": "1234",       
 "customerClientId": "1234"   
 },   
 "__ts": 1715594084035
}
Response Parameters

Parameter Name

Description

sessionId

Customer session ID for the call passed from the customer environment to U-Assist.

conversationId

ID generated by the conversation service.

startTime

Start timestamp in milliseconds.

lang

ISO language code for the call.

state

State of the call (ready, start, or stop).

endTime

End timestamp in milliseconds.

duration

Duration of the call in milliseconds.

handleDuration

Total time an agent spends on a customer interaction including talk time and any after-call work.

wrapupTime

Time an agent spends on call-related tasks after ending a call.

tenantId

The unique identifier for your account.

environment

The name of the environment.

organizationId

Organization ID associated with the Tenant.

categoryId

Category ID associated with the Organization.

type

Type of a call (batch or live).

contactType

Contact type (for example: voice, email, or chat).

journeyId

Unique ID to track customer journey across all sessions.

isDiarized

An audio file is either diarized or not.

agentId

Agent user ID.

agentClientId

Unique ID received from the customer environment to U-Assist.

customerId

Customer ID.

customerClientId

Unique ID received from the customer environment to U-Assist.

Response and Error Codes

Code

Response

200

Ok - The request has succeeded. This response code will be shown when the Conversation and Session IDs for the given Tenant ID are successfully retrieved.

400

Bad Request. The request was unacceptable, often due to missing a required parameter.

401

Authentication failed. This response code will be shown if any of the following scenarios occur:

  • The provided token is not a valid authorization token.

  • The authorization token has already expired.

403

Forbidden. If you use the access token of other roles (Analyst or Supervisor), this response code will be shown.

500

When the services down, it shows an 'Internal Server Error'.