# Automate Web Browser Interactions and Data Extraction

Extract product data from e-commerce websites, automate login and form submission processes, perform end-to-end testing of web applications, and capture screenshots and generate PDF reports of web pages using Puppeteer/Playwright.

**Canonical URL:** https://skillshunter.net/skills/github-claude-office-skills-skills-browser-automation-1c33d52542df

**JSON URL:** https://skillshunter.net/api/public/v1/skills/github-claude-office-skills-skills-browser-automation-1c33d52542df

**Markdown URL:** https://skillshunter.net/skills/github-claude-office-skills-skills-browser-automation-1c33d52542df.md

**Instructions download URL:** https://skillshunter.net/skills/github-claude-office-skills-skills-browser-automation-1c33d52542df/download

**Category:** Software & Development

**Source URL:** https://github.com/claude-office-skills/skills/blob/9c4c7d5cd2813a8936bf2c9fdb174ea883b85a11/browser-automation/SKILL.md

**Source commit:** 9c4c7d5cd2813a8936bf2c9fdb174ea883b85a11

**Version:** 1.0.0

**Listing approved at:** 2026-11-22

**Created at:** 2026-11-21T12:57:44.000000Z

**Updated at:** 2026-11-22T11:17:33.000000Z

## Catalog information

The following descriptions are catalog information. Listing approval does not mean the skill has been tested or is safe for every environment.

### Editor's note

Ensure the environment supports Puppeteer or Playwright, and prepare URLs, selectors, and actions as input for automation tasks. The first deliverable is typically extracted data, screenshots, or test results in formats such as JSON, PNG, or PDF.

### When to use it

- Extract product data from e-commerce websites
- Automate login and form submission processes
- Perform end-to-end testing of web applications
- Capture screenshots and generate PDF reports of web pages

## Skill instructions

---
name: Browser Automation
description: Automate web browser interactions, scraping, testing, and workflow automation with Puppeteer/Playwright
version: 1.0.0
author: Claude Office Skills
category: automation
tags:
  - browser
  - puppeteer
  - playwright
  - scraping
  - testing
department: engineering
models:
  - claude-3-opus
  - claude-3-sonnet
  - gpt-4
mcp:
  server: browser-mcp
  tools:
    - browser_navigate
    - browser_click
    - browser_type
    - browser_screenshot
capabilities:
  - Page navigation
  - Element interaction
  - Data extraction
  - Screenshot capture
input:
  - URLs
  - Selectors
  - Actions
  - Scripts
output:
  - Extracted data
  - Screenshots
  - Test results
  - Automation logs
languages:
  - en
related_skills:
  - web-search
  - deep-research
  - etl-pipeline
---

# Browser Automation

Automate web browser interactions for scraping, testing, and workflow automation.

## Core Capabilities

### Navigation
```yaml
navigation:
  goto:
    url: "https://example.com"
    wait_until: "networkidle"
    timeout: 30000
    
  actions:
    - wait_for_selector: ".content"
    - scroll_to_bottom: true
    - wait_for_navigation: true
```

### Element Interaction
```yaml
interactions:
  click:
    selector: "button.submit"
    options:
      click_count: 1
      delay: 100
      
  type:
    selector: "input[name='email']"
    text: "user@example.com"
    options:
      delay: 50  # Human-like typing
      
  select:
    selector: "select#country"
    value: "US"
    
  file_upload:
    selector: "input[type='file']"
    files: ["document.pdf"]
```

### Data Extraction
```yaml
scraping:
  extract_text:
    selector: ".article-content"
    
  extract_all:
    selector: ".product-card"
    fields:
      name: ".product-name"
      price: ".price"
      url:
        selector: "a"
        attribute: "href"
        
  extract_table:
    selector: "table.data"
    output: json
```

### Screenshots & PDF
```yaml
capture:
  screenshot:
    path: "screenshot.png"
    full_page: true
    type: "png"
    
  pdf:
    path: "page.pdf"
    format: "A4"
    print_background: true
```

## Workflow Examples

### Form Automation
```javascript
// Login and fill form
await page.goto('https://app.example.com/login');
await page.fill('#email', 'user@example.com');
await page.fill('#password', 'securepass');
await page.click('button[type="submit"]');
await page.waitForNavigation();

// Navigate to form
await page.click('a[href="/new-entry"]');
await page.fill('#title', 'Automated Entry');
await page.fill('#description', 'Created via automation');
await page.click('button.submit');
```

### Web Scraping
```yaml
scraping_workflow:
  - navigate: "https://news.example.com"
  - wait: ".article-list"
  - extract_all:
      selector: ".article"
      fields:
        title: "h2"
        summary: ".excerpt"
        link:
          selector: "a"
          attribute: "href"
  - paginate:
      next_button: ".pagination .next"
      max_pages: 10
  - output: "articles.json"
```

### E2E Testing
```yaml
test_workflow:
  - name: "User Registration"
    steps:
      - goto: "/register"
      - fill:
          "#email": "test@example.com"
          "#password": "Test123!"
      - click: "button[type='submit']"
      - assert:
          selector: ".success-message"
          text_contains: "Welcome"
```

## Best Practices

1. **Wait Strategies**: Use proper waits
2. **Error Handling**: Catch navigation failures
3. **Rate Limiting**: Be respectful to servers
4. **Headless Mode**: Use for production
5. **Selectors**: Prefer data-testid attributes
6. **Screenshots**: Capture on failures

