问题
I'm trying to create a test user for my facebook web application. (apps.facebook.com/<myappname>
).
I browsed my firefox browser to the following URL:
https://graph.facebook.com/<app_id>/accounts/test-users?installed=true&access_token=<app_id>|<app_secret>
I got the following result:
{ "error": { "type": "OAuthException", "message": "(#15) This method is not supported for native apps" } }
any ideas?
thanks
回答1:
Are you sure your application is configured correctly in http://www.facebook.com/developers? (See Canvas Tutorial)
Have you tried using the application access token? To get this use:
https://graph.facebook.com/oauth/access_token?client_id=YOUR_APP_ID&client_secret=YOUR_APP_SECRET&grant_type=client_credentials
substituting YOUR_APP_ID & YOUR_APP_SECRET with your respective values.
This will return a valid access token that you can substitute for APP_ACCESS_TOKEN in:
https://graph.facebook.com/APP_ID/accounts/test-users?installed=true&name=FULL_NAME&method=post&access_token=APP_ACCESS_TOKEN
来源:https://stackoverflow.com/questions/7075613/creating-test-users-method-is-not-supported-for-native-application