Skip to content

ApprovalCall

Defined in: react/components/agent/approval-prompt.tsx:53

A single tool call in a batch approval.

optional args?: string

Defined in: react/components/agent/approval-prompt.tsx:59

One-line argument preview.


optional defaultDecision?: "allow" | "deny"

Defined in: react/components/agent/approval-prompt.tsx:61

Initial decision for this call. Defaults to "allow".


id: string

Defined in: react/components/agent/approval-prompt.tsx:55

Stable id, reported back in the decision map.


optional matches?: string[]

Defined in: react/components/agent/approval-prompt.tsx:72

Patterns this call satisfies — the choices the “Allow matching” dropdown offers. The library is shell-agnostic on purpose: the host derives these however it likes and the gate just groups/applies them. For a shell tool a call running rm -rf build might carry ["Bash", "rm", "rm -rf *"]; one running cat README might carry ["Bash", "cat", "read-only"] — so the dropdown can offer “all rm”, “all cat”, a glob, or a semantic group, and selecting one allows every call that lists it. Falls back to [name]. A free-text “custom…” entry is also offered, glob-matched against args.


name: string

Defined in: react/components/agent/approval-prompt.tsx:57

Tool name, e.g. "Bash".