Search code examples
androidgoogle-assistant-sdkgoogle-home

letting my app talk to google assistant in google home


I have developed an android app that consumes an API. It plays music each time the API sends a request to the app. I want to install this app on the Google home device, In other words, I want the google home device to play the music whenever it receives a request from the API...How can I do that?


Solution

  • What you're trying to do has a number of problems, and a few involved with your perception of how things work on a Home device and with the Assistant.

    • The Google Home doesn't run Android, and you can't "install" your app on it. In fact, you don't "install" apps on a Home device at all. Instead, they act more like a web browser and access their Actions that run in the cloud.

    • The Assistant platform and Actions on Google are mostly conversation driven, and primarily driven by the user initiating the conversation. Notifications are fairly limited. This is to put users in control.

    • However, Home devices are also Cast enabled devices. So you may be able to have your mobile device be triggered through the API, and have it issue a Cast command to the device begin playback. There are restrictions on how you can initiate casting from a mobile device, however, so this may not be a good solution in your case.