Uecko_ERP/apps/server/archive/contexts/auth/presentation/dto/auth.validation.dto.ts

17 lines
577 B
TypeScript
Raw Normal View History

2025-06-24 18:38:57 +00:00
import * as z from "zod/v4";
2025-02-01 21:48:13 +00:00
export const RegisterUserSchema = z.object({
username: z.string().min(3, "Username must be at least 3 characters long"),
email: z.string().email("Invalid email format"),
2025-02-03 13:12:36 +00:00
password: z.string().min(6, "Password must be at least 6 characters long"),
2025-02-01 21:48:13 +00:00
});
export const LoginUserSchema = z.object({
email: z.string().email("Invalid email format"),
2025-02-03 13:12:36 +00:00
password: z.string().min(6, "Password must be at least 6 characters long"),
2025-02-01 21:48:13 +00:00
});
2025-02-07 17:46:41 +00:00
export const RefreshTokenSchema = z.object({
refresh_token: z.string().min(1, "Refresh token is required"),
2025-02-01 21:48:13 +00:00
});