Skip to main content
Glama
Jambozx

OnlineCyberTools MCP (280+ filterable tools)

webdev_xml_formatter

Read-onlyIdempotent

Format and validate XML documents with customizable indentation, attribute sorting, and comment removal. Check well-formedness and get element statistics.

Instructions

XML Formatter and Validator. Pretty-print, beautify, and validate XML with configurable indentation (spaces or tabs), attribute sorting, comment removal, and an optional XML declaration. Pass the document as the xml parameter. Use webdev_xml_to_json when you need to convert XML into a JSON object rather than tidy the markup; use webdev_sql_formatter or webdev_graphql_formatter for those languages. Regex-based parser (not a full XML processor), so DTDs and complex namespaces are not resolved and malformed markup is reported as an error with the original text echoed back. Runs locally via a Node bridge: read-only, non-destructive, contacts no external service, rate-limited (30 requests/minute for anonymous callers). Returns the formatted XML, a validity flag, error and warning lists, and element/attribute/size statistics.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xmlYesThe XML document to format or validate. Must not be blank.
formatNoPretty-print with indentation when true; emit compact single-line XML when false.
validateNoCheck well-formedness and report mismatched or unclosed tags as errors.
indentSizeNoNumber of spaces per indent level (ignored when indentType is tabs).
indentTypeNoWhether each indent level is spaces or a tab character.spaces
removeCommentsNoStrip XML comments from the output when true.
preserveWhitespaceNoKeep original text whitespace when true; trim element text when false.
sortAttributesNoSort the attributes of each element alphabetically by name when true.
addDeclarationNoPrepend an XML declaration (version 1.0, UTF-8) when one is absent.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
originalNoThe submitted XML, echoed back.
formattedNoThe formatted XML, or the original input when parsing failed.
isValidNoWhether the XML parsed as well-formed.
errorsNoParse error messages (empty when valid).
warningsNoNon-fatal warnings.
statsNoNode counts and size metrics for the document.
Behavior5/5

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

Annotations already indicate read-only, non-destructive, idempotent. Description adds important details: regex-based parser (not full XML processor), rate limit of 30 requests/minute, local execution via Node bridge, and error handling behavior. No contradictions.

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?

Single, well-structured paragraph covering purpose, features, alternatives, limitations, and performance. Every sentence adds value without redundancy.

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?

Given 9 parameters, full schema coverage, and existing output schema, the description adequately covers purpose, usage context, behavioral traits, and limitations. It is complete for an AI agent to decide when and how to use this tool.

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 baseline 3. Description summarizes parameter categories but does not add significant semantic value beyond what the schema already provides for each parameter.

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?

The description clearly states it formats and validates XML, listing specific features like pretty-print, attribute sorting, comment removal, and optional declaration. It distinguishes itself from siblings by naming alternative tools for XML-to-JSON conversion and other language formatters.

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

Usage Guidelines5/5

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

Explicitly tells when to use alternatives: 'Use webdev_xml_to_json when you need to convert XML into a JSON object rather than tidy the markup; use webdev_sql_formatter or webdev_graphql_formatter for those languages.' Also warns about limitations for complex XML.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Jambozx/onlinecybertools-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server