Hey @teqqy
There should not be a hyphen in front of the script name. Try this…
# turn off lamp after 10 minutes
motion_az_off:
sequence:
- delay:
minutes: 5
- service: light.turn_off
data:
entity_id: light.schreibtisch_christian
Are you using a scripts.yaml file or are you putting everything in the configuration.yaml?