get https://connect.routee.net/viber/session/
Session messages come in chronological order by default, meaning the oldest is first leading up to the most recent one.
Response parameters
| Parameter | Type | Description |
|---|---|---|
| sessionId | String | The session id of the session that includes the messages in the session array. |
| session | Array of Message objects | An array of session messages between the Viber Business account and its customer. |
| totalElements | Integer | The total amount of elements for the current search. |
Message object
| Parameter | Type | Description |
|---|---|---|
| campaign | String | The name of the campaign that initiated the session. |
| campaignTrackingId | String | The tracking id of the campaign. |
| to | String | The recipient of the message. |
| from | String | The sender of the message. |
| country | String | The country of the recipient. (If applicable) |
| status | Status object | The object with the status of the message. |
| applicationName | String | The Routee application name that was used to generate the auth token for the API usage. |
| direction | Enumerator String | The direction of the message, possible values are Inbound, Outbound. |
| ttl | String | Time range until message expires. |
| message | String | The text of the viber message. |
| imageUrl | String | The url of the image. |
| file | File object | An object holding the variables of a file exchanged between BA and customer. |
Status object
| Parameter | Type | Description |
|---|---|---|
| status | Enumerator String | The current status of the viber message. Check here for possible values. |
| date | String | The updated date of the status. |
| reason | Reason object | The reason of the status. |
Reason object
| Parameter | Type | Description |
|---|---|---|
| detailedStatus | String | The current detailed status. Check here for details. |
| description | String | The description of the detailed status. |
File object
| Parameter | Type | Description |
|---|---|---|
| fileUrl | String | The url of the file sent / received. |
| fileType | String | The type of the file sent / received. |
| fileName | String | The name of the file sent / received. |
Viber Video object
| videoUrl | String (1000 max chars, only https) | The URL where the video is hosted. |
| videoThumbnail | String (1000 max chars, only https) | The URL of a thumbnail for the Video. |
| fileSize | Integer (positive number, 200 max) | The file size in MB. |
| duration | Integer (positive number, 600 max) | The video’s duration in seconds. |
ERROR CODES
| Status | Code | Description |
|---|---|---|
| 404 | 404019020 | The viber session information was not found. |
