{
  "openapi": "3.0.1",
  "info": {
    "title": "Tool: Website Unblocker, Cloudflare Bypass and Scraping API",
    "description": "Website unblocker and anti bot bypass API. Fetch the real HTML or JSON of any page behind Cloudflare, DataDome, Akamai, AWS WAF, PerimeterX or Incapsula. Bypass 403 and challenge screens, no proxy setup, no API key. GET or POST, target country, optional AI to JSON. Pay only on a successful unblock.",
    "version": "0.1",
    "x-build-id": "YVaS4yfLbHVCM1Bzp"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapers_lat~gen5-website-unblocker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapers_lat-gen5-website-unblocker",
        "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/scrapers_lat~gen5-website-unblocker/runs": {
      "post": {
        "operationId": "runs-sync-scrapers_lat-gen5-website-unblocker",
        "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/scrapers_lat~gen5-website-unblocker/run-sync": {
      "post": {
        "operationId": "run-sync-scrapers_lat-gen5-website-unblocker",
        "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",
            "uniqueItems": true,
            "type": "array",
            "description": "One or more page URLs to fetch. One run can process many URLs. You can also paste a single URL.",
            "items": {
              "type": "string"
            }
          },
          "httpMethod": {
            "title": "HTTP method",
            "enum": [
              "GET",
              "POST"
            ],
            "type": "string",
            "description": "The request method to use for every URL.",
            "default": "GET"
          },
          "headers": {
            "title": "Request headers",
            "type": "object",
            "description": "Optional. Extra request headers to send with every URL, as key/value pairs (for example an Accept-Language or a custom header)."
          },
          "payload": {
            "title": "POST body",
            "type": "string",
            "description": "Optional. The request body to send when HTTP method is POST (for example JSON or form-encoded data)."
          },
          "renderJavaScript": {
            "title": "Render JavaScript",
            "type": "boolean",
            "description": "Turn on for JavaScript-heavy pages and single-page apps whose content is built in the browser. Off is faster for normal HTML pages.",
            "default": false
          },
          "country": {
            "title": "Target country",
            "enum": [
              "auto",
              "US",
              "GB",
              "CA",
              "AU",
              "DE",
              "FR",
              "ES",
              "IT",
              "NL",
              "BR",
              "MX",
              "AR",
              "CL",
              "CO",
              "PE",
              "JP",
              "KR",
              "IN",
              "SG",
              "HK",
              "AE",
              "ZA"
            ],
            "type": "string",
            "description": "Country to view the page from, for geo-specific content. Leave on Auto to pick the best match for each URL automatically.",
            "default": "auto"
          },
          "waitForMs": {
            "title": "Extra wait (ms)",
            "minimum": 0,
            "maximum": 30000,
            "type": "integer",
            "description": "Optional. Extra settle time in milliseconds for JavaScript pages before the HTML is captured."
          },
          "mode": {
            "title": "Unblock mode",
            "enum": [
              "auto",
              "fast",
              "thorough"
            ],
            "type": "string",
            "description": "How hard to try. Auto picks the right effort per URL. Fast uses only quick methods (cheaper, never triggers the premium unblock fee, may fail on the hardest sites). Thorough always uses the full browser render path for maximum fidelity.",
            "default": "auto"
          },
          "returnFormat": {
            "title": "Return format",
            "enum": [
              "html",
              "text",
              "json",
              "markdown"
            ],
            "type": "string",
            "description": "What to return for each page. HTML returns the full page source. Text also returns the visible text. JSON also parses the body as JSON (for API endpoints) into parsedBody. Markdown also returns the page as clean Markdown in the markdown field (good for LLMs and RAG).",
            "default": "html"
          },
          "requestTimeoutSecs": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Optional. Maximum seconds to wait for each page before moving on. Leave empty for the default."
          },
          "followRedirects": {
            "title": "Follow redirects",
            "type": "boolean",
            "description": "Follow HTTP redirects (3xx) to the final page. Turn off to capture the first response as-is.",
            "default": true
          },
          "maxUrls": {
            "title": "Max URLs To Process",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Maximum number of URLs to process in this run."
          },
          "cookies": {
            "title": "Cookies",
            "type": "object",
            "description": "Optional. Cookies to send with every URL, as {\"name\": \"value\"} pairs. Use your own session cookies for pages you are allowed to see."
          },
          "extractMetadata": {
            "title": "Extract page metadata",
            "type": "boolean",
            "description": "Adds a metadata object: title, meta description, canonical URL, language, H1, Open Graph and Twitter tags, favicon, JSON-LD types and word count.",
            "default": false
          },
          "extractLinks": {
            "title": "Extract links",
            "type": "boolean",
            "description": "Adds links (absolute URL, anchor text, internal or external) and linkCount. Up to 1,000 unique links per page.",
            "default": false
          },
          "extractContacts": {
            "title": "Extract contacts",
            "type": "boolean",
            "description": "Adds contacts: emails, phone numbers (from tel: links) and social profiles (LinkedIn, Facebook, Instagram, X, YouTube, TikTok, GitHub, WhatsApp, Telegram, Pinterest) found on the page.",
            "default": false
          },
          "extractTables": {
            "title": "Extract tables",
            "type": "boolean",
            "description": "Adds tables: every HTML table on the page as headers and rows of cell text (up to 50 tables).",
            "default": false
          },
          "cssSelector": {
            "title": "CSS selector",
            "type": "string",
            "description": "Optional. A CSS selector (for example \"h2.product-title\" or \"table tr\"). Adds selected: the text, HTML and attributes of every match (up to 500) and selectedCount."
          },
          "maxChars": {
            "title": "Max characters (text and Markdown)",
            "minimum": 100,
            "maximum": 2000000,
            "type": "integer",
            "description": "Optional. Cut the text and markdown fields to this many characters. Leave empty for no limit."
          },
          "mainContentOnly": {
            "title": "Markdown: main content only",
            "type": "boolean",
            "description": "With Markdown output, keep only the main article or content area and drop menus, headers, footers and sidebars.",
            "default": false
          },
          "includeHtml": {
            "title": "Include full HTML",
            "type": "boolean",
            "description": "Keep the full page HTML in the html field. Turn off when you only need text, Markdown or the extracted fields, to get smaller datasets.",
            "default": true
          },
          "waitForSelector": {
            "title": "Wait for element (CSS selector)",
            "type": "string",
            "description": "Optional. A page only counts as retrieved when this element is present, for example `.product-price` or `#results`. If a quick fetch does not have it, the page is opened with full JavaScript rendering."
          },
          "returnCookies": {
            "title": "Return cookies",
            "type": "boolean",
            "description": "Add the cookies the site set to each result (name, value), so you can reuse the session in your own requests.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}