{
  "openapi": "3.0.1",
  "info": {
    "title": "Screenshot URL: Website Screenshot and Visual Change Monitor",
    "description": "Screenshot URL tool: full-page or viewport screenshots of many URLs as PNG, JPEG, WebP or PDF, phone and tablet presets, element screenshots by CSS selector, cookie banners hidden. Monitor mode alerts when a page visually changes, with the diff percent and a diff image. Failed URLs are free.",
    "version": "0.1",
    "x-build-id": "m7LYUVIdgzlLgSdN5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/datahamster~screenshot-url/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-datahamster-screenshot-url",
        "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/datahamster~screenshot-url/runs": {
      "post": {
        "operationId": "runs-sync-datahamster-screenshot-url",
        "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/datahamster~screenshot-url/run-sync": {
      "post": {
        "operationId": "run-sync-datahamster-screenshot-url",
        "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",
        "properties": {
          "urls": {
            "title": "URLs",
            "type": "array",
            "description": "Pages to capture, one per line, e.g. \"https://apify.com\". Any number per run. Private and internal addresses are refused, also after redirects.",
            "default": [
              "https://apify.com"
            ],
            "items": {
              "type": "string"
            }
          },
          "format": {
            "title": "Format",
            "enum": [
              "png",
              "jpeg",
              "webp",
              "pdf"
            ],
            "type": "string",
            "description": "File type. JPEG and WebP files are much smaller than PNG. PDF prints the page (A4 by default).",
            "default": "png"
          },
          "fullPage": {
            "title": "Full page",
            "type": "boolean",
            "description": "true = the whole scrollable page (cut at Max height). false = only the visible viewport. Empty = full page in scrape mode, viewport in monitor mode. A full-page monitor runs with 2 GB of memory automatically."
          },
          "device": {
            "title": "Device",
            "enum": [
              "desktop",
              "desktop-hd",
              "laptop",
              "desktop-retina",
              "ipad",
              "iphone-15",
              "iphone-se",
              "pixel-7"
            ],
            "type": "string",
            "description": "Viewport, pixel ratio and user agent. Phone and tablet presets emulate a mobile browser (touch, mobile layout).",
            "default": "desktop"
          },
          "selector": {
            "title": "Element screenshot (CSS selector)",
            "type": "string",
            "description": "Optional: capture only the first element matching this CSS selector, e.g. \"#pricing\" or \"main table\". A page without it is a free failed row."
          },
          "waitUntil": {
            "title": "Wait until",
            "enum": [
              "load",
              "domcontentloaded",
              "networkidle"
            ],
            "type": "string",
            "description": "When to capture. Network idle waits for requests to stop but never longer than 15 s, so pages that poll forever still get captured.",
            "default": "load"
          },
          "waitForSelector": {
            "title": "Wait for selector",
            "type": "string",
            "description": "Optional: wait until this CSS selector is visible before capturing, e.g. \".price\". Not appearing within the timeout = free failed row."
          },
          "delayMs": {
            "title": "Extra delay (ms)",
            "minimum": 0,
            "maximum": 60000,
            "type": "integer",
            "description": "Wait this long after loading, before the capture, e.g. 1000 for animations.",
            "default": 0
          },
          "scrollToBottom": {
            "title": "Scroll to bottom first",
            "type": "boolean",
            "description": "true = scroll the page down to Max height and back before the capture, so lazy-loaded images appear in full-page shots.",
            "default": false
          },
          "hideCookieBanners": {
            "title": "Hide cookie banners",
            "type": "boolean",
            "description": "true = hide consent banners and their dark overlays (OneTrust, Cookiebot, Usercentrics, Didomi, Quantcast, TrustArc, Google and 30 more, plus fixed boxes that mention cookies). Nothing is clicked or accepted.",
            "default": true
          },
          "hideSelectors": {
            "title": "Hide these elements",
            "type": "array",
            "description": "CSS selectors to hide before the capture, e.g. \".ad-slot\" or \"#chat-widget\". In monitor mode this is how you mask clocks, tickers and rotating ads.",
            "items": {
              "type": "string"
            }
          },
          "quality": {
            "title": "JPEG/WebP quality",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "1-100, only for JPEG and WebP.",
            "default": 80
          },
          "viewportWidth": {
            "title": "Viewport width (px)",
            "minimum": 240,
            "maximum": 3840,
            "type": "integer",
            "description": "Optional: override the device preset's width, e.g. 1366."
          },
          "viewportHeight": {
            "title": "Viewport height (px)",
            "minimum": 240,
            "maximum": 4320,
            "type": "integer",
            "description": "Optional: override the device preset's height, e.g. 768."
          },
          "deviceScaleFactor": {
            "title": "Pixel ratio",
            "minimum": 1,
            "maximum": 3,
            "type": "number",
            "description": "Optional: override the preset's device pixel ratio, e.g. 2 for retina-sharp images (4x the pixels)."
          },
          "maxHeight": {
            "title": "Max height (px)",
            "minimum": 500,
            "maximum": 30000,
            "type": "integer",
            "description": "Full-page and element shots are cut at this height in CSS pixels, and every image stays within 16 million pixels (width x height x pixel ratio squared); the row then has truncatedAtMaxHeight: true.",
            "default": 10000
          },
          "pdfFormat": {
            "title": "PDF paper size",
            "enum": [
              "A4",
              "Letter",
              "Legal",
              "A3"
            ],
            "type": "string",
            "description": "Only for format PDF.",
            "default": "A4"
          },
          "diffThresholdPercent": {
            "title": "Monitor: change threshold (%)",
            "minimum": 0.001,
            "maximum": 100,
            "type": "number",
            "description": "Monitor mode: report a page only when more than this share of its pixels changed since the last reported screenshot, e.g. 1. Smaller changes add up until they cross it.",
            "default": 1
          },
          "pixelTolerance": {
            "title": "Monitor: pixel tolerance",
            "minimum": 0,
            "maximum": 254,
            "type": "integer",
            "description": "Monitor mode: how much a pixel's color may differ (0-255 per channel) and still count as the same. 32 ignores anti-aliasing and JPEG noise.",
            "default": 32
          },
          "proxyTier": {
            "title": "Proxy",
            "enum": [
              "auto",
              "none",
              "datacenter",
              "residential"
            ],
            "type": "string",
            "description": "auto = start without a proxy and step up to datacenter, then residential, only when a site answers with a block or challenge.",
            "default": "auto"
          },
          "proxyCountry": {
            "title": "Proxy country",
            "type": "string",
            "description": "Optional two-letter country for proxy exits, e.g. \"US\" or \"DE\" (sites that show a different page per country)."
          },
          "concurrency": {
            "title": "Parallel pages",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "How many URLs are captured at the same time in one browser, e.g. 1. With 1 GB of memory the Apify run has a quarter of a CPU core, so 1 is fastest per page; raise it together with the run memory.",
            "default": 1
          },
          "timeout": {
            "title": "Timeout per page (s)",
            "minimum": 10,
            "maximum": 180,
            "type": "integer",
            "description": "Navigation and wait timeout per page, e.g. 60.",
            "default": 60
          },
          "maxItems": {
            "title": "Max items",
            "minimum": 1,
            "type": "integer",
            "description": "Stop after this many successful screenshots (failed URLs are free and do not count), e.g. 10.",
            "default": 100
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "scrape",
              "monitor"
            ],
            "type": "string",
            "description": "scrape = full results; monitor = only new/changed items since the previous run of this task",
            "default": "scrape"
          },
          "monitorStateId": {
            "title": "Monitor state id",
            "type": "string",
            "description": "Optional state id when not running as a saved task (monitor mode)"
          },
          "webhookUrl": {
            "title": "Webhook URL",
            "type": "string",
            "description": "POST a change summary here in monitor mode"
          },
          "telegramBotToken": {
            "title": "Telegram bot token",
            "type": "string",
            "description": "Optional: bot token for monitor-mode change summaries"
          },
          "telegramChatId": {
            "title": "Telegram chat id",
            "type": "string",
            "description": "Optional: chat id that receives monitor-mode summaries"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}