Start Activity: Google Music Search - How to get song info?

Post your questions and help other users.

Moderator: Martin

Post Reply
User avatar
aximili
Posts: 23
Joined: 28 Jun 2018 11:14

Start Activity: Google Music Search - How to get song info?

Post by aximili » 30 Jul 2018 10:37

I can create a Start Activity action
Action = com.google.android.googlequicksearchbox.MUSIC_SEARCH
Wait for result ticked

Then how do you get the song info (artist/title)?

(I only found this cool tutorial for Tasker)

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Start Activity: Google Music Search - How to get song in

Post by Martin » 31 Jul 2018 11:18

Hi,

Unfortunately action com.google.android.googlequicksearchbox.MUSIC_SEARCH does not return anything to the calling app so you either have to use action Control UI to read the contents of the screen and parse the song title or use the AutoVoice plugin to get the result (which probably also reads the screen contents).

Regards,
Martin

User avatar
aximili
Posts: 23
Joined: 28 Jun 2018 11:14

Re: Start Activity: Google Music Search - How to get song in

Post by aximili » 31 Jul 2018 11:54

I see. Thank you Martin for your reply :)
I don't mind using AutoVoice, I'd also have to use that on Tasker. Control UI is fine too if it works.
Would you mind telling me how to do it in Automagic? (Sorry I'm new, still moving my tasks from Tasker)

User avatar
Desmanto
Posts: 2709
Joined: 21 Jul 2017 17:50

Re: Start Activity: Google Music Search - How to get song in

Post by Desmanto » 31 Jul 2018 18:06

I try the intent, google assistant stated that the action is not available in my country. Probably should try to change region, but I have to turn off automagic first. If not, there are many flows will be executed when the timezone change, don't wanna mess it up.

You can start the action and when the google recognize the song title, use Control UI to press the element which have the name. You need to Show overlay control during testing, so you can tap the element later. See my index at the control UI section. You can even send command to google assistant using the Control UI.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.

colabi
Posts: 134
Joined: 06 Jan 2013 22:33

Re: Start Activity: Google Music Search - How to get song in

Post by colabi » 01 Aug 2018 21:05

Try this:
http://automagic4android.com/flow.php?i ... 3f412fc378

Start search for a song with Google, if a match is found, a notification with "song", "artist" will appear in statuabar

Or use this flow like a shortcut:
http://automagic4android.com/flow.php?i ... e27118db0c

User avatar
aximili
Posts: 23
Joined: 28 Jun 2018 11:14

Re: Start Activity: Google Music Search - How to get song in

Post by aximili » 05 Aug 2018 11:43

Thank you Desmanto and especially Colabi for the flow! That works! Amazing!

Post Reply