Nodium Screenshot API -- API Reference

Complete reference for all endpoints, parameters, error codes, and response headers.

Base URL: https://api.nodium.io/api/v1/screenshot


Table of Contents

- 1. Source - 2. Format & Response - 3. Viewport & Devices - 4. Full Page - 5. Selector - 6. Clip (Crop) - 7. Blocking - 8. Customization (CSS/JS Injection) - 9. Display Emulation - 10. Wait & Timing - 11. Request (Headers, Auth, Cookies) - 12. Geolocation - 13. Proxy - 14. Image Post-Processing - 15. PDF - 16. Cache - 17. Async & Webhooks - 18. Metadata Extraction - 19. Error Control - 20. Security -- Signed URLs - 21. AI Vision (OpenAI) - 22. Effects


Endpoints

GET/POST /take -- Static Screenshot

Captures a static screenshot of a web page, raw HTML, or Markdown content.

GET  https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png
POST https://api.nodium.io/api/v1/screenshot/take
  • GET: Parameters passed as query string
  • POST: Parameters passed as JSON body (Content-Type: application/json), or as query string, or mixed

Returns the screenshot as binary data (default), JSON metadata, or empty response depending on response_type.

GET/POST /animate -- Animated Screenshot / Video

Records a video or animated GIF of a web page, including scroll animations.

GET  https://api.nodium.io/api/v1/screenshot/animate?access_key=KEY&url=https://example.com&format=mp4
POST https://api.nodium.io/api/v1/screenshot/animate

Supports all /take parameters plus animation-specific parameters.

POST /bulk -- Batch Screenshots

Captures multiple screenshots in a single request.

POST https://api.nodium.io/api/v1/screenshot/bulk

See Bulk Parameters for request format.

GET /usage -- Usage Statistics

Returns current usage and quota information.

GET https://api.nodium.io/api/v1/screenshot/usage?access_key=KEY

Response:

json
{
  "total": 10000,
  "available": 7523,
  "used": 2477,
  "concurrency": {
    "limit": 10,
    "remaining": 8,
    "reset": 1709654400000000000
  }
}
FieldTypeDescription
totalintegerTotal screenshots allowed in the current billing period
availableintegerScreenshots remaining
usedintegerScreenshots successfully consumed
concurrency.limitintegerMaximum concurrent requests
concurrency.remainingintegerConcurrent request slots available right now
concurrency.resetintegerReset timestamp (UNIX nanoseconds)

Parameters

1. Source

One (and only one) source parameter is required per request.

ParameterTypeDefaultDescriptionExample
urlstring--URL of the web page to capture. Must be a valid HTTP/HTTPS URL.https://example.com
htmlstring--Raw HTML content to render and capture.<h1>Hello World</h1>
markdownstring--Markdown content to render and capture. Converted to HTML before rendering.# Hello World
bash
# Capture a URL
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png" -o page.png

# Render HTML
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{"html": "<h1 style=\"color:blue\">Hello Nodium</h1>", "format": "png"}' \
  -o html.png

# Render Markdown
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{"markdown": "# Hello Nodium\n\nThis is **bold** text.", "format": "png"}' \
  -o md.png

2. Format & Response

ParameterTypeDefaultDescriptionExample
formatstringpngOutput format. Image: png, jpeg/jpg, webp, avif, heif, tiff, jp2, gif. Document: pdf, html, markdown.webp
response_typestringby_formatHow the response is returned. by_format = raw binary, json = JSON metadata with screenshot URL, empty = HTTP status only.json
bash
# Get JSON response with metadata
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&response_type=json"

3. Viewport & Devices

ParameterTypeDefaultDescriptionExample
viewport_widthinteger1280Viewport width in pixels.1440
viewport_heightinteger1024Viewport height in pixels.900
device_scale_factorfloat1Device pixel ratio (1--5, supports decimals like 2.25). Set to 2 for Retina displays.2
viewport_devicestring--Preset device ID. Automatically sets width, height, scale factor, mobile, touch, landscape, and user agent. Individual parameters can override the preset. See Device Presets.iphone_16_pro
viewport_mobilebooleanfalseEnable mobile viewport meta tag handling.true
viewport_has_touchbooleanfalseEnable touch event emulation.true
viewport_landscapebooleanfalseRotate the viewport to landscape orientation.true
bash
# Retina screenshot
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&device_scale_factor=2" -o retina.png

