Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add SparkElf/deepseek-harness-plus --skill browser-cdp-automationgit clone --depth 1 https://github.com/SparkElf/deepseek-harness-plusWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/sparkelf/deepseek-harness-plus/browser-cdp-automation)<a href="https://agentmods.dev/skills/sparkelf/deepseek-harness-plus/browser-cdp-automation"><img src="https://agentmods.dev/badge/skills/sparkelf/deepseek-harness-plus/browser-cdp-automation/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/sparkelf/deepseek-harness-plus/browser-cdp-automation"><img src="https://agentmods.dev/badge/skills/sparkelf/deepseek-harness-plus/browser-cdp-automation.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00105 | $0.02848 |
| Opus 5.5 | $0.00042 | $0.01139 |
| Sonnet 5.5 | $0.00021 | $0.00570 |
| Haiku 4.5 | $0.00011 | $0.00285 |
Grade A, and why
browser-cdp-automation scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -s http://127.0.0.1:9333/json/version How it starts
The opening of the file, as written. The whole thing — 194 lines — stays where its author put it; the contents beside it link to each section on GitHub.
浏览器自动化(CDP / Playwright)
这份技能解决的不是"怎么写选择器",而是怎么让自动化真的生效。
一句话贯穿全文:动作成功 ≠ 状态改变。 判断标准永远是应用自己的状态(计数器、列表、接口返回),不是你点完之后自己读回来的那个 DOM 属性。
0. 先选路线
| 场景 | 路线 |
|---|---|
| 需要复用已登录的浏览器(登录要扫码/短信,无法自动) | 接管(attach) |
| 需要页面级细粒度操作(真实鼠标、截图、网络拦截) | Playwright |
| Playwright 连不上,但端口是通的 | 裸 CDP(Runtime.evaluate + Input) |
接管真实浏览器是这里最常见的需求,因为登录态通常拿不到。
1. 接管已登录的 Chrome
浏览器必须带调试端口启动。两个硬限制:
- Chrome 136+ 拒绝对默认 user-data-dir 开放
--remote-debugging-port。 日常在用的 Chrome 基本都因此不可用,无论启动参数怎么加。 --remote-debugging-address=0.0.0.0在现代 Chrome 上已被忽略,它仍然只绑127.0.0.1。别指望靠这个参数跨机器访问。
所以正确做法是独立 profile:
chrome.exe --user-data-dir='C:\Users\<user>\auto-profile' \
--remote-debugging-port=9333 --no-first-run --no-default-browser-check
在这个 profile 里登录一次,之后长期复用。验证端口:
curl -s http://127.0.0.1:9333/json/version
从 WSL 启动 Windows Chrome 时,不要用 cmd.exe /c start ...(会阻塞在工具调用里);直接执行 .exe 并 detach:
setsid nohup "/mnt/c/.../chrome.exe" --user-data-dir='C:\...' --remote-debugging-port=9333 \
> /tmp/chrome.log 2>&1 < /dev/null &
disown
2. WSL 连不上 Windows 的调试端口
典型现象:Windows 侧 IWR http://127.0.0.1:9333/json/version 正常,WSL 侧 curl 127.0.0.1:9333 和 curl <WindowsIP>:9333 都空。WSL 日志可能伴随:
WSL (pid - ) ERROR: UtilAcceptVsock:273: accept4 failed 110
这说明 WSL2 的 localhost 转发坏了,而不是 Chrome 的问题。先确认基础连通性(ping <网关>、连一个 Windows 上监听 0.0.0.0 的端口如 445),能通就说明是端口绑定问题:Chrome 只绑 loopback,WSL 从另一个地址来,连不上。
三条路,按可行性排:
netsh interface portproxy:最干净,但需要管理员。受限环境里通常做不到。netsh interface portproxy add v4tov4 listenaddress=0.0.0.0 listenport=9334 \ connectaddress=127.0.0.1 connectport=9333- PowerShell TCP 中继(无需管理员,推荐)。在 Windows 侧跑一个监听
0.0.0.0:9334、转发到127.0.0.1:9333的 TCP 中继,见scripts/win-relay.ps1。 - 把自动化脚本放到 Windows 侧跑(多数环境没有 node,通常不可行)。
中继起来后,WSL 侧用主机 IP + 中继端口访问:
WINIP=$(ip route | awk '/^default/ {print $3; exit}')
export CDP_BASE="http://$WINIP:9334"
What ships with it
3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 194 lines · 105 tokens per session scan A 0a0f0d46957b
browser-cdp-automation is a skill published in the GitHub repository SparkElf/deepseek-harness-plus (1 stars, last pushed yesterday), licensed MIT. It adds 105 tokens to every session and 2,848 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-29.
browser-cdp-automation compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| browser-cdp-automationSparkElf/deepseek-harness-plus | Skill | 1 | yesterday | MIT | A | 105 | Claude Code, Codex |
| browser-use-cliamplifthq/oh-my-dsh | Skill | 20 | 1mo ago | MIT | C | 32 | Claude Code, Codex |
| dsh-tui-guideccch1mneyyy/dsh-TUI | Skill | 8.7k | today | MIT | A | 41 | Claude Code, Codex |
| modsearchliustack/modsearch | Skill | 1.1k | 8d ago | MIT | A | 99 | Claude Code |
| game-devsandbaseai/sandbase-skills | Skill | 212 | 11d ago | Apache-2.0 | A | 50 | Claude Code |
| screenshot-capturesandbaseai/sandbase-skills | Skill | 212 | 11d ago | Apache-2.0 | A | 45 | Claude Code |
| review-changesamplifthq/oh-my-dsh | Skill | 20 | 1mo ago | MIT | A | 22 | Claude Code, Codex |