# SiteCheck JWT Decode & Verify

> SiteCheck JWT Decode & Verify is a paid API for AI agents from api.sitecheck-api.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-11-23).

Decodes a JWT into its header, claims, and payload, and optionally verifies the signature against a JWKS URL

## Facts

- Endpoint: GET https://api.sitecheck-api.workers.dev/api/jwt/decode?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sitecheck-jwt-decode-verify-4488f07d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_m8brzjlenEbzq3wFMSI8s

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability sitecheck-jwt-decode-verify-4488f07d
```

Example prompt: Decode this JWT for me and tell me who the subject is, when it was issued, and whether it's expired: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c — and if you can, verify the signature against https://example.com/.well-known/jwks.json.

## When to prefer this

Use this endpoint when you need a lightweight, pay-per-call JWT decoder without deploying your own cryptography library — especially useful for AI agents inspecting bearer tokens, debugging auth flows, or verifying OpenID Connect / OAuth2 ID tokens against a public JWKS URL. Prefer it over full auth SDKs when you just need to read claims or do a one-off signature check without managing secrets.

## Known failure modes

- Malformed JWT (not three base64url parts) returns a parse error
- Token exceeding 16 KB may be rejected
- JWKS URL unreachable or returning non-2xx causes signature verification to fail with an error reason
- JWKS URL contains no key matching the token's kid, resulting in verified: false
- Algorithm mismatch between header and JWKS key causes verification failure
- Missing required 'token' query parameter returns a 400-level error

## How this service works

Decodes a JWT (up to 16 KB): header, payload, registered claims as ISO dates, expired and not-yet-valid flags, algorithm and signature length. With jwksUrl (public https) the signature is checked with WebCrypto for RS, PS and ES algorithms against the matching key. 'none' is never accepted; HMAC needs the secret. Tokens are secrets: this tool does not store or log them.

## Output

Returns a JSON object containing the decoded JWT header (algorithm, type, kid), the parsed claims (issuer, subject, audience, issuedAt, expiresAt, notBefore), the raw payload, whether the token is expired or not yet valid, the signature byte count, and — if a JWKS URL was provided — a verified boolean and reason string indicating whether the signature was cryptographically confirmed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "token"
     ],
     "properties": {
      "token": {
       "type": "string",
       "description": "The JWT, three base64url parts separated by dots (up to 16 KB)"
      },
      "jwksUrl": {
       "type": "string",
       "description": "Public https URL of the JWKS to verify with (optional)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "kid": null,
  "type": "JWT",
  "claims": {
   "issuer": null,
   "subject": "1234567890",
   "audience": null,
   "issuedAt": "2018-01-18T01:30:22.000Z",
   "expiresAt": null,
   "notBefore": null
  },
  "header": {
   "alg": "HS256",
   "typ": "JWT"
  },
  "source": "Decoded here; signature check with WebCrypto against the JWKS you give",
  "expired": false,
  "payload": {
   "iat": 1516239022,
   "sub": "1234567890"
  },
  "verified": null,
  "algorithm": "HS256",
  "checkedAt": "2026-10-15T14:07:52.200Z",
  "notYetValid": false,
  "signatureBytes": 32,
  "verifiedReason": "no jwksUrl given, so the signature was not checked"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sitecheck-jwt-decode-verify-4488f07d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.sitecheck-api.workers.dev](https://www.zero.xyz/host/api.sitecheck-api.workers.dev/llms.txt)
