项目作者: weijiangan

项目描述 :
Copied from https://developers.facebook.com/docs/messenger-platform/guides/quick-start. For backup and reference purpose only
高级语言: JavaScript
项目地址: git://github.com/weijiangan/messenger-chatbot.git
创建时间: 2017-09-15T15:11:09Z
项目社区:https://github.com/weijiangan/messenger-chatbot

开源协议:MIT License

下载


Facebook Messenger Bot

This example project creates a Facebook Messenger bot, completely
mirroring the quickstart located in Messenger Platform docs.

It’s an echo bot that responds to a user’s message by repeating their message back to them. It also sends a generic template when a message with “generic” text is received. This project is not dependent on any external libraries and can easily be extended.

Getting Started

To get started you need to:

  • Set up your Facebook app on Facebook

  • Configure your Facebook App

    The Callback URL you set when configuring your app on Facebook is your Glitch project’s publish URL with ‘/webhook’ appended. The publish URL is what loads when you click ‘Show’ and has the format ‘https://project-name.glitch.me‘, so for this example we used ‘https://messenger-bot.glitch.me/webhook‘ for the Callback URL.

    The Verify Token is a string you make up - it’s just used to make sure it is your Facebook app that your server is interacting with.

  • Copy your app credentials into the .env file

For more detailed setup instructions, see Messenger Platform Quick Start.