2224
}
2225
}
2227
>
// Auto-approve the agent host's server tools. They only read or
2228
>
// mutate the session's own server-held state and never touch the
2229
>
// workspace, shell, or network, so prompting for them is redundant
2230
>
// noise. Tools that explicitly require confirmation (e.g. revealing
2231
>
// unreviewed review comments) are excluded so the user is prompted.
2232
>
if (request.kind === 'custom-tool' && typeof request.toolName === 'string'
2233
&& this._serverToolHost?.toolNames.includes(request.toolName)
2234
&& !this._serverToolHost.requiresConfirmation(request.toolName)