Token导航 LogoToken导航

Agent Skill · 前端设计

browsing(browsing 命令行)

browsing 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

browsing 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为操作浏览器;许可证信息还不明确,第三方扫描有未通过项,按安装量在前端设计类的 10,216 个 Skill 里排第 1,416。

总安装 5,904周安装 251GitHub Stars 265下载 2,068核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:browsing(browsing 命令行)
来源仓库:https://github.com/obra/superpowers-chrome
仓库路径:skills/browsing
安装命令:
npx skills add https://github.com/obra/superpowers-chrome --skill browsing
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/obra/superpowers-chrome --skill browsing

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

browsing 提供基于 DevTools Protocol 的 Chrome 直接控制,支持多标签页管理。适合在 Codex、Claude、Cursor、Gemini CLI 中处理认证会话和复杂交互。自动捕获 DOM 操作并提供统一接口,无需额外配置即可启动浏览器。

使用前需确认 Chrome 可访问,注意可能触发网络和文件操作。建议结合原始 README 和仓库文档进一步核验具体使用方法和限制条件。

来源仓库内路径:skills/browsing

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/obra/superpowers-chrome --skill browsing;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要操作浏览器,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

browsing 怎么安装?

在终端执行 npx skills add https://github.com/obra/superpowers-chrome --skill browsing。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

browsing 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

browsing 需要什么权限?

权限级别是操作浏览器。该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

browsing 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

browsing 用的人多吗?

公开数据是累计安装 5,904 次,近一周安装 251 次,下载 2,068 次,GitHub 265 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

browsing 安全吗?

第三方扫描有未通过项,风险较高。除非你确认过源码,否则不建议直接安装到常用环境。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理前端设计类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

前端设计类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
frontend-design

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
browsing

browsing 命令行 · 本页

5,904265操作浏览器未明确未通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Browsing with Chrome Direct

Overview

Control Chrome via DevTools Protocol using the use_browser MCP tool. Single unified interface with auto-starting Chrome.

Announce: "I'm using the browsing skill to control Chrome."

When to Use

Use this when:

  • Controlling authenticated sessions
  • Managing multiple tabs in running browser
  • Playwright MCP unavailable or excessive

Use Playwright MCP when:

  • Need fresh browser instances
  • Generating screenshots/PDFs
  • Prefer higher-level abstractions

Auto-Capture

Every DOM action (navigate, click, type, select, eval, keyboard_press, hover, drag_drop, double_click, right_click, file_upload) automatically saves:

  • {prefix}.png — viewport screenshot
  • {prefix}.md — page content as structured markdown
  • {prefix}.html — full rendered DOM
  • {prefix}-console.txt — browser console messages

Files are saved to the session directory with sequential prefixes (001-navigate, 002-click, etc.). You must check these before using extract or screenshot actions.

The use_browser Tool

Single MCP tool with action-based interface. Chrome auto-starts on first use.

Parameters:

  • action (required): Operation to perform
  • tab_index (optional): Tab to operate on (default: 0)
  • selector (optional): CSS selector for element operations
  • payload (optional): Action-specific data
  • timeout (optional): Timeout in ms for await operations (default: 5000)

Actions Reference

Navigation

  • navigate: Navigate to URL

- payload: URL string - Example: {action: "navigate", payload: "https://example.com"}

  • await_element: Wait for element to appear

- selector: CSS selector - timeout: Max wait time in ms - Example: {action: "await_element", selector: ".loaded", timeout: 10000}

  • await_text: Wait for text to appear

- payload: Text to wait for - Example: {action: "await_text", payload: "Welcome"}

Interaction

  • click: Click element

- selector: CSS selector - Example: {action: "click", selector: "button.submit"}

  • type: Text input

- selector: Optional — clicks to focus first - payload: Text to type (\t=Tab, \n=Enter) - Example: {action: "type", selector: "#email", payload: "user@example.com"}

  • double_click: Double-click element (fires dblclick event)

- selector: CSS selector - Example: {action: "double_click", selector: ".item"}

  • right_click: Right-click element (fires contextmenu event)

