Skip to main content
Glama

jwt_decode

Read-onlyIdempotent

Decodes a JWT's header and payload WITHOUT verifying its signature, so its claims must not be trusted on this basis alone. To check authenticity, use jwt_verify.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tokenYesThe JWT to decode. Decodes header and payload only -- does not verify the signature (use /jwt-verify for that).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / token / description
      Previous value: -""New value: +"The JWT to decode. Decodes header and payload only -- does not verify the signature (use /jwt-verify for that)."
  2. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so no contradiction. The description adds valuable context beyond annotations: it explicitly warns that the signature is NOT verified, which is a critical behavioral trait for security-sensitive operations. This warning is essential for agents to avoid misusing the decoded claims. The description does not repeat annotation info but adds the non-verification caveat, which is significant.

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?

The description is two sentences with zero wasted words. The primary purpose and critical caveat (non-verification) are front-loaded, and the alternative is named concisely. Every sentence serves a purpose.

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 simplicity (single parameter, no output schema, no nested objects), the description is complete. It covers purpose, usage guidance, and the key warning about signature verification. There is no missing information that an agent would need to call this tool correctly.

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 100% and the sole parameter `token` is adequately described in the schema (including the warning about non-verification). The description adds minimal extra meaning about the parameter beyond what the schema provides, so baseline 3 is appropriate.

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 the specific verb 'Decodes' and the exact resource ('a JWT's header and payload'), and immediately distinguishes itself from jwt_verify by emphasizing it does NOT verify the signature. This clearly differentiates it from the sibling tool jwt_verify, and the mention of 'header and payload' specifies the scope.

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

Usage Guidelines5/5

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

The description explicitly states when to use this tool (for decoding without verification) and when not to trust its output ('claims must not be trusted on this basis alone'). It names the alternative tool jwt_verify for checking authenticity, giving clear guidance on when to use the sibling instead.

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.