Skip to main content
Glama

XSDHub: XML and invoice validation

Validate XML against XSD

validate_xml_against_xsd
Read-onlyIdempotent

Check XML against a pinned officialSchema package or supplied XSD 1.0/1.1. Imports resolve inside the selected package only. Returns bounded findings and original schema hashes. The mf-etransport-v2 package also runs original official Schematron 2.0.2, all phases, with separate metadata.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "xml": "<xml>"
    },
    "name": "validate_xml_against_xsd"
  }
}

Input Schema

NameRequiredDescriptionDefault
xmlYesComplete UTF-8 XML text, at most 10 MiB. DTDs and entities are blocked.
xsdNoUTF-8 XSD text, at most 1 MiB. Use either xsd or schemaFiles. No remote fetching.
rootSchemaNoRequired with schemaFiles; path of the entry XSD.
xsdVersionNoXSD engine version: 1.0 (default) or 1.1. Choose 1.1 for schemas using assertions or other XSD 1.1 features.1.0
bankProfileNoOptional ID from /bank-profiles.json; default generic-epc. Adds only the explicitly listed public-bank checks.
schemaFilesNoComplete local XSD project: 1–100 files, at most 1 MiB per file and 10 MiB total. Supply rootSchema and omit xsd; imports/includes resolve only among these files.
max_findingsNoMaximum combined errors and warnings returned (1–100). Validation scope is unchanged.
include_guidesNoInclude guide URLs in validation results.
officialSchemaNoPinned official package ID from /official-schemas.json. Supply this instead of xsd/schemaFiles; the server selects the exact engine and records original hashes.
bankProfileVersionNoOptional exact published profile version. An unavailable version fails closed.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / officialSchema / enum
      Previous value: -[
      -  "ubl-order-2.1",
      -  "ubl-despatchadvice-2.1",
      -  "dgfip-dpi-2026",
      -  "dgfip-dpi-2025",
      -  "anaf-d406",
      -  "mf-v7m3",
      -  "mf-v7k3",
      -  "mf-v7m2",
      -  "mf-v7k2",
      -  "mf-jpk-fa4",
      -  "mf-jpk-fa3",
      -  "mf-dpi-is",
      -  "mf-dpi-fr"
      -]New value: +[
      +  "ubl-order-2.1",
      +  "ubl-despatchadvice-2.1",
      +  "dgfip-dpi-2026",
      +  "dgfip-dpi-2025",
      +  "anaf-d406",
      +  "mf-v7m3",
      +  "mf-v7k3",
      +  "mf-v7m2",
      +  "mf-v7k2",
      +  "mf-jpk-fa4",
      +  "mf-jpk-fa3",
      +  "mf-dpi-is",
      +  "mf-dpi-fr",
      +  "iso-camt.053.001.08",
      +  "iso-camt.053.001.14",
      +  "iso-camt.054.001.08",
      +  "iso-camt.054.001.14",
      +  "iso-head.001.001.02",
      +  "iso-head.001.001.04",
      +  "iso-pacs.008.001.08",
      +  "iso-pacs.008.001.14",
      +  "iso-pain.001.001.03",
      +  "iso-pain.001.001.09",
      +  "iso-pain.008.001.02",
      +  "iso-pain.008.001.08",
      +  "mf-etransport-v2"
      +]
  2. Changed1 schema field changed
    • addedInput schema / properties / officialSchema
      Added value: +{
      +  "description": "Pinned official package ID from /official-schemas.json. Supply this instead of xsd/schemaFiles; the server selects the exact engine and records original hashes.",
      +  "enum": [
      +    "ubl-order-2.1",
      +    "ubl-despatchadvice-2.1",
      +    "dgfip-dpi-2026",
      +    "dgfip-dpi-2025",
      +    "anaf-d406",
      +    "mf-v7m3",
      +    "mf-v7k3",
      +    "mf-v7m2",
      +    "mf-v7k2",
      +    "mf-jpk-fa4",
      +    "mf-jpk-fa3",
      +    "mf-dpi-is",
      +    "mf-dpi-fr"
      +  ],
      +  "type": "string"
      +}
  3. Changed2 schema fields changed
    • addedInput schema / properties / bankProfile
      Added value: +{
      +  "description": "Optional ID from /bank-profiles.json; default generic-epc. Adds only the explicitly listed public-bank checks.",
      +  "maxLength": 100,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / bankProfileVersion
      Added value: +{
      +  "description": "Optional exact published profile version. An unavailable version fails closed.",
      +  "maxLength": 100,
      +  "minLength": 1,
      +  "type": "string"
      +}
  4. Changed3 schema fields changed
    • addedInput schema / properties / schemaFiles / description
      Added value: +"Complete local XSD project: 1–100 files, at most 1 MiB per file and 10 MiB total. Supply rootSchema and omit xsd; imports/includes resolve only among these files."
    • changedInput schema / properties / schemaFiles / items / properties / content / description
      Previous value: -"UTF-8 XSD text, at most 1 MiB. Use either xsd or schemaFiles. No remote fetching."New value: +"Complete UTF-8 XSD text for this project file, at most 1 MiB. Imports/includes must reference supplied project files; no remote fetching."
    • addedInput schema / properties / xsdVersion / description
      Added value: +"XSD engine version: 1.0 (default) or 1.1. Choose 1.1 for schemas using assertions or other XSD 1.1 features."
  5. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare read-only, idempotent, non-destructive, closed-world behavior, and the description adds real context beyond them: imports resolve only inside the selected package, findings are bounded, and original schema hashes are recorded. It also discloses the special mf-etransport-v2 behavior of running official Schematron 2.0.2 across all phases with separate metadata, which is non-obvious and materially affects result interpretation.

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

Conciseness5/5

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

Three tight sentences, front-loaded with the core action and then the input-mode constraints and the special-case package behavior. Every clause carries information an agent would otherwise have to discover from the schema or by trial.

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

Completeness4/5

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

For a 10-parameter, no-output-schema tool, the description covers the important behavioral surface: mode selection, import resolution boundaries, bounded output plus hashes, and the Schematron special case. It stops short of describing the shape of findings or the guide/metadata fields, leaving some inference to the schemas.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3; the description nonetheless adds meaning by clarifying that package imports are confined to the selected package and that findings are bounded while validation scope is unchanged. Those statements tie officialSchema and max_findings to observable behavior rather than restating types.

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

Purpose4/5

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

States a specific verb and resource ("Check XML against a pinned officialSchema package or supplied XSD 1.0/1.1") and names the two input modes clearly. It does not differentiate itself from the sibling tools validate_xml, validate_e_invoice, or explain_validation_error, so an agent must infer positioning from context rather than the text.

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

Usage Guidelines3/5

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

Gives useful internal selection rules: use officialSchema instead of xsd/schemaFiles, supply rootSchema with schemaFiles, and the mf-etransport-v2 path triggers Schematron. Missing any explicit when-to-use-this-vs-sibling guidance, particularly against validate_xml and validate_e_invoice, so usage is only implied by the parameter trade-offs.

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