Chris Pollett > Students > Nukala

    Print View

    [Bio]

    [Blog]

    [CS297 Project Proposal]

    [Deliverable-1]

    [Deliverable-2]

    [Deliverable-3]

    [Deliverable-4]

    [CS 297 Report_PDF]

    [CS 298 Project Proposal]

    [CS 298 Report_PDF]

    [CS 298 Presentation_PDF]

























Facebook Messenger Bot

Description: A chatbot is a service, powered by rules and sometimes artificial intelligence, that you interact with via a chat interface. To understand more on chatbot service, I have implemented a Facebook Messenger Weather Bot.

Examples:

  • Weather bot-Get weather whenever you ask.
  • Booking flight bot-Get flight information
  • News bot-Ask it to tell you when ever something interesting happens.

Facebook opened up their Messenger platform to enable bots to converse with users through Facebook Apps and on Facebook Pages. The following is a weather bot implementation using NodeJs on messenger.

Start with

  • a wit.ai bot setup (https://wit.ai/docs/quickstart)
  • a Messenger Platform setup (https://developers.facebook.com/docs/messenger-platform/quickstart)

Steps to run app:

  1. npm install body-parser express request
  2. Download and install ngrok from https://ngrok.com/download
  3. ./ngrok http 8445
  4. WIT_TOKEN=your_access_token FB_APP_SECRET=your_app_secret FB_PAGE_TOKEN=your_page_token
  5. run node messenger.js
  6. Subscribe your page to the Webhooks using verify_token and 'https://your_ngrok_io/webhook' as callback URL.
  7. Talk to your bot on Messenger!

Try it yourself! Download messenger.js

Facebook Messenger Bot Output