# iPhone 16 Pro emulation
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&viewport_device=iphone_16_pro" -o iphone.png

# Custom dimensions, landscape
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&viewport_width=1920&viewport_height=1080&viewport_landscape=true" -o wide.png

Device Presets

The viewport_device parameter accepts any of the following preset IDs. Each portrait device also has a _landscape variant (e.g. iphone_16_landscape).

Apple -- iPhones

Device IDWidthHeightScale
iphone_se3756672
iphone_xr4148962
iphone_114148962
iphone_11_pro3758123
iphone_11_pro_max4148963
iphone_12_mini3758123
iphone_123908443
iphone_12_pro3908443
iphone_13_mini3758123
iphone_133908443
iphone_13_pro3908443
iphone_13_pro_max4289263
iphone_143908443
iphone_14_pro3938523
iphone_14_pro_max4309323
iphone_153938523
iphone_15_pro3938523
iphone_15_pro_max4309323
iphone_163938523
iphone_16_pro4028743
iphone_16_pro_max4409563

Apple -- iPads

Device IDWidthHeightScale
ipad81010802
ipad_air82011802
ipad_mini74411332
ipad_pro_1183411942
ipad_pro_12_9102413662

Google Pixel

Device IDWidthHeightScale
pixel_53938512.75
pixel_64129152.625
pixel_74129152.625
pixel_7_pro4128922.625
pixel_84129152.625
pixel_8_pro4128922.625
pixel_94129152.625
pixel_9_pro4128922.625
pixel_9_pro_fold3738392.625

Samsung Galaxy

Device IDWidthHeightScale
galaxy_s213608003
galaxy_s223607803
galaxy_s233607803
galaxy_s243607803
galaxy_s24_ultra3848243
galaxy_note_204128833
galaxy_z_fold_53738393
galaxy_z_flip_53607803
galaxy_a544129152.625
galaxy_tab_s980012802
galaxy_tab_s9_ultra102413662

Other Android

Device IDWidthHeightScale
oneplus_124129153.5
xiaomi_143938733
kindle_fire_hdx80012802

Microsoft Surface

Device IDWidthHeightScale
surface_pro_913689122
surface_duo5407202.5

Desktop

Device IDWidthHeightScale
desktop_hd12807201
desktop_wxga12808001
desktop_sxga128010241
desktop_1080p192010801
desktop_uxga160012001
desktop_wuxga192012001
desktop_1440p256014401
desktop_4k384021601

Laptops / Macs

Device IDWidthHeightScale
laptop13667681
macbook_air14409002
macbook_air_15171011122
macbook_pro_14302419642
macbook_pro_16345622342
imac_24448025202

Social Media

Device IDWidthHeightUse Case
social_instagram_post10801080Instagram square post
social_instagram_story10801920Instagram story / Reels
social_twitter_post1200675Twitter/X card
social_facebook_post1200630Facebook link preview
social_linkedin_post1200627LinkedIn post image
social_og_image1200630Open Graph image

4. Full Page

ParameterTypeDefaultDescriptionExample
full_pagebooleanfalseCapture the entire scrollable page, not just the visible viewport.true
full_page_scrollbooleantrue (when full_page is enabled)Physically scroll the page before capture. Triggers lazy-loaded images and content.true
full_page_scroll_delayinteger (ms)400Delay between each scroll step. Increase for pages with heavy lazy-loading.800
full_page_scroll_byinteger (px)viewport heightPixels to scroll per step.500
full_page_max_heightinteger (px)unlimitedMaximum capture height. Protects against infinite-scroll pages.15000
full_page_algorithmstringdefaultdefault = Chrome DevTools Protocol native capture. by_sections = captures section by section then stitches.by_sections
bash
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&full_page=true&full_page_scroll=true&full_page_scroll_delay=600&full_page_max_height=20000" -o fullpage.png

5. Selector

