Get conversation history and document state for a specific session.
Returns the full message history (user and AI messages), current document HTML content, document version, chunk count, and attachment list. Use this to restore a previous session or inspect what changes were made.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Successful Response
Conversation history with document state and restoration instructions.
Session identifier.
Ordered list of messages. Each item has: id (string), sender ('user' or 'ai'), content (string), timestamp (ISO 8601), turn_index (int).
Current document state. Present if the session has an active document.
Frontend instruction: 'update' (load document_state HTML into editor), 'clear' (reset editor), or 'keep' (no change).