Skip to content

ToolApprovalCallback

ToolApprovalCallback = (pending) => Promise<ToolApprovalDecision> | ToolApprovalDecision

Defined in: _worktrees/docs-release/gaunt-sloth/packages/core/src/core/types.ts:422

Callback the GthAgentRunner invokes when a run suspends on a tool-approval interrupt, once per pending tool call. Returns the human’s decision. When no handler is wired (e.g. a non-interactive run), the runner defaults to reject so a run can never silently hang or auto-approve.

PendingToolInterrupt

Promise<ToolApprovalDecision> | ToolApprovalDecision