Get a chat

SDK platic.chat.get()

Read a chat's current state and full history. The response uses the detail format from Get a conversation (V1).

Example

await platic.chat.get("chat_123");

Path parameters

ParameterTypeDescriptionRequired
idstringUnique chat ID, returned when you create or list chats.✓

Query parameters

ParameterTypeDescriptionRequired
workspacestringOnly if the credential covers several workspaces: the chat's workspace. Required in that case—

Response

{
  "status": "success",
  "data": {
    "id": "conversation_doc_01JCHAT",
    "conversationId": "chat_01JCHAT23456789",
    "clientId": "client_123",
    "agentId": "agent_01JABCDEF23456789",
    "canSendDirectMessage": true,
    "workspaceId": "ws_001",
    "channelId": "workspace-ws_001-agent-agent_01JABCDEF23456789",
    "contactName": "Ana López",
    "phoneNumber": "5215512345678",
    "topic": "Plan selection",
    "platform": "platica",
    "source": "api_chat",
    "status": "active",
    "operation": "automatic",
    "messageCount": 2,
    "owners": ["sales@acme.com"],
    "tags": ["prospect"],
    "creationDate": "2026-07-20T18:00:00.000Z",
    "lastUpdate": "2026-07-20T18:30:00.000Z",
    "messages": [
      {
        "id": "msg_user_01JCHAT98765432",
        "role": "user",
        "content": "Help me choose the right plan for my team.",
        "contentType": "text",
        "direction": "incoming",
        "status": "received",
        "creationDate": "2026-07-20T18:29:40.000Z"
      },
      {
        "id": "msg_assistant_01JCHAT98765433",
        "role": "assistant",
        "content": "For a team of 25 people using WhatsApp, these are the best options...",
        "contentType": "text",
        "direction": "outgoing",
        "status": "delivered",
        "creationDate": "2026-07-20T18:30:00.000Z"
      }
    ]
  }
}
FieldDescription
idUnique, canonical ID of the document
conversationIdThread ID (chat_*). It does not identify the contact
clientIdContact the chat is attributed to
agentIdMain agent; a temporary delegation to a subagent does not change it
canSendDirectMessageAlways true in Platica internal chats
workspaceIdID of the chat's workspace
channelIdID of the internal channel
contactNameName of the contact
phoneNumberThe contact's phone number, when there is one
topicTopic or subject of the chat
platformPlatform; for these chats it is platica
sourceAlways api_chat
statusChat state: active, finished or expired
operationOperation mode
messageCountNumber of messages in messages
ownersList of emails of the responsible users
tagsAssociated tags
creationDateCreation date, ISO 8601
lastUpdateLast update date, ISO 8601
messagesFull message history of the chat, in chronological order
FieldDescription
idUnique ID of the message
roleSender role: user (the contact), assistant (agent/AI), tool (tool calls and their results) or event (system events, such as the start of the conversation). To display the conversation, use only user and assistant
contentContent of the message
contentTypeContent type: text, image, audio, etc.
directionMessage direction: incoming, outgoing, or null when it does not apply
statusMessage status: received, delivered, read, failed
creationDateDate and time the message was created

Errors

Statusdetails.codeWhen
400INVALID_REQUESTThe id is not valid, or the credential covers several workspaces and workspace is missing or is not one of them
401UNAUTHENTICATEDThe credential is missing or not valid
404NOT_FOUNDThere is no API chat with that id in the workspace. A scheduled turn answers 404 until it runs

See Errors for the full shape of an error.