Files

39 lines
955 B
TypeScript

import { z } from "zod";
import { BaseSchema } from "@server/routes/api/schema";
export const AuthenticationProvidersInfoSchema = BaseSchema.extend({
body: z.object({
/** Authentication Provider Id */
id: z.uuid(),
}),
});
export type AuthenticationProvidersInfoReq = z.infer<
typeof AuthenticationProvidersInfoSchema
>;
export const AuthenticationProvidersUpdateSchema = BaseSchema.extend({
body: z.object({
/** Authentication Provider Id */
id: z.uuid(),
/** Whether the Authentication Provider is enabled or not */
isEnabled: z.boolean(),
}),
});
export type AuthenticationProvidersUpdateReq = z.infer<
typeof AuthenticationProvidersUpdateSchema
>;
export const AuthenticationProvidersDeleteSchema = BaseSchema.extend({
body: z.object({
/** Authentication Provider Id */
id: z.uuid(),
}),
});
export type AuthenticationProvidersDeleteReq = z.infer<
typeof AuthenticationProvidersDeleteSchema
>;