Skip to content

zero-auth API Documentation v1.6.0


zero-auth API Documentation / VerifyTokenOptions

Interface: VerifyTokenOptions ​

Defined in: packages/zero-auth/src/core/verify.ts:6

Optional issuer, audience, and clock-skew policy for JWTs.

Extends ​

Properties ​

algorithm? ​

optional algorithm?: SupportedAlgorithm

Defined in: packages/zero-auth/src/core/verify.ts:8

The expected JWT algorithm.

Default ​

ts
"HS256"

algorithms? ​

optional algorithms?: SupportedAlgorithm[]

Defined in: packages/zero-auth/src/core/verify.ts:10

Explicit allowed algorithms whitelist (overrides algorithm).


audience? ​

optional audience?: string | string[]

Defined in: packages/zero-auth/src/types/auth.ts:160

Expected aud claim. Added to new tokens and checked during verification.

Inherited from ​

JwtValidationConfig.audience


clockTolerance? ​

optional clockTolerance?: number

Defined in: packages/zero-auth/src/types/auth.ts:162

Allowed clock skew in seconds when validating time-based claims.

Inherited from ​

JwtValidationConfig.clockTolerance


issuer? ​

optional issuer?: string

Defined in: packages/zero-auth/src/types/auth.ts:158

Expected iss claim. Added to new tokens and checked during verification.

Inherited from ​

JwtValidationConfig.issuer