ParameterTypeDefaultDescriptionExample
selectorstring (CSS)--CSS selector of the element to capture. Only that element is included in the output. Prefix with shadow/ to traverse Shadow DOM (e.g. shadow/.my-element).#main-content
selector_algorithmstringdefaultdefault = browser-native bounding box. clip = clip-based capture (better for partially visible elements).clip
selector_scroll_into_viewbooleantrueScroll to the element before capturing. Useful for triggering lazy-load.true
error_on_selector_not_foundbooleanfalseReturn an error if the CSS selector does not match any element.true
scroll_into_viewstring (CSS)--Scroll the page until this selector is visible, then capture the full viewport..footer
scroll_into_view_adjust_topinteger (px)0Vertical offset adjustment when scrolling to the element. Positive = down, negative = up.-50
capture_beyond_viewportbooleanfalseAllow capturing content that extends beyond the visible viewport.true
bash
# Capture a specific element
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&selector=%23main-content" -o element.png

# Capture an element inside Shadow DOM
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&selector=shadow/.hero-banner" -o shadow.png

6. Clip (Crop)

Crop a rectangular region from the page. All four parameters must be provided together.

ParameterTypeDefaultDescriptionExample
clip_xinteger--Left coordinate of the crop area in pixels.100
clip_yinteger--Top coordinate of the crop area in pixels.200
clip_widthinteger--Width of the crop area in pixels.800
clip_heightinteger--Height of the crop area in pixels.600
bash
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&clip_x=0&clip_y=0&clip_width=800&clip_height=400" -o cropped.png

7. Blocking

ParameterTypeDefaultDescriptionExample
block_adsbooleanfalseBlock advertisements using EasyList/uBlock filter lists.true
block_cookie_bannersbooleanfalseBlock GDPR/cookie consent banners.true
block_banners_by_heuristicsbooleanfalseAlternative heuristic-based banner blocking. Use if block_cookie_banners is insufficient.true
block_chatsbooleanfalseBlock live chat widgets (Intercom, Crisp, Drift, Tawk, Zoho, FB Messenger, etc.).true
block_trackersbooleanfalseBlock analytics and tracking scripts.true
block_requestsstring[]--Block network requests matching URL patterns. Supports wildcards (*).["google-analytics", ".doubleclick.net"]
block_resourcesstring[]--Block requests by resource type: document, stylesheet, image, media, font, script, xhr, fetch, websocket, eventsource, manifest, other.["font", "media"]
hide_selectorsstring[]--Hide elements by CSS selector (applies display: none !important).[".popup", "#banner"]
bash
# Clean screenshot without distractions
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&block_ads=true&block_cookie_banners=true&block_chats=true&block_trackers=true" -o clean.png

# Block specific domains
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com",
    "format": "png",
    "block_requests": ["*analytics*", "*tracking*"],
    "hide_selectors": [".newsletter-popup", ".cookie-banner"]
  }' -o blocked.png

8. Customization (CSS/JS Injection)

ParameterTypeDefaultDescriptionExample
stylesstring--Custom CSS injected into the page before capture.body { font-size: 18px; } .ad { display: none; }
scriptsstring--Custom JavaScript executed before capture.document.querySelector('.popup').remove();
scripts_wait_untilstring[]--Navigation events to wait for after script execution: load, domcontentloaded, networkidle0, networkidle2. Required if the script triggers a redirect.["networkidle0"]
clickstring (CSS)--Click on an element before capture. Supports shadow/ prefix for Shadow DOM..accept-cookies
error_on_click_selector_not_foundbooleantrueReturn an error if the click target is not found.false
hoverstring (CSS)--Hover over an element before capture. Supports shadow/ prefix..tooltip-trigger
error_on_hover_selector_not_foundbooleantrueReturn an error if the hover target is not found.false
bash
# Inject custom styles
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&styles=body%7Bbackground%3Ared%7D" -o styled.png

# Click a button before capture
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com",
    "format": "png",
    "click": ".accept-cookies",
    "delay": 1
  }' -o clicked.png

9. Display Emulation

ParameterTypeDefaultDescriptionExample
dark_modeboolean--Force color scheme. true = prefers-color-scheme: dark, false = prefers-color-scheme: light. Omit to use the site default.true
reduced_motionbooleanfalseForce prefers-reduced-motion: reduce. Disables CSS animations.true
media_typestringscreenCSS media type emulation. screen (default) or print (useful for PDF).print
omit_backgroundbooleanfalseTransparent page background. Works with PNG, WebP (images) and MOV (video).true
bash
# Dark mode screenshot
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&dark_mode=true" -o dark.png

