First install the dependencies:
npm i
Then build the project:
npm run build
In the end, specify the required environment variables from the Facebook developer panel:
cp .env.example .env
BOT_ID
: TheApp ID
fromSettings
->Basic
BOT_SECRET
: TheApp Secret
fromSettings
->Basic
BOT_PAGE_ID
: ThePage ID
fromMessenger
->Settings
->Access Tokens
BOT_PAGE_TOKEN
: ThePage Token
fromMessenger
->Settings
->Access Tokens
BOT_VERIFY_TOKEN
: TheVerify Token
fromMessenger
->Settings
->Webhooks
npm run start
docker-compose up -d
Then use the following commands to be able to connect using application webhooks
npm run tunnel
or using ngrok
ngrok http 3000
npm run document
After running the command, go to http://localhost:8080 on your preferred browser
npm test
npm run coverage