Skip to content

API User Me Update

IENFI edited this page Feb 4, 2026 · 1 revision

PATCH /v1/me

로그인된 사용자 본인의 프로필 정보(닉네임, 프로필 이미지) 를 수정한다.


Request

Endpoint

PATCH /v1/me

인증

  • Access Token: ⭕️ 필요
    • Authorization: Bearer <accessToken>

Request Body

{
	"nickname":"string",
	"profileImageId":"string"
}
필드 타입 필수 설명
nickname string ⭕️ 사용자 닉네임
profileImageId string ⭕️ 프로필 이미지 ID

Response

성공 응답 (200)

{
  success: true,
  data: {
    userId: string,
    user: {
      id: string,
      email: string,
      nickname: string,
      provider: 'google' | 'kakao'
      providerId: string,
      profileImageId: string | null,
      profileImage: undefined | { url: string },
      settings: Record<string, any>,
      createdAt: string,
    },
    stat: {
      recentTags: ["맛집", "여행"],
      frequentTags: ["산책", "코딩"],
      recentEmotions: ["기쁨", "설렘"],
      frequentEmotions: ["평온"]
    }
  },
  error: null
}

profileImage는 profileImageId가 유효한 경우에만 반환되며,

이미지 정보가 없는 경우 undefined일 수 있다.


Error

아래 경우를 제외하면 대부분 400, 500 (Internal Server) 에러를 반환한다.

오류 상황 Status Code Message
Access Token / userId 인가 오류 401 UNAUTHORIZED Access token is required.
인증 실패 401 UNAUTHORIZED Unauthorized (UserGuard 기본 메시지)
닉네임 길이 오류 400 BAD_REQUEST 닉네임은 최소 2자 이상, 최대 50자까지 가능합니다.
닉네임 형식 오류 400 BAD_REQUEST 닉네임은 한글, 영어, 숫자만 입력 가능합니다.

Notes

  • 본 API는 /me 기반(Self-service) API로, 본인 정보만 수정 가능하다.
  • 닉네임 유효성 검사는 서버에서 수행된다.
  • 프로필 이미지 변경은 profileImageId 기준으로 처리된다.

Clone this wiki locally