---
title: "Capture screenshot of a web page"
method: POST
path: "/v1/web/screenshot"
tags: ["Web"]
---

# Capture screenshot of a web page

`POST /v1/web/screenshot`

Capture screenshot of the specified URL with optional configuration. Returns binary image data by default for optimal performance.

## Request body

- object
  - `url` string, uri, required
  - `waitTime` integer
  - `base64` boolean — Return base64 string instead of binary Uint8Array
  - `screenshotOptions` object
    - `captureBeyondViewport` boolean
    - `clip` object
      - `height` integer, required
      - `width` integer, required
      - `x` integer, required
      - `y` integer, required
      - `scale` number
    - `encoding` 'binary' | 'base64'
    - `fromSurface` boolean
    - `fullPage` boolean
    - `omitBackground` boolean
    - `optimizeForSpeed` boolean
    - `quality` integer
    - `type` 'png' | 'jpeg' | 'webp'
  - `viewport` object
    - `height` integer
    - `width` integer
    - `deviceScaleFactor` number
    - `hasTouch` boolean
    - `isLandscape` boolean
    - `isMobile` boolean

## Response `200`

Screenshot captured successfully - returns binary image data by default

- object
  - `success` true, required
  - `data` object, required
    - `metadata` object, required
      - `width` number, required
      - `height` number, required
      - `format` string, required
      - `size` number, required
      - `url` string, required
      - `timestamp` string, required
    - `permanentUrl` string, uri — Permanent R2 storage URL for the image
    - `fileId` string — Unique file ID for tracking
  - `creditsCost` number — Credits consumed by this operation
  - `requestId` string, uuid, required — Unique request identifier for tracing
  - `timestamp` string, date-time, required — ISO timestamp when the response was generated

## Other responses

- `401` — Authentication required
- `422` — Validation error
- `500` — Internal server error

---

[API](https://skmtc.net/weblinq/apis/weblinq-api.md) · [All operations](https://skmtc.net/weblinq/apis/weblinq-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/weblinq/weblinq-api/revisions/364690cf91b7/schema)
