# Set the volume for a group of speakers to be the average volume of the speakers that are not Google Home or Google Mini devices

- id: group_playback_start
  alias: "CCA: Group playback (start)"
  trigger:
  - platform: state
    entity_id: media_player.all_my_speakers, media_player.kitchen_speakers, media_player.main_speakers
    from: 'off'
  condition:
  - condition: template
    value_template: "{{ trigger.to_state.state in ['idle', 'paused', 'playing'] }}"
  action:
  - service: python_script.cca_sync_chromecast_volumes
    data:
      entity_id: "{{ trigger.entity_id }}"
