Skip to main content
Glama
laszlopere

mcp-bytesmith

encode

Encode bytes or text into base-N, URL, IDNA, bech32, hexdump, or bytes32 formats. Options for padding, alphabet, and width.

Instructions

Encode bytes/text into a string form (base-N, URL, IDNA, bech32, hexdump, bytes32).

data is decoded to bytes via input_format (text|hex|base64). options is a per-scheme dict: padding (bool, default true — base32/base64 family), alphabet (custom symbol set — base58/base62), hrp (required for bech32/bech32m), width (bytes per line — hexdump, default 16). idna and bytes32 read data as a text string / short string respectively. bytes32 is a fixed-width 32-byte EVM word: inputs of <32 bytes are right-padded with 0x00; decode returns all 32 bytes (it does NOT strip trailing nulls, so the round-trip is lossless — rstrip them yourself for a short string). Returns {scheme, encoded}. Example: encode("hello", "base64") -> encoded "aGVsbG8="

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYesInput to encode, decoded to bytes via `input_format` (idna/bytes32 read it as text).
schemeYesTarget encoding: base16/32/32hex/32crockford/45/58/58check/62/64/64url, ascii85/base85/z85, url/url_form (percent), idna, bech32/bech32m, hexdump, or bytes32 (32-byte EVM word).
input_formatNoHow `data` is decoded to bytes; default 'text'.text
optionsNoPer-scheme options: padding (bool, base32/64 family), alphabet (base58/62), hrp (required for bech32/bech32m), width (hexdump, default 16). Default None.
Behavior5/5

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

No annotations provided, so the description fully discloses behavior: how data is decoded via input_format, per-scheme options, padding, alphabet, hrp, width, and bytes32 padding with round-trip note. It also specifies the return format. 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.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with a clear overall statement, then per-parameter details and an example. It is slightly lengthy (~170 words) but each sentence provides valuable information; could be trimmed slightly but still good.

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 the tool's complexity (20 schemes, multiple options, no output schema), the description is comprehensive. It covers data decoding, scheme-specific options, bytes32 behavior, and return format. Missing only explicit mention of error cases, but schema enums handle validation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% but the description adds significant value: it explains the meaning of each parameter (data, scheme, input_format, options) with specific details (e.g., default for input_format, per-scheme options like padding, hrp, width). It also provides an example, enhancing understanding beyond the schema.

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 encodes bytes/text into a string form using various schemes (base-N, URL, IDNA, bech32, hexdump, bytes32). It lists specific schemes and provides an example, making the purpose unambiguous and distinct from sibling tools like decode or hash.

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

Usage Guidelines4/5

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

While it doesn't explicitly state when to use versus alternatives, the description gives clear context on how to use each scheme and parameter. The sibling tools are sufficiently different (e.g., decode, hash) that the purpose alone guides selection, but explicit guidance would be better.

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/laszlopere/mcp-bytesmith'

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