agentleFS
m00kkm00kk/agent-skills-playbook/skills/browser-agent-automation/SKILL.md

browser-agent-automation

Skill0 starsChanged 6 months agoMITView on GitHub

Automates web tasks with LLM-driven browsers using Playwright, Browser-Use, or Playwright MCP. Use for browser automation agents, scraping with agents, form filling, or E2E flows described in natural language.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Default: Playwright MCP in Cursor.

    line 19
  2. Distinctive:

    Never automate login without explicit user consent in session

    line 23
  3. Distinctive:

    Do not exfiltrate cookies/localStorage to logs

    line 26
  4. Distinctive:

    Wait for network idle or specific selector, not fixed sleeps

    line 46

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Browser Agent Automation

Choose approach

ApproachBest for
Playwright MCPExisting Playwright tests; IDE agents
Browser-Use (Python)Greenfield "do this on the site" tasks
Cursor IDE browser MCPInteractive debugging in Cursor

Default: Playwright MCP in Cursor; Browser-Use for standalone Python agents.

Safety rules

  • Never automate login without explicit user consent in session
  • Respect robots.txt and site ToS for bulk scraping
  • Cap steps (e.g. 30 actions) and timeout per navigation
  • Do not exfiltrate cookies/localStorage to logs

Workflow

- [ ] Define goal and success condition (URL, element, downloaded file)
- [ ] Start from known URL; avoid open-ended googling
- [ ] Use accessibility snapshots before clicks (prefer refs/roles)
- [ ] Verify after each critical action (screenshot or DOM check)
- [ ] On failure: one alternate strategy, then stop and report

Playwright MCP (Cursor)

  1. List tabs → navigate → lock → snapshot
  2. Interact via dedicated browser tools (not raw CDP input)
  3. Unlock when done

Reliability patterns

  • Wait for network idle or specific selector, not fixed sleeps
  • Idempotent clicks: confirm state changed
  • For forms: fill → validate → submit → verify confirmation text

Anti-patterns

  • Brittle CSS selectors when role+name available
  • Infinite retry loops on captcha/login walls
  • Storing credentials in skill files or repo

Report blockers (captcha, 2FA) and ask user to take over.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.