feat: 카카오 계정의 본인 복구와 인증 후 연결 교체를 추가한다

This commit is contained in:
Hide_D committed 2026-11-07 21:31:16 +09:00
1 parent d1cdf8a85f
commit c81d304073
22 files changed
+1338 -199

No files matched your search

+21 -1
View File
@@ -1,3 +1,4 @@
import type { KakaoLinkAuthorization, KakaoLinkSnapshot } from './kakaoLinkPolicy.js';
export interface UserRecord {
id: string;
username: string;
@@ -155,7 +156,21 @@ export interface CreateUserInput {
};
}
export interface CompleteKakaoLinkInput {
firstUserId?: string;
expected: KakaoLinkSnapshot;
authorization: KakaoLinkAuthorization;
oauthId: string;
email: string;
oauthInfo: UserOAuthInfo;
verifiedAt: Date;
talkVerifiedUntil: Date;
password?: string;
}
export interface UserRepository {
findDetachedKakaoOwner(oauthId: string): Promise<string | null>;
completeKakaoIdentityLink(userId: string, input: CompleteKakaoLinkInput): Promise<UserRecord>;
findById(id: string): Promise<UserRecord | null>;
findByIds(ids: string[]): Promise<UserRecord[]>;
findByUsername(username: string): Promise<UserRecord | null>;
@@ -168,7 +183,12 @@ export interface UserRepository {
updatePassword(userId: string, password: string): Promise<void>;
updateOAuthInfo(userId: string, oauthInfo: UserOAuthInfo): Promise<void>;
syncKakaoIdentity(userId: string, email: string, oauthInfo: UserOAuthInfo): Promise<UserRecord>;
markKakaoTalkVerified(userId: string, validUntil: Date): Promise<UserRecord>;
markKakaoTalkVerified(
userId: string,
validUntil: Date,
authRevision?: number,
oauthId?: string
): Promise<UserRecord>;
linkKakao(
userId: string,
input: {