[−][src]Function surf::options
ⓘImportant traits for Request<C>
pub fn options(uri: impl AsRef<str>) -> Request<NativeClient>
Perform a one-off OPTIONS
request.
About the HTTP Method
The HTTP OPTIONS method is used to describe the communication options for the target resource. The client can specify a URL for the OPTIONS method, or an asterisk (*) to refer to the entire server.
Panics
This will panic if a malformed URL is passed.
Errors
Returns errors from the middleware, http backend, and network sockets.
Examples
let string = surf::options("https://httpbin.org/options").recv_string().await?;