http-rs / surf

Fast and friendly HTTP client framework for async Rust
https://docs.rs/surf
Apache License 2.0
1.45k stars 119 forks source link

HTTP version configurable. #264

Open wess opened 3 years ago

wess commented 3 years ago

Im trying to use Surf to work with the GitHub API and they aren't accepting HTTP version 2. So I would like to be able to set the http version to 1.1x

jbr commented 3 years ago

This seems like a reasonable feature request :thumbsup:

In the short term, try using the async-h1 backend, which only supports http/1.1

Fishrock123 commented 2 years ago

2.3.0+ has surf::Config, so if our backends support this you should be able to add support for it. This would probably have to be done in the underlying http-client crate: https://github.com/http-rs/http-client