Agents
Agent approvals
Which agent actions need your approval by default, and how to approve, reject, or cancel a request
Why approvals exist
Agents can do real work in your project: they can publish a docs site, restore an older version, start a generation, or change a custom domain. We keep you in control of the actions that affect your live site or your data. For those actions, the agent asks first, and a person decides.
Agents always work on a named branch, so their edits do not reach readers until someone publishes them. Approvals cover the steps that come after that.
Actions and default modes
Each action has a default mode. You can change the mode for your projects, and only the modes listed for that action are offered.
| Action | What it does | Default mode | Modes you can choose |
|---|---|---|---|
Publish (docs.publish) | Makes a branch version live on the docs site | Require approval | Allow, Require approval, Block |
Restore (docs.restore) | Brings back a prior published version | Require approval | Allow, Require approval, Block |
Add a domain (domain.add) | Attaches a custom domain to a project | Require approval | Allow, Require approval, Block |
Remove a domain (domain.remove) | Detaches a custom domain | Require approval | Allow, Require approval, Block |
Create a project (project.create) | Creates a new project | Allow | Allow, Require approval, Block |
Delete a project (project.delete) | Deletes a project | Require approval | Require approval, Block |
Generate docs (generation.start) | Starts a Doxabot generation | Require approval | Allow, Require approval, Block |
Deleting a project never offers Allow. We always keep a person in the loop for that action.
Note:
Block stops the action completely. The agent receives an error, and nothing runs.
Where to change the modes
You set the modes on two pages in the dashboard:
Project settings, then Agent approvals: the modes for one project. Owners and admins can save changes. Other members see the page read only. This page also has an erase option that controls whether a publish removes the branch after it goes live, and a setting that requires a different person than the requester to decide a request. See Teams and roles for member roles.
Account settings, then Agent approvals: your personal defaults for each action, including project creation.
A few rules apply when you change a mode:
A change applies to new requests only. A pending request keeps the mode it had when it was created.
Changing a mode to Allow does not approve pending requests. A person still decides them.
Changing a mode to Block cancels the pending requests that the new setting now blocks, with the reason "Blocked by a project setting" or "Blocked by a user setting."
Every change to a mode is recorded in the agent activity for that project. See Live agent activity.
Review an approval request
When an agent asks for an action that needs approval, the request appears in the dashboard with a status and a review page. Follow these steps to decide it.
Open the request
Open the project in the dashboard and find the approval request. Each request shows its title, who asked for it, and when. The page also tells you why it needs approval, such as the project setting or your account setting.
Read what will happen
The What happens list describes the effects in plain language. The Details list shows the inputs the agent sent, such as the branch to publish or the domain to add. Check these before you decide.
Approve, reject, or cancel
Choose one of the decisions on the page:
Approve runs the action now. The request moves to executing, and then to completed or failed.
Reject declines the request. The agent does not run the action.
Cancel withdraws a pending request.
Publish requests are also available from the publish menu. See Publishing and restore.
Note:
An approval checks the state again just before it runs. If the branch, the version, or the domain changed after the request was created, the request becomes stale and nothing runs. Ask the agent to create a new request for the current state.
Request statuses
| Status | Meaning |
|---|---|
| Pending | Waiting for a decision. |
| Executing | Approved and running now. |
| Completed | The action finished. |
| Failed | The action started but did not finish. |
| Rejected | A person declined the request. |
| Cancelled | The request was withdrawn, or a setting now blocks it. |
| Expired | No one decided within 168 hours. |
| Stale | The situation changed before approval, or a newer request replaced this one. |
A few details to keep in mind:
Only one pending request exists for each target. If the same agent repeats the same request, it gets the pending request back. If a different request arrives for the same target, the older pending request becomes stale and the new one takes its place.
A second approval on a request that is no longer pending fails, so you cannot run the same action twice.
Requests that stay in executing for more than 15 minutes are marked failed.