agentleFS
Agentic-Engineering-AgencyAgentic-Engineering-Agency/agentforge/skills/browser-automation/SKILL.md

browser-automation

Skill4 starsChanged 9 months agoApache-2.0Archived repositoryView on GitHub

Built-in browser automation skill for AgentForge agents. Navigate web pages, interact with elements, extract content, and take screenshots using Playwright.

  • Installs packages

36 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use api-test-suite-builder, karpathy-coder and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Arnav-0Skill

    api-test-suite-builder

    Use when the user asks to generate API tests, create integration test suites, test REST endpoints, or build contract tests.

    Also in 5 projects that use this

  • csiddhant796-blipSkill

    karpathy-coder

    Use when writing, reviewing, or committing code to enforce Karpathy's 4 coding principles — surface assumptions before coding, keep it simple, make surgical changes, define verifiable goals. Triggers on "review my diff", "check complexity", "am I overcomplicating this", "karpathy check", "before I commit", or any code quality concern where the LLM might be overcoding.

    Also in 4 projects that use this

  • xAmirHamza77Skill

    pentest-tools

    Active penetration testing toolchain. Covers reconnaissance, port scanning, vulnerability scanning, web exploitation, SQL injection, directory brute-forcing, password cracking, and more. Exposes 20+ security tools to the AI agent via MCP servers (pentestMCP / mcp-security-hub). Trigger keywords: penetration testing, port scan, Nmap, vulnerability scan, Nuclei, SQL injection, SQLMap, directory brute-force, FFUF, password cracking, Hashcat, reconnaissance, subdomain, web exploitation, ZAP, Burp.

    Also in 4 projects that use this

  • Arnav-0Skill

    agenthub

    Multi-agent collaboration plugin that spawns N parallel subagents competing on the same task via git worktree isolation. Agents work independently, results are evaluated by metric or LLM judge, and the best branch is merged. Use when: user wants multiple approaches tried in parallel — code optimization, content variation, research exploration, or any task that benefits from parallel competition. Requires: a git repo.

    Also in 4 projects that use this

  • xAmirHamza77Skill

    browser-extension-reverse

    Use for authorized reverse engineering of browser extensions (Chrome/Firefox) including manifest analysis, background workers, and extension-based credential or traffic logic recovery.

    Also in 3 projects that use this

  • +7 more from xAmirHamza77

The file

We split this skill into the rules it gives an agent

9 rules. 0 are common, 6 are distinctive, and 3 are very specific to this project.

  • 0

    Common

    Most of the 26 edited versions we read keep these.

  • 6

    Distinctive

    This author's own choices. Worth a look.

  • 3

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When a user asks you to interact with a web page:

    line 89
  2. Distinctive:

    Use snapshot to understand the page structure (accessibility tree)

    line 93
  3. Distinctive:

    Use extractText to get readable content from the page

    line 94
  4. Distinctive:

    Use click and type to interact with forms and buttons

    line 95
  5. Distinctive:

    Use screenshot to capture visual state when needed

    line 96
  6. Distinctive:

    Always close sessions when done to free resources

    line 97
  7. Very specific:

    Prefer #id selectors over class-based selectors

    line 101
  8. Very specific:

    Use waitForSelector before clicking or typing

    line 102
  9. Very specific:

    Use extractText with a selector to get specific section content

    line 104

“Common” is measured: kept by at least 6 in 10 of the 26 edited versions of this file we could read. “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 Automation

Built-in AgentForge Skill — Automate web browsers to navigate, interact, extract data, and capture screenshots.

Overview

The Browser Automation skill gives agents the ability to interact with web pages programmatically using Playwright. This is essential for:

  1. Web scraping — Extract text, data, and structured content from any website
  2. Form filling — Automate login flows, form submissions, and multi-step workflows
  3. Visual verification — Take screenshots for visual QA or documentation
  4. Research — Navigate and read web pages to gather information
  5. Testing — Verify web application behavior

Supported Actions

ActionDescriptionKey Parameters
navigateGo to a URLurl (required)
clickClick an elementselector (CSS selector)
typeType text into an inputselector, text
screenshotCapture the pagefullPage (optional)
snapshotGet accessibility tree—
extractTextExtract page textselector (optional)
evaluateRun JavaScriptjs (code string)
waitWait for element/timeselector or timeMs
scrollScroll the pagedirection, amount
selectSelect dropdown optionselector, value
hoverHover over elementselector
goBackNavigate back—
goForwardNavigate forward—
reloadReload the page—
closeClose the session—

How to Use

Setup

import { createBrowserTool, MCPServer } from '@agentforge-ai/core';

// Create browser tool with default config
const { tool, shutdown } = createBrowserTool({ headless: true });

// Register with MCP server
const server = new MCPServer({ name: 'my-tools' });
server.registerTool(tool);

// Or use the convenience function
import { registerBrowserTool } from '@agentforge-ai/core';
const { shutdown: cleanup } = registerBrowserTool(server, { headless: true });

Docker Sandbox Mode

For secure, isolated browser execution (recommended for production):

const { tool, shutdown } = createBrowserTool({
  sandboxMode: true,
  headless: true,
});

This launches the browser inside a Docker container with:

  • Isolated network and filesystem
  • 2GB shared memory for stability
  • Automatic cleanup on shutdown

Direct Import

import { createBrowserTool } from '@agentforge-ai/core/browser';

Agent Instructions

When a user asks you to interact with a web page:

  1. Navigate to the target URL first
  2. Wait for key elements to load before interacting
  3. Use snapshot to understand the page structure (accessibility tree)
  4. Use extractText to get readable content from the page
  5. Use click and type to interact with forms and buttons
  6. Use screenshot to capture visual state when needed
  7. Always close sessions when done to free resources

Tips for Reliable Automation

  • Prefer #id selectors over class-based selectors
  • Use waitForSelector before clicking or typing
  • For SPAs, wait after navigation for content to render
  • Use extractText with a selector to get specific section content
  • Take screenshots before and after critical actions for verification

Configuration Options

OptionTypeDefaultDescription
headlessbooleantrueRun browser without UI
defaultTimeoutnumber30000Navigation timeout (ms)
browserTypestring'chromium'Browser engine
viewportWidthnumber1280Viewport width
viewportHeightnumber720Viewport height
userAgentstring—Custom user agent
persistStatebooleanfalseSave cookies/state
statePathstring—Path for state file
sandboxModebooleanfalseDocker isolation
maxSessionsnumber5Max concurrent sessions

Session Management

Each session gets its own isolated browser context with separate cookies, storage, and state. Use sessionId to manage multiple concurrent browsing sessions:

// Session A: logged into site X
await tool.handler({ action: { kind: 'navigate', url: 'https://site-x.com' }, sessionId: 'session-a' });

// Session B: logged into site Y (completely isolated)
await tool.handler({ action: { kind: 'navigate', url: 'https://site-y.com' }, sessionId: 'session-b' });

Prerequisites

  • Playwright: npm install playwright && npx playwright install chromium
  • Docker (optional): Required only for sandboxMode

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.