val UnsupportedMediaType = HttpStatusCode(415, "Unsupported Media Type")
val RequestedRangeNotSatisfiable = HttpStatusCode(416, "Requested Range Not Satisfiable")
val ExceptionFailed = HttpStatusCode(417, "Exception Failed")
val UpgradeRequired = HttpStatusCode(426, "Upgrade Required")
val TooManyRequests = HttpStatusCode(429, "Too Many Requests")
val RequestHeaderFieldTooLarge = HttpStatusCode(431, "Request Header Fields Too Large")
I was wanting to use "422 Unprocessable Entity", but there isn't a constant for it in
io.ktor.http.HttpStatusCode
yet. Is it a case of "PRs welcome", or is there a deliberate reason not to include certain codes?
c
cy
08/02/2018, 9:04 AM
Well, 422 status code is introduced as part of webdav
cy
08/02/2018, 9:05 AM
so it't not a regular HTTP status code
cy
08/02/2018, 9:05 AM
I'd say we have to include all webdav status codes or none
cy
08/02/2018, 9:06 AM
On the other hand PRs are always welcome 🙂
m
Matt
08/02/2018, 9:20 AM
😁
Matt
08/02/2018, 9:23 AM
Yeah, I've seen 422 used a few times in REST-y APIs that had nothing to do with WebDAV simply because it happens to have a useful semantics