Consolidate approval telemetry context (#36825)

## What changed

Add the tool name to `ApprovalCtx` and use the context's call ID and session
telemetry when recording approval decisions. This removes redundant `ToolCtx`
and telemetry parameters from `resolve_tool_approval`.

GitOrigin-RevId: 238a6f708f83993d64606bfaa74df344b0b46178
This commit is contained in:
Dylan Hurd authored and copyberry committed 2026-08-04 02:29:43 +00:00
1 parent 64bb8094ba
commit b2dc8b3e4b
3 files changed
+12 -21

No files matched your search

+1
View File
@@ -121,6 +121,7 @@ pub(crate) struct ApprovalCtx<'a> {
pub session: &'a Arc<Session>,
pub turn: &'a Arc<TurnContext>,
pub call_id: &'a str,
pub tool_name: &'a ToolName,
pub retry_reason: Option<String>,
pub network_approval_context: Option<NetworkApprovalContext>,
}