# Transparent background
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&omit_background=true" -o transparent.png

10. Wait & Timing

ParameterTypeDefaultDescriptionExample
delayinteger (seconds)0Additional wait time after page load, before capture. Values > 30s require async=true and timeout > 300.3
wait_untilstring[]["load"]Browser events to wait for: load, domcontentloaded, networkidle0 (0 connections for 500ms), networkidle2 (max 2 connections for 500ms). When multiple values are given, all must be satisfied.["load", "networkidle2"]
wait_for_selectorstring (CSS)--Wait until this CSS selector appears in the DOM. Supports comma-separated selectors..content-loaded
wait_for_selector_algorithmstringat_least_oneat_least_one = any selector matches. at_least_by_count = each selector matches at least once.at_least_by_count
timeoutinteger (seconds)60Global timeout. Max: 90 (sync), 300 (async).90
navigation_timeoutinteger (seconds)30Navigation timeout. Max: 30.15
bash
# Wait for dynamic content
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&wait_until=networkidle0&wait_for_selector=.main-content&delay=2" -o waited.png

11. Request (Headers, Auth, Cookies)

ParameterTypeDefaultDescriptionExample
user_agentstringChrome defaultCustom User-Agent string. Overridden by viewport_device.MyBot/1.0
headersstring[]--Custom HTTP headers. Format: Header-Name:Header-Value. Multiple headers supported.["X-Custom:value", "Accept-Language:fr-FR"]
cookiesstring[]--Custom cookies. Format: name=value; Domain=domain; Secure; HttpOnly. Multiple cookies supported.["session=abc123; Domain=example.com"]
authorizationstring--Authorization header value. Supports Basic, Bearer, and other schemes.Bearer eyJhbGci...
time_zonestring--Emulated timezone. Uses IANA timezone IDs.Europe/Paris
bypass_cspbooleanfalseBypass the site's Content Security Policy. Necessary when injecting custom scripts on pages with strict CSP.true
bash
# Screenshot with authentication
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://app.example.com/dashboard",
    "format": "png",
    "authorization": "Bearer eyJhbGciOiJIUzI1NiIs...",
    "cookies": ["session=abc123; Domain=example.com; Secure"],
    "time_zone": "America/New_York"
  }' -o dashboard.png

12. Geolocation

All geolocation parameters must be provided together.

ParameterTypeDefaultDescriptionExample
geolocation_latitudefloat--Latitude coordinate.48.858184 (Eiffel Tower)
geolocation_longitudefloat--Longitude coordinate.2.294720
geolocation_accuracyfloat (meters)--Accuracy in meters.10
bash
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://maps.google.com&format=png&geolocation_latitude=48.858184&geolocation_longitude=2.294720&geolocation_accuracy=10" -o paris.png

13. Proxy

ParameterTypeDefaultDescriptionExample
ip_country_codestring--Route through a datacenter proxy in the specified country. Supported: us, gb, de, fr, it, es, jp, kr, cn, in, au, br, mx, ca, nz, pe, is, ie.us
proxystring--Custom HTTP proxy. Format: http://user:password@host:port/. Overrides ip_country_code.http://user:pass@proxy.example.com:8080/
bash
# Capture as seen from Japan
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&ip_country_code=jp" -o japan.png

14. Image Post-Processing

ParameterTypeDefaultDescriptionExample
image_qualityinteger (0--100)80Image compression quality. Applies to: jpeg, webp, png, tiff, jp2, avif, heif.95
image_widthintegerviewport widthResize the output image to this width. Aspect ratio is preserved.640
image_heightintegerviewport heightResize the output image to this height. Aspect ratio is preserved.480
bash
# High-quality JPEG with specific dimensions
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=jpeg&image_quality=95&image_width=800" -o resized.jpg

15. PDF

