HTTP Status Code

#http

Written by Paul
μ›Ή λΈŒλΌμš°μ €κ°€ μ„œλ²„μ— http μš”μ²­μ„ ν•  경우, 성곡 ν˜Ήμ€ μ‹€νŒ¨ μ—¬λΆ€ 및 λ‹€μŒ ν–‰λ™μœΌλ‘œ 무엇을 ν•΄μ•Ό ν•˜λŠ”μ§€ μ•Œλ €μ£ΌλŠ” μƒνƒœ μ½”λ“œμ΄λ‹€.
그룹은 5개 그룹으둜 λ‚˜λˆ„μ–΄ 진닀.

100λ²ˆλŒ€ (Information): 정보 응닡

  • 100 (continue): μ„œλ²„κ°€ request headerλŠ” λ°›μ•˜κ³ , ν΄λΌμ΄μ–ΈνŠΈκ°€ request bodyλ₯Ό 보내고 μžˆλŠ” μƒνƒœ
  • 101 (switching protocols): μš”μ²­μžκ°€ μ„œλ²„μ—κ²Œ switching protocol 을 λ¬»λŠ” μƒνƒœ
  • 102 (processing): μš”μ²­μžκ°€ μ„œλ²„μ—κ²Œ μš”μ²­ ν•˜μ˜€κ³ , μ„œλ²„κ°€ 이λ₯Ό μ²˜λ¦¬ν•˜μ˜€μ§€λ§Œ 응닡이 μ—†λŠ” μƒνƒœ
  • 103 (checkpoint): μ€‘λ‹¨λœ Putκ³Ό Post μš”μ²­μ„ λ˜μ°Ύμ„ 수 μžˆλŠ” requestλ₯Ό μ‚¬μš©ν•˜λŠ” μƒνƒœ

200λ²ˆλŒ€ (Successful): 성곡 응닡

  • 200 (ok): μ—λŸ¬μ—†μ΄ 성곡이 μ™„λ£Œλœ μƒνƒœ
  • 201 (created): requestκ°€ λ˜μ—ˆκ³ , μš”μ²­μ„ λ°”νƒ•μœΌλ‘œ μƒˆλ‘œμš΄ μžμ›μ΄ λ§Œλ“€μ–΄μ§„ μƒνƒœ
  • 202 (accepted): μ„œλ²„κ°€ requestλ₯Ό 전솑 λ°›μ•˜μœΌλ‚˜, ν˜„μž¬ μ™„μ „ν•˜κ²Œ μ²˜λ¦¬λ˜μ§€ μ•Šμ€ μƒνƒœ
  • 203 (non-authoritative information): μ„œλ²„κ°€ ν΄λΌμ΄μ–ΈνŠΈ μš”κ΅¬ 쀑 μΌλΆ€λ§Œ μ „λ‹¬ν•œ μƒνƒœ
  • 204 (no content): request μš”μ²­μ„ 처리 ν›„ ν΄λΌμ΄μ–ΈνŠΈμ—κ²Œ 전달 ν•  컨텐츠가 μ—†λŠ” μƒνƒœ. 주둜 μ‚­μ œ μš”μ²­ ν›„ status code둜 쓰인닀.
  • 205 (reset content): no content μƒνƒœλΌμ„œ ν΄λΌμ΄μ–ΈνŠΈμ˜ λ·°κ°€ reset이 ν•„μš”ν•œ μƒνƒœ
  • 206 (partial content): ν΄λΌμ΄μ–ΈνŠΈμ˜ header λ²”μœ„ 문제둜 μ„œλ²„κ°€ μžμ›μ˜ μΌλΆ€λ§Œμ„ 전달받은 μƒνƒœ
  • 207 (multi-status): λ©€ν‹°-μƒνƒœ 응닡은 λ‹€μˆ˜μ˜ λ¦¬μ†ŒμŠ€κ°€ μ—¬λŸ¬ 개의 μƒνƒœ μ½”λ“œμΈ 상황이 μ μ ˆν•œ κ²½μš°μ— ν•΄λ‹Ήλ˜λŠ” 정보λ₯Ό μ„œλΉ„μŠ€μ— μ „λ‹¬ν•œ μƒνƒœ (사싀 무슨 말인지 잘 λͺ¨λ₯΄κ² λ‹€)
  • 208 (multi-status): λ©€ν‹°-μƒνƒœ 읍응닡 DAVμ—μ„œ μ‚¬μš©, propstat(property와 status의 ν•©μ„±μ–΄) 응닡 μ†μ„±μœΌλ‘œ 동일 μ»¬λ ‰μ…˜μœΌλ‘œ λ°”μΈλ“œλœ 볡수의 λ‚΄λΆ€ 멀버λ₯Ό 반볡적으둜 μ—΄κ±°ν•˜λŠ” 것을 ν”Όν•˜κΈ° μœ„ν•΄ μ‚¬μš©ν•˜λŠ” μƒνƒœ (사싀 무슨 말인지 잘 λͺ¨λ₯΄κ² λ‹€)
  • 226 (IM Used): μ„œλ²„κ°€ GET μš”μ²­μ— λŒ€ν•œ λ¦¬μ†ŒμŠ€λ₯Ό μ²˜λ¦¬ν–ˆμœΌλ©°, 응닡이 ν•˜λ‚˜ λ˜λŠ” κ·Έ μ΄μƒμ˜ μΈμŠ€ν„΄μŠ€ μ‘°μž‘μ΄ ν˜„μž¬ μΈμŠ€ν„΄μŠ€μ— 적용이 λ˜μ—ˆμŒμ„ μ•Œλ¦¬λŠ” μƒνƒœ

