hyperlane-plugin-openapi 23.3.0

An OpenAPI 3.1.0 specification builder and zero-allocation interactive API docs plugin for the Hyperlane framework serving ETag-cached /openapi.json (with 304 support) and a self-contained zero-CDN /docs explorer.
Documentation
/// OpenAPI specification version emitted by [`OpenApiSpec`].
pub const OPENAPI_VERSION: &str = "3.1.0";

/// Default path serving the pre-serialized OpenAPI JSON document.
pub const DEFAULT_SPEC_PATH: &str = "/openapi.json";

/// Default path serving the self-contained interactive HTML API documentation explorer.
pub const DEFAULT_DOCS_PATH: &str = "/docs";

/// Default `Cache-Control` header applied to OpenAPI specification and docs responses.
pub const DEFAULT_OPENAPI_CACHE_CONTROL: &str = "public, max-age=300";

/// JSON media type for `/openapi.json`.
pub(crate) const CONTENT_TYPE_JSON: &str = "application/json; charset=utf-8";

/// HTML media type for `/docs`.
pub(crate) const CONTENT_TYPE_HTML: &str = "text/html; charset=utf-8";

/// Lowercase hexadecimal digits for ETag formatting.
pub(crate) const HEX_LOWER: &[u8; 16] = b"0123456789abcdef";

/// Default API title when constructed via `Default`.
pub(crate) const DEFAULT_API_TITLE: &str = "Hyperlane API";

/// Default API version when constructed via `Default`.
pub(crate) const DEFAULT_API_VERSION: &str = "1.0.0";