Use Playwright MCP to see browser console errors, take screenshots, monitor network requests, and debug UI issues in the NXTG-Forge web dashboard. Activate when debugging UI bugs, verifying visual changes, or checking for console errors after code changes.
Drive a real (headless) Chromium against the running NXTG-Forge dashboard from inside Claude Code, using the Playwright MCP server. No Windows Chrome dependency — Playwright launches its own headless Chromium inside WSL.
The Playwright MCP server is registered in forge-ui/.mcp.json, NOT in the plugin's
.mcp.json (which only registers governance / orchestrator / semgrep). The browser_* tools
only exist when a Claude Code session has forge-ui/.mcp.json loaded — i.e. you are working in
the forge-ui/ repo. From the plugin repo alone they are unavailable. Config as shipped:
"playwright": { "command": "npx", "args": ["@playwright/mcp@latest", "--headless", "--console-level", "debug"] }
Two consequences of that exact config:
--console-level debug → browser_console_messages returns verbose debug logs, not just
errors. Filter for error/warning yourself; do not assume a clean-looking tail means no errors.--caps flag → the pdf, vision (coordinate clicks/screenshots), and devtools
capabilities are OFF. browser_pdf_save and coordinate-based interaction are not available here.Start both servers from forge-ui/ (one command starts Vite :5050 + Express API :5051):
cd forge-ui && npm run dev
Confirm they're up before driving the browser:
curl -sf http://localhost:5050 >/dev/null && echo "UI up"
curl -sf http://localhost:5051/api/health >/dev/null && echo "API up"
| Task | Tool |
|------|------|
| Go to a URL | browser_navigate |
| Get the DOM as an accessibility tree (+ element refs) | browser_snapshot |
| Capture the page as an image | browser_take_screenshot |
| Read console output | browser_console_messages |
| List HTTP requests the page made | browser_network_requests |
| Wait for text / state (not a fixed sleep) | browser_wait_for |
| Click / type on a snapshot element | browser_click / browser_type (need a ref) |
| Run JS in page context | browser_evaluate |
| Multiple tabs | browser_tabs (single tool, action arg) |
The interaction model is snapshot-first: browser_snapshot returns the accessibility
tree with an element ref for each node; browser_click / browser_type operate on those
refs. You cannot click by raw CSS selector or by pixel coordinates in this config — snapshot,
find the element, then act on its ref.
browser_navigate → http://localhost:5050browser_console_messages → scan for error entries (React errors, failed imports,
Maximum update depth, uncaught exceptions). Debug-level noise is expected — grep for error.browser_network_requests → any 4xx/5xx? A failed /api/* call (API server down or
route 500) is the most common cause of a blank data panel.browser_take_screenshot → capture the rendered state for the report.browser_navigate → http://localhost:5050 (fresh navigate reloads the Vite bundle — do
NOT reuse a stale open page after an HMR edit).browser_wait_for → wait for a stable element/text instead of guessing a sleep.browser_console_messages → confirm no Maximum update depth exceeded / Warning: reappears.browser_take_screenshot → visual confirmation.browser_navigate → http://localhost:5050browser_snapshot → locate the "Command" nav item, grab its refbrowser_click (that ref) → open Command Centerbrowser_snapshot again → grab the ref of a command button (e.g. "Forge Status")browser_click (that ref)browser_console_messages → check for errors triggered by the actionbrowser_network_requests → confirm the backing API call returned 2xxbrowser_take_screenshot → verify the result renderedforge-ui/.mcp.json, not the plugin. A session opened only in
forge-plugin/ has no browser_* tools. Work from forge-ui/.--console-level debug means console output is noisy. Absence of a visible error at the
tail of browser_console_messages is not proof of no error — filter the full list for error.browser_click/browser_type require a ref from
browser_snapshot. Clicking "by text" or by coordinates does not work in this config
(no --caps vision). Re-snapshot after any navigation or DOM change — refs go stale.browser_pdf_save is unavailable here (needs --caps pdf); so is coordinate-based
screenshotting/clicking (--caps vision). Don't reach for them.browser_tabs tool
with an action argument — the old browser_tab_list / browser_tab_new / browser_tab_select
/ browser_tab_close names do not exist.browser_navigate fresh to force the current build.forge-ui/.mcp.json also pins a stale forge server path (--project .../v3, the old
pre-rename directory). Unrelated to browser debugging, but don't be surprised the orchestrator
MCP there points at a dead path.If Playwright can't reach the UI:
curl -sf http://localhost:5050 — Vite up?curl -sf http://localhost:5051/api/health — API up?cd forge-ui && npm run dev if either fails.browser_* tools themselves are missing, confirm the session loaded
forge-ui/.mcp.json (you're in the forge-ui/ repo), then reconnect the MCP server.Search for places (restaurants, cafes, etc.) via Google Places API proxy on localhost.
Interact with GitHub using the `gh` CLI. Use `gh issue`, `gh pr`, `gh run`, and `gh api` for issues, PRs, CI runs, and advanced queries.
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.
Start voice calls via the OpenClaw voice-call plugin.
Notion API for creating and managing pages, databases, and blocks.
Gemini CLI for one-shot Q&A, summaries, and generation.
Category:developer