/v1/definitions/{key}/rows/{rowId}/script/generateGenerate a call script for a record
Builds a call script from one lead's own facts AND SAVES it as that lead's own version — which is what makes the Generate button mean something. Regenerating retires the previous row-scoped version in the same transaction, so the lead's ladder never forks. The answer carries ai_status: disabled and the script is stored as static: no model is wired here, and a static script must never be mistaken for an AI one. Leads page only.
Access class: def:read.
Send request
Use the documented inputs to call this endpoint directly.
Parameters
Values are applied to the request and the example on the right.
Request body
application/jsonrequiredResponses
the action's answer
{
"data": {
"branches": [
{
"children": [
{
"children": [
{
"children": [
{
"children": [
{
"exit": "string",
"id": "",
"say": "string",
"tag": "string",
"trigger": "string"
}
],
"exit": "string",
"id": "",
"say": "string",
"tag": "string",
"trigger": "string"
}
],
"id": "",
"next": "string",
"say": "string",
"tag": "string",
"trigger": "string"
}
],
"exit": "string",
"id": "",
"next": "string",
"say": "string",
"tag": "string",
"trigger": "string"
}
],
"id": "",
"next": "string",
"say": "string",
"tag": "string",
"trigger": "string"
}
],
"brief": {
"headline": "string",
"hooks": [
"string"
],
"key_facts": [
"string"
],
"watch_outs": [
"string"
]
},
"generator": "string",
"id": 1.5,
"source_context": {
"ai_status": "string",
"name": "string",
"resolved_from": "string",
"script_id": 1.5,
"version": 1.5
},
"spine": [
{
"key": "string",
"label": "string",
"purpose": "string",
"say": "string"
}
],
"status": "string"
}
}a refusal: {"error": "<what a person needs to read>"}. 401 no credential, 402 the plan does not include this, 403 the seat does not, 404 the thing does not exist or is not yours to see.
{
"error": "string"
}