Files
Will Pfleger 7e6461242a feat(audio-client): accept a client request in connect (#8497)
## Summary

Related:
[block/buzz-app#1424](https://github.com/block/buzz-app/pull/1424)
(native federated sessions; attaches the assertion on Huddle audio once
this lands)

`buzz_audio_client::connection::connect` took the audio URL as `&str`,
so a host had no way to add headers to the WebSocket upgrade. buzz-app
needs to send its NIP-FI user assertion (`Nostr-Federated-Identity:
Bearer <jwt>`) on the Huddle audio socket. The relay checks NIP-FI when
the audio connection upgrades (`audio/handler.rs` →
`check_nip_fi_at_upgrade`).

This PR widens the parameter to `impl IntoClientRequest + Unpin`, the
same bound `connect_async_tls_with_config` already takes. Nothing else
changes: TLS, timeouts and the NIP-42 handshake work as before. Existing
`&str`/`&String` callers, including
`desktop/src-tauri/src/huddle/relay_api.rs`, compile unchanged.

---------

Signed-off-by: Will Pfleger <wpfleger@block.xyz>
Co-authored-by: Duncan <dcfd242e557282d7a1e2cf2e6877522682f1e5c6156dc92ca7d90eaedd3b0f95@buzz.block.builderlab.xyz>
2026-10-20 22:58:04 +00:00
..