go2rtc icon indicating copy to clipboard operation
go2rtc copied to clipboard

[REQUEST]: Auto configure ICE using Home Assistant

Open RyanMorash opened this issue 1 month ago • 4 comments

Home Assistant 2025.12 introduces a new API endpoint that allows fetching of the HA Cloud ICE servers and credentials: https://github.com/home-assistant/core/pull/157774

It would be great if go2rtc could use a long-lived access token from HA to automatically use this info.

RyanMorash avatar Dec 16 '25 15:12 RyanMorash

If you have set up go2rtc in Home Assistant, HA will pass the configured ice servers on each WebRTC offer on the websocket API (https://github.com/home-assistant/core/blob/84d7c37502907d0ea024203eefbe680774e5b496/homeassistant/components/go2rtc/init.py#L329), which will be handled in go2rtc in https://github.com/AlexxIT/go2rtc/blob/master/internal/webrtc/webrtc.go#L143

@AlexxIT Is the above-described approach already fulfilling the request? If not, I prefer that HA sets them via an API call

edenhaus avatar Dec 17 '25 05:12 edenhaus

I use Frigate provided go2rtc with the WebRTC Camera card. After my testing it seems the only way that remote viewing works is with the credentials manually added in the configuration

RyanMorash avatar Dec 17 '25 06:12 RyanMorash

HA Cloud ICE can be used only for default HA lovelace card. Users use go2rtc in different WebUI and with different cards.

I think that if a person has paid for Nabu Casa, he has the right to use this service as well. But I will not add such a feature without official permission from the Nabu Casa team.

AlexxIT avatar Dec 17 '25 08:12 AlexxIT

You have official permission from Nabu Casa to add this feature, thanks!

bbangert avatar Dec 19 '25 15:12 bbangert