300λ²ˆλŒ€ (Redirection): λ¦¬λ‹€μ΄λ ‰μ…˜ 응닡

  • 300 (Multiple Choices): μ΅œλŒ€ λ‹€μ„―κ°œμ˜ 링크λ₯Ό κ³¨λΌμ„œ 이동할 수 μžˆλŠ” μƒνƒœ
  • 301 (permanently moved): μš”μ²­λœ νŽ˜μ΄μ§€κ°€ μƒˆλ‘œμš΄ URL둜 이동 된 μƒνƒœ
  • 302 (found): μš”μ²­λœ νŽ˜μ΄μ§€κ°€ μΌμ‹œμ μœΌλ‘œ μƒˆ URL둜 이동 된 μƒνƒœ
  • 303 (see other): μš”μ²­λœ νŽ˜μ΄μ§€λŠ” λ‹€λ₯Έ URLμ—μ„œ 찾을 수 μžˆλŠ” μƒνƒœ
  • 304 (not modified): λ§ˆμ§€λ§‰ μš”μ²­ 이후 μˆ˜μ •λ˜μ§€ μ•Šμ€ μƒνƒœ
  • 305 (use proxy): location ν•„λ“œμ— proxy의 URL을 μ‚¬μš©ν•˜λŠ” μƒνƒœ
  • 306 (switch proxy): μ‚¬μš©ν•˜μ§€ μ•ŠλŠ” μ½”λ“œ
  • 307: Temporary Redirect 302 Found HTTP 응닡 μ½”λ“œμ™€ λ™μΌν•œ 의미λ₯Ό 가지고 있으며, μ‚¬μš©μž μ—μ΄μ „νŠΈκ°€ λ°˜λ“œμ‹œ μ‚¬μš©λœ HTTP λ©”μ†Œλ“œλ₯Ό λ³€κ²½ν•˜μ§€ 말아야 ν•˜λŠ” 점만 λ‹€λ₯Έ μƒνƒœ
  • 308: Permanent Redirect 301 Moved Permanently HTTP 응닡 μ½”λ“œμ™€ λ™μΌν•œ 의미λ₯Ό 가지고 있으며, μ‚¬μš©μž μ—μ΄μ „νŠΈκ°€ λ°˜λ“œμ‹œ HTTP λ©”μ†Œλ“œλ₯Ό λ³€κ²½ν•˜μ§€ 말아야 ν•˜λŠ” 점만 λ‹€λ₯Έ μƒνƒœ

