-
Notifications
You must be signed in to change notification settings - Fork 1
feat: 카카오 회원탈퇴 기능 구현 완료 #78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 10 commits
883b49b
103aefc
2e773c7
7c0eae6
09d3f9c
145332d
7190e16
e62fd9b
5c3c589
7d1df73
31e1f40
c30c41e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,17 +1,27 @@ | ||
| package org.yapp.apis.auth.strategy.withdraw | ||
|
|
||
| import jakarta.validation.Valid | ||
| import mu.KotlinLogging | ||
| import org.springframework.stereotype.Component | ||
| import org.springframework.validation.annotation.Validated | ||
| import org.yapp.apis.auth.dto.request.WithdrawStrategyRequest | ||
| import org.yapp.apis.auth.manager.KakaoApiManager | ||
| import org.yapp.domain.user.ProviderType | ||
|
|
||
| @Component | ||
| @Validated | ||
| class KakaoWithdrawStrategy( | ||
| private val kakaoApiManager: KakaoApiManager | ||
| ) : WithdrawStrategy { | ||
| private val log = KotlinLogging.logger {} | ||
|
|
||
| override fun getProviderType() = ProviderType.KAKAO | ||
|
|
||
| override fun withdraw(request: WithdrawStrategyRequest) { | ||
| // kakaoApiManager.unlink(request.providerId) | ||
| override fun withdraw(@Valid request: WithdrawStrategyRequest) { | ||
| log.info("Starting Kakao withdrawal for user: ${request.userId}, providerId: ${request.providerId}") | ||
|
|
||
| val unlinkResponse = kakaoApiManager.unlink(request.providerId) | ||
|
|
||
| log.info("Successfully unlinked Kakao user. Response ID: ${unlinkResponse.id}") | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,8 @@ | ||||||||||||||||||||||||
| package org.yapp.apis.config | ||||||||||||||||||||||||
|
|
||||||||||||||||||||||||
| import org.springframework.boot.context.properties.ConfigurationProperties | ||||||||||||||||||||||||
|
|
||||||||||||||||||||||||
| @ConfigurationProperties(prefix = "oauth.kakao") | ||||||||||||||||||||||||
| data class KakaoOauthProperties( | ||||||||||||||||||||||||
| val adminKey: String | ||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||
|
Comment on lines
+5
to
+8
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) 관리자 키에 대한 검증 추가를 고려해보세요. 설정 프로퍼티가 올바르게 구현되었지만, 다음과 같이 검증 어노테이션을 추가할 수 있습니다: +import jakarta.validation.constraints.NotBlank
+
@ConfigurationProperties(prefix = "oauth.kakao")
data class KakaoOauthProperties(
+ @field:NotBlank(message = "Kakao admin key must not be blank")
val adminKey: String
)📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| package org.yapp.infra.external.oauth.kakao.response | ||
|
|
||
| import com.fasterxml.jackson.annotation.JsonProperty | ||
|
|
||
| data class KakaoUnlinkResponse private constructor( | ||
| @JsonProperty("id") | ||
| val id: String | ||
| ) |
Uh oh!
There was an error while loading. Please reload this page.