Skip to content

Commit 893e3df

Browse files
authored
Merge pull request fbsamples#18 from zardra/readme
Readme
2 parents 19353c9 + 67134c6 commit 893e3df

File tree

2 files changed

+14
-12
lines changed

2 files changed

+14
-12
lines changed

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Graph API Webhooks Samples
22

3-
These are sample clients for [Facebook's Graph API Webhooks](https://developers.facebook.com/docs/graph-api/webhooks/) and [Instagram's Subscriptions API](https://www.instagram.com/developer/subscriptions/).
3+
These are sample clients for Facebook's [Webhooks](https://developers.facebook.com/docs/graph-api/webhooks/) product and Instagram's [Subscriptions API](https://www.instagram.com/developer/subscriptions/).
44

5-
1. [Heroku](heroku)
6-
1. [Hubot](hubot)
5+
1. [Heroku](heroku) - A sample client that receives Webhook events.
6+
1. [Hubot](hubot) - A script that messages a chat room when a Facebook Page post is published using Webhooks.

heroku/README.md

+11-9
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
# Graph API Webhooks Heroku Sample
22

3-
This is a sample client for [Facebook's Graph API Webhooks](https://developers.facebook.com/docs/graph-api/webhooks/) and [Instagram's Subscriptions API](https://www.instagram.com/developer/subscriptions/), powered by [Node.js on Heroku](https://devcenter.heroku.com/articles/getting-started-with-nodejs).
3+
This is a sample client for Facebook's [Webhooks](https://developers.facebook.com/docs/graph-api/webhooks/) product and Instagram's [Subscriptions API](https://www.instagram.com/developer/subscriptions/), powered by [Node.js on Heroku](https://devcenter.heroku.com/articles/getting-started-with-nodejs).
44

55
## Setup
66

7-
### Heroku
8-
1. Deploy with this button: [![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/fbsamples/graph-api-webhooks-samples)
9-
1. Test your deployment with `curl https://<your-subdomain>.herokuapp.com` - you should see a list of received webhooks.
10-
1. For handling POST request validation (optional, but suggested), set the `APP_SECRET` [config var](https://devcenter.heroku.com/articles/config-vars) using your app secret value from your [Facebook app's settings](https://developers.facebook.com/apps).
7+
### Facebook Webhooks
118

12-
### Facebook
13-
1. Create a new [Facebook application](https://developers.facebook.com/apps).
14-
1. Set up your Facebook application's [Graph API Webhooks subscription](https://developers.facebook.com/docs/graph-api/webhooks/#setup) using `https://<your-subdomain>.herokuapp.com/facebook` as the callback URL. It is recommended that you set a `TOKEN` [config var](https://devcenter.heroku.com/articles/config-vars) as part of the set up of your Heroku app to secure requests. If you choose not to set a config var, then you will need to set a verify token of 'token' when configuring the callback URL.
9+
1. Refer to Facebook's [Webhooks sample app documentation](https://developers.facebook.com/docs/graph-api/webhooks/sample-apps) to see how to use this app.
10+
1. Deploy the sample app on Heroku with this button:
1511

16-
### Instagram
12+
[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/fbsamples/graph-api-webhooks-samples)
13+
14+
### Instagram Subscription API
1715
1. Register an [Instagram API client](https://instagram.com/developer/clients/manage/).
16+
1. Deploy the sample app on Heroku with this button:
17+
18+
[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/fbsamples/graph-api-webhooks-samples)
19+
1820
1. Set up your client's [subscription](https://www.instagram.com/developer/subscriptions/) using your `https://<your-subdomain>.herokuapp.com/instagram` as the callback URL. It is recommended that you set a `TOKEN` [config var](https://devcenter.heroku.com/articles/config-vars) as part of the set up of your Heroku app to secure requests. If you choose not to set a config var, then you will need to set a verify token of 'token' when configuring the callback URL.

0 commit comments

Comments
 (0)