scraping_browser_navigate
Navigate a scraping browser session to a new URL for accessing real-time web data and bypassing restrictions.
Instructions
Navigate a scraping browser session to a new URL
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL to navigate to |
Implementation Reference
- browser_tools.js:43-65 (handler)The complete tool handler for 'scraping_browser_navigate', defining the tool's metadata, Zod input schema, and the execute function which initializes a browser session, navigates to the specified URL using page.goto(), retrieves title and current URL, and returns a status message.let scraping_browser_navigate = { name: 'scraping_browser_navigate', description: 'Navigate a scraping browser session to a new URL', parameters: z.object({ url: z.string().describe('The URL to navigate to'), }), execute: async({url})=>{ const page = await (await require_browser()).get_page({url}); try { await page.goto(url, { timeout: 120000, waitUntil: 'domcontentloaded', }); return [ `Successfully navigated to ${url}`, `Title: ${await page.title()}`, `URL: ${page.url()}`, ].join('\n'); } catch(e){ throw new UserError(`Error navigating to ${url}: ${e}`); } }, };
- browser_tools.js:307-320 (registration)Registration of the 'scraping_browser_navigate' tool by including it in the conditionally exported 'tools' array (only if API_TOKEN is set; otherwise, activation instructions tool is exported). This array is likely imported and used by the MCP server to register all browser tools.export const tools = process.env.API_TOKEN ? [ scraping_browser_navigate, scraping_browser_go_back, scraping_browser_go_forward, scraping_browser_links, scraping_browser_click, scraping_browser_type, scraping_browser_wait_for, scraping_browser_screenshot, scraping_browser_get_text, scraping_browser_get_html, scraping_browser_scroll, scraping_browser_scroll_to, ] : [scraping_browser_activation_instructions];
- browser_tools.js:46-48 (schema)Zod schema defining the input parameters for the tool: a required 'url' string.parameters: z.object({ url: z.string().describe('The URL to navigate to'), }),