Status Button Google Calendar Help PLS

I am trying to create a status icon that shows me the Tomorrow status of a Google Calendar.
I tried the following but I get an error message ( Message malformed: extra keys not allowed @ data[‘binary_sensor’] ) :
description: “”
mode: single
trigger:

    • platform: calendar*
  • event: start*
  • offset: “-24:0:0”*
  • entity_id: calendar.work*
    • platform: calendar*
  • event: end*
  • offset: “24:0:0”*
  • entity_id: calendar.work*
    binary_sensor:
    • name: Work Tomorrow*
    • state: “{{ iif(‘Work’ in trigger.calendar_event.summary, iif(trigger.event == ‘start’, ‘on’, ‘off’), states(‘binary_sensor.chagim_tomorrow’)) }}”*

What did I do wrong ?

It is hard to tell since it is not properly formatted, but it looks like you have combined an automation configuration with a trigger-based template binary sensor configuration… you can’t just mix and match configurations, each type has specific structural criteria.

Thanks.
If the first part is correct :
‘’’
image

Then, how do I create a “button” (binary sensor?) that shows that status.
I am very much a novice at HA automation. I am trying to use the Google calendar Integration to tell me (and show in HA) that I have an event Tomorrow.

This is a sensor that tells me it is a paid holiday tomorrow

  - platform: template
    sensors:
      feestdag_offset:
        friendly_name: "Feestdag"
        value_template: >
          {% if as_timestamp(states.calendar.feestdagen_in_belgie.attributes.start_time) - as_timestamp(now()) < 172800  %}on{% else %}off{% endif %}

Hartelijk dank ( Nederlander in Miami :grinning:)
If my calendar is named chagim, would this be the full confguration :grinning:

‘’’
description: “”
mode: single
trigger:

  • platform: calendar
    event: start
    offset: “-24:0:0”
    entity_id: calendar.7_chagim
  • platform: calendar
    event: end
    offset: “-24:0:0”
    entity_id: calendar.7_chagim
  • platform: template
    sensors: chagim_offset:
    friendly_name: “chagim tomorrow”
    value_template: >
    {% if as_timestamp(states.calendar.chagim.attributes.start_time) - as_timestamp(now()) < 172800 %}on{% else %}off{% endif %}
    ‘’’