Capture a web page screenshot
litescrape.web.screenshotCapture a public HTTP(S) page as a PNG
- Price
- $0.00015/successAt provider cost
- Success rate
- —No success-rate data yetLast 30 days · 0 calls
- Latency p50
- ——
- Last verified
- Sep 29, 2026Verified working
GEThttps://toolswitch.dev/v1/tools/litescrape.web.screenshot?url=https%3A%2F%2Fexample.comPreview- Uses platform quota
- Synchronous response
- Reads public data
Parameters
The returned screenshot_url needs the same bearer key for PNG download. That download is free and the URL expires after seven days.
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| Query parameters | ||||
url | string | Required | Public HTTP(S) URL to capture, 1-8,192 characters. Include http:// or https://; bare domains are rejected. The host must be public, on port 80 or 443, without embedded credentials. | https://example.com |
locale | string | Optional | Browser locale as a language tag, 2-64 characters. Defaults to the browser's own. | en-US |
referer | string | Optional | HTTP(S) URL sent as the Referer. | https://example.com |
timeout | number | Optional | Optional budget for the entire request in seconds, measured from gateway receipt until the response is ready to send. Includes admission, queueing and settlement. Must be greater than 0 and at most 90. On expiry, the call is not billed and returns 503 request_deadline_exceeded with retryable=true and a request ID. Omit to retain the standard server deadline. | |
full_page | boolean | Optional | Capture the full page when true. The default, false, captures the viewport. | true |
robots_txt | string | Optional | User agent, 1-256 characters, to check against the site's robots.txt; disallowed URLs are rejected. | MyBot |
user_agent | string | Optional | User-Agent for the page request, 1-1,024 characters without control characters. Defaults to the browser's own. | |
page_timeout | integer | Optional | Seconds from 1 through 180 for page loading and browser operations. Cannot extend the total request budget set by timeout. | 30 |
remove_overlay | boolean | Optional | Remove modal and cookie-banner overlays from the page. | |
respond_timing | string | Optional | Page readiness condition to reach before responding. | network-idle |
detach_invisibles | boolean | Optional | Drop display:none elements from the page. | |
wait_for_selector | string | Optional | CSS selector to wait for after navigation, 1-2,048 characters. POST also accepts a list of 1-16 selectors. | main |
assert_status_code | integer | Optional | Expected origin HTTP status, 100-599. A different status is rejected; otherwise a rendered error page is a successful capture. | 200 |
- Query parameters
urlstringRequiredPublic HTTP(S) URL to capture, 1-8,192 characters. Include http:// or https://; bare domains are rejected. The host must be public, on port 80 or 443, without embedded credentials.
Example:
https://example.comlocalestringOptionalBrowser locale as a language tag, 2-64 characters. Defaults to the browser's own.
Example:
en-USrefererstringOptionalHTTP(S) URL sent as the Referer.
Example:
https://example.comtimeoutnumberOptionalOptional budget for the entire request in seconds, measured from gateway receipt until the response is ready to send. Includes admission, queueing and settlement. Must be greater than 0 and at most 90. On expiry, the call is not billed and returns 503 request_deadline_exceeded with retryable=true and a request ID. Omit to retain the standard server deadline.
full_pagebooleanOptionalCapture the full page when true. The default, false, captures the viewport.
Example:
truerobots_txtstringOptionalUser agent, 1-256 characters, to check against the site's robots.txt; disallowed URLs are rejected.
Example:
MyBotuser_agentstringOptionalUser-Agent for the page request, 1-1,024 characters without control characters. Defaults to the browser's own.
page_timeoutintegerOptionalSeconds from 1 through 180 for page loading and browser operations. Cannot extend the total request budget set by timeout.
Example:
30remove_overlaybooleanOptionalRemove modal and cookie-banner overlays from the page.
respond_timingstringOptionalPage readiness condition to reach before responding.
Example:
network-idledetach_invisiblesbooleanOptionalDrop display:none elements from the page.
wait_for_selectorstringOptionalCSS selector to wait for after navigation, 1-2,048 characters. POST also accepts a list of 1-16 selectors.
Example:
mainassert_status_codeintegerOptionalExpected origin HTTP status, 100-599. A different status is rejected; otherwise a rendered error page is a successful capture.
Example:
200
Code samples
Replace $TOOLSWITCH_KEY with the key you created in the console.
curl -X GET 'https://toolswitch.dev/v1/tools/litescrape.web.screenshot?url=https%3A%2F%2Fexample.com' \
-H "X-Toolswitch-Key: $TOOLSWITCH_KEY"import os
import requests
response = requests.request(
"GET",
"https://toolswitch.dev/v1/tools/litescrape.web.screenshot?url=https%3A%2F%2Fexample.com",
headers={"X-Toolswitch-Key": os.environ["TOOLSWITCH_KEY"]},
)
response.raise_for_status()
print(response.text)const response = await fetch("https://toolswitch.dev/v1/tools/litescrape.web.screenshot?url=https%3A%2F%2Fexample.com", {
method: "GET",
headers: {
"X-Toolswitch-Key": process.env.TOOLSWITCH_KEY ?? "",
},
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
console.log(await response.text());This gateway API is in preview; its URL and authentication may change. The example parameters are sample data. Calls are billed at $0.00015/success, including the service fee.