curl --request GET \
--url https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments \
--header 'Authorization: <api-key>'import requests
url = "https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)using RestSharp;
var options = new RestClientOptions("https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.get("https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments")
.header("Authorization", "<api-key>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"conversationsMessage": {
"id": 1,
"channel": "FACEBOOK_POST",
"from": "55555544444433333",
"to": "999990000011111",
"direction": "INBOUND",
"conversationId": "3f8c9a2e-1b6f-4d3a-9f5b-2e4b6c8d9e7f",
"authorId": "7a1d5b4c-8e2f-4c3b-b9a1-5f6d7e8f9a0b",
"authorType": "CUSTOMER",
"createdAt": "2025-01-10T08:51:23.100+00:00",
"updatedAt": "2025-01-10T08:51:23.100+00:00",
"content": {
"text": "Hello!",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"id": "55555544444433333",
"type": "SOCIAL_USER"
},
"to": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"content": {
"commentMoContent": {
"text": "Hello!",
"type": "TEXT"
},
"type": "COMMENT"
},
"socialContext": {
"externalId": "999990000011111_123456789123457",
"postId": "987654321987_999990000011112",
"parentId": null,
"permalinkUrl": null,
"extCreated": "2025-01-10T08:51:23.100+00:00",
"username": "John Doe",
"actionType": "ADD"
},
"channel": "FACEBOOK_POST",
"direction": "INBOUND"
},
"contentType": "TEXT"
},
"olderComments": [
{
"id": null,
"channel": "FACEBOOK_POST",
"authorName": "John Doe:123456789",
"direction": "INBOUND",
"conversationId": "a06b6abc-1c8f-4b4f-8600-f4f651418e8f",
"createdAt": "2025-01-09T08:51:23.100+00:00",
"content": {
"text": "Test",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"id": "55555544444433333",
"type": "SOCIAL_USER"
},
"to": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"content": {
"commentMoContent": {
"text": "Test",
"type": "TEXT"
},
"type": "COMMENT"
},
"socialContext": {
"externalId": "999990000011111_123456789123456",
"postId": "987654321987_999990000011111",
"parentId": null,
"permalinkUrl": null,
"extCreated": "2025-01-09T08:51:17Z",
"username": "John Doe",
"actionType": "ADD"
},
"channel": "FACEBOOK_POST",
"direction": "INBOUND"
},
"contentType": "TEXT"
}
],
"newerComments": [
{
"id": null,
"channel": "FACEBOOK_POST",
"authorName": "Peter Northrop:8132498432",
"direction": "OUTBOUND",
"conversationId": "e50588de-123b-45c8-9f58-8e3376805646",
"createdAt": "2025-02-18T13:56:10.465+00:00",
"content": {
"socialMentions": [],
"text": "@John Doe OK",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"to": {
"id": "8132498432",
"type": "SOCIAL_USER"
},
"content": {
"text": "@John Doe OK",
"type": "TEXT"
},
"replyToCommentId": "999990000011111_546621549845623",
"mentions": [],
"channel": "FACEBOOK_POST",
"direction": "OUTBOUND"
},
"contentType": "TEXT"
}
]
}{
"requestError": {
"serviceException": {
"messageId": "NOT_FOUND",
"text": "Invalid conversationId 'related-comments' given! No such entity exists."
}
}
}{
"requestError": {
"serviceException": {
"messageId": "UNAUTHORIZED",
"text": "Unauthorized"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "FORBIDDEN",
"text": "Forbidden"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "NOT_FOUND",
"text": "Not found"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "GENERAL_ERROR",
"text": "Something went wrong. Please contact support."
}
}
}Get related comments
Use this method to return social comments related to a specified inbound comment within a conversation. It returns up to 50 older and 50 newer comments that are on the same hierarchy level as the inbound comment.
Required scope: Enable one of: conversations:manage, conversations:read.
curl --request GET \
--url https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments \
--header 'Authorization: <api-key>'import requests
url = "https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)using RestSharp;
var options = new RestClientOptions("https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.get("https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments")
.header("Authorization", "<api-key>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.messaging.phonovation.com/ccaas/1/conversations/{conversationId}/related-comments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"conversationsMessage": {
"id": 1,
"channel": "FACEBOOK_POST",
"from": "55555544444433333",
"to": "999990000011111",
"direction": "INBOUND",
"conversationId": "3f8c9a2e-1b6f-4d3a-9f5b-2e4b6c8d9e7f",
"authorId": "7a1d5b4c-8e2f-4c3b-b9a1-5f6d7e8f9a0b",
"authorType": "CUSTOMER",
"createdAt": "2025-01-10T08:51:23.100+00:00",
"updatedAt": "2025-01-10T08:51:23.100+00:00",
"content": {
"text": "Hello!",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"id": "55555544444433333",
"type": "SOCIAL_USER"
},
"to": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"content": {
"commentMoContent": {
"text": "Hello!",
"type": "TEXT"
},
"type": "COMMENT"
},
"socialContext": {
"externalId": "999990000011111_123456789123457",
"postId": "987654321987_999990000011112",
"parentId": null,
"permalinkUrl": null,
"extCreated": "2025-01-10T08:51:23.100+00:00",
"username": "John Doe",
"actionType": "ADD"
},
"channel": "FACEBOOK_POST",
"direction": "INBOUND"
},
"contentType": "TEXT"
},
"olderComments": [
{
"id": null,
"channel": "FACEBOOK_POST",
"authorName": "John Doe:123456789",
"direction": "INBOUND",
"conversationId": "a06b6abc-1c8f-4b4f-8600-f4f651418e8f",
"createdAt": "2025-01-09T08:51:23.100+00:00",
"content": {
"text": "Test",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"id": "55555544444433333",
"type": "SOCIAL_USER"
},
"to": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"content": {
"commentMoContent": {
"text": "Test",
"type": "TEXT"
},
"type": "COMMENT"
},
"socialContext": {
"externalId": "999990000011111_123456789123456",
"postId": "987654321987_999990000011111",
"parentId": null,
"permalinkUrl": null,
"extCreated": "2025-01-09T08:51:17Z",
"username": "John Doe",
"actionType": "ADD"
},
"channel": "FACEBOOK_POST",
"direction": "INBOUND"
},
"contentType": "TEXT"
}
],
"newerComments": [
{
"id": null,
"channel": "FACEBOOK_POST",
"authorName": "Peter Northrop:8132498432",
"direction": "OUTBOUND",
"conversationId": "e50588de-123b-45c8-9f58-8e3376805646",
"createdAt": "2025-02-18T13:56:10.465+00:00",
"content": {
"socialMentions": [],
"text": "@John Doe OK",
"showUrlPreview": null
},
"singleSendMessage": {
"from": {
"externalId": "999990000011111",
"type": "SOCIAL_PAGE"
},
"to": {
"id": "8132498432",
"type": "SOCIAL_USER"
},
"content": {
"text": "@John Doe OK",
"type": "TEXT"
},
"replyToCommentId": "999990000011111_546621549845623",
"mentions": [],
"channel": "FACEBOOK_POST",
"direction": "OUTBOUND"
},
"contentType": "TEXT"
}
]
}{
"requestError": {
"serviceException": {
"messageId": "NOT_FOUND",
"text": "Invalid conversationId 'related-comments' given! No such entity exists."
}
}
}{
"requestError": {
"serviceException": {
"messageId": "UNAUTHORIZED",
"text": "Unauthorized"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "FORBIDDEN",
"text": "Forbidden"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "NOT_FOUND",
"text": "Not found"
}
}
}{
"requestError": {
"serviceException": {
"messageId": "GENERAL_ERROR",
"text": "Something went wrong. Please contact support."
}
}
}Authorizations
This is the most secure authorization type and the one with the most flexibility.
API keys can be generated by calling the dedicated API method. Furthermore, API keys can have a limited scope and cover only some API methods. Lastly, they can be revoked at any time. This range of possibilities makes API keys well suited for separating the API access rights across multiple applications or use cases. Finally, the loss of an API key is easily manageable.
You can manage your API keys from GUI, or programmatically with dedicated API.
API key Authorization header example:
Authorization: App 003026bbc133714df1834b8638bb496e-8f4b3d9a-e931-478d-a994-28a725159ab9
Path Parameters
ID of the conversation to get.
Response
OK
Show child attributes
Show child attributes
Returns up to 50 comments created before the specified inbound comment, at the same level of the conversation.
Show child attributes
Show child attributes
Returns up to 50 comments created after the specified inbound comment, at the same level of the conversation.
Show child attributes
Show child attributes