Exposing LiveKit status in site settings serializer

@Falco Is it possible to expose a public check in the site settings/serializer for whether LiveKit is configured, alongside voice_enabled?

Today voice_enabled is client-exposed, but there’s no public signal for whether a site can serve LiveKit. The only LiveKit-related site attribute, voice_livekit_per_room_available, is scoped to the room-form checkbox, so it returns false under the all_rooms policy and can’t be used to answer “does this site do LiveKit at all”.

RoomSerializer#expected_transport covers the per-room case nicely, but that requires fetching rooms first, and it comes back empty when voice_public_access is off, even on a site where LiveKit is fully configured.

Would something like this be acceptable? It’s derived from existing state, exposes no credentials or policy detail, and needs no new endpoint.

It would go in plugins/voice/plugin.rb, after the voice_livekit_per_room_available block and just before the Voice::DefaultRoomSeeder.ensure! line:

# Public, credential-free signal that the site can serve LiveKit at all.
add_to_serializer(:site, :voice_livekit_available) do
Voice::Livekit.configured? && SiteSetting.voice_livekit_room_policy != "disabled"
end

לייק 1