XMPP::AltConnectionResolver
XEP-0156 (v1.4.0): discovers WebSocket and BOSH endpoints from the HTTPS host-meta document (XRD XML or JRD JSON). The DNS _xmppconnect TXT method was removed from the spec and is deliberately not implemented.
Constants
BOSH_REL = "urn:xmpp:alt-connections:xbosh"
JRD_PATH = "/.well-known/host-meta.json"
WEBSOCKET_REL = "urn:xmpp:alt-connections:websocket"
XRD_PATH = "/.well-known/host-meta"
Instance methods
discover(domain : String, config : Config | Nil = nil, fetcher : String -> String | Nil = ->(url : String) do
https_get(url, config)
end) : Array(AlternativeEndpoint)
Discovers alternative endpoints, ordered WebSocket before BOSH and wss/https before ws/http. Fetches the XRD document first and falls back to JRD when XRD yields no alt-connection links.