- selector: CSS selector - Example: {action: "right_click", selector: ".row"}

  • select: Select dropdown option

- selector: CSS selector - payload: Option value(s) - Example: {action: "select", selector: "select[name=state]", payload: "CA"}

  • keyboard_press: Press special keys (Tab, Enter, Escape, Arrow keys, F1-F12)

- payload: Key name - modifiers: Optional {shift, ctrl, alt, meta} - Example: {action: "keyboard_press", payload: "Tab"}

Mouse Actions (CDP-Level)

These use CDP Input.dispatchMouseEvent, bypassing synthetic event restrictions.

  • hover: Move mouse over element (CSS:hover, tooltips, menus)

- selector: CSS selector - Example: {action: "hover", selector: ".menu-trigger"}

  • drag_drop: Drag element to target (native drag-and-drop via CDP)

- selector: Source element - payload: Target selector or JSON coordinates {"x":N,"y":N} - Example: {action: "drag_drop", selector: ".card", payload: ".column-2"}

  • mouse_move: Move mouse to coordinates

- payload: JSON {"x":N,"y":N} (optional: steps, fromX, fromY for smooth movement) - Example: {action: "mouse_move", payload: "{\"x\":100,\"y\":200}"}

  • scroll: Scroll via mouse wheel events

- payload: Direction (up/down/left/right) or JSON {"deltaX":N,"deltaY":N} - selector: Optional — scroll within element - Example: {action: "scroll", payload: "down"}

