Helium Logo
GET/api/v1/public/threads/{thread_id}/history

Get Conversation History

Retrieve the complete conversation history for a thread. This includes all messages exchanged between you and the AI agent.

Request

curl -X GET \
"https://api.he2.ai/api/v1/public/threads/thread_456/history?project_id=proj_123" \
-H "X-API-Key: he-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

Path Parameters

ParameterTypeDescription
thread_idstring (required)The thread ID

Query Parameters

ParameterTypeDescription
project_idstring (required)Project ID
pageinteger (optional)Page number (default: 1)
page_sizeinteger (optional)Messages per page (1-1000, default: 100)
include_file_contentboolean (optional)Include file content (default: false)
include_status_messagesboolean (optional)Include status messages (default: false)
compactboolean (optional)Return minimal fields (default: false)

Response

{
"success": true,
"thread_id": "thread_456",
"messages": [
{
"message_id": "msg_1",
"role": "user",
"content": "Create a website",
"created_at": "2024-01-01T10:00:00Z"
},
{
"message_id": "msg_2",
"role": "assistant",
"content": "Here is your website...",
"created_at": "2024-01-01T10:00:30Z",
"has_code": true,
"has_files": true
}
],
"pagination": {
"current_page": 1,
"total_pages": 1,
"has_next": false
}
}