{
  "openapi": "3.0.1",
  "info": {
    "title": "Broken Link Checker – 404s with Source Pages & Anchor Text",
    "description": "Crawl a website and check every internal and external link (optionally images, scripts, CSS): status code, error type (DNS, timeout, SSL, 4xx, 5xx), redirect target and all source pages with anchor text. One row per broken link, priced per crawled page.",
    "version": "0.1",
    "x-build-id": "kA28Cnz8gSaicgu0U"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/adamplaenitz~broken-link-checker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-adamplaenitz-broken-link-checker",
        "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/adamplaenitz~broken-link-checker/runs": {
      "post": {
        "operationId": "runs-sync-adamplaenitz-broken-link-checker",
        "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/adamplaenitz~broken-link-checker/run-sync": {
      "post": {
        "operationId": "run-sync-adamplaenitz-broken-link-checker",
        "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": "Pages where the crawl starts, usually your homepage (e.g. https://example.com). Only check websites you own or are allowed to crawl.",
            "items": {
              "type": "string"
            }
          },
          "maxPages": {
            "title": "Maximum pages to crawl",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Stop crawling after this many pages. Every link found on the crawled pages is still checked. You pay per crawled page, so this also caps the cost.",
            "default": 100
          },
          "maxDepth": {
            "title": "Maximum link depth",
            "minimum": 0,
            "maximum": 1000,
            "type": "integer",
            "description": "How many clicks away from a start URL the crawler follows internal links. 0 = only the start URLs.",
            "default": 20
          },
          "crawlScope": {
            "title": "Which pages count as internal",
            "enum": [
              "same-domain",
              "same-hostname"
            ],
            "type": "string",
            "description": "Same domain: the start host and its subdomains (blog.example.com). Same hostname: only the start host. \"www.\" is ignored in both cases. Only internal pages are crawled; external links are checked but not crawled.",
            "default": "same-domain"
          },
          "checkExternalLinks": {
            "title": "Check external links",
            "type": "boolean",
            "description": "Also check links to other websites (one polite HEAD/GET request each, limited parallel requests per external host).",
            "default": true
          },
          "checkResources": {
            "title": "Check images, scripts and stylesheets",
            "type": "boolean",
            "description": "Also check the src/href of img, script, stylesheet and icon tags (finds missing images and broken CSS/JS files).",
            "default": false
          },
          "outputMode": {
            "title": "Output",
            "enum": [
              "broken",
              "broken-and-redirects",
              "all"
            ],
            "type": "string",
            "description": "Broken links only (default), broken links plus redirecting links, or every link with its status (full link inventory).",
            "default": "broken"
          },
          "includeBlocked": {
            "title": "Report links blocked for bots (401/403/429/999)",
            "type": "boolean",
            "description": "Many sites (e.g. LinkedIn, some shops) refuse automated requests. These links are reported with status \"blocked\" so you can check them manually. Switch off to hide them.",
            "default": true
          },
          "respectRobotsTxt": {
            "title": "Respect robots.txt",
            "type": "boolean",
            "description": "Do not crawl pages that robots.txt disallows (they are listed as \"not-checked\" in the full output). Single external link checks do not consult robots.txt, just like a visitor clicking the link.",
            "default": true
          },
          "includePatterns": {
            "title": "Crawl only pages matching",
            "type": "array",
            "description": "Optional. Glob patterns (`*` = any characters) for internal pages to crawl, matched against the full URL or – if they start with `/` – against the path, e.g. `/blog/*`. Regular expressions go between slashes, e.g. `/(en|de)/`. Start URLs are always crawled.",
            "items": {
              "type": "string"
            }
          },
          "excludePatterns": {
            "title": "Do not crawl pages matching",
            "type": "array",
            "description": "Optional. Same syntax, e.g. `*?replytocom=*` or `/tag/*`. Links to these pages are still checked, but the pages are not crawled.",
            "items": {
              "type": "string"
            }
          },
          "ignoreLinkPatterns": {
            "title": "Ignore links matching",
            "type": "array",
            "description": "Optional. Links matching these patterns are neither checked nor reported, e.g. `https://www.linkedin.com/*` or `*/cdn-cgi/*`.",
            "items": {
              "type": "string"
            }
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "Maximum parallel requests overall (1–50). Your own website gets up to this many; external hosts are limited separately (see below).",
            "default": 10
          },
          "maxRequestsPerExternalHost": {
            "title": "Parallel requests per external host",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Politeness limit for other websites (1–10). Pages with hundreds of links to one host (e.g. \"Edit on GitHub\" links) are checked faster with a higher value – or skip them with \"Ignore links matching\".",
            "default": 3
          },
          "requestTimeoutSecs": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 60,
            "type": "integer",
            "description": "A link that does not answer within this time counts as a timeout (after one retry).",
            "default": 15
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. Only needed if your website blocks requests from cloud servers.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}