Skip to main content

Module deprecated

Module deprecated 

Source
Expand description

Deprecation marker type (RFC 8594).

Deprecated carries a sunset date and an optional replacement link, and can inject the standard Deprecation and Sunset response headers defined in RFC 8594.

§Example

use api_bones::deprecated::Deprecated;

let d = Deprecated::new("2025-12-31")
    .with_link("https://api.example.com/v2/docs");
assert_eq!(d.sunset, "2025-12-31");
assert!(d.link.is_some());

Structs§

Deprecated
Deprecation metadata for an API resource or endpoint.