Skip to main content
Glama

html_to_markdown

Convert raw HTML into clean Markdown by stripping navigation, headers, footers, sidebars, forms, and scripts, leaving the readable article. Works offline without a network request.

Instructions

Turn HTML you already have into clean Markdown: navigation, headers, footers, sidebars, forms and scripts are stripped, the readable article remains. No browser, no network request, milliseconds. Use this when you hold the HTML (a saved page, an API response, a scraped body); use url_to_markdown when you only have a URL. $0.01.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
htmlYesRaw HTML source
modeNoarticle strips navigation; full keeps everythingarticle
outputNojson → {markdown, title, mode}; md → .md filejson
base_urlNoMakes relative links and images absolute
output_pathNo
idempotency_keyNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.7.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral burden. It clearly discloses what gets stripped (navigation, headers, footers, sidebars, forms, scripts), that no browser/network request is made, that it is fast, and the cost. It does not cover error behavior or edge cases, but covers the most relevant operational traits.

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?

Four crisp sentences front-load the core purpose, then add usage routing, performance, and cost. Every sentence contributes useful information without padding.

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?

The description provides strong selection guidance, behavioral expectations, performance characteristics, and pricing. It relies on the schema for parameter details; the two undocumented parameters are a minor gap but do not undermine overall tool selection or basic invocation.

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 description coverage is 67%, and the description adds little parameter-level meaning beyond what the schema already provides. It reinforces article-mode stripping behavior but leaves output_path and idempotency_key undocumented in both schema and description.

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 states a specific verb and resource: turning existing HTML into clean Markdown. It also distinguishes itself from url_to_markdown by emphasizing 'HTML you already have' versus having only a URL.

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 states when to use this tool: when holding HTML from a saved page, API response, or scraped body. It also names the alternative url_to_markdown and the condition that should route to it.

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