ParameterTypeDefaultDescriptionExample
pdf_print_backgroundbooleanfalsePrint background graphics and colors.true
pdf_fit_one_pagebooleanfalseScale content to fit on a single page.true
pdf_landscapebooleanfalseLandscape orientation.true
pdf_paper_formatstringa4Paper size: a0, a1, a2, a3, a4, a5, a6, legal, letter, tabloid.letter
pdf_marginstring0Uniform margin for all sides. Accepts CSS units.20px
pdf_margin_topstring--Override top margin.10mm
pdf_margin_rightstring--Override right margin.10mm
pdf_margin_bottomstring--Override bottom margin.10mm
pdf_margin_leftstring--Override left margin.10mm
Recommended combination for full-page PDF: format=pdf&media_type=screen&pdf_print_background=true&pdf_fit_one_page=true
bash
# Generate a PDF with background and margins
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=pdf&pdf_print_background=true&pdf_paper_format=a4&pdf_margin=20px" -o document.pdf

16. Cache

ParameterTypeDefaultDescriptionExample
cachebooleanfalseEnable caching. Cached screenshots are not counted against your quota and are not logged.true
cache_ttlinteger (seconds)--Cache time-to-live. Min: 14400 (4 hours), Max: 2592000 (30 days).86400 (24 hours)
cache_keystring--Custom cache key to differentiate cached versions.homepage-v2

Cache behavior:

  • The cache key is computed from all request parameters combined
  • Cached results are served via CDN and are shareable without exposing your API key
  • The cache URL is returned in the x-nodium-cache-url response header and in the JSON response (cache_url)
  • Caching is not compatible with webhooks
bash
# Cache for 24 hours
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&cache=true&cache_ttl=86400" -o cached.png

17. Async & Webhooks

ParameterTypeDefaultDescriptionExample
asyncbooleanfalseRun the screenshot asynchronously. Returns 202 Accepted immediately after credential validation. Result is delivered via webhook.true
webhook_urlstring--URL to POST the screenshot result to when processing completes.https://hooks.example.com/screenshot
webhook_signbooleantrueSign the webhook body with HMAC SHA-256 using your signing key.true
webhook_errorsbooleanfalseInclude error details in the webhook payload.true
external_identifierstring--Custom identifier returned in the webhook headers as x-nodium-external-identifier.order-12345

Webhook headers delivered to your endpoint:

HeaderDescription
X-Nodium-SignatureHMAC SHA-256 signature of the body
x-nodium-rendering-secondsRendering time
x-nodium-size-bytesScreenshot file size
x-nodium-trace-idTrace ID
x-nodium-referenceScreenshot reference
x-nodium-external-identifierYour custom identifier
x-nodium-error-codeError code (if webhook_errors=true)
x-nodium-error-messageError message (if webhook_errors=true)
bash
# Async screenshot with webhook
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://heavy-page.example.com",
    "format": "png",
    "async": true,
    "webhook_url": "https://hooks.example.com/screenshot-ready",
    "webhook_sign": true,
    "external_identifier": "job-42"
  }'

18. Metadata Extraction

All metadata parameters are disabled by default for performance. Enable only what you need.

ParameterTypeDefaultDescriptionJSON Response FieldResponse Header
metadata_image_sizebooleanfalseOutput image dimensions.metadata.image_size.{width, height}x-nodium-image-width, x-nodium-image-height
metadata_page_titlebooleanfalsePage <title> tag.metadata.page_titlex-nodium-page-title
metadata_open_graphbooleanfalseOpen Graph meta tags (title, description, image, url, type, site_name).metadata.open_graphx-nodium-open-graph
metadata_iconbooleanfalseFavicon URL and type.metadata.icon.{url, type}x-nodium-icon
metadata_fontsbooleanfalseFonts used on the page.metadata.fonts--
metadata_contentbooleanfalseExtract page content and upload to CDN. Returns a temporary URL.content.{url, expires}x-nodium-content-url, x-nodium-content-expires
metadata_content_formatstringhtmlFormat for content extraction: html or markdown.----
metadata_http_response_status_codebooleanfalseHTTP status code returned by the target site.http_response.status_codex-nodium-http-status-code
metadata_http_response_headersbooleanfalseHTTP response headers from the target site.http_response.headersx-nodium-http-headers
bash
# Extract Open Graph data and page title
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&response_type=json&metadata_page_title=true&metadata_open_graph=true&metadata_icon=true"

19. Error Control

