POST /api/flow
Generates or edits a Voiceblox flow using Claude. Returns a list of operations to apply to the canvas.Request
| Field | Type | Required | Description |
|---|---|---|---|
messages | ChatMessage[] | ✅ | Conversation history with the AI |
currentGraph | { nodes, edges } | — | Current graph state (SimpleNode[] + SimpleEdge[]) |
webSearchEnabled | boolean | — | Enable web search for the AI generator |
Response
| Field | Type | Description |
|---|---|---|
done | boolean | true when operations are ready; false when AI is asking a question |
message | string | AI response text to display to the user |
operations | EditOperation[] | List of graph operations to apply (only when done: true) |
versionName | string | Short description of the change for the version history |
thinking | string | Claude’s reasoning (extended thinking output) |
Operation types
Error responses
| Status | Description |
|---|---|
400 | Missing messages field |
500 | Anthropic API error or graph validation failure |