Detect available browser interaction layer (Playwright MCP, Slicc playwright-cli, cmux-browser, CDP) and load the right commands — then navigate, click, fill, and screenshot through a unified verb set. Use before any browser interaction in skills that shouldn't hardcode a specific layer. Triggers on: browser universal, detect browser, browser layer, browser setup, which browser, browser interaction, open browser, use browser.
100
100%
Does it follow best practices?
Impact
Pending
No eval scenarios have been run
Advisory
Suggest reviewing before use
Tools are already in your context. Use mcp__plugin_playwright_playwright__*
tools directly. Key guidance:
browser_snapshot first to get an accessibility
tree with element refs ([ref="e5"]). Use refs in browser_click,
browser_type, etc.browser_tabs handles list, create, select, and close.browser_wait_for accepts text to wait for or a timeout.browser_take_screenshot captures the current viewport.Run playwright-cli help to get the installed command list. Then fetch the
full workflow reference (optional -- local help is sufficient if this fails):
WebFetch https://raw.githubusercontent.com/ai-ecoverse/slicc/main/src/defaults/workspace/skills/playwright-cli/SKILL.mdKey guidance:
playwright-cli snapshot to get element refs.
Use refs with click, fill, dblclick, hover, select.playwright-cli goto <url>playwright-cli open <url> (background) or
playwright-cli tab-new <url>tab-list, tab-select <index>, tab-closecat /.playwright/session.md for command log recovery.Run these to get the command surface and discover browser surfaces:
cmux browser --help
cmux identify --no-caller
cmux list-pane-surfacesIf no browser surface exists, create one:
cmux new-surface --type browser --pane <ref> --url <url>All commands follow the pattern: cmux browser --surface <ref> <subcommand>.
Key guidance:
click, fill, type.cmux identify, never hardcode.file:// URLs -- content must be served over HTTP.cmux browser --surface <ref> snapshot --compactcmux browser --surface <ref> navigate <url>cmux browser --surface <ref> eval <expression>cmux browser --surface <ref> tab new|list|switch|closecmux browser --surface <ref> wait --load-state completehighlight <selector>, addstyle <css>,
addscript <js>, state save|load <path> for checkpointing.Store the resolved CDP_JS path. All commands use node "$CDP_JS" <command>.
Run node "$CDP_JS" (no args) to see the full command list.
Key guidance:
click, type.ax-tree is the primary method (semantic roles and
names). Use dom as fallback for raw HTML./tmp/, then use the Read tool to view the PNG.eval "await fetch('/api').then(r=>r.json())"list to see tabs with IDs, then --id <target-id>
on any command.eval "window.open('<url>')" then list for new tabs.
eval "window.close()" to close (only works on script-opened tabs).console and network commands stream events for debugging
(not available in other layers).