{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Screenshot API: Full-Page PNG, JPEG and PDF Captures",
    "description": "Capture full-page or viewport screenshots of any public web page as PNG, JPEG or WebP, with an optional A4 PDF. Desktop or mobile width, cookie banners hidden, robots.txt obeyed, and you pay only for each image saved.",
    "version": "1.0",
    "x-build-id": "Q0diG7MhCgl6mLcgO"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/rowcraft~website-screenshot-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-rowcraft-website-screenshot-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/rowcraft~website-screenshot-api/runs": {
      "post": {
        "operationId": "runs-sync-rowcraft-website-screenshot-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/rowcraft~website-screenshot-api/run-sync": {
      "post": {
        "operationId": "run-sync-rowcraft-website-screenshot-api",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "required": [
          "urls"
        ],
        "properties": {
          "urls": {
            "title": "Website URLs",
            "type": "array",
            "description": "Pages to capture, one per line: a full address (https://example.com/pricing) or just a domain (example.com). Duplicates and invalid entries are skipped and never charged.",
            "items": {
              "type": "string"
            }
          },
          "format": {
            "title": "Image format",
            "enum": [
              "png",
              "jpeg",
              "webp"
            ],
            "type": "string",
            "description": "PNG is lossless and the sharpest; JPEG and WebP are much smaller for long pages (set the quality below).",
            "default": "png"
          },
          "fullPage": {
            "title": "Full page",
            "type": "boolean",
            "description": "Capture the whole scrollable page. Turn it off to capture only what fits in the window (width x height below). Ignored when a CSS selector is given. Pages taller than 16,000 px are cut at that height.",
            "default": true
          },
          "width": {
            "title": "Window width (px)",
            "minimum": 200,
            "maximum": 3840,
            "type": "integer",
            "description": "Width of the browser window in pixels. Default 1280 on desktop, 390 when Mobile view is on. Between 200 and 3840."
          },
          "height": {
            "title": "Window height (px)",
            "minimum": 200,
            "maximum": 4000,
            "type": "integer",
            "description": "Height of the browser window in pixels: the size of the picture when Full page is off. Default 800 on desktop, 844 on mobile. Between 200 and 4000."
          },
          "mobile": {
            "title": "Mobile view",
            "type": "boolean",
            "description": "Open the page as a phone does: touch device, mobile Chrome user agent and, unless you set a width, a 390 px wide window. Many sites then serve their mobile layout.",
            "default": false
          },
          "deviceScaleFactor": {
            "title": "Pixel ratio",
            "minimum": 1,
            "maximum": 3,
            "type": "integer",
            "description": "1 = one image pixel per page pixel. 2 or 3 give sharper pictures for retina screens, with 4 to 9 times as many pixels (bigger files, a lower page-height limit).",
            "default": 1
          },
          "quality": {
            "title": "JPEG / WebP quality",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "From 1 (smallest file) to 100 (best picture). Used for JPEG and WebP only; PNG is always lossless.",
            "default": 80
          },
          "selector": {
            "title": "CSS selector (one element)",
            "type": "string",
            "description": "Capture only the first element that matches this CSS selector (for example `#pricing` or `main article`) instead of the page. The row is not created when nothing visible matches."
          },
          "pdf": {
            "title": "Also save a PDF",
            "type": "boolean",
            "description": "Save an A4 PDF of the page (print layout, backgrounds included, up to 50 pages) next to the picture. Included in the price of the screenshot; the link is in `pdfUrl`.",
            "default": false
          },
          "delayMs": {
            "title": "Extra wait before the capture (ms)",
            "minimum": 0,
            "maximum": 30000,
            "type": "integer",
            "description": "Wait this long after the page has loaded, for animations, late widgets or slow scripts. 0 = no extra wait. The actor already waits for the network to go quiet.",
            "default": 0
          },
          "timeoutMs": {
            "title": "Page timeout (ms)",
            "minimum": 3000,
            "maximum": 120000,
            "type": "integer",
            "description": "Longest time to let a page load. A page that has not loaded by then is reported as a timeout and not charged. After the load the actor waits up to 10 more seconds for the network to go quiet.",
            "default": 20000
          },
          "hideCookieBanners": {
            "title": "Hide cookie banners",
            "type": "boolean",
            "description": "Hide the common cookie-consent banners and pop-ups with CSS before the capture. Nothing is clicked or accepted on the page.",
            "default": true
          },
          "scrollToLoad": {
            "title": "Scroll to load lazy images",
            "type": "boolean",
            "description": "For full-page captures, scroll down the page once (and back) so images that load on scroll appear in the picture. Adds about a second on long pages. It scrolls only; it never clicks.",
            "default": true
          },
          "maxItems": {
            "title": "Maximum screenshots delivered",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many screenshots are saved and delivered. 0 = the whole list.",
            "default": 0
          },
          "maxConcurrency": {
            "title": "Pages captured at the same time",
            "minimum": 1,
            "maximum": 4,
            "type": "integer",
            "description": "How many pages are open at once (1 to 4). The default 2 suits the 1 GB of memory of the run; raise it only together with the run's memory. Requests to the same site are still spaced out.",
            "default": 2
          },
          "onlyNew": {
            "title": "Only new rows since the last run",
            "type": "boolean",
            "description": "Remember the rows already delivered to you (in a key-value store in your Apify account) and deliver only rows that appeared since the last run with the same state key. The first run delivers everything that matches; later runs cost only the new rows. Ideal for schedules.",
            "default": false
          },
          "stateName": {
            "title": "State name",
            "type": "string",
            "description": "Name of the memory used by \"Only new rows\". Use a different name for each schedule or search (for example `stockholm-python`) so they do not share one memory.",
            "default": "default"
          },
          "notifyUrl": {
            "title": "Notify this URL when the run ends",
            "type": "string",
            "description": "A webhook address that receives one JSON POST with the number of new rows and links to the dataset: a Slack or Discord incoming webhook, a Make, n8n or Zapier catch hook, or your own endpoint. The message is also in the `text` (Slack) and `content` (Discord) fields."
          },
          "notifyWhenEmpty": {
            "title": "Notify also when there are no new rows",
            "type": "boolean",
            "description": "By default the notification is sent only when at least one row was delivered.",
            "default": false
          },
          "requestIntervalMs": {
            "title": "Delay between requests (ms)",
            "minimum": 250,
            "maximum": 10000,
            "type": "integer",
            "description": "Minimum pause between two page loads (and robots.txt reads) to the same site. Default 1000 ms. Pages on different sites are not delayed. Minimum 250.",
            "default": 1000
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}