vasani-arpit / WBOT

A simple Web based BOT for WhatsApp™ in NodeJS 😜. Working as of 📅 Feb 4th, 2024
Other
990 stars 314 forks source link

webhook not working #226

Closed merco closed 3 years ago

merco commented 3 years ago

Describe the bug webhook example is not working for me

To Reproduce I set http://davidemercanti.altervista.org/wbot/bot.php" and I send Qq as message, but I get the "No exact Match found" `<?php header("Content-Type: application/json"); header("Access-Control-Allow-Origin: *"); header("Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type,Accept");

$x = file_get_contents("php://input"); $x = json_decode($x); $message = $x->text; $msg_typ = $x->type;

$response = array(array('text' => '', 'type' => 'message'));

if($message == 'Qq') { $response = array(array('text' => 'hello my dear friend', 'type' => 'message')); $response = json_encode($response);

} echo($response); ?>`

merco commented 3 years ago

I have to set HTTPS in the url