Official Python SDK for ScreenshotMAX API
Project description
ScreenshotMAX Python SDK
This is the official Python SDK for the ScreenshotMAX API.
It allows you to easily capture high-quality screenshots of any URL directly from your applications. The SDK handles authentication, request signing, and provides a simple interface to integrate ScreenshotMAX’s powerful screenshot services into your Python projects.
Get started in minutes. Just sign up to receive your access and secret keys, import the client, and you’re ready to capture screenshots.”
The SDK client is synchronized with the latest ScreenshotMAX API options.
Installation
pip install screenshotmax
Usage
Use the SDK to generate signed or unsigned URLs for screenshots, PDFs, web scraping, or animated screenshot—without executing the request. Or fetch and download the result directly. You have full control over when and how each capture runs.
Screenshot example
from screenshotmax import SDK
from screenshotmax.enum import ImageFormat
from screenshotmax.options import ScreenshotOptions
sdk = SDK("<ACCESS_KEY>", "<SECRET_KEY>")
# set up options
opts = ScreenshotOptions(
url="https://example.com",
format=ImageFormat.PNG
)
# fetch screenshot (chaining method)
result, headers = sdk.screenshot.set_options(opts).fetch()
# optionnaly: generate signed URL
# (https://api.screenshotmax.com/v1/screenshot?url=https%3A%2F%2Fexample.com&format=png&access_key=<ACCESS_KEY>&signature=370f5b161bc59eed13b76........1f778635d7fc595dbab12)
url = sdk.screenshot.get_url()
Web scraping example
from screenshotmax import SDK
from screenshotmax.options import ScrapeOptions
sdk = SDK("<ACCESS_KEY>", "<SECRET_KEY>")
# set up options and scrape content (chaining)
opts = ScrapeOptions(url="https://example.com")
sdk.scrape.set_options(opts)
result, headers = sdk.scrape.fetch()
PDF generation example
from screenshotmax import SDK
from screenshotmax.enums import PDFPaperFormat
from screenshotmax.options import PDFOptions
sdk = SDK("<ACCESS_KEY>", "<SECRET_KEY>")
# set up options and scrape content (chaining)
opts = PDFOptions(url="https://example.com", pdf_paper_format=PDFPaperFormat.LETTER)
result, headers = sdk.pdf.set_options(opts).fetch()
Scheduled task example
from screenshotmax import SDK
from screenshotmax.options import PDFOptions
sdk = SDK("<ACCESS_KEY>", "<SECRET_KEY>")
# get all tasks from account
tasks = sdk.task.get_tasks()
# {"tasks":[{
# "id":5678133109850112,
# "name":"Test CRON",
# "api":"screenshot",
# "query":
# "url=https%3A%2F%2Fexample.com",
# "frequency":"every_day",
# "crontab":"25 13 * * *",
# "timezone":"Etc/UTC",
# "enabled":true,
# "created":1747229104,
# "last_run":1748611516,
# "runs":18}]}
License
screenshotmax is released under the MIT license.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file screenshotmax-1.0.1.tar.gz.
File metadata
- Download URL: screenshotmax-1.0.1.tar.gz
- Upload date:
- Size: 17.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a3e7f9ab7f24335a0fec4e5798ef2c3195104801cd7b7bf47ce989fe83a91ea5
|
|
| MD5 |
5b0e7f1ff2ab8b41d34789ea799e82c5
|
|
| BLAKE2b-256 |
0da994aa05a8f23a800097910050f7c05cedf03fe5fca63094eeee866ae9e1fa
|
File details
Details for the file screenshotmax-1.0.1-py3-none-any.whl.
File metadata
- Download URL: screenshotmax-1.0.1-py3-none-any.whl
- Upload date:
- Size: 18.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
96c7ccbfd487cba20554a5848d394fe7a86bb81bf8cd71fe1f789920c7002356
|
|
| MD5 |
22518396c466fb419445e8c28a6c6ca7
|
|
| BLAKE2b-256 |
49d0867aab5665e6cf79f3be11704325f870aebbbcdc7847779d0213a8a0172d
|