{"version":"2.1.269","anchor":"sendmessage-and-sendfile-tools-refactored-to-a-create-cont","canonical_anchor":"sendmessage-and-sendfile-tools-refactored-to-a-create-cont","heading":"SendMessage and SendFile tools refactored to a create()-context pattern","tier":"internal","area":"Elsewhere","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.269\/e\/sendmessage-and-sendfile-tools-refactored-to-a-create-cont","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.269","markdown":"### SendMessage and SendFile tools refactored to a create()-context pattern\n\nSendMessage and SendFile tools were rebuilt internally to share permission\/session state through a common factory\n\n**Unclear.** The finding describes an architectural refactor but does not state any resulting behavior change for users.\n\n**What**\n\nThe internal code for the `SendMessage` and `SendFile` tools was restructured. Instead of each tool receiving its permission-checking and session context separately on every call, they're now built through a shared `create()` factory that sets up this context once and a new helper that throws an error if the permission system isn't properly wired up. Several other internal tools (log tailing, a health-port check, a sandbox-related tool, and an MCP tool wrapper) were changed the same way, now returning their behavior from a `create()` method instead of exposing it as flat properties.\n\n**Why**\n\nThis is an internal restructuring to make tools access session and permission state consistently, rather than each tool wiring it up on its own. It shouldn't change what these tools do, but it's the kind of groundwork that reduces bugs from inconsistent permission handling across tools.\n\n- Area: Elsewhere\n- Tier: Under the hood\n- Useful: 1\/5\n- Signal: 1\/5"}