Skip to main content

Conversations

SDK methods for the Conversations module, accessed via soat.conversations. See the Conversations module docs for permissions and data model, and each method's REST page for the full request/response schema.

soat.conversations.listConversations()

List conversations

  • Method: GET
  • Path: /api/v1/conversations
await soat.conversations.listConversations({
query: { /* + optional */ },
});

Request & response schema

soat.conversations.createConversation()

Create a conversation

  • Method: POST
  • Path: /api/v1/conversations
await soat.conversations.createConversation({
body: { /* + optional */ },
});

Request & response schema

soat.conversations.getConversation()

Get a conversation by ID

  • Method: GET
  • Path: /api/v1/conversations/{conversation_id}
await soat.conversations.getConversation({
path: { conversation_id },
});

Request & response schema

soat.conversations.updateConversation()

Update a conversation

  • Method: PATCH
  • Path: /api/v1/conversations/{conversation_id}
await soat.conversations.updateConversation({
path: { conversation_id },
body: { /* + optional */ },
});

Request & response schema

soat.conversations.deleteConversation()

Delete a conversation

  • Method: DELETE
  • Path: /api/v1/conversations/{conversation_id}
await soat.conversations.deleteConversation({
path: { conversation_id },
});

Request & response schema

soat.conversations.listConversationMessages()

List conversation messages

  • Method: GET
  • Path: /api/v1/conversations/{conversation_id}/messages
await soat.conversations.listConversationMessages({
path: { conversation_id },
query: { /* + optional */ },
});

Request & response schema

soat.conversations.addConversationMessage()

Add a message to a conversation

  • Method: POST
  • Path: /api/v1/conversations/{conversation_id}/messages
await soat.conversations.addConversationMessage({
path: { conversation_id },
body: { message, role, /* + optional */ },
});

Request & response schema

soat.conversations.generateConversationMessage()

Generate the next message in a conversation

  • Method: POST
  • Path: /api/v1/conversations/{conversation_id}/generate
await soat.conversations.generateConversationMessage({
path: { conversation_id },
body: { agent_id, /* + optional */ },
});

Request & response schema

soat.conversations.removeConversationMessage()

Remove a message from a conversation

  • Method: DELETE
  • Path: /api/v1/conversations/{conversation_id}/messages/{document_id}
await soat.conversations.removeConversationMessage({
path: { conversation_id, document_id },
});

Request & response schema

soat.conversations.getConversationTags()

Get conversation tags

  • Method: GET
  • Path: /api/v1/conversations/{conversation_id}/tags
await soat.conversations.getConversationTags({
path: { conversation_id },
});

Request & response schema

soat.conversations.replaceConversationTags()

Replace conversation tags

  • Method: PUT
  • Path: /api/v1/conversations/{conversation_id}/tags
await soat.conversations.replaceConversationTags({
path: { conversation_id },
body,
});

Request & response schema

soat.conversations.mergeConversationTags()

Merge conversation tags

  • Method: PATCH
  • Path: /api/v1/conversations/{conversation_id}/tags
await soat.conversations.mergeConversationTags({
path: { conversation_id },
body,
});

Request & response schema