http-constant 23.3.2

A comprehensive library providing common HTTP constants for header names, versions, MIME types, and protocol identifiers.
Documentation
<div align="center">

<img src="https://devhub.vip/pages/docs/img/hyperlane.png" alt="http-constant logo" height="120">

# http-constant

**Zero-Dependency Canonical HTTP Protocol Constants**

[![Crates.io Version](https://flat.badgen.net/crates/v/http-constant)](https://crates.io/crates/http-constant)
[![Docs.rs](https://img.shields.io/docsrs/http-constant?style=flat-square)](https://docs.rs/http-constant)
[![CI Status](https://img.shields.io/github/actions/workflow/status/hyperlane-dev/hyperlane/rust.yml?branch=master&style=flat-square&label=CI)](https://github.com/hyperlane-dev/hyperlane/actions/workflows/rust.yml)
[![Rust 2024](https://img.shields.io/badge/edition-2024-orange.svg?style=flat-square)](https://www.rust-lang.org)
[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg?style=flat-square)](../LICENSE)

[Workspace Overview](../README.md) ยท [API Docs](https://docs.rs/http-constant/latest/)

</div>

---

## Overview

`http-constant` is the zero-dependency leaf crate providing canonical HTTP header keys, header values, status codes, methods, MIME types, file extensions, and HTTP/2 protocol constants across the [`hyperlane`](../README.md) workspace.

## Installation

```sh
cargo add http-constant
```

## Usage

```rust
use http_constant::{CONTENT_TYPE, APPLICATION_JSON};

fn json_header() -> (&'static str, &'static str) {
    (CONTENT_TYPE, APPLICATION_JSON)
}
```

## Verification

```sh
cargo run -p hyperlane-cli -- fmt --check
cargo clippy -p http-constant --all-features --all-targets -- -D warnings
cargo test -p http-constant --all-features
```

## License

This project is licensed under the MIT License. See the [LICENSE](../LICENSE) file for details.

## Contact

For inquiries, please contact the author at [root@devhub.vip](mailto:root@devhub.vip).