Get contact conversations
curl --request GET \
--url https://core-api.getaptly.com/api/contacts/{contactId}/conversations \
--header 'x-token: <api-key>'import requests
url = "https://core-api.getaptly.com/api/contacts/{contactId}/conversations"
headers = {"x-token": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-token': '<api-key>'}};
fetch('https://core-api.getaptly.com/api/contacts/{contactId}/conversations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://core-api.getaptly.com/api/contacts/{contactId}/conversations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core-api.getaptly.com/api/contacts/{contactId}/conversations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://core-api.getaptly.com/api/contacts/{contactId}/conversations")
.header("x-token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://core-api.getaptly.com/api/contacts/{contactId}/conversations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"personIds": [
"<string>"
],
"conversations": [
{
"_id": "<string>",
"subject": "<string>",
"description": "<string>",
"messageCount": 123,
"type": "<string>",
"status": 123,
"assigneeId": "<string>",
"participants": [
"<string>"
],
"channel": {
"id": "<string>",
"type": "<string>"
},
"metrics": {
"lastMessageAt": "2023-11-07T05:31:56Z",
"lastActivityAt": "2023-11-07T05:31:56Z",
"lastMessageDirection": "in"
}
}
],
"hasMore": true,
"skip": 123,
"limit": 123
}Contacts
Get contact conversations
Find real email, SMS, and call conversations by the contacts’ stored email addresses and phone numbers, without a helpdesk ticket requirement. Includes open and closed threads by default, with no recent-date cutoff. Excludes junk/deleted streams and synthetic bulk-campaign activity. Newest message first, across accessible inboxes. API keys have company scope; delegate tokens need contacts:* read scope and follow current membership, inbox/team/monitor and contact-type sharing permissions (respecting channel opt-outs). Every contact must be active and in the authenticated company. Empty addresses return an empty page.
GET
/
api
/
contacts
/
{contactId}
/
conversations
Get contact conversations
curl --request GET \
--url https://core-api.getaptly.com/api/contacts/{contactId}/conversations \
--header 'x-token: <api-key>'import requests
url = "https://core-api.getaptly.com/api/contacts/{contactId}/conversations"
headers = {"x-token": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-token': '<api-key>'}};
fetch('https://core-api.getaptly.com/api/contacts/{contactId}/conversations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://core-api.getaptly.com/api/contacts/{contactId}/conversations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://core-api.getaptly.com/api/contacts/{contactId}/conversations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-token", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://core-api.getaptly.com/api/contacts/{contactId}/conversations")
.header("x-token", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://core-api.getaptly.com/api/contacts/{contactId}/conversations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-token"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"personIds": [
"<string>"
],
"conversations": [
{
"_id": "<string>",
"subject": "<string>",
"description": "<string>",
"messageCount": 123,
"type": "<string>",
"status": 123,
"assigneeId": "<string>",
"participants": [
"<string>"
],
"channel": {
"id": "<string>",
"type": "<string>"
},
"metrics": {
"lastMessageAt": "2023-11-07T05:31:56Z",
"lastActivityAt": "2023-11-07T05:31:56Z",
"lastMessageDirection": "in"
}
}
],
"hasMore": true,
"skip": 123,
"limit": 123
}Authorizations
ApiKeyHeaderDelegateToken
Path Parameters
Required string length:
1 - 128Query Parameters
Available options:
all, open, closed Channel meta.id; narrows authorized inboxes, never expands access.
Subject contains text; comma-separated literal alternatives.
Maximum string length:
200Required range:
0 <= x <= 100000Required range:
1 <= x <= 60