Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Whatsapp Api - How to automatically send pre-filled message which is in the url

To create your own link with a pre-filled message that will automatically appear in the text field of a chat, use https://wa.me/whatsappphonenumber/?text=urlencodedtext where whatsappphonenumber is a full phone number in international format and URL-encodedtext is the URL-encoded pre-filled message.

Example:https://wa.me/15551234567?text=I'm%20interested%20in%20your%20car%20for%20sale

https://faq.whatsapp.com/en/android/26000030/

or

<a href="https://api.whatsapp.com/send?phone=0123456789&text=I'm%20interested%20in%20your%20services" target="_blank">  Click to WhatsApp Chat</a>

The message in the url shows in the input field of whatsapp message box is there a way so that the message gets posted or sent automatically ? Reason behind it- There will be a icon on the website for whatsap chat anyone who clicks on that icon his message should be automatically send to the website's contact number which is in the url.

like image 567
mand1 Avatar asked Oct 03 '18 06:10

mand1


People also ask

How do you automatically send pre-filled message which is in the URL?

Create your own link with a pre-filled message The pre-filled message will automatically appear in the text field of a chat. Use https://wa.me/whatsappphonenumber?text=urlencodedtext where whatsappphonenumber is a full phone number in international format and urlencodedtext is the URL-encoded pre-filled message.

Can you automate sending WhatsApp messages?

Tap the + icon in the top-right corner and tap Create Personal Automation. On the next screen, tap Time of Day to schedule when to run your automation. In this case, select the dates and times when you want to schedule WhatsApp messages. Once that is done, tap Next.

How can I send a message from WhatsApp to my website?

Open the web browser and then paste 'https://api.WhatsApp.com/send?phone=number' in the Address bar of your phone's browser. In the place of “number”, enter the phone number of the person to whom you want to send a WhatsApp message with the country code.


1 Answers

I was looking at this sometime back and sadly still there is no way to automatically send messages through the client app. It makes sense in a way to prevent spam & misuse. The closest thing is to pre-fill the content and let the user send the message to the desired phone number.

If you are a business you could try the Whatsapp for Business API - https://www.whatsapp.com/business/api to implement chatbot like features and that might fit whatever use case you are looking to build. Anyways it a request only feature for now but you can try the same.

Or if you would want to get wild and try app overlay to auto send the message but Whatsapp prevents app overlay and never lets users proceed to use the app.

like image 88
Satheesh Avatar answered Nov 04 '22 00:11

Satheesh