{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Screenshot API - Bulk, Full Page & Visual Change Alerts",
    "description": "Screenshots of many web pages (desktop or mobile, full page), and alerts when a page visually changes.",
    "version": "0.1",
    "x-build-id": "6RS0qE6gToDRvD3VT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/afterstar~website-screenshots/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-afterstar-website-screenshots",
        "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/afterstar~website-screenshots/runs": {
      "post": {
        "operationId": "runs-sync-afterstar-website-screenshots",
        "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/afterstar~website-screenshots/run-sync": {
      "post": {
        "operationId": "run-sync-afterstar-website-screenshots",
        "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": "One page URL per line.",
            "items": {
              "type": "string"
            }
          },
          "devices": {
            "title": "Devices",
            "type": "array",
            "description": "Take each screenshot as a desktop, a phone, or both.",
            "items": {
              "type": "string",
              "enum": [
                "desktop",
                "mobile"
              ],
              "enumTitles": [
                "Desktop (1366×768)",
                "Mobile (iPhone size)"
              ]
            },
            "default": [
              "desktop"
            ]
          },
          "fullPage": {
            "title": "Full page",
            "type": "boolean",
            "description": "Capture the whole scrolling page, not just the visible area (at most 10,000 pixels tall; a taller page is cut there and the row says capped). Priced as a full-page screenshot.",
            "default": false
          },
          "format": {
            "title": "Format",
            "enum": [
              "png",
              "jpeg"
            ],
            "type": "string",
            "description": "The image format.",
            "default": "png"
          },
          "waitMs": {
            "title": "Wait after load (ms)",
            "minimum": 0,
            "maximum": 8000,
            "type": "integer",
            "description": "Extra wait after the page loads, for late content (max 8,000). Each shot has 18 seconds in total (full page: 35 s).",
            "default": 1000
          },
          "hideSelectors": {
            "title": "Hide these elements (CSS selectors)",
            "type": "array",
            "description": "Optional: elements to hide before the shot, one CSS selector per line (like #chat-widget or .newsletter-popup).",
            "items": {
              "type": "string"
            }
          },
          "hideCookieBanners": {
            "title": "Hide common cookie banners",
            "type": "boolean",
            "description": "Hide the consent boxes of the common cookie tools (OneTrust, Cookiebot, Didomi, Usercentrics and others) before the shot. They're only hidden, never accepted; banners made another way may stay.",
            "default": false
          },
          "changeThreshold": {
            "title": "Change threshold",
            "minimum": 1,
            "maximum": 128,
            "type": "integer",
            "description": "In 'New, changed and removed' mode: how different (perceptual-hash distance, 0-256) a page must look, on two runs in a row, to count as changed.",
            "default": 12
          },
          "maxItems": {
            "title": "Max URLs",
            "minimum": 1,
            "type": "integer",
            "description": "The most URLs per run.",
            "default": 500
          },
          "outputMode": {
            "title": "Output mode",
            "enum": [
              "all",
              "new",
              "changes"
            ],
            "type": "string",
            "description": "'All' lists everything found now. 'Only new' lists results never seen in earlier runs. 'New, changed and removed' also lists results that changed or disappeared. The first scheduled run counts everything as new; use 'Baseline only' to start cheaply.",
            "default": "all"
          },
          "baselineOnly": {
            "title": "Baseline only (remember the current results, output nothing)",
            "type": "boolean",
            "description": "Saves what exists now without listing it, so the next scheduled run shows only what's new. Charged like a run with nothing new.",
            "default": false
          },
          "stateKey": {
            "title": "Memory name (optional)",
            "type": "string",
            "description": "Leave empty: each saved task keeps its own memory. Set a name to share one memory between tasks, or a new name to start over.",
            "default": ""
          },
          "resetState": {
            "title": "Forget earlier runs",
            "type": "boolean",
            "description": "Starts from an empty memory: every result counts as new again.",
            "default": false
          },
          "webhookUrl": {
            "title": "Webhook URL (optional)",
            "type": "string",
            "description": "We POST a summary plus up to 100 new, changed or removed results here when something changed. Works with Slack incoming webhooks (choose the Slack format), Zapier, Make and n8n.",
            "default": ""
          },
          "webhookFormat": {
            "title": "Webhook format",
            "enum": [
              "json",
              "slack"
            ],
            "type": "string",
            "description": "JSON for automation tools; 'Slack message' sends one line of text.",
            "default": "json"
          },
          "webhookAlways": {
            "title": "Call the webhook on every run",
            "type": "boolean",
            "description": "By default the webhook is called only when something changed or a source failed.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}