Lint hreflang annotations
lint_hreflangLint hreflang annotations for international SEO. Accepts pasted text (not a URL; this tool never fetches anything): page HTML with tags, an XML sitemap with xhtml:link alternates, or a JSON set {"pages":[{"url","canonical","alternates":[{"hreflang","href"}]}]}. Checks language/script/region codes, x-default, self-reference, canonical conflicts, duplicates and reciprocal return links. Returns valid true/false, counts, the codes found, and up to 25 issues with paths, messages and suggested fixes. Read-only. Same engine as the HrefGate JSON API (POST /api/lint).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input | Yes | Page HTML, sitemap XML, or JSON {"pages":[{"url":"https://example.com/en/","alternates":[{"hreflang":"en","href":"https://example.com/en/"}]}]}. | |
| page_url | No | Absolute URL of the pasted HTML page (HTML input only). Enables self-reference and canonical checks. | |
| include_raw | No | Also return the full /api/lint JSON (all issues) in structuredContent.raw. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| raw | No | Full /api/lint response (only when include_raw is true) | |
| codes | No | ||
| infos | Yes | ||
| pages | No | ||
| valid | Yes | ||
| errors | Yes | ||
| issues | Yes | ||
| version | Yes | ||
| warnings | Yes | ||
| alternates | No | ||
| issuesOmitted | No |