How to get started with sending api commands from home assistant?

Hello, I am wanting to do some really basic/silly, but useful things with automations from home assistant to yatse to possibly multiple different phones. Keeping it simple for now, I am wanting to start testing on my phone, but I’m not sure how to get started.

I have seen others accomplish this on the forum, but there is little to no detail on what was done…but I can see that what i am wanting to do is possible. I found the api doc with some pre-built commands (which, at this time is probably all i would ever need); I tried to send a service call from Home assistant and that didn’t work. So now I am wondering, what are the steps in order for this to work? At this point, I’m really only concerned with opening the app via a call from home assistant…that’s all.

I purchased yatse YEARS ago, so I am sure i have the full version, I read something about ‘Tasker’, but also read that it is built in so at this point i believe that i shouldn’t need any other 3rd party app and should be able to just send something from home assistant to my phone…but I’m not sure how.
Any help is appreciated!

Well… I just kept tinkering around and something worked…hopefully this helps someone in the future.

This is 2 actions to do a sequential automation, the first step will open the yatse app, the second step will select the host (in the example, the call would select host number “04”. The api documentation linked above was used to figure out the calls and also some random searching on the companion docs eventually led me to something that worked.

The yatse app is far superior than anything that can be replicated in home assistant so glad i finally have a path way to do some automating with the remote. Having to switch hosts all the time is annoying so perhaps i can springboard off a light turning on in a room or something to switch the hosts…idk, the possibilities are endless now. Again, hope this helps someone in the future.

- service: notify.mobile_app_<your phone name>
  data:
    message: "command_activity"
    data:
      intent_package_name: "org.leetzone.android.yatsewidgetfree"
      intent_action: "android.intent.action.VIEW"
      intent_uri: "yatse://command/show/remote"

- service: notify.mobile_app_<your phone name>
  data:
    message: "command_activity"
    data:
      intent_package_name: "org.leetzone.android.yatsewidgetfree"
      intent_action: "android.intent.action.VIEW"
      intent_uri: "yatse://command/select/media_center?ID=04"

My next question is… is there a custom command that can be done to switch back to the home assistant companion app? That could be useful for something like a wall tablet where both the home assistant companion app and yatse is installed to be able to switch back and forth between the two apps?

update Scratch that…maybe… I’m not able to get this to work with a amazon fire modified tablet to be android. I would expect the above to work just fine with anything that is true android.