Skip to content

Variable: authSchema

ts
const authSchema: ZodUnion<readonly [ZodObject<{
  apiToken: ZodString;
  email: ZodString;
  type: ZodLiteral<"basic">;
}, $strip>, ZodUnion<readonly [ZodObject<{
  token: ZodString;
  type: ZodLiteral<"bearer">;
}, $strip>, ZodObject<{
  getToken: ZodCustom<() => Promise<string>, () => Promise<string>>;
  type: ZodLiteral<"bearer">;
}, $strip>]>, ZodObject<{
  accessToken: ZodOptional<ZodString>;
  clientId: ZodOptional<ZodString>;
  clientSecret: ZodOptional<ZodString>;
  cloudId: ZodOptional<ZodString>;
  expiresAt: ZodOptional<ZodNumber>;
  onTokenRefresh: ZodOptional<ZodCustom<OnTokenRefresh, OnTokenRefresh>>;
  refreshToken: ZodOptional<ZodString>;
  siteUrl: ZodOptional<ZodString>;
  type: ZodLiteral<"oauth2">;
}, $strip>]>;

Defined in: src/core/schemas/auth.ts:73