Screenshot of a URL or HTML (ScreenshotOne compatible)
Captures a public URL or an HTML document and returns the image (or PDF). Nothing is stored. Retrying is safe: a render has no side effects and nothing is stored, so a repeated request never creates a duplicate. Retry 408, 429 and 503 with an increasing wait (for example 2, 4 and 8 seconds); do not retry other 4xx errors.
Request
- Base URL: https://api.sahifa.dev
- URL: https://api.sahifa.dev/take
- Auth: one of:
- API key in header X-API-Key
- API key in query parameter access_key
Query parameters
Public http(s) address to capture. Send exactly one of url and html.
HTML document to capture.
For jpeg and webp.
CSS selector of one element to capture; 404 if nothing matches.
Authorization header sent to the page.
Name=value pairs.
name=value pairs.
Seconds.
Seconds; capped at 30.
Accepted and ignored.
URL patterns, * as wildcard.
Response
The image or PDF, or JSON when response_type=json
Changes
No recorded changes to this operation across all 1 revision of this API.