{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Content Crawler",
    "description": "Website Content Crawler crawls websites and extracts clean text, Markdown, HTML and metadata from every page for LLMs, RAG pipelines and search indexes. Works on JavaScript sites too.",
    "version": "1.1",
    "x-build-id": "Fl6CR9SmcwO0eQkwT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/fastdataapi~website-content-crawler/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-fastdataapi-website-content-crawler",
        "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/fastdataapi~website-content-crawler/runs": {
      "post": {
        "operationId": "runs-sync-fastdataapi-website-content-crawler",
        "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/fastdataapi~website-content-crawler/run-sync": {
      "post": {
        "operationId": "run-sync-fastdataapi-website-content-crawler",
        "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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "🔗 Start URLs",
            "type": "array",
            "description": "One or more pages to start from. The crawler follows links on the same website (www. ignored) up to the crawl depth below. Each start URL gets its own result limit.",
            "items": {
              "type": "string"
            }
          },
          "maxResults": {
            "title": "🔢 Max results per start URL",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "How many pages to save for EACH start URL. Only pages with readable text count. 0 = no limit. Free plan: up to 20 pages per run (all start URLs together) and 200 per month; paid plans have no limit.",
            "default": 20
          },
          "includeUrlGlobs": {
            "title": "🎯 Include URLs (globs)",
            "type": "array",
            "description": "Follow only links that match one of these patterns, e.g. https://docs.apify.com/academy/**. Empty = every page of the same website. Start URLs are always opened.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "glob"
              ],
              "properties": {
                "glob": {
                  "type": "string",
                  "title": "Glob of a web page"
                }
              }
            }
          },
          "excludeUrlGlobs": {
            "title": "🎯 Exclude URLs (globs)",
            "type": "array",
            "description": "Never follow links that match one of these patterns, e.g. **/blog/**.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "glob"
              ],
              "properties": {
                "glob": {
                  "type": "string",
                  "title": "Glob of a web page"
                }
              }
            }
          },
          "maxCrawlDepth": {
            "title": "🔢 Max crawling depth",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "0 = start URLs only, 1 = also the pages they link to, and so on.",
            "default": 2
          },
          "maxCrawlPages": {
            "title": "🔢 Max pages to open per start URL",
            "minimum": 0,
            "type": "integer",
            "description": "Upper limit on pages opened for each start URL, including pages without text or errors. Empty or 0 = no extra limit."
          },
          "keepUrlFragments": {
            "title": "✅ Keep URL fragments",
            "type": "boolean",
            "description": "Treat page.html#a and page.html#b as different pages.",
            "default": false
          },
          "ignoreCanonicalUrl": {
            "title": "✅ Ignore canonical URLs",
            "type": "boolean",
            "description": "Use the loaded URL instead of the page's canonical URL for the url field and duplicate detection.",
            "default": false
          },
          "removeElementsCssSelector": {
            "title": "🔧 Remove HTML elements (CSS selector)",
            "type": "string",
            "description": "Comma-separated CSS selectors removed before the text, Markdown and HTML are extracted. The default removes navigation, footers, scripts and pop-ups.",
            "default": "nav, footer, script, style, noscript, svg, img[src^=\"data:\"], [role=\"alert\"], [role=\"banner\"], [role=\"dialog\"], [role=\"alertdialog\"], [role=\"region\"][aria-label*=\"skip\" i], [aria-modal=\"true\"]"
          },
          "readableTextCharThreshold": {
            "title": "🔢 Minimum text length",
            "minimum": 0,
            "type": "integer",
            "description": "A page with less text than this is loaded again with JavaScript. A page with less than half of it is not saved (its links are still followed).",
            "default": 100
          },
          "saveMarkdown": {
            "title": "✅ Save Markdown",
            "type": "boolean",
            "description": "Fill the markdown field of each result.",
            "default": true
          },
          "saveHtmlAsFile": {
            "title": "📦 Save HTML as a file",
            "type": "boolean",
            "description": "Also save each page's cleaned HTML as a file in the run's key-value store and put its link in the HTML file link field.",
            "default": false
          },
          "saveScreenshots": {
            "title": "📦 Save screenshots",
            "type": "boolean",
            "description": "Save a screenshot of each page loaded with JavaScript to the run's key-value store and put its link in the screenshot link field.",
            "default": false
          },
          "browserFallback": {
            "title": "✅ Load JavaScript pages",
            "type": "boolean",
            "description": "Pages load fast without JavaScript first. A page that comes back (almost) empty is loaded once more in a headless browser, so JavaScript-built sites work too.",
            "default": true
          },
          "waitForSelector": {
            "title": "⏳ Wait for CSS selector",
            "type": "string",
            "description": "When a page is loaded with JavaScript, wait until this element appears (e.g. main article).",
            "default": ""
          },
          "maxConcurrency": {
            "title": "⚡ Max concurrency",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "Pages loaded at the same time.",
            "default": 10
          },
          "maxRequestRetries": {
            "title": "🔁 Max retries per page",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "Extra tries for a page that times out or is refused. Missing pages (404) are not retried.",
            "default": 3
          },
          "requestTimeoutSecs": {
            "title": "⏳ Page timeout (seconds)",
            "minimum": 5,
            "maximum": 300,
            "type": "integer",
            "description": "How long to wait for one page.",
            "default": 30
          },
          "customHttpHeaders": {
            "title": "🔧 Custom HTTP headers",
            "type": "object",
            "description": "Extra headers sent with every request, e.g. {\"Accept-Language\": \"de-DE\"}.",
            "default": {}
          },
          "debugLog": {
            "title": "✅ Debug log",
            "type": "boolean",
            "description": "Log every page decision (why a page was skipped, retried or loaded with JavaScript).",
            "default": false
          },
          "proxyConfiguration": {
            "title": "🌐 Proxy configuration",
            "type": "object",
            "description": "Leave on \"No proxy\" for most sites - the crawler handles refused requests by itself. Pick a proxy here to use it for every request.",
            "default": {
              "useApifyProxy": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}