Skip to main content
Glama
paladini

devutils-mcp-server

html_decode

Convert HTML-encoded strings back to readable text by decoding entities like & and < into their original characters.

Instructions

Decode HTML entities in a string back to their original characters.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYesThe HTML-encoded string to decode

Implementation Reference

  • The 'html_decode' tool is registered and implemented directly within the registerEncodingTools function in src/tools/encoding.ts, using a series of string replacements to decode common HTML entities.
    server.tool(
      "html_decode",
      "Decode HTML entities in a string back to their original characters.",
      { input: z.string().describe("The HTML-encoded string to decode") },
      async ({ input }) => {
        const decoded = input
          .replace(/&/g, "&")
          .replace(/</g, "<")
          .replace(/>/g, ">")
          .replace(/"/g, '"')
          .replace(/'/g, "'")
          .replace(/'/g, "'")
          .replace(///g, "/");
        return { content: [{ type: "text" as const, text: decoded }] };
      }
    );
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It adequately explains the core transformation (entities to characters) but omits details about edge case handling (malformed entities, numeric vs named entities), idempotency, or character encoding assumptions that would be useful for a text processing utility.

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 sentence with no redundant words. The description is immediately front-loaded with the verb and object, efficiently communicating the tool's function without filler text or unnecessary elaboration.

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?

Given the tool's simplicity (single parameter, pure transformation), the description is reasonably complete. It covers the essential operation and the parameter is well-documented in the schema. Minor gap: could explicitly note that this reverses html_encode operations, but sufficient for agent 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?

The input schema has 100% description coverage ('The HTML-encoded string to decode'), so the baseline is 3. The description reinforces this by referring to 'HTML entities' in the operation summary, which adds semantic context about the expected input format, but does not provide additional details about valid entity formats or examples beyond what the schema provides.

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?

The description clearly identifies the specific transformation (decoding HTML entities → original characters) and uses precise terminology that distinguishes it from sibling decode tools like base64_decode or url_decode by specifying 'HTML entities'. However, it doesn't explicitly differentiate from html_encode (its inverse) or indicate when to choose this over other parsers.

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

Usage Guidelines2/5

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

No guidance provided on when to use this tool versus html_encode (encoding vs decoding) or versus other string manipulation tools. No examples or prerequisites (e.g., 'use when processing HTML content with escaped characters like &') are included to help the agent select appropriately from the 20+ conversion utilities available.

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/paladini/devutils-mcp-server'

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