File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
src/main/java/com/oronaminc/join/member/security Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 2020import com .oronaminc .join .member .dto .GuestLoginRequest ;
2121import com .oronaminc .join .member .dto .GuestLoginResponse ;
2222import com .oronaminc .join .member .dto .KakaoLoginRequest ;
23+ import com .oronaminc .join .member .dto .KakaoLoginResponse ;
2324import com .oronaminc .join .member .dto .SessionInfoResponse ;
2425
2526import io .swagger .v3 .oas .annotations .Operation ;
3940public class AuthController {
4041 private final AuthService authService ;
4142
43+ @ Operation (
44+ summary = "카카오 로그인" ,
45+ description = "redirect url 에 포함된 파라미터의 code와 state를 입력해주세요. 이후 모든 요청에 세션 인증이 적용됩니다."
46+ )
4247 @ PostMapping ("/kakao" )
4348 @ ResponseStatus (HttpStatus .OK )
44- public Long kakaoLogin (
49+ public KakaoLoginResponse kakaoLogin (
4550 @ RequestBody KakaoLoginRequest kakaoLoginRequest ,
4651 HttpServletRequest request
4752 ) {
@@ -59,7 +64,7 @@ public Long kakaoLogin(
5964
6065 request .getSession (true ).setAttribute (HttpSessionSecurityContextRepository .SPRING_SECURITY_CONTEXT_KEY , context );
6166
62- return memberDetails .getId ();
67+ return new KakaoLoginResponse ( memberDetails .getId () );
6368 }
6469
6570 @ Operation (
You can’t perform that action at this time.
0 commit comments