Skip to content

Conversation

Open in ChatGPT Open in Claude

Manage a user’s conversations with your agent: fetch and search them, pin the important ones, and rename, delete, or select a conversation by ID.

Fetch conversations with pagination, search, and filtering.

foldspace.agent('AGENT_NAME').getConversations({
pagination: { pageNumber: number, pageSize: number },
search: { value: string },
filters: { pinned: boolean }
});
ParameterTypeDescription
pagination.pageNumbernumberPage to fetch.
pagination.pageSizenumberNumber of conversations per page.
search.valuestringFilter conversations by search term.
filters.pinnedbooleanWhen set, restrict results by pinned state.

Get the name (title) of a conversation by ID.

foldspace.agent('AGENT_NAME').getConversationName('CONVERSATION_ID');

pinConversation(conversationId) / unpinConversation(conversationId)

Section titled “pinConversation(conversationId) / unpinConversation(conversationId)”

Pin or unpin a conversation by ID.

foldspace.agent('AGENT_NAME').pinConversation('CONVERSATION_ID');
foldspace.agent('AGENT_NAME').unpinConversation('CONVERSATION_ID');

renameConversation(conversationId, name) / deleteConversation(conversationId)

Section titled “renameConversation(conversationId, name) / deleteConversation(conversationId)”

Rename or delete a conversation by ID.

foldspace.agent('AGENT_NAME').deleteConversation('CONVERSATION_ID');
foldspace.agent('AGENT_NAME').renameConversation('CONVERSATION_ID', 'NEW_NAME');

Make a conversation the active one by ID.

foldspace.agent('AGENT_NAME').selectConversation('CONVERSATION_ID');