Skip to main content
Glama

HTML Table to Structured JSON & Markdown Parser

parse_html_tables
Read-onlyIdempotent

Convert HTML table elements into structured JSON records, Markdown grids, or CSV strings for financial statements, product comparisons, and sports statistics.

Instructions

Detects and parses HTML table elements into structured JSON record arrays and GitHub-Flavored Markdown tabular grids. Use when converting financial statements, product comparison grids, or sports statistics into structured data tables; for extracting raw clean markdown prose, use extract_clean_markdown instead. Stateless read-only edge call (max 32 KB, 60 RPM): accepts 'html_content' ('output_format' defaults to 'markdown_and_json'), supports '?demo=true' or L402 (10 sats), and returns HTTP 400 if invalid.

Input Schema

NameRequiredDescriptionDefault
min_rowsNoMinimum rows required for a table to be parsed and retained.
html_contentYesRaw HTML string containing one or more table, thead, tbody, or tr elements.
output_formatNoTabular export formatting standard: markdown and JSON, JSON records only, or CSV string.

Output Schema

NameRequiredDescriptionDefault
tables_foundYesCount of valid HTML tables detected and transformed.
markdown_tablesYesList of GitHub-Flavored Markdown formatted table strings.
structured_recordsYesParsed array of row objects keyed by header column titles.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.6.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already cover readOnly/idempotent/non-destructive/closed-world, and the description layers genuinely new operational context on top: stateless edge call, 32 KB payload cap, 60 RPM rate limit, L402 payment of 10 sats, ?demo=true, and HTTP 400 on invalid input. It stops short of describing how tables that fail min_rows are reported, but the constraint disclosure is well above the annotation baseline.

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?

Two dense sentences, front-loaded with the core action before use cases and operational limits. The second sentence stacks several facts (size, rate, formats, payment, error code) and reads a bit like a spec dump, but nothing is filler.

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 stateless parser with a full schema and an output schema, everything an agent needs is present: input format expectations, output representations, size and rate ceilings, auth options, and failure behavior. Return-value details are correctly delegated to the output schema.

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 the baseline is 3; the description still adds value by documenting the output_format default ('markdown_and_json'), which the schema does not state, and by naming html_content explicitly. min_rows is left to the schema, which is acceptable given full coverage.

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?

States a specific verb and resource ('detects and parses HTML table elements') plus the two output representations (JSON record arrays and GFM markdown grids). It names a sibling it is not, extract_clean_markdown, so an agent can route without opening either schema.

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?

Gives concrete positive cases (financial statements, product comparison grids, sports statistics) and an explicit negative case with the alternative tool named ('for extracting raw clean markdown prose, use extract_clean_markdown instead'). The when/when-not pair is fully specified.

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

Deploy Server

Other Tools