Skip to main content
Glama

Decode a JWT

decode_jwt
Read-onlyIdempotent

Decode a JSON Web Token to inspect its header and payload, view timing claims in epoch and ISO formats, and check if the token is expired. Note: signature is not verified.

Instructions

Decodes the header and payload of a JSON Web Token and reports the timing claims (iat, nbf, exp) in both epoch and ISO form, along with whether the token is expired. The signature is returned but NOT verified — this tool inspects tokens, it does not validate them, and the result always says so.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tokenYesThe JWT to decode, with or without a "Bearer " prefix.
Behavior5/5

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

Annotations already indicate readOnlyHint and idempotentHint. The description adds crucial behavioral details: the signature is returned but not verified, and the result always states this. 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.

Conciseness5/5

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

Two sentences, front-loaded with the core action, followed by important caveats. Every sentence adds value with no redundancy.

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 tool with no output schema, the description fully covers what the tool does, what it returns, and what it omits. No gaps remain.

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?

The schema already describes the token parameter with full coverage. The description does not add new semantic detail beyond mentioning the tool accepts a JWT, which is already implied by the parameter name and schema description.

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 decodes the header and payload of a JWT, reports specific claims and expiry, and notes it does not verify. This distinguishes it from a validation tool, and siblings like hash_text or generate_uuid are unrelated.

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?

The description explicitly states the tool inspects but does not validate tokens, guiding the agent not to use it for verification. It does not name an alternative tool, but the context is clear enough for proper usage.

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/lllNuggetslll/devkit-mcp'

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