/** * Manually implement zod guards of some node OIDC provider types. * * Please note that we defined `accessTokenPayloadGuard` and `clientCredentialsPayloadGuard` in this file, they are used to make the user-defined token * sample to be aligned with the real token payload given by the OIDC provider in a real use case. * * Only keep the least necessary fields in the guards to align with the raw token payload that can be used for `extraTokenClaims` method. */ import { z } from 'zod'; export declare const accessTokenPayloadGuard: z.ZodObject<{ accountId: z.ZodString; expiresWithSession: z.ZodOptional; grantId: z.ZodString; gty: z.ZodString; sessionUid: z.ZodOptional; sid: z.ZodOptional; kind: z.ZodLiteral<"AccessToken">; jti: z.ZodString; aud: z.ZodUnion<[z.ZodString, z.ZodArray]>; scope: z.ZodOptional; clientId: z.ZodOptional; }, "strict", z.ZodTypeAny, { grantId: string; jti: string; kind: "AccessToken"; accountId: string; gty: string; aud: string | string[]; sid?: string | undefined; scope?: string | undefined; sessionUid?: string | undefined; clientId?: string | undefined; expiresWithSession?: boolean | undefined; }, { grantId: string; jti: string; kind: "AccessToken"; accountId: string; gty: string; aud: string | string[]; sid?: string | undefined; scope?: string | undefined; sessionUid?: string | undefined; clientId?: string | undefined; expiresWithSession?: boolean | undefined; }>; export type AccessTokenPayload = z.infer; export declare const clientCredentialsPayloadGuard: z.ZodObject<{ kind: z.ZodLiteral<"ClientCredentials">; jti: z.ZodString; aud: z.ZodUnion<[z.ZodString, z.ZodArray]>; scope: z.ZodOptional; clientId: z.ZodOptional; }, "strict", z.ZodTypeAny, { jti: string; kind: "ClientCredentials"; aud: string | string[]; scope?: string | undefined; clientId?: string | undefined; }, { jti: string; kind: "ClientCredentials"; aud: string | string[]; scope?: string | undefined; clientId?: string | undefined; }>; export type ClientCredentialsPayload = z.infer;