tried this in Discord #integrations, and somewhat unresolved, so please allow me here too:
is there a preference of any kind using a media_player group over a regular group with the same media_players? Asking because up to now Ive always used a regular group with media_player entities, and that works just fine. My intercom plays/pauses/stops tts, music files etc etc o er the regular groups.
It was because I also do
service: group.set
data:
object_id: broadcast_available
name: Broadcast available
entities: >
{{expand('group.broadcast')|rejectattr('state','in',['unknown','unavailable'])
|map(attribute='entity_id')|join(',')}}
to auto create a group with only available players that I had a look at the media_player group, hoping it would do something like that built in. But I dont think it does… And we can not create a media_player group like that (I think).
Unless, this is valid?:
action:
- service: group.set
<<: &select_players
data:
object_id: broadcast_available
name: Broadcast available
entities: >
{{expand('group.broadcast')|rejectattr('state','in',['unknown','unavailable'])
|map(attribute='entity_id')|join(',')}}
- service: media_player.join
<<: *select_players
(nope it isnt… automation.create_broadcast_available_group: extra keys not allowed @ data['name']
)
as far as I can see, the main difference is:
{{expand('group.broadcast')
|rejectattr('state','in',['unknown','unavailable'])
|map(attribute='entity_id')|list}}
{{expand(state_attr('media_player.broadcast_group','entity_id'))
|rejectattr('state','in',['unknown','unavailable'])
|map(attribute='entity_id')|list}}
in iterating them, but other than that, why would one choose a media_player group over a regular group?