Skip to main content
Glama

x402 Toolbox

Convert between UTF-8, hex, base64, base64url, base32, base58; URL and HTML escaping

encode
Read-onlyIdempotent

Convert between UTF-8, hex, base64, base64url, base32, base58; URL and HTML escaping. Re-encodes data from one encoding to another (utf8, hex, base64, base64url, base32, base58), or applies url-encode / url-decode / html-escape / html-unescape. Reports invalid UTF-8 instead of guessing. Price: $0.003 USDC per call via x402 (eip155:8453).

Input Schema

NameRequiredDescriptionDefault
toNobase64
dataYes
fromNoutf8

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, so the safety bar is low. The description still adds genuinely useful behavior: 'Reports invalid UTF-8 instead of guessing' (error semantics) and the x402 pricing/metering model, which an agent needs to know before calling. It does not say what a return value looks like, but no output schema exists and that gap is minor for an encode utility.

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?

Front-loaded with the capability and kept to three sentences with no filler. There is mild redundancy: sentence one restates the title and sentence two repeats the same encoding list, so one sentence could be trimmed.

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 pure, idempotent transform tool with full enum schemas and annotations, this covers the encodings, escaping modes, error behavior, and cost. Missing only the default direction and input-size ceiling, which would round out an otherwise complete definition.

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 0%, so the description must carry parameter meaning. It does supply the semantic mapping the enums alone don't: 'to=url' means url-encode and 'from=url' means url-decode, and similarly for html-escape/unescape — that is real added value. It omits the defaults (to=base64, from=utf8) and the 1 MiB data limit, which the schema also leaves undocumented.

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 (re-encode/convert) plus the full set of supported encodings, and the escaping operations. An agent can immediately tell this apart from hash, hmac, url_parse or text_transform.

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?

Usage is implied by the enumeration of operations, but there is no explicit when-to-use or when-not-to guidance relative to neighbors like url_parse (which parses a URL into components) or hash/hmac (which digest rather than encode). The reader must infer the boundary.

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.