[][src]Function surf::client

pub fn client() -> Client

Construct a new Client, capable of sending Requests and running a middleware stack.

Examples

let client = surf::client();

let req = surf::get("https://httpbin.org/get");
let res = client.send(req).await?;