Linking toggle to script

Hi, very basic question. I have a script that sets a philips hue scene and turns on some other lights. Running the script in the script editor turns the lights on as intended.

How do I link this script to a toggle helper, so that it can be run from the dashboard?

thanks,
Ashley

I use a tile card for these purposes.

It looks like this when running…

I use the script entity_id for both the Card ‘Entity’ and in the Interactions section

The problem with that is that, in Home Assistant, a Toggle helper is “state-ful” while a scene is “stateless”. You can use an automation to run the script when the helper is turned “on”, but you will need to remember to set it back to “off” at the end of the automation so it will be ready for next time.

The more type-appropriate method is what teskanoo has posted above, use a button card or any other card with card actions to call the script action when “tapped”.

Makes sense, thanks!