Good evening everyone.
The WhatsApp app sports an activity which is com.whatsapp.ContactPicker
If you launch it, you are faced with a contact picker where you actually can pick a contact.
I made it work with automagic, the matter is that I have no idea about how to get the value of the picked contact.
I tried with debug condition but there are no relevant variables.
Maybe I am missing something, could you please explain how I could retrive the data from the picked contact (ID? Name? Else?) and then use it into an automagic flow to, say, open a chat with that same contact to send him a message?
Thank you.
select a Whatsapp contact
Moderator: Martin
- tsolignani
- Posts: 187
- Joined: 12 Jan 2019 11:53
- Location: Vignola, Mo, Italy
- Contact:
- tsolignani
- Posts: 187
- Joined: 12 Jan 2019 11:53
- Location: Vignola, Mo, Italy
- Contact:
Re: select a Whatsapp contact
Thank you so much, it works like a charm!
Have a nice evening.
Have a nice evening.
- tsolignani
- Posts: 187
- Joined: 12 Jan 2019 11:53
- Location: Vignola, Mo, Italy
- Contact:
Re: select a Whatsapp contact
PS is there any documentation I can read about that? I mean extracting contact but even name or other contact's properties.
Re: select a Whatsapp contact
There is no documentation. That contact picker activity only returns jid.
- tsolignani
- Posts: 187
- Joined: 12 Jan 2019 11:53
- Location: Vignola, Mo, Italy
- Contact:
Re: select a Whatsapp contact
Thank you, understood.
Still, how is one supposed to get to know that?
Did you get to know it because you happened to read something or is there a way to ask the activity regarding the values it returns?
Just to better understand, if I may ask.
Thank you.
Re: select a Whatsapp contact
Read it on stackoverflow.com
Re: select a Whatsapp contact
@tsoliganani : Usually I just test and try to find any intent or activity using start activity or send broadcast. Sometimes I google the problem, but using keyword tasker (since their user base is higher and have higher chance that someone already ask about it and maybe get solution).
Other is you can try to check the manifest xml of the app (I usually use MiXplorer to check it), to see if there is any unique string that represent something I want to find. Next level is to use logcat and try to replicate the action first and check in the logcat for any pattern we can use.
Other is you can try to check the manifest xml of the app (I usually use MiXplorer to check it), to see if there is any unique string that represent something I want to find. Next level is to use logcat and try to replicate the action first and check in the logcat for any pattern we can use.
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.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.