400λ²ˆλŒ€ (Client Error): ν΄λΌμ΄μ–ΈνŠΈ μ—λŸ¬ 응닡

  • 400 (Bad Request): μš”μ²­μ— λŒ€ν•œ 문법적 였λ₯˜κ°€ μžˆμ–΄μ„œ μ„œλ²„κ°€ 이해할 수 μ—†λŠ” μƒνƒœ. 주둜 전달 받은 μš”μ²­μ˜ μžμ›μ˜ λΆˆμΆ©λΆ„ν•¨μ„ λ‚˜νƒ€λ‚Ό λ•Œ μ“΄λ‹€.
  • 401 (Unauthorized): νŠΉμ • μš”μ²­μ΄ 인증이 λ˜μ§€ μ•Šμ•„μ„œ κΆŒν•œμ΄ μ—†λŠ” μƒνƒœ
  • 402 (Payment Required): μ΅œμ‹  status code 인데 아직 쓰지 μ•ŠλŠ” 걸둜 μ•Œκ³  있음. μΆ”ν›„ payment μ„œλΉ„μŠ€μ—μ„œ 결제λ₯Ό μš”ν• λ•Œ μ“°λŠ” κ²ƒμœΌλ‘œ μ•Œκ³  μžˆλ‹€.
  • 403 (Forbidden): μš”μ²­μ΄ 인증은 λ˜μ—ˆμ§€λ§Œ, μš”μ²­ν•œ μžμ›μ— λŒ€ν•΄μ„œλŠ” μ ‘κ·Ό ν•  κΆŒν•œμ΄ μ—†λŠ” μƒνƒœ. 401은 인증이 λ˜μ§€ μ•Šμ•„μ„œ λˆ„κ΅¬μΈμ§€ λͺ¨λ₯΄λŠ” μƒνƒœμ΄μ§€λ§Œ 403λŠ” 인증은 λ˜μ–΄μ„œ μš”μ²­μžκ°€ λˆ„κ΅¬μΈμ§€λŠ” μ•Œκ³  μžˆμœΌλ‚˜ μš”μ²­ν•œ μžμ›μ— λŒ€ν•œ κΆŒν•œμ€ μ—†μŒμ„ μ•Œλ¦¬λŠ” μƒνƒœμ΄λ‹€.
  • 404 (NotFound): μš”μ²­ν•œ μžμ›μ„ 찾을 수 μ—†λŠ” μƒνƒœ
  • 405 (Method Not Allowed): μš”μ²­μ˜ methodκ°€ μ œκ³΅λ˜μ§€ μ•Šμ€ μƒνƒœ
  • 406 (Not Acceptable): requestμ—μ„œ accept header에 not acceptable의 λ‚΄μš©μ„ 가진 μžμ›μ„ μš”μ²­ν•œ μƒνƒœ
  • 407 (Proxy Authentication Required): ν”„λ‘μ‹œ μ„œλ²„μ—κ²Œ ν•΄λ‹Ή μš”μ²­μ΄ μˆ˜ν–‰λ˜λ„λ‘ 인증을 λ°›μ•„μ•Ό ν•˜λŠ” μƒνƒœ
  • 408 (Request Timeout): μš”μ²­ λŒ€κΈ°μ‹œκ°„μ΄ μ§€λ‚œ μƒνƒœ
  • 409 (Conflict): request 좩돌둜 μΈν•΄μ„œ μš”μ²­μ΄ μ™„λ£Œλ˜μ§€ μ•Šμ€ μƒνƒœ, 생성 μš”μ²­μΈλ° 이미 μƒμ„±λ˜μ–΄ μžˆλŠ” μƒνƒœ
  • 410 (Gone): μš”μ²­ νŽ˜μ΄μ§€λŠ” 더 이상 μ‚¬μš©ν•  수 μ—†λŠ” μƒνƒœ
  • 411 (Length Required): Content-Length 뢀뢄이 λΉ μ Έμ„œ μš”μ²­μ„ ν—ˆκ°€ν•˜μ§€ μ•Šμ€ μƒνƒœ
  • 412 (Precondition Failed): request 헀더 ν•„λ“œμ— μ„ κ²° 쑰건에 λŒ€ν•œ 값이 μ„œλ²„μ—μ„œ falseκ°€ λ‚˜μ˜¨ 경우
  • 413 (Request entity too large): μš”μ²­ μ—”ν‹°ν‹°λ₯Ό μ„œλ²„κ°€ μ²˜λ¦¬ν•˜κΈ°μ— λ„ˆλ¬΄ 큰 μƒνƒœ
  • 414 (Request-URI Too Long): μš”μ²­ URIκ°€ λ„ˆλ¬΄ κΈ΄ μƒνƒœ
  • 415 (Unsupported Media Type): μ§€μ›ν•˜μ§€ μ•ŠλŠ” λ―Έλ””μ–΄ νƒ€μž…μ„ μš”μ²­ν•œ μƒνƒœ
  • 416 (Requested Range Not Satisfiable): ν΄λΌμ΄μ–ΈνŠΈκ°€ 파일의 일뢀λ₯Ό μš”μ²­ν–ˆμ„ λ•Œ μ„œλ²„κ°€ μ§€μ›ν•˜μ§€ μ•ŠλŠ” μƒνƒœ
  • 417 (Expectation Failed): Expect request-header ν•„λ“œμ˜ μš”κ΅¬λ₯Ό μ„œλ²„κ°€ μΆ©μ‘±μ‹œν‚¬ 수 μ—†λŠ” μƒνƒœ
  • 418 (im a teapot): HTTP 418 I'm a teapot ν΄λΌμ΄μ–ΈνŠΈ 였λ₯˜ 응닡 μ½”λ“œλŠ” μ„œλ²„κ°€ μ°»μ£Όμ „μžμ΄κΈ° λ•Œλ¬Έμ— 컀피 내리기λ₯Ό κ±°μ ˆν–ˆλ‹€λŠ” 것을 μ˜λ―Έν•©λ‹ˆλ‹€. 이 였λ₯˜λŠ” 1998λ…„ 만우절 λ†λ‹΄μ΄μ—ˆλ˜ ν•˜μ΄νΌ ν…μŠ€νŠΈ 컀피 포트 μ œμ–΄ κ·œμ•½(Hyper Text Coffee Pot Control Protocol)의 λ ˆνΌλŸ°μŠ€μž…λ‹ˆλ‹€.
  • 422 (Unprocessable Entity): μš”μ²­μ€ 잘 전달 λμ§€λ§Œ, 문법 였λ₯˜κ°€ λ‚œ μƒνƒœ
  • 429 (Too Many Requests): μ‚¬μš©μžκ°€ μ§€μ •λœ μ‹œκ°„μ— λ„ˆλ¬΄ λ§Žμ€ μš”μ²­μ„ 보낸 μƒνƒœ

