How to add human approval to an agent
When an agent can call tools that change the outside world, you may want a person in the loop before those calls run. Publicus pauses the agent on a sensitive tool call, records a pending request, and waits for someone to approve or deny it. This guide shows you which tool calls pause, where the requests appear, and what happens to the run after a decision.
What gets gated
Section titled “What gets gated”Publicus treats a tool call as sensitive when it can change something outside the flow. The following tools pause for approval before they run:
- Channel sends:
Channel / Slack,Channel / Discord,Channel / Teams,Channel / Telegram,Channel / WhatsApp. - Write API calls:
Rest / OperationandOpenApi / Operationrequests that are not read-only. - MCP server tools: tools exposed through an
Mcp / Toolsnode. - Subflows that wrap a gated node: when a subflow contains any of the tools above, calling it pauses for approval too. Wrapping a sensitive tool in another flow does not bypass the gate.
Read-only tools (lookups, expressions, mapping, and similar) run without pausing. You do not wire anything extra onto the canvas. When an agent decides to call one of the gated tools, Publicus opens an approval request automatically and holds the call until it is resolved.
The list above is what pauses in the default mode. How much stops for you is set by the agent’s approval mode, described next.
Approval modes
Section titled “Approval modes”An agent runs in one of four approval modes, which decide how much of its work stops for you. You choose the mode; the rules for each are fixed, so what pauses is always predictable. There is deliberately no “let the agent decide what is safe” mode — the agent reads untrusted content (fetched pages, tool results), so it is not the thing that should decide when the gate applies.
| Mode | What it does |
|---|---|
| Read-only | The agent can research and plan, but nothing changes — write, delete, and external tools are not even offered to it, except the ones you list under May change things. A web page read stays: it reads the addresses in the message and in its search results, and is refused any other. Use it for an advisor or audit agent, for an agent your customers talk to, or to let a colleague explore safely. |
| Ask first (default) | Every change asks you first. A step’s requests arrive bundled into one card, so you approve a batch of related edits in a single action instead of clicking through them one by one. |
| Auto-write | Reversible changes inside your workspace (building and configuring a flow) run on their own, each recorded. Deletes, starting a run, and anything that leaves your workspace (messages, write API calls) still ask. This is how the AI flow builder ships. |
| Autopilot | The agent acts without asking. A small protected set still stops for you: deleting credentials, filing anything that leaves your workspace, and going live. Every released call is still recorded as an audit trail. |
Where you set the mode
Section titled “Where you set the mode”-
On the agent — the Agent node has an Approval mode setting. This is the authoring default, and the only control for agents triggered headlessly (by a schedule, a webhook, or a chat channel) where no one is watching to approve. Under the setting, the node lists each tool wired to the agent and what the chosen mode does to it: runs, runs and is logged, asks first, is refused, or is not offered at all. When the answer differs between a chat and a run nobody chats in (asking the person, watching a run and following up only message someone or wait in the second), it shows both.
-
Per conversation — in the AI builder chat you can switch the mode for that conversation; it wins over the agent’s default.
-
Per workspace — an administrator can set a default mode and a ceiling: the most permissive mode anyone may choose. Setting the ceiling below Autopilot forbids unattended agents across the whole workspace.


-
Per tool — a tool node’s Approval setting is a three-way pin: inherit the mode, always ask (survives every mode, including Autopilot), or never ask (except the protected set).


Let a Read-only agent make one kind of change
Section titled “Let a Read-only agent make one kind of change”An agent your customers talk to should mostly read, and change only what you chose: create a ticket, say, but never delete one. Set its mode to Read-only and pick those tools under May change things, in the Agent node’s More settings. The picker lists the tools wired to that agent that change something.
- A listed tool still asks for approval before it runs, unless the tool itself is set to never ask. Set both when the agent should create tickets without waiting for you.
- Every tool you did not list stays out of the agent’s reach, so no message can talk it into using one.
- The list is ignored when the workspace’s ceiling is Read-only, and when someone switched a conversation to Read-only: both mean nothing changes.
- Only a person can set the list, in the flow editor. The AI builder is refused if it tries.
Most agents only ever move between Ask first and Auto-write.
Approve once for the rest of a conversation
Section titled “Approve once for the rest of a conversation”When you approve a batch in a chat in the app, you can also tick And allow routine changes for the rest of this conversation: a grant. Later reversible changes in the same conversation then proceed without asking, on your next messages too, each still recorded and pointing back at the grant that released it. Tests, messages and deletes still ask. A grant lasts as long as the conversation’s window (seven days), never covers the protected set or an always-ask tool, and is revocable from the Grants tab of Needs you.


What the agent experiences
Section titled “What the agent experiences”When a gated tool call starts:
- Publicus creates a pending approval request for that exact call, including a preview of the arguments the agent wants to use.
- The run pauses on that call and waits for a decision.
- The run report shows the agent waiting on approval, with the pending request and its decision actions inline.


