Screenshot API
POST /screenshots
Capture full-page or viewport screenshots of any URL. Supports lazy-load triggering, ad blocking, dark mode, device emulation, and scheduled captures. Jobs are processed asynchronously — poll for status or use the dashboard gallery.
Endpoint
POST https://api.devutils.in/screenshotsReturns a job object immediately. The screenshot is captured asynchronously. Poll GET /screenshots/:jobId for status.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| url | string | Yes | The URL to capture. Must include https:// |
| type | string | No | Output format: png, webp, jpg. Default: png |
| waitTime | number | No | Extra seconds to wait after page load (0–30). Useful for lazy-loaded content. |
| scheduleAt | string | No | ISO 8601 datetime to schedule the capture. Omit for immediate capture. |
| viewport | object | No | { width, height, device } — device: desktop | mobile | tablet |
| capture | object | No | { fullPage, scrollY } — fullPage captures the entire scrollable page |
| options | object | No | Advanced rendering options (see below) |
Options Object
| Field | Type | Description |
|---|---|---|
| darkMode | boolean | Apply dark color scheme via CSS |
| blockAds | boolean | Block AdSense, DoubleClick, and common ad networks |
| blockCookieBanners | boolean | Hide GDPR/cookie consent banners via CSS selectors |
| hideChatWidgets | boolean | Hide Intercom, Drift, Zendesk, and similar chat widgets |
| hideSelectors | string[] | CSS selectors to hide before capture (e.g. [".banner", "#popup"]) |
| clickBeforeCapture | string[] | CSS selectors to click before capture (e.g. dismiss modals) |
Example Requests
Full page screenshotbash
curl -X POST https://api.devutils.in/screenshots \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com",
"type": "png",
"waitTime": 2,
"viewport": { "width": 1920, "height": 1080, "device": "desktop" },
"capture": { "fullPage": true },
"options": {
"blockAds": true,
"blockCookieBanners": true
}
}'Mobile screenshot with dark modebash
curl -X POST https://api.devutils.in/screenshots \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com",
"type": "webp",
"viewport": { "width": 375, "height": 667, "device": "mobile" },
"capture": { "fullPage": false },
"options": { "darkMode": true }
}'Response
The job is created immediately. Poll for completion.
Job created (202)json
{
"success": true,
"data": {
"id": "clx1abc123",
"status": "PENDING",
"url": "https://example.com",
"type": "png",
"createdAt": "2026-04-16T10:00:00.000Z"
}
}Completed job (GET /screenshots/:id)json
{
"success": true,
"data": {
"id": "clx1abc123",
"status": "COMPLETED",
"url": "https://example.com",
"type": "png",
"signedUrl": "/file-delivery/access/eyJhbGc...",
"createdAt": "2026-04-16T10:00:00.000Z"
}
}Async Job Flow
Screenshots are processed in a queue. The typical flow:
- POST /screenshots — creates the job, returns
idandstatus: "PENDING" - Poll GET /screenshots/:id — status transitions:
PENDING → PROCESSING → COMPLETED - Download — use the
signedUrlfrom the completed job (valid for 5 minutes)
Poll for completionbash
# Poll until status is COMPLETED or FAILED
curl https://api.devutils.in/screenshots/clx1abc123 \
-H "Authorization: Bearer YOUR_API_KEY"Limits
| Limit | Value |
|---|---|
| Max viewport width | 3840 px |
| Max viewport height | 2160 px |
| Max wait time | 30 seconds |
| Page load timeout | 30 seconds |
| Signed URL expiry | 5 minutes |
| Supported formats | PNG, WebP, JPG |