{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Screenshot & URL to PDF Converter",
    "description": "Screenshots (PNG/JPEG, viewport/full page) and PDFs of public web pages. No charge for failed captures; $0.01 start fee per default 2 GB run, $0.005 per GB RAM.",
    "version": "0.2",
    "x-build-id": "6X68cljfhZRyfOfEB"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/luxe_tasks~screenshot-pdf/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-luxe_tasks-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/luxe_tasks~screenshot-pdf/runs": {
      "post": {
        "operationId": "runs-sync-luxe_tasks-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/luxe_tasks~screenshot-pdf/run-sync": {
      "post": {
        "operationId": "run-sync-luxe_tasks-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": "Public http(s) pages to capture: a list of URLs (or {\"url\": ...} objects). Only these pages are opened: links are never followed. A missing scheme gets https://; whitespace is trimmed; exact duplicates are removed. A #fragment is kept and sent to the browser, so page#a and page#b are two captures (useful for hash-routed pages like /#/pricing). Private, loopback, link-local and cloud-metadata addresses are refused.",
            "items": {
              "type": "string"
            }
          },
          "outputFormat": {
            "title": "Output format",
            "enum": [
              "png",
              "jpeg",
              "pdf"
            ],
            "type": "string",
            "description": "PNG or JPEG screenshot, or PDF.",
            "default": "png"
          },
          "fullPage": {
            "title": "Full page",
            "type": "boolean",
            "description": "Capture the whole scrollable page (up to the max height) instead of only the viewport. Ignored for PDF.",
            "default": false
          },
          "viewportWidth": {
            "title": "Viewport width (px)",
            "minimum": 320,
            "maximum": 3840,
            "type": "integer",
            "description": "Viewport width (px).",
            "default": 1280
          },
          "viewportHeight": {
            "title": "Viewport height (px)",
            "minimum": 240,
            "maximum": 2000,
            "type": "integer",
            "description": "Viewport height (px), at most 2000. For anything taller use Full page (charged as a full-page screenshot).",
            "default": 800
          },
          "waitUntil": {
            "title": "Wait until",
            "enum": [
              "load",
              "domcontentloaded",
              "networkidle"
            ],
            "type": "string",
            "description": "Page event to wait for before capturing.",
            "default": "load"
          },
          "waitForSelector": {
            "title": "Wait for selector",
            "type": "string",
            "description": "Optional CSS selector that must become visible before capture."
          },
          "delayMs": {
            "title": "Extra delay (ms)",
            "minimum": 0,
            "maximum": 30000,
            "type": "integer",
            "description": "Extra delay (ms).",
            "default": 0
          },
          "scrollToLoadLazy": {
            "title": "Scroll to load lazy content",
            "type": "boolean",
            "description": "Scroll through the page (up to the max height) to trigger lazy-loaded images, wait for images to load, then scroll back to the top.",
            "default": true
          },
          "maxFullPageHeight": {
            "title": "Max full-page height (px)",
            "minimum": 1000,
            "maximum": 30000,
            "type": "integer",
            "description": "Taller pages are cut at this height and marked truncated.",
            "default": 16000
          },
          "jpegQuality": {
            "title": "JPEG quality",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "JPEG quality.",
            "default": 80
          },
          "pdfFormat": {
            "title": "PDF page size",
            "enum": [
              "A4",
              "Letter",
              "Legal",
              "A3",
              "A5",
              "Tabloid"
            ],
            "type": "string",
            "description": "PDF page size.",
            "default": "A4"
          },
          "pdfLandscape": {
            "title": "PDF landscape",
            "type": "boolean",
            "description": "PDF landscape.",
            "default": false
          },
          "pdfPrintBackground": {
            "title": "PDF print background",
            "type": "boolean",
            "description": "PDF print background.",
            "default": true
          },
          "pdfMarginMm": {
            "title": "PDF margin (mm)",
            "minimum": 0,
            "maximum": 50,
            "type": "integer",
            "description": "Margin on all four sides of each PDF page, in millimetres. 0 = no margin; the page's own CSS @page margin is then used if it sets one. CSS @page size is ignored: the page size comes from \"PDF page size\" and \"PDF landscape\".",
            "default": 0
          },
          "pdfScale": {
            "title": "PDF scale",
            "minimum": 0.1,
            "maximum": 2,
            "type": "number",
            "description": "Zoom of the page content in the PDF (0.1 to 2). Below 1 fits more content on each page.",
            "default": 1
          },
          "hideCookieBannersAndAds": {
            "title": "Hide cookie banners and ad slots",
            "type": "boolean",
            "description": "Cosmetic only: hides common cookie-banner and ad-slot elements with CSS in the captured image. Never clicks accept, never blocks requests, never removes paywalls or login walls.",
            "default": true
          },
          "hideSelectors": {
            "title": "Hide selectors",
            "type": "array",
            "description": "Extra CSS selectors to hide (display:none) before capture.",
            "items": {
              "type": "string"
            }
          },
          "customCss": {
            "title": "Custom CSS",
            "type": "string",
            "description": "CSS injected before capture. @import and url() are not allowed."
          },
          "timeoutSecs": {
            "title": "Per-URL timeout (s)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Navigation timeout per attempt. Transient timeouts/network errors are retried once.",
            "default": 30
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Pages rendered in parallel in one shared browser. Each site is still limited to about one page per second. The effective concurrency is reduced automatically to fit the run's memory (up to 3 viewport or 2 full-page pages in parallel at the default 2 GB; one page at a time at 1 GB).",
            "default": 3
          },
          "ignoreRobotsTxt": {
            "title": "Ignore robots.txt (only for domains you own or control)",
            "type": "boolean",
            "description": "Off by default. Allowed only for runs of up to 10 URLs on ONE domain you own or control, and only together with the attestation below. Logged in every result.",
            "default": false
          },
          "overrideDomainStop": {
            "title": "Do not stop my own domain after 403/429/CAPTCHA (owners only)",
            "type": "boolean",
            "description": "Off by default. Normally a 403 or CAPTCHA stops the whole domain for the rest of the run, and a 429 is retried once only if Retry-After is 60 s or less. For ONE domain you own or control (runs of up to 10 URLs, with the attestation below), the domain is not stopped, but each URL still gets at most one retry. Logged in every result.",
            "default": false
          },
          "robotsOwnershipAttestation": {
            "title": "Ownership attestation",
            "type": "string",
            "description": "Required when ignoring robots.txt or overriding the domain stop, e.g. \"I own or control example.org and authorise these captures.\" Stored in each result record."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}