ParameterTypeDefaultDescriptionExample
ignore_host_errorsbooleanfalseCapture the screenshot even if the target site returns a non-2xx HTTP status code.true
fail_if_content_containsstring[]--Fail if the page body contains any of the specified strings (case-insensitive).["Access Denied", "404 Not Found"]
fail_if_content_missingstring[]--Fail if the page body does not contain any of the specified strings (case-insensitive).["Welcome back"]
fail_if_request_failedstring--Fail if any network request matching this URL pattern fails.api.example.com
fail_if_gpu_rendering_failsbooleanfalseFail instead of falling back to CPU/software rendering when GPU is unavailable.true
Note: Screenshots that fail due to fail_if_* conditions are not counted against your quota.
bash
# Fail if the page shows an error
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com/dashboard",
    "format": "png",
    "fail_if_content_contains": ["Access Denied", "Login Required"],
    "fail_if_content_missing": ["Dashboard"]
  }' -o dashboard.png

20. Security -- Signed URLs

ParameterTypeDefaultDescriptionExample
signaturestring--HMAC-SHA256 signature of all request parameters, generated with your signing key.a1b2c3d4e5f6...

How it works:

  1. Concatenate all query parameters (sorted alphabetically, excluding signature) into a canonical string
  2. Sign the string using HMAC-SHA256 with your signing key (available in the Nodium Dashboard)
  3. Append the hex-encoded signature as the signature parameter

Enforcement: Signature validation can be made mandatory for your organization in the Dashboard under Settings > Signed URLs. When enforced, all requests without a valid signature are rejected with signature_is_required.

Use case: Signed URLs allow you to safely expose screenshot URLs on the client side (e.g. in <img> tags) without revealing your API key.

bash
# Signed URL example
curl "https://api.nodium.io/api/v1/screenshot/take?access_key=KEY&url=https://example.com&format=png&signature=a1b2c3d4e5f6789012345678abcdef"

21. AI Vision (OpenAI)

ParameterTypeDefaultDescriptionExample
openai_api_keystring--Your OpenAI API key. Not stored by Nodium.sk-proj-...
vision_promptstring--Prompt sent to GPT Vision along with the screenshot.Describe the layout of this page
vision_max_tokensinteger--Maximum tokens for the GPT Vision response.500

The Vision completion is returned in:

  • JSON response: vision.completion
  • Header: X-Nodium-Vision-Completion
bash
# Analyze a screenshot with GPT Vision
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com",
    "format": "png",
    "response_type": "json",
    "openai_api_key": "sk-proj-...",
    "vision_prompt": "List all navigation menu items visible on this page.",
    "vision_max_tokens": 300
  }'

22. Effects

ParameterTypeDefaultDescriptionExample
watermarkstring--Text watermark overlaid on the image.DRAFT
watermark_image_urlstring--URL of an image to use as watermark.https://example.com/logo.png
watermark_opacityfloat (0--1)0.5Watermark opacity.0.3
blurstring[]--CSS selectors of elements to blur (useful for anonymizing sensitive data).[".email", ".phone-number"]
bash
# Watermark and blur sensitive info
curl -X POST "https://api.nodium.io/api/v1/screenshot/take" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com/profile",
    "format": "png",
    "watermark": "CONFIDENTIAL",
    "watermark_opacity": 0.2,
    "blur": [".personal-info", ".credit-card"]
  }' -o redacted.png

Animation Parameters (/animate)

The /animate endpoint accepts all parameters from /take plus the following animation-specific parameters.

Core Animation

ParameterTypeDefaultDescriptionExample
scenariostringdefaultAnimation scenario. default = records the page after load without scrolling. scroll = records a scroll animation.scroll
formatstringmp4Video format: mp4, webm, gif, mov, avi.gif
durationinteger (seconds)5Recording duration. Min: 1, Max: 30.10
widthintegerviewport widthVideo width. Ignored if aspect_ratio is set.1280
heightintegerviewport heightVideo height. Ignored if aspect_ratio is set.720
aspect_ratiostring--Aspect ratio (overrides width/height).16:9

Scroll Animation (scenario=scroll)

