I am trying to use Facebook’s Real Time API with my app. I am not receiving POSTS to my callback url. Some relevant info:
— I can add/modify subscriptions using the callback URL, so the URL itself is not the problem.
— I have granted my app all the right permissions
— I have deliberately included an error at the very beginning of the function that handles POSTs to the callback URL. Yet, I am not getting errors from the function.
From all this, I can only conclude that Facebook is not POSTing to my callback URL. Does anyone have any ideas what else might be going on?
Also, is there any record of Facebook’s attempted POSTs to my callback URL?
I figured out what was wrong. The callback URL I gave to facebook did not have a trailing slash, but the url I specified for my handler function did. In Django, by default, if a request does not match anything from urls.py, it will redirect to the same url with a trailing slash appended. However, POST data is lost in this process, and facebook was trying to POST. I figured this out by manually issuing a POST request to my callback URL, using cURL, at which point Django gave me a very helpful error saying all this.