Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问许可证需确认审计异常

browser-use浏览器使用

Agent Skill

browser-use 用于处理浏览器自动化、网页检查和页面信息提取,适合在 Codex、Claude、Cursor、Gemini CLI 中需要让 Agent 打开页面、读取网页或验证前端流程时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

544

周安装

22

GitHub Stars

4

下载量

171
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/bmaltais/browser-use-skill --skill browser-use

简介

browser-use 实现浏览器自动化与信息提取。

  • 适用于 Codex、Claude、Cursor、Gemini CLI,支持网页导航与 DOM 读取。
  • 内置 uv 环境管理与持久化浏览器实例以提升效率。
  • 首次运行将自动安装依赖,请确保 uv 已就绪。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Browser Automation with browser-use

All commands use the self-contained wrapper bu.sh, which:

  • Auto-bootstraps the local .venv on first run (downloads deps via uv — takes ~60s once)
  • Sets PYTHONUTF8=1 automatically (handles emoji/Unicode on Windows)
  • Keeps a persistent browser daemon for ~50ms latency per call

Shorthand — in all examples, bu means:

bash ~/.claude/skills/browser-use/bu.sh

Prerequisites

  • uv must be installed (uv --version)
  • First run will install browser-use from GitHub into ~/.claude/skills/browser-use/.venv

Core Workflow

  1. Navigate: bu open <url> — starts browser + daemon if needed
  2. Inspect: bu state — returns clickable elements with indices
  3. Interact: use indices from state (bu click 5, bu input 3 "text")
  4. Verify: bu state or bu screenshot to confirm
  5. Repeat: browser stays open between commands
  6. Cleanup: bu close when done

Browser Modes

bu open <url>                         # Default: headless Chromium
bu --headed open <url>                # Visible window
bu --profile "Default" open <url>     # Real Chrome with Default profile (existing logins/cookies)
bu --profile "Profile 1" open <url>   # Real Chrome with named profile
bu --connect open <url>               # Auto-discover running Chrome via CDP
bu --cdp-url ws://localhost:9222/... open <url>  # Connect via specific CDP URL

--connect, --cdp-url, and --profile are mutually exclusive.

Commands

# Navigation
bu open <url>                    # Navigate to URL
bu back                          # Go back in history
bu scroll down                   # Scroll down (--amount N for pixels)
bu scroll up                     # Scroll up
bu switch <tab>                  # Switch to tab by index
bu close-tab [tab]               # Close tab (current if no index)

# Page State — always run state first to get element indices
bu state                         # URL, title, clickable elements with indices
bu screenshot [path.png]         # Screenshot (base64 if no path, --full for full page)

# Interactions — use indices from state
bu click <index>                 # Click element by index
bu click <x> <y>                 # Click at pixel coordinates
bu type "text"                   # Type into focused element
bu input <index> "text"          # Click element, then type
bu keys "Enter"                  # Send keyboard keys (also "Control+a", etc.)
bu select <index> "option"       # Select dropdown option
bu upload <index> <path>         # Upload file to file input
bu hover <index>                 # Hover over element
bu dblclick <index>              # Double-click element
bu rightclick <index>            # Right-click element

# Data Extraction
bu eval "js code"                # Execute JavaScript, return result
bu get title                     # Page title
bu get html [--selector "h1"]    # Page HTML (or scoped to selector)
bu get text <index>              # Element text content
bu get value <index>             # Input/textarea value
bu get attributes <index>        # Element attributes
bu get bbox <index>              # Bounding box (x, y, width, height)

# Wait
bu wait selector "css"           # Wait for element (--state visible|hidden|attached|detached, --timeout ms)
bu wait text "text"              # Wait for text to appear

# Cookies
bu cookies get [--url <url>]     # Get cookies (optionally filtered)
bu cookies set <name> <value>    # Set cookie (--domain, --secure, --http-only, --same-site, --expires)
bu cookies clear [--url <url>]   # Clear cookies
bu cookies export <file>         # Export to JSON
bu cookies import <file>         # Import from JSON

# Python — persistent session with browser access
bu python "code"                 # Execute Python (variables persist across calls)
bu python --file script.py       # Run file
bu python --vars                 # Show defined variables
bu python --reset                # Clear namespace

# Session
bu close                         # Close browser and stop daemon
bu sessions                      # List active sessions
bu close --all                   # Close all sessions

# Recipes — store and replay DOM access patterns (no screenshot on repeat runs)
bu recipe list                   # Show all installed recipes + run history
bu recipe run <name>             # Execute a recipe directly against the DOM
bu recipe run <name> --connect   # Override auth: use CDP connect mode
bu recipe run <name> --headed    # Override: show browser window (debug)
bu recipe show <name>            # Print recipe JSON
bu recipe save <name> --file <path>  # Install a recipe JSON file
bu recipe delete <name>          # Remove a recipe