ParameterTypeDefaultDescription
scroll_delayinteger (ms)500Delay between scroll steps.
scroll_durationinteger (ms)1500Duration of a single scroll action.
scroll_byinteger (px)1000Pixels per scroll step.
scroll_start_immediatelybooleantrueStart scrolling immediately or wait for scroll_delay.
scroll_start_delayinteger (ms)0Wait time before the first scroll.
scroll_backbooleantrueScroll back up after reaching the bottom.
scroll_back_algorithmstringonceonce = smooth scroll up with easing. repeat = reverse the scroll-down algorithm.
scroll_back_after_durationinteger (ms)--Start scrolling back after this duration.
scroll_completebooleantrueStop recording when the scroll completes.
scroll_stop_after_durationinteger (ms)--Stop scrolling after this duration.
scroll_easingstringease_in_out_quintEasing function (see below).
scroll_try_navigateboolean--Navigate to a new page during the scroll.
scroll_navigate_afterinteger (ms)duration / 2When to navigate during the scroll.
scroll_navigate_to_urlstring--Destination URL for navigation.
scroll_navigate_link_hintsstring[]["pricing", "about", "customers"]Keywords to match link text for auto-navigation.
scroll_till_selectorstring (CSS)--Scroll until this selector becomes visible.
scroll_till_selector_adjust_topinteger--Vertical offset when scrolling to the selector.
scroll_to_end_afterinteger (ms)--Jump to the bottom after this duration, in one smooth motion with easing.

Easing Functions

Available values for scroll_easing:

FunctionDescription
linearConstant speed
ease_in_quadGradual acceleration (quadratic)
ease_out_quadGradual deceleration (quadratic)
ease_in_out_quadAcceleration then deceleration (quadratic)
ease_in_cubicGradual acceleration (cubic)
ease_out_cubicGradual deceleration (cubic)
ease_in_out_cubicAcceleration then deceleration (cubic)
ease_in_quartGradual acceleration (quartic)
ease_out_quartGradual deceleration (quartic)
ease_in_out_quartAcceleration then deceleration (quartic)
ease_in_quintGradual acceleration (quintic)
ease_out_quintGradual deceleration (quintic)
ease_in_out_quintAcceleration then deceleration (quintic) -- default
bash
# Record a 10-second scroll animation as GIF
curl "https://api.nodium.io/api/v1/screenshot/animate?access_key=KEY&url=https://example.com&format=gif&scenario=scroll&duration=10&scroll_easing=ease_in_out_cubic" -o scroll.gif

# MP4 video with custom scroll settings
curl -X POST "https://api.nodium.io/api/v1/screenshot/animate" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com",
    "format": "mp4",
    "scenario": "scroll",
    "duration": 15,
    "scroll_by": 500,
    "scroll_duration": 2000,
    "scroll_back": true,
    "scroll_easing": "ease_in_out_quint"
  }' -o video.mp4

Bulk Parameters (/bulk)

The /bulk endpoint accepts a JSON body with the following structure:

ParameterTypeDefaultDescription
executebooleanfalsetrue = execute all screenshots before responding (eager). false = return URLs that trigger capture on access (lazy).
optimizebooleanfalseOptimize when multiple requests target the same URL with different parameters. Requires execute=true.
optionsobject--Default ScreenshotOptions applied to every request in the batch.
requestsarray--Array of individual ScreenshotOptions objects. Each can override the defaults from options.

Request format

json
{
  "access_key": "KEY",
  "execute": true,
  "optimize": true,
  "options": {
    "format": "png",
    "viewport_width": 1280,
    "viewport_height": 1024,
    "block_ads": true
  },
  "requests": [
    { "url": "https://example.com" },
    { "url": "https://example.com/about", "format": "jpeg" },
    { "url": "https://example.com/pricing", "viewport_device": "iphone_16" }
  ]
}

Response format

Without execute (lazy):

json
[
  { "url": "https://api.nodium.io/api/v1/screenshot/take?..." },
  { "url": "https://api.nodium.io/api/v1/screenshot/take?..." },
  { "url": "https://api.nodium.io/api/v1/screenshot/take?..." }
]

With execute=true (eager):

json
[
  {
    "url": "https://api.nodium.io/api/v1/screenshot/take?...",
    "response": {
      "is_successful": true,
      "status": 200,
      "body": "<base64-encoded screenshot>"
    }
  }
]
bash
# Bulk screenshot request
curl -X POST "https://api.nodium.io/api/v1/screenshot/bulk" \
  -H "X-Access-Key: KEY" -H "Content-Type: application/json" \
  -d '{
    "execute": true,
    "options": { "format": "png", "block_ads": true },
    "requests": [
      { "url": "https://example.com" },
      { "url": "https://example.com/about" },
      { "url": "https://example.com/pricing" }
    ]
  }'

