Hello, found this thread as I was trying to do a similar thing.
After searching around on GitHub and testing it out myself, it seems you can’t execute an action passed into a script as a field (a runtime variable). You can, however, execute an action set when the script is configured.
For example, see the “confirm” and “dismiss” actions in this blueprint: core/confirmable_notification.yaml at b6d001bfe6f00db0461861c0894d5bc83306b038 · home-assistant/core · GitHub
The downside to this, obviously, is once the script is configured to do A and B, it will only ever do A and B, rather than allowing the user to tell it to do C on this specific run.
(To make it run the sequence of action(s) you’ve set, you can use a conditional. You can bypass the conditional by setting it to “true”: HAConfig/medication_reminder.yaml at 4feba7a7650adb23dbd36622911cab7d9e5a798d · MTrab/HAConfig · GitHub)