Question

This may be a basic question but the answer has alluded me so far.

I'm trying to get the request_id detailed in the return section here http://developers.facebook.com/docs/reference/dialogs/requests/

The app I'm developing is an Android app and as such makes use of the FB Android SDK. I've also looked through the Android Hackbook example here and was unable to find results: (hackbook is in the example folder) https://github.com/facebook/facebook-android-sdk

On the iOS equivalent the response of an apprequest dialog is delivered as a URL which is then parsed and the request IDs are picked from that. I'm looking for the equivalent of that functionality from the Android FB SDK and I've been unable to find it so far either here on stackoverflow or on Google.

The closest I did find was within the hackbook example there is an AppRequestsListener class which contains an onComplete call which takes in a Bundle object. My initial thoughts lead me to assume either the URL I mentioned above or the request IDs themselves are within this bundle however I'm unsure how to extract these pieces of information.

Has anyone done this before and know what I need to do? Any help would be appreciated.

Was it helpful?

Solution

Looking at FbDialog class in the API, I can see that this bundle will contain all the name value pairs contained in the query string of the redirect url. One of these name value pairs will be the request field. I haven't tried this myself yet, but this "request" field in the bundle should be precisely what you need.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top