Use Fritz!dect 400 and 440 switches

I used a combined approach of web hook, parameter, and script to change for example the color temp.

For the web hook I use the GET method together with a URL parameter as this allows to copy-paste the complete URL into a browser and test the call and automations independent of the FritzDect 440, e.g.

URL call with parameter
http://192.168.200.45:8123/api/webhook/my_secrect_webhook_id?command=esstisch_an

Web hook automation

alias: FritzBox Webhook
description: ""
triggers:
  - allowed_methods:
      - GET
    local_only: true
    webhook_id: "my_secrect_webhook_id"
    trigger: webhook
conditions: []
actions:
  - choose:
      - conditions:
          - condition: template
            value_template: "{{ trigger.query.command=='esstisch_an' }}"
        sequence:
          - action: scene.turn_on
            metadata: {}
            target:
              entity_id: scene.esstisch_an
      - conditions:
          - condition: template
            value_template: "{{ trigger.query.command=='esstisch_color_temp_up' }}"
        sequence:
          - action: script.light_color_temp_up
            metadata: {}
            data:
              max_color_temp: 4000
              target_light: light.esstisch
              color_temp_step: 300

Script for color temp up

alias: light color temp up
sequence:
  - action: light.turn_on
    target:
      entity_id: "{{ target_light }}"
    data:
      color_temp_kelvin: >
        {{iif(state_attr(target_light,'color_temp_kelvin')+color_temp_step >
        max_color_temp, max_color_temp,
        state_attr(target_light,'color_temp_kelvin')+color_temp_step)}}
          
fields:
  target_light:
    name: Light
    description: Light for color temp down
    selector:
      entity:
        filter:
          domain: light
    required: true
  max_color_temp:
    name: Maximal color temperature
    default: 4000
    selector:
      number:
        mode: box
    required: true
  color_temp_step:
    name: Change of color temperature per step
    default: 300
    selector:
      number:
        mode: box
    required: true

What a very nice eye opener for me . First made the Template and then i made the automation HA. But had to figure it out how it should work. You need to make a Webhook in HA with the simple tekst what you made in the Template. Works like a charm. Thank you .