Crates.io | rhttp_status_code |
lib.rs | rhttp_status_code |
version | 1.0.0 |
source | src |
created_at | 2023-10-12 08:24:02.203455 |
updated_at | 2023-10-12 08:24:02.203455 |
description | RFC9110 HTTP Status Code |
homepage | |
repository | https://github.com/caojen/http_status_code |
max_upload_size | |
id | 1001050 |
size | 20,143 |
This library provides definition (in number, u16
) of HTTP status code, which are defined in rfc9110
.
First, add this in your Cargo.toml:
[dependencies]
rhttp_status_code = { version = "1" }
Then, you can use it in code, like:
fn main() {
// Note: All constants are u16
let _a: u16 = rhttp_status_code::OK;
let _b: u16 = rhttp_status_code::Forbidden;
}
RFC9110
, Session 15: Link