Agent Browser Cli.Bak.Skip
使用 agent-browser CLI 进行浏览器自动化。用于签到、填表、截图、信息抓取等需要控制浏览器的任务。触发条件:(1) 用户要求自动化浏览器操作 (2) 需要签到、填表、点击按钮 (3) 需要抓取网页内容作为研究素材
MIT-0 · Free to use, modify, and redistribute. No attribution required.
⭐ 0 · 21 · 0 current installs · 0 all-time installs
duplicate of @huang-shao/agent-browser-cli-bak
MIT-0
Security Scan
OpenClaw
Suspicious
medium confidencePurpose & Capability
The SKILL.md and description consistently describe a browser-automation CLI (open, click, fill, snapshot, screenshot). However, the package claims (mentions a Vercel product) but there is no homepage or source URL, and the registry ownerId in the skill header differs from the _meta.json ownerId — this provenance mismatch is unexplained and warrants caution.
Instruction Scope
Runtime instructions stay within the stated purpose (how to open pages, snapshot, click, fill, and create cronable scripts). They do not instruct reading unrelated system files or exfiltrating data. Note: examples show embedding passwords and creating cron scripts in the user's home which could store secrets in plaintext.
Install Mechanism
Although the skill package itself is instruction-only, the SKILL.md tells users to run `npm install -g agent-browser` and `agent-browser install`. Installing a global npm package is a moderately risky operation because it runs arbitrary package code and the subsequent 'agent-browser install' likely downloads/extracts browser binaries. The skill provides no verified source link or checksum to validate the package.
Credentials
The skill declares no required environment variables, credentials, or config paths — which aligns with its purpose. However, the examples encourage storing credentials in scripts (e.g., fill "mypassword" in examples or cron jobs), which is a user practice risk rather than a declared requirement of the skill.
Persistence & Privilege
The skill does not request elevated platform privileges, does not set always:true, and does not modify other skills. It is user-invocable and can be autonomously called by the agent (default behavior), which is typical for skills.
What to consider before installing
This skill appears to be a straightforward CLI guide for browser automation, but before installing anything you should: 1) Verify the npm package provenance — check the package on the npm registry, confirm the publisher identity, and look for an official homepage or repository (this skill lacks a homepage and shows a metadata owner mismatch). 2) Inspect the package code (or its tarball) before running `npm install -g` to ensure it doesn't execute unexpected scripts. 3) Prefer installing in an isolated environment (container, VM, or dedicated non-root account) because installing global npm CLIs can run arbitrary code and the subsequent `agent-browser install` likely downloads browser binaries. 4) Avoid embedding plaintext credentials in scripts or cron jobs — use secrets managers or ephemeral tokens if possible. 5) If you need automatic check-ins, consider running them from a sandboxed machine and rotate any credentials used. If you can, obtain the package from a well-known source or use an officially documented tool from a known vendor rather than an unlinked package.Like a lobster shell, security has layers — review code before you run it.
Current versionv1.0.0
Download ziplatest
License
MIT-0
Free to use, modify, and redistribute. No attribution required.
SKILL.md
Agent Browser
Vercel 出品的浏览器自动化 CLI,基于 Playwright,比标准浏览器工具更快更灵活。
快速开始
agent-browser open <url> # 打开网页
agent-browser snapshot # 获取页面可访问性树
agent-browser click @<ref> # 点击元素(用ref引用)
agent-browser fill @<ref> "内容" # 填入内容
agent-browser close # 关闭浏览器
常用命令
导航
agent-browser open <url> # 打开URL(别名:goto, navigate)
agent-browser back # 后退
agent-browser forward # 前进
agent-browser reload # 刷新
交互
agent-browser click <sel> # 点击
agent-browser dblclick <sel> # 双击
agent-browser fill <sel> "text" # 填入(清空后填)
agent-browser type <sel> "text" # 输入(追加)
agent-browser select <sel> <value> # 选择下拉选项
agent-browser check <sel> # 勾选复选框
agent-browser uncheck <sel> # 取消勾选
agent-browser press <key> # 按键(Enter, Tab, Escape等)
获取信息
agent-browser snapshot # 获取可访问性树(推荐)
agent-browser get text <sel> # 获取文本
agent-browser get html <sel> # 获取HTML
agent-browser get value <sel> # 获取输入值
agent-browser get title # 获取页面标题
agent-browser get url # 获取当前URL
agent-browser screenshot [path] # 截图
agent-browser screenshot --annotate # 带标注的截图
元素定位
通过 snapshot 输出的 ref(如 @e14)直接引用:
agent-browser click @e14
agent-browser fill @e13 "hello"
或使用 CSS 选择器:
agent-browser click "#submit"
agent-browser fill "input[name='email']" "test@test.com"
或使用 ARIA 角色查找:
agent-browser find role button click --name "Submit"
agent-browser find text "Sign In" click
agent-browser find label "Email" fill "test@test.com"
agent-browser find placeholder "Search" type "query"
典型工作流
1. 签到任务
# 打开登录页
agent-browser open <签到页面URL>
# 获取页面结构
agent-browser snapshot
# 点击登录/签到按钮(用实际ref替换 @eXX)
agent-browser click @eXX
# 等待页面加载
sleep 2
agent-browser snapshot
2. 填表任务
agent-browser open <表单URL>
agent-browser snapshot
# 填入各字段
agent-browser find label "用户名" fill "myuser"
agent-browser find label "密码" fill "mypassword"
agent-browser find role button click --name "提交"
3. 定时签到(配合cron)
创建脚本 ~/.openclaw/scripts/daily-checkin.sh:
#!/bin/bash
agent-browser open <签到URL>
sleep 2
agent-browser find role button click --name "签到"
agent-browser screenshot /tmp/checkin_$(date +%Y%m%d).png
agent-browser close
注意事项
- 先 snapshot 再操作 - 每次页面变化后重新获取 ref
- 添加等待 - 页面加载需要时间,用
sleep 2或等待 - 保持浏览器开启 - 多个操作可以在同一浏览器会话中完成
- 完成后关闭 - 用
agent-browser close释放资源
依赖安装
如果 agent-browser 未安装:
npm install -g agent-browser
agent-browser install
Files
2 totalSelect a file
Select a file to preview.
Comments
Loading comments…
