http_status v0.1.0
HTTPStatus
Working with status codes for HTTP responses.
Defined status-lines are from https://tools.ietf.org/html/rfc7231#section-6.1
Summary
List of all statuses as tuples of {code, reason}
Expand a status code into the correct status line
Functions
List of all statuses as tuples of {code, reason}
Examples
iex> HTTPStatus.every_status |> List.first
{100, "Continue"}
Expand a status code into the correct status line
Variable naming from https://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html
Examples
iex> HTTPStatus.status_line(200)
"HTTP/1.1 200 OK\r\n"