Skip to main content
Glama

jwt_decode

Decodes the header and payload of a JSON Web Token without verifying the signature, and reports issued-at, expiry and whether it is expired. 0.001 USDC per call via x402.

Input Schema

NameRequiredDescriptionDefault
tokenYesThe JWT string
paymentProofNoPayment proof: USDC tx hash on Polygon or Base (0x...) or Solana tx signature. Omit on the first call to receive the 402 payment instructions, pay, then call again with the proof.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden, and it discloses the two most important behavioral traits: the signature is NOT verified (so the output is untrusted) and the call costs 0.001 USDC via x402. It does not say what happens with a malformed or non-JWT string, which is the main remaining gap for a no-annotation tool.

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, zero filler: the decode scope and the no-verification caveat come first, followed by the return contents and then the pricing constraint. Everything an agent needs to decide and pay is front-loaded.

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?

There is no output schema, yet the description names the returned claims (header, payload, iat, exp, expired), so return values are covered, and the payment mechanics live in the schema. The only shortfall is undefined behavior on invalid input, which matters for a free-form string parameter.

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 both parameters are fully documented in the schema, including the 402 payment retry flow, so the baseline is 3. The description's payment sentence reinforces the cost context behind paymentProof but adds no new semantics for the token parameter beyond the schema.

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?

Names a specific verb and resource (decode a JWT's header and payload) and immediately scopes it with 'without verifying the signature', which separates it from any verification tool and from generic siblings like base64 or json_format. The added return content (issued-at, expiry, expired flag) makes the tool's output purpose concrete.

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?

The 'without verifying the signature' clause implies when the tool is appropriate (inspection only, not trust decisions), but there is no explicit when-to-use/when-not statement or named alternative. With no other JWT or token-inspection sibling, the agent must infer that this is the decode path, which is implied rather than stated.

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.