scraping_browser_navigate
Navigate a web scraping browser to a specified URL to access real-time web data for AI agents and LLMs.
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 handler implementation for the 'scraping_browser_navigate' tool. It defines the tool's metadata, input schema using Zod, and the execute function which obtains a browser page and navigates to the specified URL, returning navigation status, title, and current URL.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:46-48 (schema)Zod schema defining the input parameter 'url' as a required string.parameters: z.object({ url: z.string().describe('The URL to navigate to'), }),
- browser_tools.js:307-320 (registration)The tool is registered by including it in the exported 'tools' array, which is conditionally populated based on the presence of the API_TOKEN environment variable.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];