Skip to content

Generate Column

POST
/api/v2/workbooks/{workbook_id}/generate-column
curl --request POST \
--url http://localhost:8000/api/v2/workbooks/example/generate-column \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "instruction": "example" }'

NL → column generator: turn an instruction into a validated, ready-to-add column config (formula / ai_formula / http). Does NOT add the column.

workbook_id
required
Workbook Id
string
x-workspace-id
Any of:
string
Media typeapplication/json
GenerateColumnRequest

NL → column generator: natural-language instruction to turn into a column.

object
instruction
required
Instruction

E.g. ‘extract the domain from the website URL’

string
>= 3 characters <= 2000 characters
Examplegenerated
{
"instruction": "example"
}

Successful Response

Media typeapplication/json
GenerateColumnResponse

A validated, ready-to-add column config generated from an instruction.

object
column
required
ColumnConfig

Configuration for a single workbook column.

object
channels
Any of:
object
key
additional properties
any
condition
Any of:
string
destination
Any of:
string
destination_config
Any of:
object
key
additional properties
any
formula
Any of:
string
http_body
Any of:
Http Body

Request body template (dict/str) for POST/PUT

http_extract
Any of:
string
http_headers
Any of:
object
key
additional properties
any
http_method
Any of:
string
http_url
Any of:
string
icp
Any of:
object
key
additional properties
any
id
required
Id

Unique column identifier

string
input_columns
Any of:
Array<string>
lead_field
Any of:
string
max_steps
Any of:
integer
name
required
Name

Display name

string
output_format
Any of:
string
prompt
Any of:
string
provider
Any of:
string
target_field
Any of:
string
target_rows
Any of:
integer
type
Type

Column type: lead_field, enrichment, waterfall, ai_formula, conditional, output

string
default: lead_field
verify
Any of:
boolean
waterfall
Any of:
Array<string>
width
Width

Column width in pixels

integer
default: 200
explanation
Explanation
string
""
kind
required
Kind
string
Allowed values: formula ai_formula http
Example
{
"column": {
"type": "lead_field",
"width": 200
},
"explanation": "",
"kind": "formula"
}

Validation Error

Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
ctx
Context
object
input
Input
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
Examplegenerated
{
"detail": [
{
"ctx": {},
"input": "example",
"loc": [
"example"
],
"msg": "example",
"type": "example"
}
]
}