Skip to main content
Glama

JWT decoder

jwt_decode
Read-only

Decode a JSON Web Token's header and payload. It does NOT verify the signature, so never treat the claims as trusted on the strength of this tool. Use to inspect claims such as exp, iss and aud while debugging. Runs locally; the token is not stored or sent anywhere. Returns JSON {header, payload, signature}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tokenYesThe JWT: three base64url parts separated by dots.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. Changed1 schema field changed
    • changedInput schema / properties / token / description
      Previous value: -"JWT compact serialization (three dot-separated segments)"New value: +"JWT compact serialization — three base64url segments separated by dots (xxxxx.yyyyy.zzzzz). Bearer prefix must be removed before passing."
  4. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnlyHint=true; the description goes well beyond by stating it does not verify signatures, runs locally with no token storage/transmission, and returns a specific JSON structure. No contradiction with annotations.

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?

Four sentences, each carrying essential information: purpose, security caveat, usage context, and local behavior/return format. No fluff; the most critical safety warning is front-loaded.

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?

For a single-parameter, low-complexity tool with annotations covering read-only behavior, the description provides everything needed: return shape, security caveat, and local execution. No output schema exists, but the JSON structure is explicitly stated.

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 description coverage is 100% and already explains the token format ('three base64url parts separated by dots'). The description adds no new meaning about the parameter beyond what the schema provides, so the baseline of 3 applies.

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 precisely what it does (decodes JWT header and payload) and is distinct from all sibling tools – no other JWT-specific tool exists. The verb 'Decode' plus the resource 'JSON Web Token's header and payload' leaves no ambiguity.

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?

Explicitly gives when to use ('while debugging' to inspect claims) and a strong when-not (does not verify signature, so never treat claims as trusted). Though no alternative tool is named, no sibling performs JWT decoding, so the guidance is effectively complete.

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.

Resources