Skip to main content
Updated Nov 27, 2026

Watch and wake the agent

Action type: actions/monitors/create.

Use this action when an agent (or workflow) needs to be woken up later — when a document changes, at a point in time, or when something outside AutoTalk reaches a state you care about.

A monitor is something AutoTalk watches for you, plus a reminder note. The step returns immediately with a monitorId; when a check matches, AutoTalk posts a monitor event to the conversation and the agent can continue through the normal message pipeline. Its history is bounded by the context budget and may be trimmed. The event replays your note as a reminder for the next run.

In the editor​

In the action picker it is under Monitors and notifications, as "On a record change, at a time, or when a tool says so". In the flow, a step reads like: Wake the agent in 30 minutes, or Run the tool check_tickets and wake the agent when data.tickets.size() > 0.

Under What it does:

  1. Wake the agent when: A record changes (checked about once a minute), A time comes (a reminder, once) or A tool says so (one of the agent's tools, run again and again). Only the chosen kind's settings show; another kind's settings that still hold something stay in view, with a note that the step still reads them.
  2. For A record changes: Watch a record of the kind … (Kind of record), and Which record: the record's id, usually data from an earlier step (Data or Expression, with Insert data).
  3. For A time comes: Wake the agent in … (a number and a unit), or Or at a date and time. A reminder needs one of the two; the date and time wins when both are set, and a time 7 days away or later is refused.
  4. For A tool says so: Tool (one of the agent's own tools, by name; it must only read, have 5 steps at most and have an output), Run the tool every … (every 5 minutes if empty; never more often than every 5 minutes, nor less often than once a day), What the tool is given (the tool's inputs, each a single value: Add an input) and Agent that has the tool (empty means the agent running this step).
  5. Wake the agent when this is true: the condition, written as an expression. For a record it reads the record as doc; for a tool it reads output, outputText, data and steps. If it cannot be worked out three times in a row, the monitor stops without waking the agent, and the company's owner and admins are notified.
  6. Note for the agent: the reminder the agent gets, word for word, when it is woken (Text or Expression, with Insert data; 2,000 characters at most).
  7. In which conversation: Conversation. Empty means the conversation this run is in. A run with no conversation of its own, like a workflow's, needs one here: without it the step fails.
  8. Give up after …: 24 hours if empty, 7 days at most. After that the monitor ends without waking the agent.

Later steps can read:

  • Monitor ID (monitorId): The id of the new monitor. A "Cancel a monitor" step takes it.
  • Monitor state (monitorState): The monitor's state when it was made: armed.
  • Expires at (expiresAtIso): The date and time the monitor gives up without waking the agent.
  • Succeeded: Yes when this step did not fail.

Every step also has This step runs, If this step fails, the run, Edit as fields, View as JSON and Done: see The step editor.

Earlier name: Create monitor.

Best for​

  • Delivering the result of a long job (a transcription, a transcode) into the same conversation when it finishes — without polling
  • "Remind me in 30 minutes" style self-wakes
  • Watching something outside AutoTalk — a ticket status, a price, an external job — by re-running one of the agent's own read-only tools on a schedule

The three kinds of monitor​

Watch typeWatchesWake latencyNeeds
dynadata_docOne of your company's documents (e.g. a transcription_jobs row, or a ct: custom type document) until a CEL condition over it holdsExpedited checks after transcription/transcode completion; periodic sweeps for other changes. Checks may queue, fail or retry; latency is not guaranteeditemType + itemId + condition
timeThe clockThe next sweeper minute after fireAtfireAt or delayMinutes
agent_toolThe result of one of the agent's own tools, re-run on a scheduleThe first poll whose condition holds — polls run at intervalMinutes (minimum 5)toolName + condition (+ toolArgs, intervalMinutes)

Use a record monitor (dynadata_doc) for data AutoTalk owns. A transcription job, transcode job or company document can use dynadata_doc; completion can request an expedited check. agent_tool polls on a schedule and is intended for external data read through an agent tool. Keep credentials in the tool's step configuration, not the prompt. All checks can queue, fail or retry.

Main fields​

The step's own fields, behind Edit as fields and in the API and MCP:

FieldWhat it does
watchTypeCEL resolving to dynadata_doc, time, or agent_tool
itemType / itemIddynadata_doc only: the watched document's type and _id (e.g. workflow.step(0).jobId). Only tenant-readable published types and ct: custom types can be watched
conditionA native CEL descriptor {expr: "..."} (not evaluated at create time — only parse-checked) the sweeper evaluates later. For dynadata_doc it runs over doc (the watched document); for agent_tool see the arena below
fireAt / delayMinutestime only: when to fire — an ISO datetime, or minutes from now
agentId / toolName / toolArgsagent_tool only: which tool to re-run. agentId defaults to the agent running the step; toolName must be unique on that agent (a duplicate name is refused rather than guessed); toolArgs is an object of scalar arguments checked against the tool's declared parameters at create time
intervalMinutesagent_tool only: how often to poll. Clamped to 5–1440 and jittered — never faster than 5 minutes
noteYour reminder, replayed verbatim in the wake. Write what the agent should do when the monitor wakes it
conversationIdWhich conversation to wake. Defaults to the conversation the run is in — a workflow run has no conversation, so workflow steps must set it
ttlMinutesHow long the monitor stays armed. Default 1440 (24 h), maximum 10080 (7 days). Past it the monitor expires without firing

What later steps can use​

  • workflow.step(N).monitorId — the armed monitor's id (poll it via the read-only monitors data type)
  • workflow.step(N).monitorState — armed at create time
  • workflow.step(N).expiresAtIso — when the monitor gives up without waking the agent

Writing the condition​

A missing field is an evaluation error. An unguarded condition such as doc.outputs.txt != '' fails while outputs or txt is absent and counts toward the evaluation-failure limit. Three consecutive failures stop the monitor with error and notify the company's owner and admins. To keep waiting for optional data, use a presence guard such as has(doc.status) && doc.status == 'ready', or read a safe default: maps.get(doc, 'outputs.txt', '') != ''. A condition that successfully evaluates to false keeps the monitor armed.

For dynadata_doc, the condition sees doc — the watched document.

For agent_tool, the condition sees the tool's own declared output:

VariableWhat it is
outputThe tool's rendered output.main result
outputTextThe same, always as a string
dataThe tool output parsed as JSON, when it is a JSON object or array — otherwise null. Parsed from the full output before the display truncation, so data stays usable even when outputText is cut
stepsPer-step {ok, status, error} — ok is true for a completed step whose HTTP status, if it has one, is 2xx
nowThe evaluation time

Example: data.atingiu == true, or steps[0].status == 200. Per-step payloads are deliberately not exposed — the condition sees only what the tool's own output.main projects, and the watched tool must declare an output.main (a tool without one is refused: its condition could never become true).

The condition descriptor is stored without evaluating it at creation; its runtime arena includes declared bindings. Put the moving part in toolArgs instead and have the tool compute the verdict — for example a limite parameter the tool compares against, so the condition is just data.atingiu == true.

What a watched tool may do​

An agent_tool monitor re-runs the tool headless — no model, no conversation, unattended, for up to seven days. So the tool may only read:

  • Every step must be a read-only action (HTTP request, find/search/count records, load variables). Anything that writes data, sends messages, spends money, or mints credentials is refused — at create time and re-checked on every poll.
  • At most 5 steps, and the whole tool must finish within 25 seconds per poll — a tool that is fine as an LLM tool (an HTTP step alone allows 120 s) can exceed that as a monitor; three consecutive overruns end the monitor.
  • A step that answers with an HTTP 4xx/5xx counts as completed data (steps[i].ok false, status set) and the monitor keeps polling — so a condition can watch for recovery. A poll counts toward the error strikes only when a step cannot run at all (DNS failure, connection refused, timeout) and no step in the chain completed — one completed step means the poll parks as not-met instead. To detect a persistently failing later step, put steps[i].ok into your condition.

Editing the watched tool ends the monitor​

The monitor records a fingerprint of the tool's executable surface in the version the agent runs, as it was when armed — its name, parameters, steps, and output expression. If any of those change, or the tool is removed or duplicated by name, the monitor stops at its next check, with a notification to the company's owner and admins — it does not silently keep running an older version, and it does not guess between two tools with the same name. Once the agent has been published, a saved edit changes only the draft: the monitor ends when a version with the changed tool goes live. Cosmetic edits (the description, hiding the tool) do not end the monitor. Re-arm after publishing behavioral changes.

Limits​

  • 10 armed monitors per conversation, 50 per account, and 10 armed agent_tool monitors per account (each one is a recurring poll). A monitor you no longer need can be canceled with Cancel a monitor — canceling frees its armed slot immediately
  • 20 fires per conversation per day — every fire is a billable agent run; a monitor that hits the cap takes the error path rather than resuming the next day
  • A run that was itself woken by a monitor may arm one more monitor (depth 1); chaining further is refused, so monitor → wake → monitor → wake loops cannot run away
  • Three consecutive evaluation failures flip the monitor to error and notify the company's owner and admins

Tips​

  • End the run normally after arming — send the user an interim reply ("I'll get back to you when it's ready"). The wake continues the conversation later with history retained within its context budget; the monitor is how you stop polling, not another thing to wait on.
  • The wake arrives as a monitor event message carrying your note and a snapshot of what matched. Add a system prompt telling the agent how to treat these events — see Async wakes.
  • Read the create result via workflow.step(N).monitorId, not workflow.step(N).status — status is reserved for HTTP status codes.