Skip to main content
POST
/
workflows
/
{id}
/
chat
/
messages
curl --request POST \
  --url http://localhost:5173/api/flowdrop/workflows/{id}/chat/messages \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "message": "Add a processing node called \"transform\"",
  "workflowState": {
    "nodes": [],
    "edges": []
  }
}
'
{
  "success": true,
  "data": {
    "content": "I'll add a processing node and connect it to your start node.\n\n```flowdrop\nadd transform processing\nconnect start:output transform:input\n```\n",
    "conversationId": "conv-abc123"
  }
}

Authorizations

Authorization
string
header
required

JWT token for authentication

Path Parameters

id
string
required

Workflow ID

Body

application/json

Request payload for sending a chat message

message
string
required

The user's natural language message

Example:

"Add a node called \"transform\" and connect it to the start node"

workflowState
object
required

Serialized current workflow state including nodes and edges. This gives the LLM context about the current workflow being edited.

history
object[]

Optional conversation history for multi-turn context

Response

Chat response with LLM-generated content

Wrapped response for chat message send

success
boolean
Example:

true

data
object

Response from the chat endpoint containing the LLM's reply. The content may include markdown formatting and fenced code blocks with DSL commands (```flowdrop blocks).