CasperLaiTW / laravel-fb-messenger

Laravel Facebook Messenger Provider
MIT License
105 stars 27 forks source link

Dynamical config #84

Closed elephantux closed 7 years ago

elephantux commented 7 years ago

I want use messenger for several fb pages. Is it possible to dynamically add tokens?

elephantux commented 7 years ago

I think what I found solution

class Chatbot extends BaseHandler
{
    public function __construct()
    {
        $this->createBot(config('fb-messenger.app_token'));
    }
...
elephantux commented 7 years ago

But how to provide fb-messenger.verify_token to Bot?

CasperLaiTW commented 7 years ago

Hi, verify token can setup on .env file or config

otherwise you can use to Config::set to change it.

\Config::set('fb-messenger. verify_token', 'another verify token');