Skip to main content

parse_endpoint

Function parse_endpoint 

Source
pub fn parse_endpoint(input: &str) -> Result<Url, Error>
Available on crate feature proxy only.
Expand description

Validates an explicit HTTP(S)/SOCKS proxy URL or bare host[:port].

The returned URL retains userinfo; do not log it without redaction. SOCKS default ports are supplied by transport adapters. No environment or native settings are read. See ProxyMode::Explicit for accepted endpoint syntax.

ยงErrors

Returns Error::InvalidProxyUrl with a credential-free reason.