Skip to main content
POST
Draft a workflow from a description

Authorizations

Authorization
string
header
required

An API key from Settings → API keys, sent as Authorization: Bearer kb_live_…. A workspace key starts kb_; a personal key starts kbp_ and acts as its owner.

Headers

Kallabot-Version
enum<string>

The API version to answer as, a date (YYYY-MM-DD). Leave it out for the current version (2026-11-07). An unknown version is refused with 400 unsupported_api_version.

Available options:
2026-11-07
Example:

"2026-11-07"

Body

application/json
prompt
string
default:""

What the workflow should do, in plain words. May be empty when refining (draft_id + feedback).

Maximum string length: 2000
draft_id
string | null

Refine this earlier draft instead of starting a new one.

Maximum string length: 64
Pattern: ^wfd_[A-Za-z0-9_\-]{8,40}$
feedback
string | null

With draft_id: what to change ("also email me").

Maximum string length: 2000

Response

Successful Response

draft_id
string
required

Kept for 24 hours: refine it or create it.

name
string
required

The workflow's name.

summary
string
required

What it does, in two plain sentences.

trigger
DraftTrigger · object
required

What starts it.

steps
DraftStep · object[]
required

Its steps, in order (branch and loop steps included).

needs
DraftNeed · object[]
required

Apps it needs connected.

questions
string[]
required

Anything ambiguous the owner should answer. May be empty.