whatsapp send message from php api code example
Example 1: how to make a message for whatsapp in php
{
"request": true,
"response": true,
"output": "Message Sent",
"msg_sent_today": 1
}
Example 2: how to make a message for whatsapp in php
<?PHP
$token = "";
$wa_uid = "";
$wa_pwd = "";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"http://wapi.phphive.info/api/message/receive.php");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS,"token=".$token."&wa_uid=".$wa_uid."&wa_pwd=".$wa_pwd);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$server_output = curl_exec ($ch);
curl_close ($ch);
echo $server_output;
?>