Good afternoon Rustlers! Today we’d like to announce a crate that a number of us including @carllerche, @seanmonstar, @withoutboats, and I have been working on for some time now: the http crate! This crate is intended to be sort of the “standard library for HTTP types” in the sense that it provides common types shared amongst all HTTP implementations: requests, responses, headers, etc. It does not cover transport, but is rather intended for use in libraries like Hyper, and to support an ecosystem of crates that can share HTTP-related types.

This crate is not currently published on crates.io and we’d like to get your feedback before doing so! The current plan is to publish an 0.1 release before RustConf on August 19.

We hope that the http crate can become a stable foundation for the emerging HTTP ecosystem in Rust, usable for both synchronous and asynchronous servers, clients, and middleware. This crate has been designed from the start with long-term API stability in mind, leaning heavily on principles learned throughout the ongoing Libz Blitz. We’ve also focused on making it as flexible as possible for various use cases, striving for ergonomics at compile time and speed at run time.

You can get started today with the http crate first by reading the documentation and then by using a git dependency:

[dependencies] http = { git = 'https://github.com/carllerche/http' }

We don’t expect much API-level breakage before 0.1 is released, but if you uncover any issues please feel free to report them! We want to be sure to give everyone a chance to provide feedback before the publication to crates.io. After the 0.1 publication we plan to start integrating the http crate throughout the ecosystem where possible, followed by a 1.0 release after everything looks like it’s going smoothly! (and possibly with updates from what we’ve learned along the way)

Please feel free to leave any feedback here or on GitHub!