diff --git a/src/auth/auth.controller.ts b/src/auth/auth.controller.ts index b39d810..063b82d 100644 --- a/src/auth/auth.controller.ts +++ b/src/auth/auth.controller.ts @@ -1,6 +1,7 @@ import { Body, Controller, HttpCode, HttpStatus, Post } from "@nestjs/common"; -import { SignUpDto } from "src/auth/auth.dto"; +import { SignInDto, SignUpDto } from "src/auth/auth.dto"; import { AuthService } from "src/auth/auth.service"; +import * as console from "node:console"; @Controller("auth") export class AuthController { @@ -15,6 +16,12 @@ export class AuthController { } //POST signin + @HttpCode(HttpStatus.OK) + @Post("signin") + async signIn(@Body() dto: SignInDto) { + console.log(dto); + return this.authService.doLogin(dto); + } //GET me -- Get current user data via jwt //DELETE me //PATCH me