InfluxDB to store data in intervals

Hi
at least as a workaround this works for me:

binary_sensor:
  - platform: template
    sensors:
      tbalkontuer:
        value_template: "{{ states('binary_sensor.balkontuer') }}"
        friendly_name: "Template Balkontür"
        device_class: door
        unique_id: tbalkontuer
        attribute_templates:
          update_now: "{{ (now().minute / 5) | round(0) }}"

Gets updated every 5 minutes ( at 03, 08, 13, … due to the rounding), using now() only updates every minute.
Next step is to add the same for other sensors and using only the template_sensors for storage in the influx-database

thanks for the help
Armin