{"version":"2.1.273","anchor":"tool-execution-hook-context-object-substantially-reworked","canonical_anchor":"tool-execution-hook-context-object-substantially-reworked","heading":"Tool-execution hook context object substantially reworked","tier":"internal","area":"Hooks","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.273\/e\/tool-execution-hook-context-object-substantially-reworked","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.273","markdown":"### Tool-execution hook context object substantially reworked\n\nThe context object passed to tool-execution hooks was substantially reworked with many new fields\n\n**What**\n\nThe context object handed to tool-execution hooks (code that runs around a tool call) was rebuilt. It no longer includes credentials, `isNonInteractiveSession`, `persistedToolResultFiles`, `artifactRead`, or `signal`. In their place it now carries a much larger set of fields, including `agentId`, `agentWorktree`, `taskRegistry`, `readFileState`, `getFileHistoryState`, `applyFileHistoryOp`, `sessionEnvVars`, `markPrResolvedThisSession`, `userTypedShellDispatch`, `emitToolProgress`, `shellPermission` (bundled with `abortController` and `toolUseId`), `mainLoopModel`, `effort`, `effortLayerOverride`, `unlayeredPermissions`, `abortController`, `remoteCall`, and `innerCall`.\n\n**Why**\n\nThis substantially expands what internal hooks and tool-execution code can see and do around a tool call, covering things like agent identity, file-history tracking, and per-call permissions and effort settings, rather than the narrower context passed before.\n\n- Area: Hooks\n- Tier: Under the hood\n- Useful: 2\/5\n- Signal: 3\/5"}