Retrieve all messages sent within a conversation of an agent (formerly known as project) identified by its unique projectId and sessionId. This endpoint allows you to retrieve a collection of messages exchanged in a specific conversation. Messages contain the content, timestamps, and other relevant information shared during the course of the conversation. By providing the projectId and sessionId, you can access all the messages associated with that particular conversation within the agent context. Here is an example to retrieve messages of a conversation: API SDK.
Purpose
Retrieve all messages sent within a conversation of an agent (formerly known as project) identified by its unique projectId and sessionId.
This endpoint allows you to retrieve a collection of messages exchanged in a specific conversation. Messages contain the content, timestamps, and other relevant information shared during the course of the conversation.
By providing the projectId and sessionId, you can access all the messages associated with that particular conversation within the agent context.
Here is an example to retrieve messages of a conversation: API SDK.
At a high level, this is the canonical way to work with conversations and messages between users and the agent via the CustomGPT API.
When to use
- When you need to retrieve messages that have been sent in a conversation as part of your backend or automation workflows.
- To retrieve the full message history for a thread so you can render it in your own chat UI or audit views.
