{
  "openapi": "3.0.1",
  "info": {
    "title": "Website Health Report: PageSpeed, Broken Links & SEO (PDF)",
    "description": "Client-ready website audit: PageSpeed & Core Web Vitals, broken links, redirect chains and on-page SEO per page, a 0-100 health score and prioritised to-dos, as dataset plus white-label HTML/PDF report.",
    "version": "0.1",
    "x-build-id": "eevm6mCeRRfX8ilj1"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/grace_hartwell~website-health-report/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-grace_hartwell-website-health-report",
        "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/grace_hartwell~website-health-report/runs": {
      "post": {
        "operationId": "runs-sync-grace_hartwell-website-health-report",
        "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/grace_hartwell~website-health-report/run-sync": {
      "post": {
        "operationId": "run-sync-grace_hartwell-website-health-report",
        "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": {
          "startUrl": {
            "title": "Website (start URL)",
            "type": "string",
            "description": "The website to audit, e.g. https://example.com/. Only pages on this host are crawled. Audit only sites you own or are allowed to test.",
            "default": "https://example.com/"
          },
          "maxPages": {
            "title": "Max pages",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Internal HTML pages to analyse (each one is a 'page analysed' event). Also capped by your 'Max total charge'.",
            "default": 20
          },
          "maxDepth": {
            "title": "Max crawl depth",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "0 = only the start page, 1 = start page + pages it links to, …",
            "default": 2
          },
          "apiKey": {
            "title": "Google API key (for PageSpeed Insights)",
            "type": "string",
            "description": "Your own free Google Cloud API key with the 'PageSpeed Insights API' enabled. Stored encrypted by Apify; never logged. Without a key, Google allows (almost) no PageSpeed requests: speed scores are then skipped (free) and the report covers links and on-page SEO."
          },
          "strategies": {
            "title": "PageSpeed strategies",
            "type": "array",
            "description": "mobile and/or desktop. Each strategy is one 'PageSpeed audit' event per page.",
            "items": {
              "type": "string",
              "enum": [
                "mobile",
                "desktop"
              ],
              "enumTitles": [
                "Mobile",
                "Desktop"
              ]
            },
            "default": [
              "mobile"
            ]
          },
          "maxPagespeedPages": {
            "title": "Max pages with PageSpeed",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "PageSpeed Insights runs for this many pages closest to the start page (10–60 s each). 0 = no PageSpeed.",
            "default": 10
          },
          "clientName": {
            "title": "Client name",
            "type": "string",
            "description": "Shown in the report header, e.g. 'Bakery Miller'."
          },
          "agencyName": {
            "title": "Your agency / company name",
            "type": "string",
            "description": "White label: shown as 'Prepared by …'. When set (or a logo is set), the report shows no tool credit."
          },
          "agencyLogoUrl": {
            "title": "Your logo URL",
            "type": "string",
            "description": "Public https URL of your logo (PNG or JPEG for the PDF; SVG/WebP only in the HTML report). Max 2 MB."
          },
          "brandColor": {
            "title": "Brand colour",
            "type": "string",
            "description": "Header colour as hex, e.g. #1F3A5F.",
            "default": "#1F3A5F"
          },
          "contactLine": {
            "title": "Contact line (footer)",
            "type": "string",
            "description": "e.g. 'hello@youragency.com · youragency.com'. Shown in the report footer."
          },
          "reportTitle": {
            "title": "Report title",
            "type": "string",
            "description": "Default: 'Website Health Report'."
          },
          "generatePdf": {
            "title": "Create PDF report",
            "type": "boolean",
            "description": "Store report.pdf next to report.html in the key-value store.",
            "default": true
          },
          "checkExternalLinks": {
            "title": "Check external links",
            "type": "boolean",
            "description": "Also check links to other websites (one HEAD/GET request each, never crawled).",
            "default": true
          },
          "checkResources": {
            "title": "Check images, scripts, stylesheets",
            "type": "boolean",
            "description": "Also check sub-resources and detect mixed content (http resources on https pages).",
            "default": true
          },
          "maxLinksToCheck": {
            "title": "Max links to check",
            "minimum": 0,
            "type": "integer",
            "description": "Unique links checked per run (internal first). 0 = no limit.",
            "default": 500
          },
          "includeSubdomains": {
            "title": "Treat subdomains as internal",
            "type": "boolean",
            "description": "Crawl blog.example.com when starting at example.com.",
            "default": false
          },
          "requestTimeoutSecs": {
            "title": "Timeout per link/page request (seconds)",
            "minimum": 3,
            "maximum": 120,
            "type": "integer",
            "description": "A link that does not answer in this time is reported as timeout.",
            "default": 15
          },
          "psiTimeoutSecs": {
            "title": "Timeout per PageSpeed call (seconds)",
            "minimum": 30,
            "maximum": 300,
            "type": "integer",
            "description": "PageSpeed Insights audits usually take 10–60 s.",
            "default": 120
          },
          "maxRetries": {
            "title": "Retries for 429/5xx/network errors",
            "minimum": 0,
            "maximum": 6,
            "type": "integer",
            "description": "With exponential backoff (Retry-After is honoured for PageSpeed).",
            "default": 2
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Parallel crawl requests (link checks use up to 2×, never more than 'per host' on one host).",
            "default": 5
          },
          "perHostConcurrency": {
            "title": "Max parallel requests per host",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Keeps the load on each website low.",
            "default": 2
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}