Skip to main content

GET /api/v1/chat/history

Returns the full message history for the current chat session.

Authentication​

Optional. Works for both authenticated and anonymous sessions (identified by session cookie).

Request​

No query parameters.

Example​

curl -X GET https://intotes.com/api/v1/chat/history

Response​

200 OK​

{
"messages": [
{
"id": 1,
"sender": "user",
"text": "I have a question about my withdrawal",
"created_at": 1712238000000
},
{
"id": 2,
"sender": "support",
"text": "I can help with that. Could you provide your transaction ID?",
"created_at": 1712238005000
},
{
"id": 3,
"sender": "user",
"text": "It's TXN-12345",
"created_at": 1712238060000
}
]
}

Note: created_at is returned as Unix milliseconds (not ISO 8601). The sender field is "user" or "support".

Errors​

StatusCodeDescription
401—No chat_session_id cookie found
500—Server failed to retrieve history