get
https://api.octopush.com/v1/public/conversations/messages/list
Encoding : UTF-8
Authentication
Your "api-key" and "api-login" identifiers must be added in the headers.
Definition
This web service allows you to get the conversation messages with some special parameters.
Special parameters
| Name | Type | Description |
|---|---|---|
| page | int | The page number to retrieve (default is 1) |
| per_page | int | The number of items per page (default is 50) |
| contact | string | A combination of the following values to retrieve the conversation: phone_number, email, facebook_id, conversation_id. |
| phone_number | string | Search all types of conversations by phone number (sms, rcs, multi_channel). |
| string | Find a contact by email and then use their phone number to search for conversations. | |
| facebook_id | string | Search for only Facebook conversations by this ID (value format should be fid_{facebook_id}). |
| conversation_id | string | Search for a specific conversation, input format will be cid_{uuid}. |
How Our API Deals With Incorrect Data
The API we provide will try to interpret your request as best it can. If a parameter has the wrong value, we will try to understand it anyway. If the parameter has the wrong type, we will try to format it as best we can. Thus, we have determined default values, which are indicated in our documentation. If a parameter could not be recognized or "fixed", we will ignore it, but your request will be sent.
If one of your parameters does not have the right value, or does not have the right type, we will try to :
- "cast" (convert) it so that it can be understood.
- format it (delete prohibited characters for example)
Server Response Example in JSON
Success
[
{
"message_id": "***",
"text": "Example inbound RCS message",
"direction": "inbound",
"delivery_status": null,
"channel": "rcs",
"user_identifier": "***",
"user_identifiers": {
"phone_number": "***",
"email": "***",
"facebook_page_id": null
},
"agent_assigned_to": null,
"contact_name": "Example name",
"contact_identifiers": {
"phone_number": "***",
"email": null,
"facebook_id": null
}
},
{
"message_id": "***",
"text": "Example outbound SMS message",
"direction": "outbound",
"delivery_status": "sending",
"channel": "sms",
"user_identifier": "***",
"user_identifiers": {
"phone_number": "***",
"email": "***",
"facebook_page_id": null
},
"agent_assigned_to": null,
"contact_name": "Example name",
"contact_identifiers": {
"phone_number": "***",
"email": null,
"facebook_id": null
}
}
]