{
  "openapi": "3.0.1",
  "info": {
    "title": "Stealth Web Scraper",
    "description": "General-purpose stealth  collection helper for public pages when a dedicated source Actor is not available. Prefer specialized Actors for jobs, ads, maps, and e-commerce.",
    "version": "0.2",
    "x-build-id": "iW4SBgeu9Dyq9YUYo"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lentic_clockss~stealth-web-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lentic_clockss-stealth-web-scraper",
        "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/lentic_clockss~stealth-web-scraper/runs": {
      "post": {
        "operationId": "runs-sync-lentic_clockss-stealth-web-scraper",
        "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/lentic_clockss~stealth-web-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-lentic_clockss-stealth-web-scraper",
        "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 to scrape",
            "minItems": 1,
            "maxItems": 40,
            "type": "array",
            "description": "List of absolute http(s) URLs to scrape. Localhost, direct private, loopback, link-local, multicast, reserved IP, ambiguous numeric, and whitespace/control-character targets are rejected. Only pages successfully written to the default dataset are billed.",
            "items": {
              "type": "string"
            },
            "default": [
              "https://example.com"
            ]
          },
          "extractSelectors": {
            "title": "CSS selectors to extract",
            "type": "object",
            "description": "Optional key-value pairs of CSS selectors. Example: {\"title\": \"h1\", \"price\": \".product-price\", \"cta\": \"a[href]\"}. Leave empty to get the page content only.",
            "default": {}
          },
          "outputFormat": {
            "title": "Output format",
            "enum": [
              "html",
              "text",
              "both"
            ],
            "type": "string",
            "description": "Choose whether to return rendered HTML, plain text, or both.",
            "default": "text"
          },
          "waitForSelector": {
            "title": "Wait for selector",
            "type": "string",
            "description": "Optional CSS selector expected on the final page before extraction. If it never appears, the page is moved to the failures dataset and is not billed as a successful page."
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 4,
            "type": "integer",
            "description": "Pages scraped in parallel. Higher values cut run time and platform cost; the worker retries a few pages if its slots are busy.",
            "default": 3
          },
          "pageTimeout": {
            "title": "Page timeout (seconds)",
            "minimum": 30,
            "maximum": 120,
            "type": "integer",
            "description": "Maximum time to wait for each page to load and pass anti-bot checks.",
            "default": 45
          },
          "proxyGroup": {
            "title": "Proxy group hint",
            "enum": [
              "auto",
              "RESIDENTIAL",
              "BUYPROXIES94952"
            ],
            "type": "string",
            "description": "Optional hint for the scrape worker. Residential egress is provided by the worker (not minted in this Actor). Prefer leaving the default.",
            "default": "RESIDENTIAL"
          },
          "proxyCountry": {
            "title": "Proxy country",
            "type": "string",
            "description": "Optional ISO country for residential egress (e.g. us, gb, de, kr). When omitted, the worker infers country from the first URL (host map / TLD, e.g. .co.uk→gb, coupang.com→kr)."
          },
          "provider": {
            "title": "Engine provider",
            "type": "string",
            "description": "Optional force: unlocker_only, brightdata_unlocker, patchright, camoufox, orchestrator. Leave empty for automatic ladder."
          },
          "cookies": {
            "title": "Cookies",
            "type": "array",
            "description": "Optional cookies forwarded to the worker browser (Playwright cookie objects).",
            "items": {
              "type": "object"
            }
          },
          "headers": {
            "title": "Extra HTTP headers",
            "type": "object",
            "description": "Optional request headers forwarded to Unlocker / browser (string map)."
          },
          "gotoWaitUntil": {
            "title": "Navigation wait until",
            "enum": [
              "commit",
              "domcontentloaded",
              "load",
              "networkidle"
            ],
            "type": "string",
            "description": "Browser navigation waitUntil strategy.",
            "default": "domcontentloaded"
          },
          "blockResources": {
            "title": "Block heavy resources",
            "type": "boolean",
            "description": "When true, worker blocks images/fonts/media to cut proxy bandwidth (default true).",
            "default": true
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}