Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/joannajjliu/art-auction-messenger-bot
messenger bot for hackathon
https://github.com/joannajjliu/art-auction-messenger-bot
Last synced: 5 days ago
JSON representation
messenger bot for hackathon
- Host: GitHub
- URL: https://github.com/joannajjliu/art-auction-messenger-bot
- Owner: joannajjliu
- Created: 2020-06-11T01:57:34.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-12-13T01:20:51.000Z (about 2 years ago)
- Last Synced: 2024-12-07T19:07:20.285Z (2 months ago)
- Language: JavaScript
- Homepage:
- Size: 1.17 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 14
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# art-auction-messenger-bot
messenger bot for hackathon## Bot set-up steps:
- Rename ".sample.env" to ".env" and add the required information
- If using free ngrok for local tunneling, the callback url will need to be updated on each new ngrok session with "https://[ngrok link]/webhook". The PAGE_ACCESS_TOKEN may also need to be regenerated on each new session.
### Setting up webhook
- Reference: https://developers.facebook.com/docs/messenger-platform/getting-started/webhook-setup
- Testing the webhook
- Run local app: "nodemon index.js" in command line
- Test webhook verification:
- In a separate command line:
curl -X GET "localhost:1337/webhook?hub.verify_token=&hub.challenge=CHALLENGE_ACCEPTED&hub.mode=subscribe"
- Test webhook:
- curl -H "Content-Type: application/json" -X POST "localhost:1337/webhook" -d '{"object": "page", "entry": [{"messaging": [{"message": "TEST_MESSAGE"}]}]}'
### Quick Start App:
- reference: https://developers.facebook.com/docs/messenger-platform/getting-started/quick-start### Running MongoDB local commands:
- mongo
- show dbs
- Switch to db: use [db name]
- Drop db: db.dropDatabase()
- show collections
- list all entities in collection: db.[collection name].find()### Localhost locations:
- nodeJS app ran at http://localhost:8080
- mongoDB ran at mongodb://localhost:27017