500λ²ˆλŒ€ (Server Error): μ„œλ²„ μ—λŸ¬ 응닡

  • 500 (Internal Server Error): 포괄적인 μ„œλ²„ μ—λŸ¬ λ©”μ‹œμ§€, μ„œλ²„κ°€ μ—λŸ¬κ°€ μ™œ λ‚¬λŠ”μ§€ μ–΄λ–»κ²Œ μ²˜λ¦¬ν•΄μ•Όν•˜λŠ”μ§€ 아직 λͺ¨λ₯΄λŠ” μƒνƒœ. μ„œλ²„ μΈ‘μ—μ„œ νŠΉμ • μ—λŸ¬μ— λŒ€ν•œ 핸듀링이 λ˜μ–΄μžˆμ§€ μ•Šλ‹€.
  • 501 (Not Implemented): μ„œλ²„κ°€ ν•΄λ‹Ή μš”μ²­ λ©”μ†Œλ“œλ₯Ό 인식 λͺ»ν•˜κ±°λ‚˜, 이행할 λŠ₯λ ₯이 μ—†λŠ” μƒνƒœ
  • 502 (Bad Gateway): κ²Œμ΄νŠΈμ›¨μ΄λ‚˜ ν”„λ‘μ‹œμ˜ μƒνƒœκ°€ λ‚˜μ˜κ±°λ‚˜ κ³ΌλΆ€ν•˜μΈ μƒνƒœ
  • 503 (Service Unavailable): μΌμ‹œμ μœΌλ‘œ μ„œλΉ„μŠ€κ°€ μ‚¬μš© λΆˆκ°€λŠ₯ ν•œ μƒνƒœ, (μž„μ‹œ 쑰건에 μ‚¬μš©λ˜μ–΄μ•Ό ν•˜λ©°, Retry-After: HTTP ν—€λ”λŠ” κ°€λŠ₯ν•˜λ©΄ μ„œλΉ„μŠ€λ₯Ό λ³΅κ΅¬ν•˜κΈ° μ „ μ˜ˆμƒ μ‹œκ°„μ„ 포함해야 함)
  • 504 (Gateway Timeout): κ³ΌλΆ€ν•˜ λ“±μ˜ 이유둜 κ²Œμ΄νŠΈμ›¨μ΄λ‚˜ ν”„λ‘μ‹œμ˜ ν•œκ³„ λŒ€κΈ° μ‹œκ°„μ΄ μ§€λ‚œ μƒνƒœ
  • 505 (HTTP Version Not Supported): requestμ—μ„œ μ‚¬μš©ν•œ HTTP ν”„λ‘œν† μ½œμ„ μ„œλ²„κ°€ μ§€μ›ν•˜μ§€ μ•ŠλŠ” μƒνƒœ
  • 511 (Network Authentication Required): ν΄λΌμ΄μ–ΈνŠΈμ˜ 접근을 μœ„ν•œ λ„€νŠΈμ›Œν¬ 인증이 ν•„μš”ν•œ μƒνƒœ
참고자료 http://www.incodom.kr/Status_codehttps://developer.mozilla.org/ko/docs/Web/HTTP/Status/418
← Go home