Overloading functions

Hi,

is it possible to “overload” services to work for different device types? For example, both light.turn_off and switch.turn_off services are available, but is it possible to have e.g. one script that is able to turn off either a light or a switch?

homeassistant.turn_off

1 Like

Thanks, that’s it!