botman / driver-twilio

BotMan Twilio Driver

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

twilio driver never send replies messages

yossyrey opened this issue · comments

i just new using botman.
I have issue with twilio driver,
i just do all samples for twilio driver in docs, but seems it never send message to a number.

require_once 'vendor/autoload.php';
use BotMan\BotMan\BotMan;
use BotMan\BotMan\BotManFactory;
use BotMan\BotMan\Drivers\DriverManager;
$config = [
'twilio' => [
'token' => '####'
]
];
DriverManager::loadDriver(\BotMan\Drivers\Twilio\TwilioVoiceDriver::class);
DriverManager::loadDriver(\BotMan\Drivers\Twilio\TwilioMessageDriver::class);
$botman = BotManFactory::create($config);
$botman->hears('hello', function($bot) {
$bot->reply('Hello too');
});
$botman->fallback(function($bot) {
$bot->reply('Sorry, I did not understand these commands..');
});
$botman->listen();
no error, but it never send msg back to a number.
anyone can help, maybe give sample working for non laravel version.