Runtime loop
- The coding-agent runtime loop: create a browser, execute Playwright, read observation/status, repeat, then clean up.
- The difference between model-free runtime tools and delegated
run_web_agent. - Debug UI and CDP URLs as inspection capabilities.
Setup
Ask the host
manage_browsersfor browser lifecycle, status, Debug UI, CDP URL, and cleanup.execute_playwright_codefor browser work that needs page state and post-step observation.
Expected output
Optional delegated agent mode
If the MCP host should delegate the whole browsing goal to Webcompute, enable theagent or all surface and use run_web_agent.
browsing model profile affects MCP only through run_web_agent. The default runtime tools remain model-free.
Production notes
- Use runtime tools when the host plans each step.
- Use
run_web_agentwhen the user explicitly delegates the whole browsing goal. - Treat Debug UI and CDP URLs as bearer capabilities.
- Close browsers when the task is done.
Inspect
- Tool calls in the host transcript.
- Browser status through
manage_browsers. - Observations from
execute_playwright_code. - Debug UI for live page review.
Cleanup
Ask the host to close the browser when the task is done, or callmanage_browsers with the close action for the browser ID it created.
Common failures
- If the host claims it browsed without calling the MCP tools, ask it to rerun with browser tool use visible in the transcript.
- If the host needs proxy setup, use SDK, CLI browser creation, REST, or quick actions; current MCP tool schemas do not expose a custom proxy field.