Available on crate feature
local-server only.Expand description
A server that binds to a random port on localhost and waits for a GET HTTP
request.
§Example
use matrix_sdk::utils::local_server::LocalServerBuilder;
let (uri, server_handle) = LocalServerBuilder::new().spawn().await?;
open_uri(uri);
if let Some(query_string) = server_handle.await {
parse_query_string(&query_string);
}
Structs§
- Local
Server Builder - Builder for a server that binds on a random port on localhost and waits for
a
GETHTTP request. - Local
Server Redirect Handle - A handle to wait for the end-user to be redirected to a server spawned by
LocalServerBuilder. - Local
Server Shutdown Handle - A handle to shutdown a server spawned by
LocalServerBuilder. - Query
String - A query string from a URI.
Enums§
- Local
Server IpAddress - The IP address that we want the
LocalServerBuilderto bind to. - Local
Server Response - The content that the end user will see when they a redirected to the local server’s URI.