v5

OpenAPI 3.1.02026-08-025631,1012.8 MB
Agent Sessions

Get History

Get conversation history for a session.

Returns messages in chronological order (oldest first).

Args: request: FastAPI request with tenant context session_id: Session identifier limit: Maximum messages to return (default: 50, max: 200) offset: Pagination offset (default: 0)

Returns: GetHistoryResponse with message history

Raises: NotFoundError: If session not found

Example: bash curl -X GET "http://localhost:8000/v1/agents/sessions/ses_abc123/history?limit=20&offset=0" \ -H "Authorization: Bearer {api_key}" \ -H "X-Namespace: {namespace_id}"

get/v1/agents/sessions/{session_id}/history

Path parameters

session_idstring required

Session ID

Session ID

Query parameters

limitinteger

Maximum messages to return

Maximum messages to return

offsetinteger

Pagination offset

Pagination offset

Response

Successful Response

session_idstring required

Session identifier

total_messagesinteger required

Total messages in session

returned_messagesinteger required

Messages returned

has_moreboolean required

Whether more messages available