main.go 3.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. package statuses
  2. import (
  3. "net/http"
  4. )
  5. type Code int
  6. const (
  7. Continue Code = http.StatusContinue
  8. SwitchingProtocols = http.StatusSwitchingProtocols // RFC 9110, 15.2.2
  9. Processing = http.StatusProcessing // RFC 2518, 10.1
  10. EarlyHints = http.StatusEarlyHints // RFC 8297
  11. OK = http.StatusOK // RFC 9110, 15.3.1
  12. Created = http.StatusCreated // RFC 9110, 15.3.2
  13. Accepted = http.StatusAccepted // RFC 9110, 15.3.3
  14. NonAuthoritativeInfo = http.StatusNonAuthoritativeInfo // RFC 9110, 15.3.4
  15. NoContent = http.StatusNoContent // RFC 9110, 15.3.5
  16. ResetContent = http.StatusResetContent // RFC 9110, 15.3.6
  17. PartialContent = http.StatusPartialContent // RFC 9110, 15.3.7
  18. MultiStatus = http.StatusMultiStatus // RFC 4918, 11.1
  19. AlreadyReported = http.StatusAlreadyReported // RFC 5842, 7.1
  20. IMUsed = http.StatusIMUsed // RFC 3229, 10.4.1
  21. MultipleChoices = http.StatusMultipleChoices // RFC 9110, 15.4.1
  22. MovedPermanently = http.StatusMovedPermanently // RFC 9110, 15.4.2
  23. Found = http.StatusFound // RFC 9110, 15.4.3
  24. SeeOther = http.StatusSeeOther // RFC 9110, 15.4.4
  25. NotModified = http.StatusNotModified // RFC 9110, 15.4.5
  26. UseProxy = http.StatusUseProxy // RFC 9110, 15.4.6
  27. TemporaryRedirect = http.StatusTemporaryRedirect // RFC 9110, 15.4.8
  28. PermanentRedirect = http.StatusPermanentRedirect // RFC 9110, 15.4.9
  29. BadRequest = http.StatusBadRequest // RFC 9110, 15.5.1
  30. Unauthorized = http.StatusUnauthorized // RFC 9110, 15.5.2
  31. PaymentRequired = http.StatusPaymentRequired // RFC 9110, 15.5.3
  32. Forbidden = http.StatusForbidden // RFC 9110, 15.5.4
  33. NotFound = http.StatusNotFound // RFC 9110, 15.5.5
  34. MethodNotAllowed = http.StatusMethodNotAllowed // RFC 9110, 15.5.6
  35. NotAcceptable = http.StatusNotAcceptable // RFC 9110, 15.5.7
  36. ProxyAuthRequired = http.StatusProxyAuthRequired // RFC 9110, 15.5.8
  37. RequestTimeout = http.StatusRequestTimeout // RFC 9110, 15.5.9
  38. Conflict = http.StatusConflict // RFC 9110, 15.5.10
  39. Gone = http.StatusGone // RFC 9110, 15.5.11
  40. LengthRequired = http.StatusLengthRequired // RFC 9110, 15.5.12
  41. PreconditionFailed = http.StatusPreconditionFailed // RFC 9110, 15.5.13
  42. RequestEntityTooLarge = http.StatusRequestEntityTooLarge // RFC 9110, 15.5.14
  43. RequestURITooLong = http.StatusRequestURITooLong // RFC 9110, 15.5.15
  44. UnsupportedMediaType = http.StatusUnsupportedMediaType // RFC 9110, 15.5.16
  45. RequestedRangeNotSatisfiable = http.StatusRequestedRangeNotSatisfiable // RFC 9110, 15.5.17
  46. ExpectationFailed = http.StatusExpectationFailed // RFC 9110, 15.5.18
  47. Teapot = http.StatusTeapot // RFC 9110, 15.5.19 (Unused)
  48. MisdirectedRequest = http.StatusMisdirectedRequest // RFC 9110, 15.5.20
  49. UnprocessableEntity = http.StatusUnprocessableEntity // RFC 9110, 15.5.21
  50. Locked = http.StatusLocked // RFC 4918, 11.3
  51. FailedDependency = http.StatusFailedDependency // RFC 4918, 11.4
  52. TooEarly = http.StatusTooEarly // RFC 8470, 5.2.
  53. UpgradeRequired = http.StatusUpgradeRequired // RFC 9110, 15.5.22
  54. PreconditionRequired = http.StatusPreconditionRequired // RFC 6585, 3
  55. TooManyRequests = http.StatusTooManyRequests // RFC 6585, 4
  56. RequestHeaderFieldsTooLarge = http.StatusRequestHeaderFieldsTooLarge // RFC 6585, 5
  57. UnavailableForLegalReasons = http.StatusUnavailableForLegalReasons // RFC 7725, 3
  58. InternalServerError = http.StatusInternalServerError // RFC 9110, 15.6.1
  59. NotImplemented = http.StatusNotImplemented // RFC 9110, 15.6.2
  60. BadGateway = http.StatusBadGateway // RFC 9110, 15.6.3
  61. ServiceUnavailable = http.StatusServiceUnavailable // RFC 9110, 15.6.4
  62. GatewayTimeout = http.StatusGatewayTimeout // RFC 9110, 15.6.5
  63. HTTPVersionNotSupported = http.StatusHTTPVersionNotSupported // RFC 9110, 15.6.6
  64. VariantAlsoNegotiates = http.StatusVariantAlsoNegotiates // RFC 2295, 8.1
  65. InsufficientStorage = http.StatusInsufficientStorage // RFC 4918, 11.5
  66. LoopDetected = http.StatusLoopDetected // RFC 5842, 7.2
  67. NotExtended = http.StatusNotExtended // RFC 2774, 7
  68. NetworkAuthenticationRequired = http.StatusNetworkAuthenticationRequired // RFC 6585, 6
  69. )