{
  "openapi": "3.0.1",
  "info": {
    "title": "Lighthouse Audit & Safe Browsing Website Checker",
    "description": "Lighthouse audits plus Google Safe Browsing checks for any URL list: four scores, lab metrics, ranked fixes, page weight, third-party cost and threat flags. Mobile, desktop or both, median of 1-5 runs, sitemap page discovery, optional HTML report.",
    "version": "1.0",
    "x-build-id": "P3B5DC84a4cdN4aCp"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/xyrelith-data~google-lighthouse-safe-browsing/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-xyrelith-data-google-lighthouse-safe-browsing",
        "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/xyrelith-data~google-lighthouse-safe-browsing/runs": {
      "post": {
        "operationId": "runs-sync-xyrelith-data-google-lighthouse-safe-browsing",
        "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/xyrelith-data~google-lighthouse-safe-browsing/run-sync": {
      "post": {
        "operationId": "run-sync-xyrelith-data-google-lighthouse-safe-browsing",
        "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": [
          "mode",
          "urls"
        ],
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "audit",
              "safeBrowsing"
            ],
            "type": "string",
            "description": "Run a full Lighthouse audit plus a Safe Browsing check, or only check Safe Browsing site status.",
            "default": "audit"
          },
          "urls": {
            "title": "Website URLs or domains",
            "minItems": 1,
            "type": "array",
            "description": "Websites to check, one per line. Paste full URLs (https://example.com/pricing) or bare domains (example.com). Duplicates are removed and missing https:// is added. A sitemap URL (sitemap.xml) is expanded into its pages.",
            "items": {
              "type": "string"
            }
          },
          "device": {
            "title": "Device",
            "enum": [
              "mobile",
              "desktop",
              "both"
            ],
            "type": "string",
            "description": "(mode=audit) Emulate a mid-range mobile phone on a slow 4G connection, a desktop browser, or run both profiles.",
            "default": "mobile"
          },
          "categories": {
            "title": "Lighthouse categories",
            "uniqueItems": true,
            "type": "array",
            "description": "(mode=audit) Which score categories to compute. Leave empty to run all four. Fewer categories make each audit a little faster.",
            "items": {
              "type": "string",
              "enum": [
                "performance",
                "accessibility",
                "best-practices",
                "seo"
              ],
              "enumTitles": [
                "Performance",
                "Accessibility",
                "Best practices",
                "SEO"
              ]
            },
            "default": [
              "performance",
              "accessibility",
              "best-practices",
              "seo"
            ]
          },
          "runsPerUrl": {
            "title": "Runs per URL",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "(mode=audit) Lighthouse scores vary between runs. With more than one run, every score and lab metric is the median of the completed runs. Each run is a full Lighthouse audit.",
            "default": 1
          },
          "throttling": {
            "title": "Network throttling",
            "enum": [
              "simulated",
              "devtools",
              "none"
            ],
            "type": "string",
            "description": "(mode=audit) Simulated matches PageSpeed Insights and is the most stable. DevTools applies real network and CPU throttling. None measures the raw connection.",
            "default": "simulated"
          },
          "includeSafeBrowsing": {
            "title": "Check Safe Browsing",
            "type": "boolean",
            "description": "(mode=audit) Add Google Safe Browsing status, malware, social engineering and unwanted software flags, and the last-checked date to every audited site. The actor checks the host first and then the exact page path when Google flags the site or cannot rate it.",
            "default": true
          },
          "sitemapPages": {
            "title": "Pages from each sitemap",
            "minimum": 0,
            "maximum": 25,
            "type": "integer",
            "description": "(mode=audit) For every URL or domain you list, also audit up to this many pages from its sitemap (found through robots.txt or /sitemap.xml). Set 0 to audit only the URLs you provided. A sitemap URL pasted directly is always expanded (up to 10 pages when this is 0).",
            "default": 0
          },
          "maxOpportunities": {
            "title": "Opportunities per audit",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "(mode=audit) How many ranked Lighthouse improvement opportunities to return, largest estimated savings first.",
            "default": 10
          },
          "includeHtmlReport": {
            "title": "Create HTML report",
            "type": "boolean",
            "description": "Write a self-contained HTML report for this run to the key-value store and add its link to every record.",
            "default": false
          },
          "auditTimeoutSecs": {
            "title": "Timeout per Lighthouse run (seconds)",
            "minimum": 30,
            "maximum": 300,
            "type": "integer",
            "description": "(mode=audit) Hard limit for one Lighthouse run. A timed-out run is retried once; if both attempts fail, a failed audit record is returned instead of stopping the whole run.",
            "default": 120
          },
          "maxItems": {
            "title": "Maximum audits",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Stop after this many audit records. A URL run on both mobile and desktop counts as two. Safe Browsing-only mode counts one record per unique site.",
            "default": 25
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}