Heidi API
Ask Heidi

Ask Heidi

Get a response from the Heidi AI Assistant

Method: POST

Path: /sessions/{session_id}/ask-ai

Description: Get a streamed AI response from Heidi.

Request

POST /sessions/1234567890/ask-ai HTTP/1.1
Authorization: Bearer <your_token>
Content-Type: application/json
{
  "ai_command_text": "Summarise the following text",
  "content": "My long paragraph of text",
  "content_type": "MARKDOWN"
}

ai_command_text is the instruction for the Heidi AI Assistant. content is used as context for the AI to generate a response. content_type can be MARKDOWN or HTML.

Response

{ "data": "My " }
{ "data": "summary" }
{ "data": " of the " }
{ "data": "text." }