import { ApiProperty } from '@nestjs/swagger'; import { IsNotEmpty } from 'class-validator'; import { Match } from '../../validators/match-validator'; export default class StoreUserRequestDTO { id?: string; @ApiProperty({ type: String, description: 'First name', default: '', example: 'John', required: false, }) @IsNotEmpty() firstName: string; @ApiProperty({ type: String, description: 'Last name', default: '', example: 'Doe', required: false, }) @IsNotEmpty() lastName: string; @ApiProperty({ type: String, description: 'Profile Picture', default: '', example: 'https://fakeImgUrl.com', required: false, }) profilePicture?: string | null; @ApiProperty({ type: String, description: 'email', default: '', example: 'johndoe@fakemail.com', required: false, }) @IsNotEmpty() email: string; @IsNotEmpty() password: string; @Match('password') @IsNotEmpty() passwordConfirmation: string; }