Skip to main content

Send Message

POST 

/v1/conversations

Send a message to an AI agent and receive a response.

Creates a new conversation if conversation_id is not provided, or continues an existing conversation. Supports both streaming and non-streaming responses.

Streaming Mode (stream: true):

  • Returns text/event-stream content type
  • Real-time Server-Sent Events (SSE)
  • Event types include:
    • metadata: Initial message metadata
    • conversation_created: New conversation info (if created)
    • thought_chunk: Agent's reasoning process
    • tool_call: Tool invocation details
    • tool_intervention_required: Approval requested for a tool call
    • tool_intervention_resolution: Result of the approval decision
    • tool_output: Tool execution results
    • message: Response content chunks
    • close: Stream completion signal

Non-Streaming Mode (stream: false or omitted):

  • Returns application/json content type
  • Complete response with full message content
  • Includes conversation_id and message_id

Optional Parameters:

  • collection_id: Reference documents from a specific collection
  • uploads: List of file upload metadata for live file uploads (document IDs from KMS)
  • is_incognito: Private mode (not saved to history)
  • message_only: Return only message content without thoughts/steps
  • run_in_background: Return HTTP 202 immediately and finish processing in-process
  • bypass_tool_approval: Automatically approve eligible tools (default: true). Set to false to require approval.

Request​

Responses​

Successful response. Returns JSON for non-streaming or Server-Sent Events for streaming requests.