SDK reference · Assistants and evaluation
client.conversations
client.conversations.{ create, send, messages, pause, memories, remember, forget }Each message starts a job that answers it; messages returns the conversation so far.
create
create(input: ConversationCreate, key: string): Promise<Resource>Starts a conversation.
Parameters
keystring- An idempotency key. Retrying with the same key and input returns the first result instead of acting twice.
Returns Promise<Resource>
send
send(id: string, content: string, key: string): Promise<Submission>Sends a message; the reply arrives as a job.
Parameters
keystring- An idempotency key. Retrying with the same key and input returns the first result instead of acting twice.
Returns Promise<Submission>
messages
messages(id: string, after?: number): Promise<Page>Messages after a cursor.
Returns Promise<Page>
pause
pause(id: string, paused: boolean, key: string): Promise<Resource>Pauses or resumes replies.
Parameters
keystring- An idempotency key. Retrying with the same key and input returns the first result instead of acting twice.
Returns Promise<Resource>
memories
memories(id: string): Promise<Page>What the assistant remembers here.
Returns Promise<Page>
remember
remember(id: string, name: string, input: AssistantMemory, key: string): Promise<Resource>Stores or replaces a memory.
Parameters
keystring- An idempotency key. Retrying with the same key and input returns the first result instead of acting twice.
Returns Promise<Resource>
forget
forget(id: string, name: string, key: string): Promise<Resource>Deletes a memory.
Parameters
keystring- An idempotency key. Retrying with the same key and input returns the first result instead of acting twice.
Returns Promise<Resource>