The argument preview is trimmed and redacted. Values whose names look like secrets (anything containing secret, token, password, key, or auth) are shown as [REDACTED], and long values are truncated, so a reviewer can judge the request without seeing sensitive data.
Find pending requests
Section titled “Find pending requests”Open Needs you, the second row of the sidebar, under Home. It lists the requests still waiting beside everything else that waits on a person, and its amber count tells you at a glance when an agent needs you. You can approve or deny from there. See Needs you.
For every request, decided ones too, open the Approvals tab beside Needs you.


The Approvals table lists each request with:
- Tool: the tool the agent wants to call, and under it what the agent wants to do, in a plain-language line when the agent stated one, otherwise the redacted, truncated arguments.
- Risk: what the call would do, such as Deletes something or Leaves your workspace.
- Status: pending, approved, denied, or expired.
- Undoable: whether saying yes can be taken back.
- Requested: when the agent raised the request, and under it when a waiting request times out if no one decides.
Three more columns are hidden until you turn them on in the column menu: Decision set (requests raised in the same agent step share a set, decided together), Run (the run the request belongs to) and Expires (the timeout as its own column, to sort on).


The table opens on the Waiting view. Destructive narrows it to waiting requests for tools that delete or overwrite, and Decided shows past requests, and so does Expired, which sits in the views menu rather than beside the tabs. The Approvals, policy and grants page describes every column and view.


Pending requests also appear directly on the run report, so you can decide without leaving the page you are watching. See Runs for the report itself.
Approve or deny
Section titled “Approve or deny”Each pending row, in Needs you, in the Approvals table and inline on the run report, has two actions:
-
Approve: confirm the action and let the tool call run. Publicus asks you to confirm, then resolves the request.
-
Deny: block the call. Publicus asks for a reason (required) before it records the denial.


Both actions record who decided and when, alongside the reason for a denial, in the request’s audit trail. Open a request to see its full history on the view page.


By default any user in the workspace can decide. Set AGENT_APPROVALS_APPROVERS=admin to restrict decisions to administrators; the restriction applies everywhere a decision can be made, including the inline actions on the run report.
What happens after a decision
Section titled “What happens after a decision”The agent run reacts to the decision as soon as it lands:
- Approved: the tool call runs with the previewed arguments, and the agent continues with the result.
- Denied: the tool call does not run. The agent is told the tool was denied and keeps going from there, so it can explain the outcome or try a different approach instead of crashing. If earlier tool calls in the same run already had side effects and those tools declare a compensating tool (see the Subflow node), Publicus rolls those side effects back before the agent continues.
If the agent repeats the exact same call (same tool, same arguments) within the same turn, Publicus reuses the existing decision rather than asking again. The same call in a later turn raises a fresh request, so a reviewer sees each new attempt.
If no one decides in time
Section titled “If no one decides in time”A waiting agent does not hold anything open. The run suspends on the pending request, consuming no resources, and a decision resumes it automatically. You never need to re-run the flow: approve or deny whenever you get to it, and the agent picks up from the tool call.
A request stays decidable until its expires time. When that time passes without a decision, Publicus marks the request expired, treats the tool call as not approved, and wakes the suspended run (within about a minute of expiry) so the agent can continue and report the outcome.
You can tune these windows through environment configuration:
| Setting | What it controls | Default |
|---|---|---|
AGENT_APPROVALS_TTL_SECONDS |
How long a request stays decidable before it expires. | 1800 |
AGENT_APPROVALS_AUTO_APPROVE_ON_EXPIRY |
When a request expires, approve it instead of treating it as not approved. | false |
AGENT_APPROVALS_AUTO_APPROVE |
Approve every request immediately, with no human decision. Requests are still recorded as an audit trail. | false |
AGENT_APPROVALS_AUTO_APPROVE is a deployment-wide break-glass switch that applies to every tenant. To let a specific agent act without asking, set its approval mode to Autopilot instead — it is scoped to that agent, still stops for the protected set, and stays visible in the workspace.


Verify it works
Section titled “Verify it works”- Build an agent with a gated tool, such as a
Channel / Slacksend wired to the agent’s TOOL handle. See build an AI agent for the wiring. - Run the flow with a prompt that makes the agent call that tool.
- Open Needs you and confirm an approval row appears for the tool call. The Approvals tab shows the same request with its tool name and an argument preview.
- Approve it and confirm the tool runs and the agent finishes. Run again, deny it with a reason, and confirm the tool does not run.
Related
Section titled “Related”- How to build an AI agent: wire tools, memory, a trigger, and a reply.
- Llm / Agent: the Agent node reference.
- Connect an agent to a chat channel: the channel sends that pause for approval.
- Outbound request safety: the firewall that protects agent and channel network calls.