使用 PHP 向 Whatsapp 号码发送消息

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/48333959/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-26 02:39:41  来源:igfitidea点击:

Send messages to Whatsapp number using PHP

phpwhatsappwhatsapi

提问by Deepu Sasidharan

I have to send messages to the customer's whatsapp numberprogramatically.

我必须以编程方式向客户的whatsapp 号码发送消息。

What are the pre requirements/needs?

什么是预先要求/需要?

Do I need to convert/register my personal number to business account?

我是否需要将我的个人号码转换/注册为企业帐户?

Is there any APIprovided by whatsappfor this?

whatsapp是否为此提供了任何API

回答by Jhess Kun

Do I need to convert/register my personal number to business account?

我是否需要将我的个人号码转换/注册为企业帐户?

Not necessarily, it's your choice if you want to share your personal account, even though you recommend using a business account

不一定,如果您想共享您的个人帐户,这是您的选择,即使您建议使用企业帐户

Is there any APIprovided by whatsappfor this?

whatsapp是否为此提供了任何API

According to Whatsapp's own documentation, they do not have a direct API, but you can create a link to send the messages, according to the documentation, follow the submission parameter by the URL: https://api.whatsapp.com/send?phone=

根据Whatsapp自己的文档,他们没有直接的API,但您可以创建一个链接来发送消息,根据文档,按照URL的提交参数: https://api.whatsapp.com/send?phone=

Here's another example:

这是另一个例子:

Use: https://api.whatsapp.com/send?phone=15551234567

使用https://api.whatsapp.com/send?phone=15551234567

Don't use: https://api.whatsapp.com/send?phone=+001-(555)1234567

不要使用https://api.whatsapp.com/send?phone=+001-(555)1234567

You can see more in: https://faq.whatsapp.com/en/android/26000030/

您可以在以下位置查看更多信息:https: //faq.whatsapp.com/en/android/26000030/

回答by Weiyan Wang

WhatsApp just launched business api recently

WhatsApp 最近刚刚推出了业务 API

What are the pre requirements/needs?

什么是预先要求/需要?

Please submit a form at https://www.facebook.com/business/m/whatsapp/business-apito sign up

请在https://www.facebook.com/business/m/whatsapp/business-api提交表格以注册

Do I need to convert/register my personal number to business account?

我是否需要将我的个人号码转换/注册为企业帐户?

You need to register a phone number as business account, after registration, you cannot use whatsapp app with the same number on your device. So it's better to register business account with another number rather than your personal number

您需要将电话号码注册为企业帐户,注册后,您将无法在您的设备上使用相同号码的whatsapp应用程序。所以最好用其他号码注册企业帐户而不是您的个人号码

Is there any API provided by whatsapp for this?

whatsapp 是否为此提供了任何 API?

Please check out https://www.whatsapp.com/business/apifor more information

请查看https://www.whatsapp.com/business/api了解更多信息