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:
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}"
REQUIRED: Bearer token authentication using your API key. Format: 'Bearer sk_xxxxxxxxxxxxx'. You can create API keys in the Mixpeek dashboard under Organization Settings.
REQUIRED: Namespace identifier for scoping this request. All resources (collections, buckets, taxonomies, etc.) are scoped to a namespace. You can provide either the namespace name or namespace ID. Format: ns_xxxxxxxxxxxxx (ID) or a custom name like 'my-namespace'
Session ID
Maximum messages to return
1 <= x <= 200Pagination offset
x >= 0Successful Response
Response for retrieving conversation history.
Attributes: session_id: Session identifier messages: List of messages in chronological order total_messages: Total number of messages in session returned_messages: Number of messages returned (may be limited) has_more: Whether there are more messages available
Example:
python response = GetHistoryResponse( session_id="ses_abc123", messages=[...], total_messages=50, returned_messages=20, has_more=True )