Skip to main content

read_json_response

Function read_json_response 

Source
pub async fn read_json_response<T, S>(stream: S) -> Result<T>
where T: DeserializeOwned, S: Stream<Item = Result<Bytes>> + Sync + Send + Unpin,
Expand description

Helper to read a json response from a byte stream.

This will collect the full response before trying to deserialize it.