You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

72 lines
3.7KB

  1. package httptest
  2. // HTTP status codes as registered with IANA.
  3. // See: http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
  4. // Raw Copy from the future(tip) net/http std package in order to recude the import path of "net/http" for the users.
  5. const (
  6. StatusContinue = 100 // RFC 7231, 6.2.1
  7. StatusSwitchingProtocols = 101 // RFC 7231, 6.2.2
  8. StatusProcessing = 102 // RFC 2518, 10.1
  9. StatusEarlyHints = 103 // RFC 8297
  10. StatusOK = 200 // RFC 7231, 6.3.1
  11. StatusCreated = 201 // RFC 7231, 6.3.2
  12. StatusAccepted = 202 // RFC 7231, 6.3.3
  13. StatusNonAuthoritativeInfo = 203 // RFC 7231, 6.3.4
  14. StatusNoContent = 204 // RFC 7231, 6.3.5
  15. StatusResetContent = 205 // RFC 7231, 6.3.6
  16. StatusPartialContent = 206 // RFC 7233, 4.1
  17. StatusMultiStatus = 207 // RFC 4918, 11.1
  18. StatusAlreadyReported = 208 // RFC 5842, 7.1
  19. StatusIMUsed = 226 // RFC 3229, 10.4.1
  20. StatusMultipleChoices = 300 // RFC 7231, 6.4.1
  21. StatusMovedPermanently = 301 // RFC 7231, 6.4.2
  22. StatusFound = 302 // RFC 7231, 6.4.3
  23. StatusSeeOther = 303 // RFC 7231, 6.4.4
  24. StatusNotModified = 304 // RFC 7232, 4.1
  25. StatusUseProxy = 305 // RFC 7231, 6.4.5
  26. _ = 306 // RFC 7231, 6.4.6 (Unused)
  27. StatusTemporaryRedirect = 307 // RFC 7231, 6.4.7
  28. StatusPermanentRedirect = 308 // RFC 7538, 3
  29. StatusBadRequest = 400 // RFC 7231, 6.5.1
  30. StatusUnauthorized = 401 // RFC 7235, 3.1
  31. StatusPaymentRequired = 402 // RFC 7231, 6.5.2
  32. StatusForbidden = 403 // RFC 7231, 6.5.3
  33. StatusNotFound = 404 // RFC 7231, 6.5.4
  34. StatusMethodNotAllowed = 405 // RFC 7231, 6.5.5
  35. StatusNotAcceptable = 406 // RFC 7231, 6.5.6
  36. StatusProxyAuthRequired = 407 // RFC 7235, 3.2
  37. StatusRequestTimeout = 408 // RFC 7231, 6.5.7
  38. StatusConflict = 409 // RFC 7231, 6.5.8
  39. StatusGone = 410 // RFC 7231, 6.5.9
  40. StatusLengthRequired = 411 // RFC 7231, 6.5.10
  41. StatusPreconditionFailed = 412 // RFC 7232, 4.2
  42. StatusRequestEntityTooLarge = 413 // RFC 7231, 6.5.11
  43. StatusRequestURITooLong = 414 // RFC 7231, 6.5.12
  44. StatusUnsupportedMediaType = 415 // RFC 7231, 6.5.13
  45. StatusRequestedRangeNotSatisfiable = 416 // RFC 7233, 4.4
  46. StatusExpectationFailed = 417 // RFC 7231, 6.5.14
  47. StatusTeapot = 418 // RFC 7168, 2.3.3
  48. StatusUnprocessableEntity = 422 // RFC 4918, 11.2
  49. StatusLocked = 423 // RFC 4918, 11.3
  50. StatusFailedDependency = 424 // RFC 4918, 11.4
  51. StatusUpgradeRequired = 426 // RFC 7231, 6.5.15
  52. StatusPreconditionRequired = 428 // RFC 6585, 3
  53. StatusTooManyRequests = 429 // RFC 6585, 4
  54. StatusRequestHeaderFieldsTooLarge = 431 // RFC 6585, 5
  55. StatusUnavailableForLegalReasons = 451 // RFC 7725, 3
  56. StatusInternalServerError = 500 // RFC 7231, 6.6.1
  57. StatusNotImplemented = 501 // RFC 7231, 6.6.2
  58. StatusBadGateway = 502 // RFC 7231, 6.6.3
  59. StatusServiceUnavailable = 503 // RFC 7231, 6.6.4
  60. StatusGatewayTimeout = 504 // RFC 7231, 6.6.5
  61. StatusHTTPVersionNotSupported = 505 // RFC 7231, 6.6.6
  62. StatusVariantAlsoNegotiates = 506 // RFC 2295, 8.1
  63. StatusInsufficientStorage = 507 // RFC 4918, 11.5
  64. StatusLoopDetected = 508 // RFC 5842, 7.2
  65. StatusNotExtended = 510 // RFC 2774, 7
  66. StatusNetworkAuthenticationRequired = 511 // RFC 6585, 6
  67. )