A comand-line utility for taking automated screenshots of websites
Project description
shot-scraper
A comand-line utility for taking automated screenshots of websites
For background on this project see shot-scraper: automated screenshots for documentation, built on Playwright.
Documentation
Full documentation can be found at shot-scraper.datasette.io
Get started with GitHub Actions
To get started without installing any software, use the shot-scraper-template template to create your own GitHub repository which takes screenshots of a page using shot-scraper
. See Instantly create a GitHub repository to take screenshots of a web page for details.
Quick installation
You can install the shot-scraper
CLI tool using pip:
pip install shot-scraper
# Now install the browser it needs:
shot-scraper install
Taking your first screenshot
You can take a screenshot of a web page like this:
shot-scraper https://datasette.io/
This will create a screenshot in a file called datasette-io.png
.
Many more options are available, see Taking a screenshot for details.
Examples
- The shot-scraper-demo repository uses this tool to capture recently spotted owls in El Granada, CA according to this page, and to generate an annotated screenshot illustrating a Datasette feature as described in my blog.
- Ben Welsh built @newshomepages, a Twitter bot that uses
shot-scraper
and GitHub Actions to take screenshots of news website homepages and publish them to Twitter. The code for that lives in palewire/news-homepages. - scrape-hacker-news-by-domain uses
shot-scraper javascript
to scrape a web page. See Scraping web pages from the command-line with shot-scraper for details of how this works.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for shot_scraper-0.14.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5e6ce2efb50895b3bb7a0c9cf5d898e79cd809af32eedfd2977ff5ced3a89652 |
|
MD5 | e42f2e06f3a2639c76bef1709408f86c |
|
BLAKE2b-256 | d9976206211989cfc88e93c163530e8c0c6c498fff8f43f0398bf2e495a8b31d |