{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Screenshot & PDF (Full Page, Any Device)",
    "description": "Clean full-page screenshots and PDFs of any website, with cookie banners, consent pop-ups and chat widgets removed automatically. Desktop, laptop, tablet and phone in one run. JPEG, PNG, WebP or PDF. Failed and blocked pages are never charged. Works with AI agents via MCP.",
    "version": "0.0",
    "x-build-id": "Vf63Ym4i6FIMQoSq6"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/pagecraft~website-screenshot-pdf/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-pagecraft-website-screenshot-pdf",
        "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/pagecraft~website-screenshot-pdf/runs": {
      "post": {
        "operationId": "runs-sync-pagecraft-website-screenshot-pdf",
        "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/pagecraft~website-screenshot-pdf/run-sync": {
      "post": {
        "operationId": "run-sync-pagecraft-website-screenshot-pdf",
        "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": "URLs",
            "type": "array",
            "description": "Web pages to capture. Add as many as you like. Domains without https:// are fine (e.g. example.com).",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "devices": {
            "title": "Devices",
            "type": "array",
            "description": "Capture each URL on one or more devices. Choose several for a full responsive check in one run. Each URL × device is one capture.",
            "items": {
              "type": "string",
              "enum": [
                "desktop",
                "laptop",
                "macbook",
                "widescreen",
                "tablet",
                "iphone",
                "android",
                "custom"
              ],
              "enumTitles": [
                "Desktop 1920×1080",
                "Laptop 1366×768",
                "MacBook 1440×900 (Retina)",
                "Widescreen 2560×1440",
                "Tablet (iPad Pro 11)",
                "iPhone 15 Pro",
                "Android (Pixel 7)",
                "Custom size (set below)"
              ]
            },
            "default": [
              "desktop"
            ]
          },
          "format": {
            "title": "Output format",
            "enum": [
              "jpeg",
              "png",
              "webp",
              "pdf"
            ],
            "type": "string",
            "description": "JPEG is fastest and small. PNG is lossless but larger. WebP gives the smallest files. PDF creates a multi-page document of the page.",
            "default": "jpeg"
          },
          "captureMode": {
            "title": "What to capture",
            "enum": [
              "fullPage",
              "viewport",
              "element"
            ],
            "type": "string",
            "description": "Full page scrolls the whole page. Viewport captures only what is visible on screen. Element captures a single part of the page (set a CSS selector). Ignored for PDF.",
            "default": "fullPage"
          },
          "selector": {
            "title": "Element CSS selector",
            "type": "string",
            "description": "Only for 'A specific element' mode, e.g. #pricing or .hero."
          },
          "removeCookieBanners": {
            "title": "Remove cookie banners",
            "type": "boolean",
            "description": "Accepts or hides cookie and consent dialogs (OneTrust, Cookiebot, Didomi, Quantcast, Usercentrics and many more) so they don't cover the page.",
            "default": true
          },
          "hidePopups": {
            "title": "Hide chat widgets and popups",
            "type": "boolean",
            "description": "Hides live-chat bubbles (Intercom, Drift, HubSpot, Zendesk, Crisp, Tawk) and leftover consent overlays.",
            "default": true
          },
          "blockAds": {
            "title": "Block ads, trackers and video",
            "type": "boolean",
            "description": "Blocks common ad, analytics and tracking networks and video streams. Pages load faster and look cleaner.",
            "default": true
          },
          "darkMode": {
            "title": "Dark mode",
            "type": "boolean",
            "description": "Ask the page to render its dark theme, if it has one.",
            "default": false
          },
          "quality": {
            "title": "JPEG/WebP quality",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "1 to 100. Higher is sharper but larger.",
            "default": 80
          },
          "outputWidth": {
            "title": "Resize output to width (px)",
            "minimum": 0,
            "maximum": 7680,
            "type": "integer",
            "description": "Shrink the final image to this width, keeping proportions. Great for thumbnails. 0 keeps the original size.",
            "default": 0
          },
          "scaleFactor": {
            "title": "Pixel density",
            "enum": [
              "0",
              "1",
              "2",
              "3"
            ],
            "type": "string",
            "description": "Override the device pixel ratio. 2 gives Retina-sharp images. 0 uses each device's default.",
            "default": "0"
          },
          "maxHeight": {
            "title": "Maximum full-page height (px)",
            "minimum": 500,
            "maximum": 30000,
            "type": "integer",
            "description": "Very long pages are cut off at this height to keep files usable.",
            "default": 15000
          },
          "customWidth": {
            "title": "Custom width (px)",
            "minimum": 200,
            "maximum": 3840,
            "type": "integer",
            "description": "Used when the 'Custom size' device is selected.",
            "default": 1280
          },
          "customHeight": {
            "title": "Custom height (px)",
            "minimum": 200,
            "maximum": 2160,
            "type": "integer",
            "description": "Used when the 'Custom size' device is selected.",
            "default": 800
          },
          "pdfFormat": {
            "title": "PDF paper size",
            "enum": [
              "A4",
              "Letter",
              "Legal",
              "A3",
              "Tabloid"
            ],
            "type": "string",
            "description": "Paper size for PDF output.",
            "default": "A4"
          },
          "pdfLandscape": {
            "title": "Landscape PDF",
            "type": "boolean",
            "description": "Use landscape orientation.",
            "default": false
          },
          "pdfPrintBackground": {
            "title": "Include backgrounds",
            "type": "boolean",
            "description": "Keep background colours and images in the PDF.",
            "default": true
          },
          "pdfMedia": {
            "title": "PDF styling",
            "enum": [
              "screen",
              "print"
            ],
            "type": "string",
            "description": "'Screen' makes the PDF look like the website. 'Print' uses the site's print stylesheet, if any.",
            "default": "screen"
          },
          "waitUntil": {
            "title": "Wait until",
            "enum": [
              "domcontentloaded",
              "load",
              "networkidle"
            ],
            "type": "string",
            "description": "When the page counts as loaded. 'Page loaded' waits up to 10 seconds for the load event, then captures anyway, so slow trackers never stall your run. 'Network idle' is slowest but safest for heavy JavaScript apps.",
            "default": "load"
          },
          "delayMs": {
            "title": "Extra delay before capture (ms)",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Wait this long after loading, for animations or late content.",
            "default": 1000
          },
          "waitForSelector": {
            "title": "Wait for element",
            "type": "string",
            "description": "Optional CSS selector to wait for before capturing, e.g. .chart-loaded."
          },
          "scrollToLoad": {
            "title": "Scroll to load lazy images",
            "type": "boolean",
            "description": "Scrolls through the page first so lazy-loaded images and sections appear in full-page captures.",
            "default": true
          },
          "timeoutSecs": {
            "title": "Page timeout (seconds)",
            "minimum": 10,
            "maximum": 30,
            "type": "integer",
            "description": "Give up on loading a page after this long (10 to 30 seconds). Every page also has an overall limit of 75 seconds.",
            "default": 30
          },
          "hideSelectors": {
            "title": "Extra elements to hide",
            "type": "array",
            "description": "CSS selectors to hide before capture, e.g. .banner, #promo.",
            "items": {
              "type": "string"
            }
          },
          "customCss": {
            "title": "Custom CSS",
            "type": "string",
            "description": "CSS injected into every page before capture."
          },
          "locale": {
            "title": "Browser language",
            "type": "string",
            "description": "Language/locale the browser reports, e.g. en-GB, de-DE, fr-FR.",
            "default": "en-US"
          },
          "timezone": {
            "title": "Time zone",
            "type": "string",
            "description": "IANA time zone, e.g. Europe/London. Leave empty for UTC."
          },
          "maxRetries": {
            "title": "Retries per page",
            "minimum": 0,
            "maximum": 2,
            "type": "integer",
            "description": "Retry a page that fails quickly (up to this many times). Slow failures are not retried. A failed or blocked capture has a small fee (see Pricing).",
            "default": 2
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. Use Apify datacenter proxies or your own proxy URLs for sites that block automated browsers. Residential proxies are not supported."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}