Files
calendar/packages/trpc/server/routers/viewer/organizations/updateUser.schema.ts
T
08e1b0a9c8 feat: attributes (#15964)
Co-authored-by: Joe Au-Yeung <j.auyeung419@gmail.com>
Co-authored-by: Omar López <zomars@me.com>
2024-08-15 14:49:05 -07:00

18 lines
561 B
TypeScript

import { z } from "zod";
import { assignUserToAttributeSchema } from "../attributes/assignUserToAttribute.schema";
export const ZUpdateUserInputSchema = z.object({
userId: z.number(),
username: z.string().optional(),
bio: z.string().optional(),
name: z.string().optional(),
email: z.string().optional(),
avatar: z.string().optional(),
role: z.enum(["ADMIN", "MEMBER", "OWNER"]),
timeZone: z.string(),
attributeOptions: assignUserToAttributeSchema.optional(),
});
export type TUpdateUserInputSchema = z.infer<typeof ZUpdateUserInputSchema>;