[package]
edition = "2024"
name = "rate-limits"
version = "0.7.0"
authors = ["Matthias Endler <matthias@endler.dev>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A parser for HTTP rate limit headers"
homepage = "https://github.com/mre/rate-limits"
documentation = "https://docs.rs/rate-limits"
readme = "README.md"
keywords = [
"http",
"rate-limit",
"header",
"parser",
]
license = "Apache-2.0/MIT"
repository = "https://github.com/mre/rate-limits"
[features]
default = ["http"]
[lib]
name = "rate_limits"
path = "src/lib.rs"
[[test]]
name = "parse"
path = "tests/parse.rs"
[dependencies.bitflags]
version = "2.11.1"
[dependencies.displaydoc]
version = "0.2.5"
[dependencies.headers]
version = "0.4"
[dependencies.http]
version = "1.4"
optional = true
[dependencies.once_cell]
version = "1.21.3"
[dependencies.reqwest]
version = "0.12"
optional = true
default-features = false
[dependencies.thiserror]
version = "2.0.18"
[dependencies.time]
version = "0.3.46"
features = ["parsing"]
[dev-dependencies.doc-comment]
version = "0.3.4"
[dev-dependencies.indoc]
version = "2.0.7"
[dev-dependencies.time]
version = "0.3.46"
features = [
"parsing",
"macros",
]
[lints.clippy]
missing_const_for_fn = "warn"
module_name_repetitions = "allow"
[lints.clippy.all]
level = "warn"
priority = -1
[lints.rust]
absolute_paths_not_starting_with_crate = "warn"
anonymous_parameters = "deny"
macro_use_extern_crate = "deny"
missing_copy_implementations = "warn"
missing_debug_implementations = "warn"
missing_docs = "deny"
semicolon_in_expressions_from_macros = "warn"
unreachable_pub = "warn"
unused_extern_crates = "warn"
variant_size_differences = "warn"
[lints.rustdoc]
invalid_html_tags = "warn"