{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/ayrank-com/json-schema/ayrank-com-hreflang-checker-response-schema.json",
  "title": "HreflangCheckerResponse",
  "x-generated": "2026-12-02",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/ayrank-com-openapi.json#/components/schemas/HreflangCheckerResponse",
  "type": "object",
  "required": [
    "input",
    "finalUrl",
    "status",
    "redirects",
    "error",
    "report",
    "alternates",
    "alternatesListed",
    "limits",
    "checkedAt",
    "poweredBy"
  ],
  "properties": {
    "input": {
      "type": "string"
    },
    "finalUrl": {
      "type": "string",
      "description": "URL that answered after redirects. The set is checked against it."
    },
    "status": {
      "type": [
        "integer",
        "null"
      ]
    },
    "redirects": {
      "type": "integer"
    },
    "error": {
      "type": [
        "string",
        "null"
      ],
      "description": "timeout, network, too-many-redirects or null."
    },
    "truncated": {
      "type": "boolean",
      "description": "The page was larger than the read cap."
    },
    "report": {
      "type": [
        "object",
        "null"
      ],
      "description": "Null unless the page answered 2xx. { pageUrl, canonical, canonicalMatch (exact, trailing-slash or none), entries, entriesTotal, sources { html, header }, headEnd { reason (end-tag, body, element or eof), tag, line }, issues, errors, warnings }. Each entry is { hreflang, href, url, source (html or header), line, code { valid, xDefault, language, script, region, problem, suggestion }, self }. Each issue is { code, severity (error, warning or info), count, samples }. Codes: invalid-format, underscore, not-iso-639-1, unknown-language, region-only, withdrawn-language, unknown-script, numeric-region, reserved-region, withdrawn-region, unknown-region, missing-href, invalid-href, relative-href, missing-self, outside-head, alternate-not-200, no-return-link, alternate-canonical-mismatch, duplicate-hreflang, self-trailing-slash, missing-x-default, not-alternate, media-attribute, canonical-elsewhere, return-link-trailing-slash, alternate-redirect, alternate-unreachable, no-hreflang, language-looks-like-region, both-sources, alternates-not-checked."
    },
    "alternates": {
      "type": "array",
      "description": "One per alternate URL read: { url, hreflang (values the page gives it), outcome (ok, redirect, not-200, blocked, timeout, network, too-many-redirects or skipped), status, redirects, finalUrl, finalStatus, hreflangCount, returnLink (exact, trailing-slash, none or null), returnHreflang, canonical, canonicalMatch }.",
      "items": {
        "type": "object"
      }
    },
    "alternatesListed": {
      "type": "integer",
      "description": "Alternate URLs the page lists, other than itself."
    },
    "limits": {
      "type": "object",
      "description": "The caps used for this call."
    },
    "checkedAt": {
      "type": "string",
      "format": "date-time"
    },
    "poweredBy": {
      "$ref": "#/$defs/PoweredBy"
    }
  },
  "$defs": {
    "PoweredBy": {
      "type": "object",
      "required": [
        "text",
        "url"
      ],
      "properties": {
        "text": {
          "type": "string",
          "const": "Powered by AY Rank"
        },
        "url": {
          "type": "string",
          "format": "uri"
        }
      }
    }
  }
}