haskell-servant / haskell-servant/servant

Idea Symbolic Names for HTTP Status codes

Open
#628 9 comments 1 reaction 0 assignees View on GitHub
enhancement help wanted servant-api
Dominant language
Haskell
Stars
2k
Forks
427
Avg merge
2d 23h
Merged PRs (30d)
5

Description

I had a thought, currently to express a http status code you have to remember the number, would it be possible to have a named type for them. So instead of having the number 304 in my code I could ahve the value 'NotModified' which esp for some of the more unusual status codes would be very helpful in making code more readable.

For example if I see that something should return 415 I probably will have to look up what that means but if I see `UnsupportedMediaType` it is self documenting.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.