List chats
curl --request GET \
--url https://app.cassidyai.com/api/admin/v1/chats \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.cassidyai.com/api/admin/v1/chats"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.cassidyai.com/api/admin/v1/chats', 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://app.cassidyai.com/api/admin/v1/chats",
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: Bearer <token>"
],
]);
$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://app.cassidyai.com/api/admin/v1/chats"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.cassidyai.com/api/admin/v1/chats")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.cassidyai.com/api/admin/v1/chats")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"nextCursor": "<string>",
"chats": [
{
"id": "<string>",
"name": "<string>",
"agent": {
"id": "<string>",
"name": "<string>"
},
"user": {
"id": "<string>",
"name": "<string>",
"email": "<string>"
},
"source": "web",
"isTestChat": true,
"createdAt": "<string>",
"lastActivityAt": "<string>",
"credits": 123
}
]
}{
"code": "BAD_REQUEST",
"message": "Invalid input data",
"issues": []
}{
"code": "UNAUTHORIZED",
"message": "Authorization not provided",
"issues": []
}{
"code": "FORBIDDEN",
"message": "Insufficient access",
"issues": []
}{
"code": "NOT_FOUND",
"message": "Not found",
"issues": []
}{
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit exceeded. Retry after the Retry-After interval."
}{
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"issues": []
}Chats
List chats
Lists Agent chats started in the range, newest first.
Each chat includes
- Its name and most recent Agent
- The person who started it
- Where it happened (
source), such asweb,slack,teams, orembedded - Whether it is an Agent test chat (
isTestChat), started while editing an Agent - When it started and when it was last active
- The credits it used
Leaves out Agent test chats unless includeTestChats is true. Filter by person, Agent, model, or source. Agent and model filters match the chat’s most recent Agent, so a chat that switched Agents is listed under the one it uses now. Page through results with cursor.
Excludes chats run by Workflows. Messages are not included.
Requires the Chats permission (chats:read).
GET
/
chats
List chats
curl --request GET \
--url https://app.cassidyai.com/api/admin/v1/chats \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.cassidyai.com/api/admin/v1/chats"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.cassidyai.com/api/admin/v1/chats', 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://app.cassidyai.com/api/admin/v1/chats",
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: Bearer <token>"
],
]);
$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://app.cassidyai.com/api/admin/v1/chats"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.cassidyai.com/api/admin/v1/chats")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.cassidyai.com/api/admin/v1/chats")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"nextCursor": "<string>",
"chats": [
{
"id": "<string>",
"name": "<string>",
"agent": {
"id": "<string>",
"name": "<string>"
},
"user": {
"id": "<string>",
"name": "<string>",
"email": "<string>"
},
"source": "web",
"isTestChat": true,
"createdAt": "<string>",
"lastActivityAt": "<string>",
"credits": 123
}
]
}{
"code": "BAD_REQUEST",
"message": "Invalid input data",
"issues": []
}{
"code": "UNAUTHORIZED",
"message": "Authorization not provided",
"issues": []
}{
"code": "FORBIDDEN",
"message": "Insufficient access",
"issues": []
}{
"code": "NOT_FOUND",
"message": "Not found",
"issues": []
}{
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit exceeded. Retry after the Retry-After interval."
}{
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"issues": []
}Query Parameters
Only include Agents that use these models, such as claude-opus-5-5, including the built-in model's own Agent. Agents count as the model they use today, so changing an Agent's model moves its past usage too. Thinking levels are combined. Pass several as a comma-separated list.
Maximum array length:
20