Skip to main content

Lightweight browser automation daemon with CLI

Project description

Browser CLI

If you are an LLM, see AGENTS.md for quick setup instructions.


If you are a human

Install

Preferred (published package):

pipx install browser-cli
browser install

Without publishing (install directly from Git):

pipx install "git+https://github.com/<your-org>/<your-repo>.git"
browser install

From a local checkout:

bash ./setup.sh

Manual dev install (fallback):

pip install -e .
browser install

Start the daemon

In a terminal:

browser-daemon

A browser window will open. Keep this running.

Create a session

In another terminal:

browser create

This opens a fresh browser window. Manually log into any sites you need (GitHub, Jira, etc.).

Run browser actions

# Navigate to a site
browser <session_id> navigate github.com/user/repo

# Get page elements
browser <session_id> snapshot

# Click an element
browser <session_id> click ".readme"

# Take a screenshot
browser <session_id> screenshot

# Type text
browser <session_id> type "input[name=search]" "query"

List active sessions

browser list

Delete a session

browser delete <session_id>

Stop the daemon

Press Ctrl+C in the terminal running browser-daemon.


Commands Reference

Standalone (No Daemon)

Capture Command:

Uses JPEG format for efficient file sizes (~10x smaller than PNG).

browser capture <url> [options]

Options:

  • -f, --full-page - Capture full scrollable page (default: viewport only)
  • -o, --output <path> - Custom output path

Examples:

# Quick viewport screenshot (fastest, smallest file)
browser capture https://example.com

# Full page screenshot
browser capture https://example.com -f

# Save to custom location
browser capture https://example.com -o ./my-screenshot.jpg

# Full page + custom path
browser capture https://example.com -f -o ./full-page.jpg

# Capture localhost
browser capture http://localhost:3000
browser capture http://127.0.0.1:8080/dashboard

Daemon Commands

Command Description
browser install Install Chromium runtime
browser create Create new session (opens browser for login)
browser list List active sessions
browser <id> navigate <url> Navigate to URL
browser <id> snapshot [selector] Get page elements
browser <id> click <selector> Click element
browser <id> type <selector> <text> Type text
browser <id> hover <selector> Hover element
browser <id> select <selector> <value> Select dropdown option
browser <id> press <key> Press keyboard key
browser <id> screenshot [selector] Take screenshot
browser <id> back Go back
browser <id> forward Go forward
browser <id> delete Delete session

Troubleshooting

"Command not found: browser" or "browser: command not found"

If pipx install succeeded but commands aren't found, your shell may not have ~/.local/bin in PATH:

# Quick fix (current session only)
export PATH="$HOME/.local/bin:$PATH"

# Permanent fix (add to shell config)
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc  # or ~/.bashrc
source ~/.zshrc  # apply immediately

"Daemon not running"

browser-daemon

Browser doesn't open

browser install

Session not found

browser list

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

browser_automation_cli-0.1.0.tar.gz (14.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

browser_automation_cli-0.1.0-py3-none-any.whl (12.7 kB view details)

Uploaded Python 3

browser_automation_cli-0.1.0-py2.py3-none-any.whl (10.7 kB view details)

Uploaded Python 2Python 3

File details

Details for the file browser_automation_cli-0.1.0.tar.gz.

File metadata

  • Download URL: browser_automation_cli-0.1.0.tar.gz
  • Upload date:
  • Size: 14.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for browser_automation_cli-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e33e4aba294a6ac02a3e76d1272dc7363d4d39eaaeb60cfdae0f69ff6d3f8f94
MD5 f2c65865374d0527c1c7a9e67703fb4f
BLAKE2b-256 ba942599a2f0bf81b3e655cb1d17ea20abbe2b4f3ff4a0b8a81e2cdf323007d9

See more details on using hashes here.

File details

Details for the file browser_automation_cli-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for browser_automation_cli-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cd79cfe1eca39ce8d203ab365240b025e4cbaa59e64509a57f1df8bb4a129eb3
MD5 c9330e9236c480d5bc4a33052c8f01c7
BLAKE2b-256 8955c5b1a0d0abc41290e24fd40f4a0048384cab93b4f05e042ba118e781bf0f

See more details on using hashes here.

File details

Details for the file browser_automation_cli-0.1.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for browser_automation_cli-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 fb34c5110b6c3b66ed82b9f7173cd56427e872b19b45f76203b9b1718a44b77e
MD5 ff39505895bf9b13c3c471ed34335583
BLAKE2b-256 15e960ce06c1ff617c861d5aa2d4aa7897af9ef6213b7cf6c88a795284e43c73

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page