Skip to content

Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.

docs: update data available in hooks for Playwright removal

Marian Schneiderb579308c3bcc
diff --git a/docs/customize/hooks.mdx b/docs/customize/hooks.mdx
index a56cf66b8..78cbc5073 100644
--- a/docs/customize/hooks.mdx
+++ b/docs/customize/hooks.mdx
@@ -96,12 +96,12 @@ When working with agent hooks, you have access to the entire `Agent` instance. H
- `agent.history.model_actions()`: Actions taken by the agent
- `agent.history.extracted_content()`: Content extracted from web pages
- `agent.history.urls()`: URLs visited by the agent
-- `agent.browser_session` gives direct access to the `Browser()` and CDP interface
+- `agent.browser_session` gives direct access to the `BrowserSession` and CDP interface
- `agent.browser_session.agent_focus`: Get the current CDP session the agent is focused on
- `agent.browser_session.get_or_create_cdp_session()`: Get the current CDP session for browser interaction
- `agent.browser_session.get_tabs()`: Get all tabs currently open
- - `agent.browser_session.get_page_html()`: Current page HTML
- - `agent.browser_session.take_screenshot()`: Screenshot of the current page
+ - `agent.browser_session.get_current_page_url()`: Get the URL of the current active tab
+ - `agent.browser_session.get_current_page_title()`: Get the title of the current active tab
## Tips for Using Hooks