Endpoint
Overview
Retrieve the chat conversation history for a specific user and optional session. Returns all messages exchanged between the user and AI agents.Chat history is automatically persisted to the database for all conversations. Sessions can be used to organize related conversations.
Request Parameters
Unique identifier for the user whose history to retrieve
User ID whose data was queried (for help-ask feature). Defaults to
user_id.Optional session ID to filter by specific conversation thread
Maximum number of messages to return (max: 100)
Number of messages to skip (for pagination)
Response Format
Message Object
| Field | Type | Description |
|---|---|---|
msg_id | string | Unique message identifier |
role | string | user or assistant |
content | string | Message text content |
timestamp | string | ISO 8601 timestamp |
session_id | string | Session identifier |
file_list | array | Attached files (user messages only) |
agent | string | Agent used (assistant messages only) |
provider | string | LLM provider (assistant messages only) |
model | string | Model name (assistant messages only) |
tool_calls | array | MCP tool calls made (assistant messages only) |
Additional Endpoints
Get Session List
Delete History
For shared sessions (help-ask feature), use
/api/history_by_person endpoint to retrieve conversations where you helped another user.