Thursday, December 01, 2011

How to create test accounts in Facebook

Hi All,

Facebook now doesn't allow you to test your facebook application without creating test accounts. When you try to test your non published Facebook application and try to post any update you will get this error message:

oAuthException #100 can only call this method on valid test users for your app

To create a test account in Facebook, here is the steps:
1) Copy and paste the following url in your browser:

Before hit enter, do the following:
a) Get the access token for your facebook application, to get it paste the following url in the browser:

b) Permissions: To grant certain permissions to the test account, read the full extended permissions from below link:

If you get an error when you specify a name, you can omit the name parameters and in this case FB will create a name for your test account.

Once you edit above parameters and hit enter in the browser, you will get a message like this showing that your test account has been created successfully.

   "id": "XXXXXXXXXXX",
   "access_token": "XCEWWEE#######EEEEEU8ffOT3VYD70ld0nYCiNlZB5Flmh59yfPksO5XfUdVxnZAhi0oEKvpJxACywhxsNgwGWfe6gH2B1DaxVUSXy2mCfo1jzf3TUk7",
   "login_url": "",
   "email": "cqszpqv_smithwwwqitz_133222765997\",
   "password": "211212121233"

Try to log in with the username and password before run your application.

Hope this helps.

* References:
- How to create test users in Facebook:

No comments: