scraping_browser_screenshot
Capture screenshots of web pages for documentation, monitoring, or analysis purposes using the Bright Data Web MCP server.
Instructions
Take a screenshot of the current page
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| full_page | No | Whether to screenshot the full page (default: false) You should avoid fullscreen if it's not important, since the images can be quite large |
Implementation Reference
- browser_tools.js:196-215 (handler)Full tool object definition including the execute handler that captures a screenshot of the browser page (full page optional) using Puppeteer's page.screenshot and returns it via image_content.let scraping_browser_screenshot = { name: 'scraping_browser_screenshot', description: 'Take a screenshot of the current page', parameters: z.object({ full_page: z.boolean().optional().describe([ 'Whether to screenshot the full page (default: false)', 'You should avoid fullscreen if it\'s not important, since the ' +'images can be quite large', ].join('\n')), }), execute: async({full_page = false})=>{ const page = await (await require_browser()).get_page(); try { const buffer = await page.screenshot({fullPage: full_page}); return image_content({buffer}); } catch(e){ throw new UserError(`Error taking screenshot: ${e}`); } }, };
- browser_tools.js:199-205 (schema)Zod schema for input parameters: optional full_page boolean.parameters: z.object({ full_page: z.boolean().optional().describe([ 'Whether to screenshot the full page (default: false)', 'You should avoid fullscreen if it\'s not important, since the ' +'images can be quite large', ].join('\n')), }),
- browser_tools.js:307-320 (registration)Registration of the scraping_browser_screenshot tool in the exported tools array (conditional on 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];