"ha" shell command doesn't work

hello, I am triying to make this simple command work:

ha restart audio

but it seems to not execute and if I try in developers section I receive this error:

stdout: ""
stderr: "bash: ha: No such file or directory"
returncode: 127

i have tried with or without bash but with no success.

Anyone have suggestions?
Thanks

install ‘advanced ssh and web terminal’ add-on with protection mode off, and execute it there.

i already have it and actually using it manually. the fact is that i want this to be automated by the click of a button, so i put it in shell commands to create a button, but it doesn’t work!

is there a way to use that advanced ssh and web tetminal app in an automation?

you could write a command line script that ssh’s in to the addon, and then runs that command.

The syntax is ssh user1@server1 command1

so ssh root@<IP> "ha restart audio"

okay, thank you. The ip that I have to set is the ip address of the home assistant machine, correct?