Skip to Content
Baseera Docs

Approvals

How approval cards work for the user, how to approve, reject with a reason or undo, and where you see the result.

The assistant never changes anything in your app on its own. When the model asks for a write or draft tool, the user sees an approval card and decides. This guide shows what the user sees and what you can read afterwards.

What the user sees

The user asks for a change, for example "Mark invoice INV-1042 as paid".

An approval card appears in the chat. It shows the sentence your tool's describe returns, such as "Mark invoice INV-1042 as paid", with the values of the call. Nothing has changed yet.

The user presses Approve or Reject.

If the model asks for several changes in one turn, the cards are numbered ("1 of 3") and count down as the user decides.

Approve

After Approve, the card shows Working on it… and then Done. Your tool runs in the user's browser, with the user's session. If your code throws, the card shows Failed. The assistant then continues with the result.

Reject with a reason

Press Reject. A box labelled Reason for rejecting (optional) opens. Type a short reason (up to 500 characters) and press Confirm rejection, or press Cancel to go back.

The tool does not run. The model is told "The user declined", with the reason, so it can answer sensibly, for example by offering another option. The card shows Rejected.

In immersive mode a proposed value appears under the form field as a Baseera draft with Approve and Reject beside the field. It never touches the field until the user approves.

Undo

If the tool provides an undo function, a done card shows Undo. Pressing it runs your undo code and the card shows Undone.

  • Only calls that finished can be undone, and only for tools that define undo.
  • The undo data is kept in memory for the life of the page. After a reload, earlier calls can no longer be undone.
  • The model is not told about an undo. Its next turn does not know the change was reversed.
  • If your undo fails, the card stays undoable so the user can try again.

Where you see approvals

Open the agent's Sessions page and open a session. Each tool call in the trace shows its kind, input and output (unless the agent is set not to store tool data), and a line such as "Approved by ... at ..." or "Rejected by ... at ...: the reason". In immersive mode, the record timeline shows Draft proposed, Draft approved and Draft rejected. The agent's Overview counts Changes approved.

You can also test the approval path before you publish. In a test, choose per tool whether the simulated user approves or rejects with a reason. See Test suites.

What can go wrong

SymptomCause and fix
A change happened with no cardThe tool was registered as read. Change it to write.
The card says what the tool is, not what it doesAdd a describe function to the tool. Without it the card shows the tool name and its input as JSON.
No Undo buttonThe tool has no undo, the call failed, or the page was reloaded.
The assistant keeps asking after a rejectionGive a clearer reason when you reject. The model reads it.
The assistant says it did something that was not approvedIt cannot: platform rules forbid claiming a change before a tool result confirms it. Open the session trace to check what ran.

Next steps

On this page