- A prompt — the whole job, in plain English
- Tools — exactly what it is allowed to do
- Tags — which leads it answers
Goal bots used to be built from stages — step 1, step 2, step 3, each with its
own advance conditions. Stages are gone. The conversation itself is the state: the
bot reads the thread and knows what it has already asked, so there is no step
pointer to get stuck or jump ahead.
Writing the prompt
Write it the way you would brief a new rep. Ordered instructions are fine — the bot follows them without needing a stage machine.Tools
A bot can only use what you give it, so it can never talk about doing something it cannot do.
Only one calendar’s booking tools are ever handed to a bot, so it cannot book into
the wrong calendar when both are connected.
get_lead_details is how the bot picks up context your team already has. Whatever is in a
lead’s Notes — “quoted in March, went quiet”, “only answers after 5pm” — comes back with
it, so the bot works from it instead of asking the lead something you already know. Notes are
treated as internal: the bot uses them for context and does not read them back to the lead.Tags decide who it talks to
includeTags is the trigger. The bot answers a lead carrying any one of them.
excludeTags is the veto — it never answers a lead carrying one of those.
A common pattern is to tag on completion: onDoneTag is applied to the lead once
the bot books, which your CRM workflow can pick up.
Two things the engine enforces on its own
These hold no matter what the prompt says. It cannot book a time the lead was never offered. A booking is refused unless an earlier bot message actually named a clock time. A “yes” to the trial is not a “yes” to a time — the bot has to offer, and the lead has to pick. It cannot book a time the calendar did not return. The requested slot is re-checked against live availability before booking; on a miss the bot is handed the real nearest times so it re-offers instead of inventing one.Saving what the bot learns
A bot can write the answers it gets straight onto the lead. List what you want undercollectFields:
customFields, in the lead’s own words:
collectFields out and nothing is extracted.
Typing indicator
Bots show the typing indicator before replying, because a tool loop makes real calls and checking a calendar can take a few seconds. Turn it off for a particular bot with"typingIndicator": false.
It only works on lines where the Private API is available. Everywhere else it is
skipped regardless of the setting.
Testing before you go live
Create the bot with"status": "paused", then use
Simulate to run it against a
transcript. Nothing is sent — no message, no draft, no notification — and the
response shows which tools actually ran, so a bot that only talks about
checking a calendar is obvious straight away.
When it reads right, PATCH it to active.
API
Goal bots are fully manageable with a workspace API key — prompt, tools, tags, tone, and status. See List Goal Bots to get started./api/goal-bots and /api/tasks are the same API. /api/tasks is the name from
before the engines merged and still works; responses carry both goalBots and
taskAgents keys.