Skip to main content

Add your description here

Project description

Page Scoop

A command-line tool for capturing HTML content and screenshots from web pages using browserless.

Features

  • Capture HTML content from any URL
  • Take screenshots with customizable options:
    • Multiple formats (PNG, JPEG, WEBP)
    • Adjustable viewport size
    • Full-page capture
    • Image quality control
  • Configurable through:
    • Command-line arguments
    • Environment variables
    • Configuration file

Installation

uv tool install page-scoop

Requirements

  • Python 3.10 or higher
  • A browserless instance (self-hosted or cloud service)

Configuration

You can configure page-scoop using one of these methods:

  1. Command-line arguments
  2. Environment variables
  3. Configuration file

Configuration File

Create a configuration file (~/.config/page-scoop/config.json) with the following structure:

{
    "browserless_url": "your-browserless-url",
    "token": "your-auth-token",
    "cf_client_id": "your-cloudflare-client-id",
    "cf_client_secret": "your-cloudflare-client-secret"
}

Usage

Capture HTML

page-scoop html https://example.com

Options:

  • --browserless-url: Browserless instance URL
  • --token: Auth token for browserless
  • --output: Save HTML to file instead of stdout
  • --timeout: HTTP request timeout in seconds
  • --wait-for: Wait for selector to appear before capture
  • --wait-time: Wait time in milliseconds before capture

Take Screenshot

page-scoop screenshot https://example.com --output screenshot.png

Options:

  • --browserless-url: Browserless instance URL
  • --token: Auth token for browserless
  • --output: Path to save screenshot file
  • --timeout: HTTP request timeout in seconds
  • --width: Viewport width
  • --height: Viewport height
  • --full-page: Capture full page height
  • --format: Screenshot format (png, jpeg, webp)
  • --quality: Image quality (for JPEG/WEBP)
  • --wait-for: Wait for selector to appear before capture
  • --wait-time: Wait time in milliseconds before capture
  • --overwrite: Overwrite existing file if it exists

Create/Update Configuration

page-scoop config --browserless-url your-url --token your-token

Options:

  • --browserless-url: Browserless instance URL
  • --token: Auth token for browserless
  • --cf-client-id: Cloudflare Access client ID
  • --cf-client-secret: Cloudflare Access client secret
  • --update: Update existing config file

Environment Variables

  • BROWSERLESS_URL: Browserless instance URL
  • BROWSERLESS_TOKEN: Auth token for browserless
  • CF_CLIENT_ID: Cloudflare Access client ID
  • CF_CLIENT_SECRET: Cloudflare Access client secret

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

page_scoop-0.1.0.tar.gz (11.3 kB view details)

Uploaded Source

Built Distribution

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

page_scoop-0.1.0-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: page_scoop-0.1.0.tar.gz
  • Upload date:
  • Size: 11.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.0

File hashes

Hashes for page_scoop-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2b52fddb6da49b6fd7afdff0d5b3baf773b54469500ff02be5dcd0a9339661ad
MD5 dde7e273542c4422cd20da0490a80ca6
BLAKE2b-256 f7191a0c3dce8496be66356b1ec49b94551d8107238d97d417578847bbac1bcd

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for page_scoop-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d8c935892027cc30e2276d5d42a9f5af06f9b3127f3c5de4fdddb254bfab7d0f
MD5 b2e1ea52233c9f38bb6754ba3af7c092
BLAKE2b-256 4d85a94f683e0e153284f1b63977315324a43ba962afdeda0d5dc17fb73cf082

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