Currently tungstenite defines its own types for all of this but internally uses the http crate already. It seems like it would make sense to re-use the types from the http crate instead as that would also allow easier integration with other code.
Doing this might also simplify e.g. #70 and could for example also allow the HTTP part of the WebSocket connection to be handled by another HTTP library with tungstenite only taking care of populating the request, parsing the response and then taking over the upgraded HTTP connection.
Currently tungstenite defines its own types for all of this but internally uses the http crate already. It seems like it would make sense to re-use the types from the http crate instead as that would also allow easier integration with other code.
Doing this might also simplify e.g. #70 and could for example also allow the HTTP part of the WebSocket connection to be handled by another HTTP library with tungstenite only taking care of populating the request, parsing the response and then taking over the upgraded HTTP connection.