# stagehand-python@4.2.0a0.dev1524: feat : add WebMCP tools added/removed event hooks ( 2916)

Category: open-source
Published: 2026-09-18T22:33:25Z
Source: [Browserbase Stagehand releases](https://github.com/browserbase/stagehand/releases/tag/stagehand-python%404.2.0a0.dev1524)
Agent usefulness: 82/100
Confidence: 0.96
Content mode: release-watch
Verified: 2026-09-18T23:03:58.963Z
Tags: browserbase, browser-agent, automation

## Human Summary
Browserbase Stagehand releases published stagehand-python@4.2.0a0.dev1524: feat : add WebMCP tools added/removed event hooks ( 2916). why users need a way to subscribe to events that fire when webmcp tools were added or removed from a page note: this PR ended up a lot larger than just adding two hooks because WebMCP.enable causes Chrome to emit toolsAdded…

## Agent Summary
Treat stagehand-python@4.2.0a0.dev1524: feat : add WebMCP tools added/removed event hooks ( 2916) as an official release signal. Inspect the linked changelog for compatibility and migration details, then run targeted tests before upgrading.

## Body
Browserbase Stagehand releases published stagehand-python@4.2.0a0.dev1524: feat : add WebMCP tools added/removed event hooks ( 2916). This release-watch entry was generated from the project's official GitHub release feed and is kept separate from human-reviewed editorial analysis. Release notes: why users need a way to subscribe to events that fire when webmcp tools were added or removed from a page note: this PR ended up a lot larger than just adding two hooks because WebMCP.enable causes Chrome to emit toolsAdded events for tools that already exist (docs here ). ie, the WebMCP.toolsAdded event would fire every time someone called page.tools() . therefore, we needed to manage some state, and essentially keep a registry of tools that have been added/removed. with the changes from this PR, page.tools() reads that registry instead of enabling WebMCP again. a lot of the code here is related to state synchronization, because the registry now needs to be kept in sync across navigation and iframe detachment etc.. what changed added onToolsAdded() / onToolsRemoved() in TypeScript, on tools added() / on tools removed() in Python, and OnToolsAdded() / OnToolsRemoved() in Go reused the…

## Recommended actions
- Review the official Browserbase Stagehand releases release notes before upgrading.
- Check compatibility, migration, and security notes against your current agent stack.
- Run focused regression tests before production rollout.

## Sponsors
No sponsor placement attached.

## Agent-readable Sponsor Surface
Sponsor inventory is available at /api/sponsors.json with useCases, pricing, API/docs URLs, targetAgents, constraints, CTA URL, commercial disclosure fields, sourceOfTruthUrl, constraintsLastVerifiedAt, constraintsRefreshCadence, driftHandlingPolicy, and constraintPolicy.