interface JwtResolverOptions

Options for JwtResolver.

Properties

optional
claim: string

JWT claim name that holds the tenant id (default 'tenant_id').

optional
headerName: string

Authorization header name (default 'authorization').

optional
decode: (token: string) => Record<string, unknown> | null

Custom JWT-decode function. When absent the plugin resolves IJwtService.decode from the capability token in register().

Usage

import { type JwtResolverOptions } from "multi-tenancy-plugin/src/index.ts";