Voice integration media intent
For voice input to search Media, there will be an Intent send out with the list of search result,
HMI could ignore to show current played one, or customize UI display with current search result by this Intent.
Note
In current version 2.49.1, Media provider switch through voice command is not ready for test yet.
Support command with provider specific as "Spotify", or just general command without provider,
which will control current Media provider.

- Action: Intent.ACTION_VIEW
- Bundle Fields:
Key |
Value |
ValueType |
provider |
"spotify" |
default means current provider |
- Example Code that voice send out for Media sign in:
| val provider = "spotify"
val intentUrl = Uri.parse("telenav://app.media/login?api=1&source=voice&provider="+provider)
val mediaIntent = Intent(Intent.ACTION_VIEW, intentUrl)
mediaIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
startActivity(mediaIntent)
|
Post Media search result from Voice to Media HMI
- Action: Intent.ACTION_VIEW
- Bundle Fields:
Key |
Value |
ValueType |
provider |
"spotify" |
default means current provider |
search_result |
see MediaItem Data Model |
Array of MediaItem |
- Example Code that voice send out for Media results display:
| val provider = "spotify"
val list = ... (MediaItem ArrayList)
val intentUrl = Uri.parse("telenav://app.media/search/result?api=1&source=voice&provider=${provider}")
val mediaIntent = Intent(Intent.ACTION_VIEW, intentUrl)
mediaIntent.putExtra("search_result", list)
mediaIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
appContext.startActivity(mediaIntent)
|