Jun 2, 2010 at 5:52 PM
Edited Jun 2, 2010 at 5:53 PM
I am working on an FBML facebook app that needs to be deployed in an environment where the web server (web tier) does not have permission to make outbound calls. I have no control over this. To make it work, I need to set up a web service on a separate
server (app tier) that makes the facebook api calls.
How do I instantiate the facebook api on the app tier? I have the following code running on the app tier and it returns the user, but a lot of the fields are null where they would have data when returned by the call on the web tier.
FBMLCanvasSession session = new FBMLCanvasSession(ConfigurationManager.AppSettings["ApiKey"], ConfigurationManager.AppSettings["Secret"]);
session.UserId = xxxxxxxxxx; //(this is a real ID in my code)
Api faceookApi = new Api(session);
Facebook.Schema.user user = faceookApi.Users.GetInfo();
Since this is run in the context of a web request, I do have all the query string and post parameters that facebook sends. Is it possible to put that information manually in the session object? Is an FBMLCanvasSession even the right type of session object to
be using here?