POST /api/sign-up
request
{
"userId": "hi",
"name": "이지수",
"email": "s22@",
"grade": 3,
"password": "123"
}
response
로그인 성공 - 200 OK {"message": "로그인 되었습니다."}
로그인 실패 - 500 fail(이메일 같거나 유저 아이디 같으면 500 Error) {"message": "로그인 되지 않았습니다."}
post /api/login
requset
{
"userId" : "뽀뽕",
"password": "sucode"
}
response
로그인 성공 - 200 OK “ 로그인이 되었습니다”
로그인 실패 - 401 Unauthorized “로그인 되지 않았습니다”
GET /api/user-check?userId=userId
*인코딩 에러 있음 —> @PathVariable을 @RequestParam로 변경하였더니 해결
response
아이디 중복 - 409 Conflict