Skip to main content
Glama
laszlopere

mcp-bytesmith

eth_hash

Compute Ethereum hashes: raw keccak-256, EIP-191 personal sign, or EIP-712 typed-data digests. Accepts text, hex, or base64 input, outputs hex or base64.

Instructions

Compute an Ethereum hash: raw keccak-256, EIP-191, or EIP-712 typed-data.

Returns {kind, hash}. For kind=eip712 the result also carries {domain_separator, struct_hash}, the two EIP-712 component hashes. Note keccak-256 is the pre-NIST Ethereum variant, not hashlib's SHA3-256.

Example: eth_hash("keccak256", "hello", "text") -> hash="0x1c8aff950685c2ed4bc3174f3472287b56d9517b9c948127319a09a7a36deac8".

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
kindYesHash flavor: 'keccak256' (raw Ethereum keccak-256), 'eip191' (personal_sign prefixed message), or 'eip712' (typed-data digest).
dataYesPolymorphic: for keccak256/eip191 it is the message bytes decoded per input_format; for eip712 it is the typed-data JSON object (a JSON string or already-parsed dict with types/primaryType/domain/message) and input_format is ignored.
input_formatNoHow to decode `data` to bytes for keccak256/eip191 (ignored for eip712); hex is 0x-prefixed or bare.text
output_formatNoDigest encoding: 'hex' is 0x-prefixed, or 'base64'.hex
Behavior4/5

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

With no annotations, the description carries full burden. It discloses that for eip712, the result includes additional component hashes, and notes the keccak-256 variant differs from standard SHA3-256. No destructive behavior is relevant. This is good transparency, though it could mention input size limits or error handling.

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?

Description is reasonably concise: 3 sentences plus an example. It front-loads the core purpose and then explains special cases. The example is helpful and earned its place. Could be slightly tighter, but not verbose.

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?

Lacks an output schema, but the description explains the return structure ('{kind, hash}' with extra fields for eip712). For a hash calculation tool, this covers key details. Missing minor aspects like error responses or behavior on invalid input, but overall sufficient given the tool's simplicity.

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?

All 4 parameters have descriptions in the input schema (100% coverage). The description adds value by explaining that for eip712, 'input_format' is ignored and 'data' is a JSON object, and provides an example of the output format. This goes beyond the schema without being redundant.

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?

Description clearly states the tool computes Ethereum hashes with three specific flavors: keccak-256, EIP-191, and EIP-712. This differentiates it from sibling tools like 'hash' or 'ens_namehash', making purpose unambiguous.

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?

Provides an example but does not explicitly state when to use this tool vs alternatives like 'hash' for non-Ethereum hashes or 'eth_selector' for function selectors. Usage context is implied, but no exclusions or comparative guidance are given.

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