Skip to main content
GET
https://api.trillet.ai
/
v2
/
api
/
active-calls
List Active Calls
curl --request GET \
  --url https://api.trillet.ai/v2/api/active-calls \
  --header 'x-api-key: <api-key>' \
  --header 'x-workspace-id: <x-workspace-id>'
{
  "data": [
    {
      "id": "665a1b2c3d4e5f6a7b8c9d0e",
      "roomName": "call-abc123",
      "customerPhone": "+14155551234",
      "customerName": "John Doe",
      "aiAgentName": "Customer Support Agent",
      "duration": 145,
      "status": "active",
      "sentiment": "positive",
      "lastMessage": "Sure, I can help you with that!",
      "transferRequested": false,
      "type": "phone",
      "participants": [
        {
          "identity": "agent-001",
          "isAgent": true,
          "joinedAt": "2024-06-01T10:00:00.000Z"
        },
        {
          "identity": "customer-001",
          "isAgent": false,
          "joinedAt": "2024-06-01T10:00:01.000Z"
        }
      ]
    }
  ],
  "count": 1,
  "timestamp": "2024-06-01T10:02:25.000Z"
}

Headers

x-api-key
string
required
API key used for authenticating requests to the API.
x-workspace-id
string
required
Workspace identifier for the API.

Response Fields

data
array
Array of active call objects.
id
string
Unique identifier for the active call.
roomName
string
The LiveKit room name for the call.
customerPhone
string
Customer’s phone number.
customerName
string
Customer’s name if available.
aiAgentName
string
Name of the AI agent handling the call.
duration
number
Current call duration in seconds.
status
string
Call status (always “active” for this endpoint).
sentiment
string
Current detected sentiment of the conversation.
lastMessage
string
The most recent message in the conversation.
transferRequested
boolean
Whether a transfer to a human agent has been requested.
type
string
Call type: “phone” or “web”.
participants
array
Array of call participants.
count
number
Total number of active calls.
timestamp
string
Server timestamp of the response.
{
  "data": [
    {
      "id": "665a1b2c3d4e5f6a7b8c9d0e",
      "roomName": "call-abc123",
      "customerPhone": "+14155551234",
      "customerName": "John Doe",
      "aiAgentName": "Customer Support Agent",
      "duration": 145,
      "status": "active",
      "sentiment": "positive",
      "lastMessage": "Sure, I can help you with that!",
      "transferRequested": false,
      "type": "phone",
      "participants": [
        {
          "identity": "agent-001",
          "isAgent": true,
          "joinedAt": "2024-06-01T10:00:00.000Z"
        },
        {
          "identity": "customer-001",
          "isAgent": false,
          "joinedAt": "2024-06-01T10:00:01.000Z"
        }
      ]
    }
  ],
  "count": 1,
  "timestamp": "2024-06-01T10:02:25.000Z"
}