I am trying to make a webapp in java that is able to send user status to facebook, and I am having some problems with the authorization process. Basically, I have a struts2 action that redirects the user to the facebook login page, which then redirects me to me with "code". Then I use this code to access another facebook url (to trade it for an access token).
The problem is that I probably just missed something simple, that this second facebook url is not redirected to the action, instead it just returns a page with an access token on it. So my question is: how can I access this token for input into my database, preferably without showing the access token to the end user?
TL; DR; Any idea how I could trigger a request from an action in struts2 to an external url and parse the response without showing it to the user? Thank!
Cheers, Lucas Rezek
source
share