The Python browser object provides: browser.url, browser.title, browser.html, browser.goto(url), browser.back(), browser.click(index), browser.type(text), browser.input(index, text), browser.keys(keys), browser.upload(index, path), browser.screenshot(path), browser.scroll(direction, amount), browser.wait(seconds).

Cloud API

bu cloud connect                 # Provision cloud browser and connect
bu cloud connect --timeout 120 --proxy-country US  # With options
bu cloud login <api-key>         # Save API key (or set BROWSER_USE_API_KEY)
bu cloud logout                  # Remove API key
bu cloud v2 GET /browsers        # REST passthrough (v2 or v3)
bu cloud v2 POST /tasks '{"task":"...","url":"..."}'
bu cloud v2 poll <task-id>       # Poll task until done

Common Workflows

Authenticated Browsing (existing Chrome session)

bu --connect open https://gmail.com   # Reuse logged-in Chrome via CDP
bu --connect state
bu --connect eval "document.title"

Requires Chrome launched with --remote-debugging-port=9222.

Authenticated Browsing (Chrome profile)

bu profile list                                # Check available profiles
bu --profile "Default" open https://github.com # Already logged in

Extracting Data via JavaScript

bu --connect open https://x.com/notifications
bu --connect eval "Array.from(document.querySelectorAll('[data-testid=\"notification\"]')).slice(0,10).map(n => n.innerText).join('\n---\n')"

Exposing Local Dev Servers

bu tunnel 3000                             # → https://abc.trycloudflare.com
bu open https://abc.trycloudflare.com

Command Chaining

bu open https://example.com && bu state
bu input 5 "user@example.com" && bu input 6 "password" && bu click 7

Chain when you don't need intermediate output. Run separately when you need to parse state to discover indices first.

Global Options

OptionDescription
--headedShow browser window
--profile [NAME]Use real Chrome (bare --profile uses "Default")
--connectAuto-discover running Chrome via CDP
--cdp-url <url>Connect via CDP URL (http:// or ws://)
--session NAMETarget a named session (default: "default")
--jsonOutput as JSON
--mcpRun as MCP server via stdin/stdout

Tips

  1. Always run state first to see available elements and their indices
  2. Use --headed for debugging to see what the browser is doing
  3. Sessions persist — browser stays open between commands
  4. eval with JS is the most powerful extraction method for complex pages

Troubleshooting

  • First run slow? Normal — downloading ~200MB of deps into .venv. Subsequent runs are instant.
  • Browser won't start? bu close then bu --headed open <url>
  • Element not found? bu scroll down then bu state
  • Unicode errors? Already handled — bu.sh sets PYTHONUTF8=1 automatically

Cleanup

bu close           # Close browser session
bu tunnel stop --all  # Stop tunnels (if any)

Recipe System

Recipes store DOM access patterns so repeated tasks skip visual discovery entirely.

First run: discover selectors manually → write a recipe JSON Repeat runs: bu recipe run <name> executes JS directly — no screenshot, no element scanning

Recipe JSON format

{
  "name": "my_recipe",
  "version": 1,
  "description": "What this recipe does",
  "url": "https://example.com/page",

  "auth": {
    "mode": "connect",      // "connect" | "profile" | "headless"
    "profile": null,        // Chrome profile name (mode=profile only)
    "headed": false,
    "session": "default"
  },

  "steps": [
    {
      "id": "nav",
      "type": "navigate",
      "url": "https://example.com/page",
      "wait_for": ".main-content",
      "wait_timeout_ms": 10000
    },
    {
      "id": "extract",
      "type": "eval",
      "js": "document.querySelector('.result')?.innerText",
      "output_var": "result",
      "fallback_selectors": [".alt-result", "[data-result]"]
    }
  ],

  "output": { "format": "text", "var": "result" },
  "metadata": { "created": "2026-01-01", "last_run": null, "run_count": 0, "broken_step": null }
}

Step types

TypeRequired fieldsWhat it does
navigateurlOpen URL; optionally wait for a CSS selector
evaljsRun JavaScript; stores result in output_var
clickindexClick element by index from bu state
inputindex, textClick element then type text
waitselector or textWait for element or text to appear
scrolldirectionScroll up or down

Self-healing fallback

When an eval step fails:

  1. Each fallback_selectors entry is tried as document.querySelector('SEL')?.innerText
  2. First match wins — logged to stderr, recipe continues
  3. If all fallbacks fail: screenshot saved to recipes/.broken_<name>_<step>.png, broken_step set in metadata, exit 1

Sample recipe

See recipes/x_notifications.json — fetches X.com notifications using CDP connection.

Platform support

Works on Linux, macOS, and Windows (Git Bash or WSL required on Windows). bash must be available in PATH — it is on all standard configurations.

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

36.01%
按下载量换算62

Claude

29.74%
按下载量换算51

Cursor

18.41%
按下载量换算31

Gemini CLI

9.09%
按下载量换算16

安全审计

Gen Agent Trust Hub

未通过

Socket

可疑

Snyk

未通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills