2FA 로그인 오류 응답

2FA 로그인 오류 응답 (PostUsers2FALoginErrorResponse)

Docker Hub에 2단계 인증(2FA) 로그인을 시도했을 때 실패한 경우 돌려주는 응답 스키마예요. detail 필드에 오류 내용을 담아서, 왜 로그인이 안 됐는지 클라이언트에 알려줍니다.

출처: 문서

본문

응답 본문은 detail 필드 하나를 가진 객체예요. 값은 오류를 설명하는 문자열이고, 예를 들어 인증 정보가 틀렸다면 이런 형태가 옵니다.

{
  "description": "failed second factor login response.",
  "examples": [
    {
      "detail": "Incorrect authentication credentials"
    }
  ],
  "properties": {
    "detail": {
      "description": "Description of the error.",
      "example": "Incorrect authentication credentials",
      "type": "string"
    }
  },
  "type": "object"
}
  • detail은 오류 설명 문자열이에요.
  • 예시처럼 인증 자격 정보가 잘못됐을 때 Incorrect authentication credentials 같은 메시지가 돌아옵니다.

더 알아보기