Skip to main content
Glama

HMAC generator

hmac
Read-onlyIdempotent

Compute a keyed message authentication code from text and a secret key, choosing the digest algorithm and hex or base64 output to verify message integrity and authenticity.

Instructions

Compute an HMAC of a message with a secret key. (Same as IT-Tools /hmac-generator.)

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "<text>",
      "key": "<key>"
    },
    "name": "hmac"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYesSecret key (UTF-8)
textYes
encodingNoDigest encodinghex
algorithmNosha256

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint and openWorldHint=false, so the safety and determinism profile is covered structurally. The description adds nothing beyond that: it does not state that the result is a deterministic pure computation, that the default algorithm is sha256, or what secret-handling expectations exist. Consistent with annotations but not additive.

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 short sentences with the operative definition front-loaded and no padding within the first sentence. The trailing parenthetical reference to the IT-Tools equivalent is low-value filler but does not obscure anything.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

This is a simple pure-function tool, so the bar is modest, and annotations cover the safety profile. However, with no output schema the description should say what comes back (an encoded digest string, hex by default), and it omits the default algorithm. An agent can call it, but return-shape expectations are left to the schema's encoding default.

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?

Schema coverage is 50%: key and encoding carry descriptions, while text has none and algorithm only has an enum. The description clarifies that 'text' is the message being authenticated, which is genuinely useful, but it says nothing about algorithm or encoding choices. Marginal value over the schema, roughly baseline.

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 names a specific verb and resource: compute an HMAC of a message using a secret key. That is materially clearer than the bare name, and the 'with a secret key' phrasing hints at the keyed-vs-unkeyed distinction. It stops short of explicitly differentiating this from the sibling hash_text, which an agent would need to tell the two apart.

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 only implied: an agent must infer that this is the tool for keyed message authentication rather than plain hashing. There is no explicit when-to-use, no exclusion, and no pointer to hash_text or encrypt_text as alternatives. The '(Same as IT-Tools /hmac-generator.)' note is a familiarity reference, not routing guidance.

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