sendAIMessage
POST
/api/v1/ai/conversations/{conversationId}/messages
const url = 'https://example.com/api/v1/ai/conversations/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/messages';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"attachments":[{"execution_id":"example","flow_id":"example","kind":"flow","namespace":"example","path":"example"}],"text":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/ai/conversations/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/messages \ --header 'Content-Type: application/json' \ --data '{ "attachments": [ { "execution_id": "example", "flow_id": "example", "kind": "flow", "namespace": "example", "path": "example" } ], "text": "example" }'Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”conversationId
required
string format: uuid
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
attachments
Array<object>
object
execution_id
Execution UUID.
string
flow_id
Flow ID of a flow.
string
kind
required
string
namespace
Namespace of a flow or a file.
string
path
File path of a file.
string
key
additional properties
any
text
required
string
key
additional properties
any
Responses
Section titled “ Responses ”Events of the turn: text, tool_call, tool_result, pending_action, error and done.
Media typetext/event-stream