Skip to content

Commit

Permalink
fix(auth-api): 리프레쉬 API 오류 응답 타입으로 정의한다 (#305)
Browse files Browse the repository at this point in the history
  • Loading branch information
leegwae committed Aug 11, 2023
1 parent 0afe4b7 commit d5574c0
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/lib/api/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,17 @@ export interface RefreshResult {
accessToken: string;
}
export type RefreshResponse = SuccessResponse<RefreshResult>;
export type RefreshError =
| NotExistMemberLoginError
| InvalidRefreshTokenRefreshError;
export type NotExistMemberRefreshError = ErrorResponse & {
code: 'NOT_EXIST_MEMBER';
statusCode: 404;
};
export type InvalidRefreshTokenRefreshError = ErrorResponse & {
code: 'INVALID_REFRESH_TOKEN';
statusCode: 401;
};

/* ================================ [사용자 엔티티] ====================================== */

Expand Down

0 comments on commit d5574c0

Please sign in to comment.