Create A Link That Will Open Viber And WhatsApp And Will Send A Message To Me


Answer :

What you need is called deep-linking, some examples for viber and whatsapp are:



Viber:



<a href="viber://pa?chatURI=[public account URI]&text=[message text]"> some text </a>


WhatsApp:



<a href="whatsapp://send?abid=[users name]&text=[message text]"> some text </a>


While not a deep link, you can also use the following url (don't use + on phone) for WhatsApp:



<a href="https://api.whatsapp.com/send?phone=0000000">Contact Me</a>





Sources:



http://origamiengine.com/deep-linking

https://support.viber.com/customer/en/portal/articles/2872423-deep-links



Viber link to user should be like this:



viber://contact?number=%2B0000000000000


Use international telephone number format without + but with %2B.



Since you don't want to create a public account (aka viber links including /pa? ) then simple add the link: <a href="viber://chat?number=012345678901"">chat with me</a>
The first two digits are country code and no + sign needed.



Comments

Popular posts from this blog

Converting A String To Int In Groovy

"Cannot Create Cache Directory /home//.composer/cache/repo/https---packagist.org/, Or Directory Is Not Writable. Proceeding Without Cache"

Android SDK Location Should Not Contain Whitespace, As This Cause Problems With NDK Tools