Conversations are the persistent thread containers for all user–assistant exchanges in NISIRA Assistant. Each conversation is identified by a randomly generated 11-character URL-safe slug that hides the internal numeric primary key. All four endpoints require a valid JWT Bearer token and scope every operation to the authenticated user — users cannot access or modify conversations that belong to other accounts.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/HugoX2003/nisira-assistant/llms.txt
Use this file to discover all available pages before exploring further.
GET /api/conversations/
Returns a paginated list of conversations belonging to the authenticated user, ordered by most-recently-updated first.Query Parameters
Page number, 1-indexed.
Number of conversations per page. Clamped to the range [1, 100].
Response
Array of conversation summary objects.
Current page number.
Page size used for this response.
Total number of conversations owned by the user.
true if there are additional pages beyond the current one.Example
POST /api/conversations/create/
Creates a new, empty conversation for the authenticated user.Request Body
Optional display title for the conversation. If omitted, the backend generates a default title based on the current date and time (e.g.,
"Conversación 10/11/2024 14:22").Response
The new conversation’s slug. Use this as
conversation_id when sending the first message.Legacy numeric primary key.
URL-safe 11-character random slug (same as
id).The conversation title that was saved.
ISO 8601 creation timestamp.
Confirmation message:
"Conversación creada exitosamente".Example
GET /api/conversations/<conversation_id>/messages/
Returns paginated messages for a specific conversation. Page 1 returns the 15 most recent messages in ascending chronological order (oldest first within the page). Page 2 returns the 15 messages before those, also in ascending order — this design supports infinite-scroll history loading from the bottom of the chat window.The
conversation_id path parameter accepts either the slug (preferred, e.g., aB3dEfGhIjK) or the legacy numeric ID (e.g., 47). The backend detects which format is being used automatically.Query Parameters
Page number. Page 1 is the most recent batch of messages.
Number of messages per page. Clamped to the range [1, 100].
Response
The conversation slug.
The conversation’s display title.
Ordered array of message objects (ascending by creation time within the page).
Total number of messages in the conversation.
true if older pages of messages exist beyond the current page.Example
DELETE /api/conversations/<conversation_id>/delete/
Permanently deletes a conversation and all of its messages. This operation is irreversible — allMessage records are deleted via CASCADE, and any associated Rating records are also removed.
Response
Confirmation string:
"Conversación eliminada exitosamente".