File Upload

  • file_upload: Set files on input[type=file] elements (can't be done via JavaScript)

- selector: File input element - payload: File path or JSON {"files":["/path/a.pdf","/path/b.jpg"]} - Example: {action: "file_upload", selector: "#upload", payload: "/tmp/doc.pdf"}

Extraction

  • extract: Get page content

- payload: Format ('markdown'|'text'|'html') - selector: Optional - limit to element - Example: {action: "extract", payload: "markdown"} - Example: {action: "extract", payload: "text", selector: "h1"}

  • attr: Get element attribute

- selector: CSS selector - payload: Attribute name - Example: {action: "attr", selector: "a.download", payload: "href"}

  • eval: Execute JavaScript

- payload: JavaScript code - Example: {action: "eval", payload: "document.title"}

Export

  • screenshot: Capture screenshot of a specific element

- payload: Filename - selector: Optional - screenshot specific element - Viewport screenshots are auto-captured after every DOM action. Use this only when you need a specific element. - Example: {action: "screenshot", payload: "/tmp/chart.png", selector: ".chart"}

Tab Management

  • list_tabs: List all open tabs

- Example: {action: "list_tabs"}

  • new_tab: Create new tab

- Example: {action: "new_tab"}

  • close_tab: Close tab

- tab_index: Tab to close - Example: {action: "close_tab", tab_index: 2}

Browser Mode Control

  • show_browser: Make browser window visible (headed mode)

- Example: {action: "show_browser"} - ⚠️ WARNING: Restarts Chrome, reloads pages via GET, loses POST state

  • hide_browser: Switch to headless mode (invisible browser)

- Example: {action: "hide_browser"} - ⚠️ WARNING: Restarts Chrome, reloads pages via GET, loses POST state

  • browser_mode: Check current browser mode, port, and profile

- Example: {action: "browser_mode"} - Returns: {"headless": true|false, "mode": "headless"|"headed", "running": true|false, "port": 9222, "profile": "name", "profileDir": "/path"}

Profile Management

  • set_profile: Change Chrome profile (must kill Chrome first)

- Example: {action: "set_profile", "payload": "browser-user"} - ⚠️ WARNING: Chrome must be stopped first

  • get_profile: Get current profile name and directory

- Example: {action: "get_profile"} - Returns: {"profile": "name", "profileDir": "/path"}

Default behavior: Chrome starts in headless mode with "superpowers-chrome" profile on a dynamically allocated port (range 9222-12111). Override with CHROME_WS_PORT env var or MCP --port=N flag.

Critical caveats when toggling modes:

  1. Chrome must restart - Cannot switch headless/headed mode on running Chrome
  2. Pages reload via GET - All open tabs are reopened with GET requests
  3. POST state is lost - Form submissions, POST results, and POST-based navigation will be lost
  4. Session state is lost - Any client-side state (JavaScript variables, etc.) is cleared
  5. Cookies/auth may persist - Uses same user data directory, so logged-in sessions may survive

When to use headed mode:

  • Debugging visual rendering issues
  • Demonstrating browser behavior to user
  • Testing features that only work with visible browser
  • Debugging issues that don't reproduce in headless mode

When to stay in headless mode (default):

  • All other cases - faster, cleaner, less intrusive
  • Screenshots work perfectly in headless mode
  • Most automation works identically in both modes

Profile management: Profiles store persistent browser data (cookies, localStorage, extensions, auth sessions).

Profile locations:

  • macOS: ~/Library/Caches/superpowers/browser-profiles/{name}/
  • Linux: ~/.cache/superpowers/browser-profiles/{name}/
  • Windows: %LOCALAPPDATA%/superpowers/browser-profiles/{name}/

When to use separate profiles:

  • Default profile ("superpowers-chrome"): General automation, shared sessions
  • Agent-specific profiles: Isolate different agents' browser state

- Example: browser-user agent uses "browser-user" profile

  • Task-specific profiles: Testing with different user contexts

- Example: "test-logged-in" vs "test-logged-out"

Profile data persists across:

  • Chrome restarts
  • Mode toggles (headless ↔ headed)
  • System reboots (data is in cache directory)

To use a different profile:

  1. Kill Chrome if running: await chromeLib.killChrome()
  2. Set profile: {action: "set_profile", "payload": "my-profile"}
  3. Start Chrome: Next navigate/action will use new profile

Quick Start Pattern

Navigate and extract:
{action: "navigate", payload: "https://example.com"}
{action: "await_element", selector: "h1"}
{action: "extract", payload: "text", selector: "h1"}

Common Patterns

Fill and Submit Form

{action: "navigate", payload: "https://example.com/login"}
{action: "await_element", selector: "input[name=email]"}
{action: "type", selector: "input[name=email]", payload: "user@example.com"}
{action: "type", selector: "input[name=password]", payload: "pass123"}
{action: "keyboard_press", payload: "Enter"}
{action: "await_text", payload: "Welcome"}

Uses keyboard_press to submit the form.

Multi-Tab Workflow

{action: "list_tabs"}
{action: "click", tab_index: 2, selector: "a.email"}
{action: "await_element", tab_index: 2, selector: ".content"}
{action: "extract", tab_index: 2, payload: "text", selector: ".amount"}

Dynamic Content

{action: "navigate", payload: "https://example.com"}
{action: "type", selector: "input[name=q]", payload: "query"}
{action: "click", selector: "button.search"}
{action: "await_element", selector: ".results"}
{action: "extract", payload: "text", selector: ".result-title"}

Get Link Attribute

{action: "navigate", payload: "https://example.com"}
{action: "await_element", selector: "a.download"}
{action: "attr", selector: "a.download", payload: "href"}

Execute JavaScript

{action: "eval", payload: "document.querySelectorAll('a').length"}
{action: "eval", payload: "Array.from(document.querySelectorAll('a')).map(a => a.href)"}

Resize Viewport (Responsive Testing)

Use eval to resize the browser window for testing responsive layouts:

{action: "eval", payload: "window.resizeTo(375, 812); 'Resized to mobile'"}
{action: "eval", payload: "window.resizeTo(768, 1024); 'Resized to tablet'"}
{action: "eval", payload: "window.resizeTo(1920, 1080); 'Resized to desktop'"}

Note: This resizes the window, not device emulation. It won't change:

  • Device pixel ratio (retina displays)
  • Touch events
  • User-Agent string

For most responsive testing, window resize is sufficient.

Clear Cookies

Use eval to clear cookies accessible to JavaScript:

{action: "eval", payload: "document.cookie.split(';').forEach(c => { document.cookie = c.trim().split('=')[0] + '=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/'; }); 'Cookies cleared'"}

Note: This clears cookies accessible to JavaScript. It won't clear:

  • httpOnly cookies (server-side only)
  • Cookies from other domains

For most logout/reset scenarios, this is sufficient.

Scroll Page

{action: "scroll", payload: "down"}
{action: "scroll", payload: "up"}
{action: "scroll", selector: ".container", payload: "{\"deltaX\":0,\"deltaY\":500}"}

Uses real mouse wheel events (vs eval + scrollTo which bot detectors flag).

Tips

Always wait before interaction: Don't click or fill immediately after navigate - pages need time to load.

// BAD - might fail if page slow
{action: "navigate", payload: "https://example.com"}
{action: "click", selector: "button"}  // May fail!

// GOOD - wait first
{action: "navigate", payload: "https://example.com"}
{action: "await_element", selector: "button"}
{action: "click", selector: "button"}

Use specific selectors: Avoid generic selectors that match multiple elements.

// BAD - matches first button
{action: "click", selector: "button"}

// GOOD - specific
{action: "click", selector: "button[type=submit]"}
{action: "click", selector: "#login-button"}

Submit forms: Use keyboard_press with Enter after type, or append \n to the payload.

{action: "type", selector: "#search", payload: "query"}
{action: "keyboard_press", payload: "Enter"}

Check content first: Extract page content to verify selectors before building workflow.

{action: "extract", payload: "html"}

Troubleshooting

Element not found:

  • Use await_element before interaction
  • Verify selector with extract action using 'html' format

Timeout errors:

  • Increase timeout: {timeout: 30000} for slow pages
  • Wait for specific element instead of text

Tab index out of range:

  • Use list_tabs to get current indices
  • Tab indices change when tabs close

eval returns [object Object]:

  • Use JSON.stringify() for complex objects: {action: "eval", payload: "JSON.stringify({name: 'test'})"}
  • For async functions: {action: "eval", payload: "JSON.stringify(await yourAsyncFunction())"}

Test Automation (Advanced)

When building test automation, you have two approaches:

Approach 1: use_browser MCP (Simple Tests)

Best for: Single-step tests, direct Claude control during conversation

{"action": "navigate", "payload": "https://app.com"}
{"action": "click", "selector": "#test-button"}
{"action": "eval", "payload": "JSON.stringify({passed: document.querySelector('.success') !== null})"}

Approach 2: chrome-ws CLI (Complex Tests)

Best for: Multi-step test suites, standalone automation scripts

Key insight: chrome-ws is the reference implementation showing proper Chrome DevTools Protocol usage. When use_browser doesn't work as expected, examine how chrome-ws handles the same operation.

# Example: Automated form testing
./chrome-ws navigate 0 "https://app.com/form"
./chrome-ws fill 0 "#email" "test@example.com"
./chrome-ws click 0 "button[type=submit]"
./chrome-ws wait-text 0 "Success"

When use_browser Fails

  1. Check chrome-ws source code - It shows the correct CDP pattern
  2. Use chrome-ws to verify - Test the same operation via CLI
  3. Adapt the pattern - Apply the working CDP approach to use_browser

Common Test Automation Patterns

  • Form validation: Fill forms, check error states
  • UI state testing: Click elements, verify DOM changes
  • Performance testing: Measure load times, capture metrics
  • Screenshot comparison: Capture before/after states

Advanced Usage

For command-line usage outside Claude Code, see COMMANDLINE-USAGE.md.

For detailed examples, see EXAMPLES.md.

Protocol Reference

Full CDP documentation: https://chromedevtools.github.io/devtools-protocol/

平台分布

Codex

34.57%
按下载量换算715

Claude

29.84%
按下载量换算617

Cursor

18%
按下载量换算372

Gemini CLI

7.82%
按下载量换算162

安全审计

Gen Agent Trust Hub

未通过

Socket

可疑

Snyk

未通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills