Conversation history for Mesa de Ayuda IA is persisted in PostgreSQL across two tables:Documentation Index
Fetch the complete documentation index at: https://mintlify.com/geremyjampiersalasgarcia-eng/Caso_Practico_Semillero_IA/llms.txt
Use this file to discover all available pages before exploring further.
conversations (session metadata — UUID, title, timestamps) and messages (individual turns, including role, content, attached image data, RAG sources, and the agents that answered). These three endpoints allow the Next.js frontend — and any other API client — to retrieve, display, and manage chat sessions. Messages within a conversation are always returned sorted by created_at ascending so they appear in chronological order regardless of insertion order.
GET /api/v1/conversations/
Returns a paginated list of conversation sessions, ordered by most recently updated.Query Parameters
Number of conversations to skip (offset for pagination).
Maximum number of conversations to return. Reduce this value when displaying a shorter sidebar list.
Response
Returns an array ofConversationListResponse objects:
| Field | Type | Description |
|---|---|---|
id | string | UUID of the conversation |
title | string | null | Auto-generated title (first message snippet), or null |
updated_at | datetime | ISO 8601 timestamp of the last message in this conversation |
Example
GET /api/v1/conversations/
Returns the full detail of a single conversation, including all messages sorted bycreated_at.
Path Parameters
The UUID of the conversation to retrieve. Returns HTTP 404 if no conversation with that ID exists.
Response
Returns aConversationDetailResponse object:
| Field | Type | Description |
|---|---|---|
id | string | UUID of the conversation |
title | string | null | Auto-generated title or null |
created_at | datetime | ISO 8601 timestamp when the conversation was created |
updated_at | datetime | ISO 8601 timestamp of the last activity |
messages | MessageResponse[] | Ordered array of all messages in the conversation |
MessageResponse in the messages array contains:
| Field | Type | Description |
|---|---|---|
id | string | UUID of the message |
role | "user" | "assistant" | Who authored the message |
content | string | The text of the message |
image_data | string | null | Base64 image attached to this message, or null |
sources | object[] | RAG source documents used to generate this assistant message |
agents_used | string[] | Agents that contributed to this assistant message |
created_at | datetime | ISO 8601 timestamp when this message was stored |
Example
DELETE /api/v1/conversations/
Permanently deletes a conversation and all of its messages from PostgreSQL.Path Parameters
The UUID of the conversation to delete. Returns HTTP 404 if the conversation does not exist.
Response
Returns HTTP 200 with a confirmation message on success:Example
The
meta.conversation_id returned by every POST /chat/ response is the same UUID used by these endpoints. Pass it back in the conversation_id field of subsequent chat requests to maintain context across multiple turns — the backend will load the stored message history from PostgreSQL and inject it into the agent prompts automatically.