feat: auth dtos

This commit is contained in:
Louis Auzuret
2022-06-20 15:47:35 +02:00
parent ff7782b95c
commit 28c8e39415
2 changed files with 28 additions and 0 deletions
+12
View File
@@ -0,0 +1,12 @@
import { IsNotEmpty } from "class-validator";
import { ApiProperty } from '@nestjs/swagger';
export class LoginDto {
@ApiProperty()
@IsNotEmpty()
password: string;
@ApiProperty()
@IsNotEmpty()
username: string;
}
+16
View File
@@ -0,0 +1,16 @@
import { IsNotEmpty } from "class-validator";
import { ApiProperty } from '@nestjs/swagger';
export class RegisterDto {
@ApiProperty()
@IsNotEmpty()
password: string;
@IsNotEmpty()
@ApiProperty()
username: string;
@IsNotEmpty()
@ApiProperty()
email: string;
}