Error Codes

Complete list of all API error codes.

Error CodeHTTP StatusDescriptionRecommended Action
access_key_required400Access key is missing.Provide your API key via header, query parameter, or JSON body.
access_key_invalid400Access key is invalid or revoked.Check your API key in the Dashboard. Generate a new one if needed.
signature_is_required400Signed URL is required for this organization.Generate a signed URL using your signing key.
signature_is_not_valid400Signature does not match.Verify your signing key and the parameter canonical string.
screenshots_limit_reached400Monthly quota exceeded.Upgrade your plan or wait for the next billing period.
concurrency_limit_reached400Too many concurrent requests.Wait for ongoing requests to complete, or upgrade your plan.
request_not_valid400Invalid request parameters.Check the error message for details on which parameter is invalid.
selector_not_found400CSS selector not found on the page.Verify the selector exists. Disable with error_on_selector_not_found=false.
invalid_cookie_parameter400Malformed cookie string.Use the format name=value; Domain=domain.
invalid_header_parameter400Malformed header string.Use the format Header-Name:Header-Value.
resulting_image_too_large400Output image exceeds size limits.Reduce viewport size, disable full_page, or lower device_scale_factor.
request_body_too_large413Request body too large.Reduce the size of html or markdown content.
name_not_resolved400DNS resolution failed.Verify the URL is correct and the domain exists.
network_error500Cannot connect to the target URL.Check if the target is accessible. Retry with exponential backoff.
host_returned_error500Target site returned non-2xx status.Use ignore_host_errors=true to capture anyway.
timeout_error500Operation timed out.Increase timeout, use async=true for long operations, or simplify the request.
content_contains_specified_string500Page contains a forbidden string (fail_if_content_contains).Review the page content or adjust the condition.
content_missing_specified_string500Page is missing a required string (fail_if_content_missing).Review the page content or adjust the condition.
matched_failed_request500A network request matching fail_if_request_failed has failed.Check the target API or adjust the pattern.
script_triggers_redirect400Injected script caused a redirect.Add scripts_wait_until to handle the navigation.
storage_access_denied400Cannot access storage service.Verify your storage credentials in the Dashboard.
internal_application_error500Internal server error. Safe to retry.Retry with exponential backoff.
temporary_unavailable503Service is overloaded. Safe to retry.Wait and retry with exponential backoff.

Response Headers

Every successful response includes the following headers:

HeaderDescriptionExample
x-nodium-rendering-secondsTime spent rendering the screenshot (seconds).2.34
x-nodium-size-bytesSize of the output file in bytes.245760
x-nodium-referenceUnique reference ID for this screenshot.1234567
x-nodium-trace-idTrace ID for debugging and support requests.abc123-def456
x-nodium-cache-urlPublic URL of the cached screenshot (when cache=true).https://cdn.nodium.io/cache/abc.png
x-nodium-image-widthImage width in pixels (when metadata_image_size=true).1280
x-nodium-image-heightImage height in pixels (when metadata_image_size=true).1024
x-nodium-page-titlePage title (when metadata_page_title=true).Example Domain
x-nodium-open-graphJSON-encoded Open Graph data (when metadata_open_graph=true).{"title":"..."}
x-nodium-iconJSON-encoded favicon info (when metadata_icon=true).{"url":"...","type":"image/x-icon"}
x-nodium-http-status-codeTarget site HTTP status (when metadata_http_response_status_code=true).200
x-nodium-http-headersTarget site response headers (when metadata_http_response_headers=true).JSON-encoded headers
x-nodium-content-urlURL to extracted content (when metadata_content=true).https://cdn.nodium.io/content/abc.html
x-nodium-content-expiresExpiration timestamp for content URL.2026-03-06T00:00:00Z
X-Nodium-Vision-CompletionGPT Vision response (when vision_prompt is set).The page shows...
x-nodium-external-identifierYour custom identifier (webhooks only).order-12345
X-Nodium-SignatureHMAC-SHA256 signature (webhooks only, when webhook_sign=true).a1b2c3d4...