Remote - Command

Dears,
I have a more delicate project that looks like this:
Sony TV with android where HA discovers the TV + remote control
Sorround JBL where the remote control is quite damaged
Broadlink RM4mini where I learned its commands and I use a HUE remote control
I want to learn the commands on the remote control (TV) to be able to control the JBL, I have the option to choose Broadnlink or the TV remote control, if I choose the remote control, nothing happens, but if I choose Broadlink, and press a button on the TV remote control , the button is memorized, I try it, it works.
I took and saved the selected buttons as a script, BUT, I can’t use the automation like this:
trigger - when I press the remote control button (the script) - it didn’t find any option to bring it up
action - push script y (I can bring it to “call service” without problems
so, does anyone know how I can use the script to trigger?
thx,
Nick

Post your automation

hi @tmjpugh unfortunately I don’t have any automation because I haven’t found any way to use a script as a trigger. That’s why I wrote, maybe I can find support from someone

Its possible to use rest api call HA service

This service may trigger automation, change switch state (which can perform action or call automation) or perform anything within HA

You may also directly make api call
From your script to do what you desire