Decode options.
OptionalerrorMessagePrefix?: stringOptional prefix for error messages thrown during decoding, to provide more context on where the error occurred
OptionalheaderSchema?: HeaderSchemaSchema to use for validating the header. If not provided the
default zJwtHeader schema will be used
The compact encoded jwt
OptionalpayloadSchema?: PayloadSchemaSchema to use for validating the payload. If not provided the
default zJwtPayload schema will be used
Decoded and schema-validated JWT header, payload, and signature segment.
Decodes a compact JWT and validates its header and payload with Zod schemas.
This helper does not verify the JWT signature.