Each folder contains a functioning test app for Node.js, Ruby, and Python. Each uses their respective popular web frameworks, Express, Sinatra, and Flask. To run, do the following:
- Open up your terminal and navigate to the language you're testing:
- For Node.js,
cd node - For Ruby,
cd ruby - For Python,
cd python
- Install dependencies:
- For Node.js,
npm install - For Ruby,
bundle install
- Open up either the
index.js,index.rb, orindex.pyand replace your'WEBHOOK_SECRET'with your webhook secret found in your webhook dashboard after clicking into the the webhook you want to test from that list. - Run the app:
- For Node.js,
node index.js - For Ruby,
ruby index.rb - For Python,
python index.py
- Open up a local tunnel using ngrok to the local port specified after the previous step. Typically, for Node.js it will be port
5000, for Ruby it will be port4567, and for Python it will be port5000. - Set the URL given by ngrok on the webhook dashboard.
- Send a test webhook by selecting the
Pingbutton on the webhook dashboard.