What is Callback URL in Facebook webhook page subscription?

Karthick Radhakrishnan picture Karthick Radhakrishnan · Jan 13, 2016 · Viewed 27.4k times · Source

I'm trying to stream the real time public feeds using Facebook Web-hook API. Here I'm trying to set up a page subscription in Web-hook console. There is a field called Callback URL. What is this URL about?

I have also tried going through the documentation for Setting up callback URL. but I Couldn't figure out.

https://developers.facebook.com/docs/graph-api/webhooks#setup

Cant the callback URL be SSL localhost? Whenever I try to give a localhost URL i get a error message "Unable to verify provided URL".

Answer

Phil Hudson picture Phil Hudson · Jul 14, 2016

You can forward the request to localhost with the following:

  1. Download and install ngrok from https://ngrok.com/download
  2. ./ngrok http 8445
  3. Subscribe your page to the Webhooks using verify_token and https://<your_ngrok_io>/webhook as callback URL.
  4. Talk to your bot on Messenger!