I am writing an application that needs to post to a Facebook page. I have code that gets a user access token by using the oauth URL below.
With the user access token I then get a page access token. I followed an example in the following link that worked and it works for me (http://thoughts.citynaksha.com/2011/04/post-on-facebook-page-as-page-not-as.html). I get the accounts for the user and then loop though them to find the page access token and then post to it using RestFB.
However, the next time I need to get a user access token, I get an error message such as.
{"error":{"message":"This authorization code has been used.","type":"OAuthException","code":100}}
The user access token I created initially was based on the oauth authorization code I get using a URL such as the one below.