Skip to main content

from_link

Function from_link 

Source
pub fn from_link(link: &str) -> Result<ConnectionIdentifier, String>
Expand description

Decode a ConnectionIdentifier from ANY supported link form:

  • web+qualia://connect?p=<payload> — the deep link (payload is the p= query value).
  • https://<domain>/w#<payload> — the HTTPS fallback (payload is the # fragment).
  • a bare qcx1_… string.

The extracted payload is percent-decoded defensively (base64url is URL-safe, but a %-escaped payload is still accepted) before ConnectionIdentifier::decode.