Skip to main content
Glama

Lint hreflang annotations

lint_hreflang
Read-onlyIdempotent

Lint 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

TableJSON Schema
NameRequiredDescriptionDefault
inputYesPage HTML, sitemap XML, or JSON {"pages":[{"url":"https://example.com/en/","alternates":[{"hreflang":"en","href":"https://example.com/en/"}]}]}.
page_urlNoAbsolute URL of the pasted HTML page (HTML input only). Enables self-reference and canonical checks.
include_rawNoAlso return the full /api/lint JSON (all issues) in structuredContent.raw.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rawNoFull /api/lint response (only when include_raw is true)
codesNo
infosYes
pagesNo
validYes
errorsYes
issuesYes
versionYes
warningsYes
alternatesNo
issuesOmittedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly/idempotent/non-destructive/openWorld=false, so the safety profile is covered. The description adds genuine value beyond that: the 'never fetches anything' constraint, the 25-issue cap, and the concrete return shape (valid true/false, counts, codes, issues with paths/messages/fixes).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Dense but front-loaded with the core action and the input contract before the exhaustive check list. Every sentence carries information, though the enumeration of checks and the API reference make it longer than strictly necessary.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a single-required-input linting tool with an output schema, the description covers purpose, input forms, the no-fetch constraint, and the checks performed. An agent has everything needed to invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so all three parameters are already documented, including input format examples and page_url's role. The description restates the accepted formats but adds no syntax or semantics beyond the schema, making the baseline 3 correct.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Specific verb 'lint' plus explicit resource 'hreflang annotations' scoped to 'international SEO'. It enumerates exactly what is checked (codes, x-default, self-reference, canonical conflicts, duplicates, reciprocals), so an agent knows precisely what the tool does without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Clearly states the input modality and a key exclusion: 'Accepts pasted text (not a URL; this tool never fetches anything)'. No siblings exist to route against, so there is nothing left to differentiate, but it stops short of explicit when-to-use/when-not guidance beyond the fetch exclusion.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources