Test User Access Token

To test your re-login flow for people whose tokens have expired, FB Login provides the ability to set a custom expiration period for test user access tokens.

Set an Expiration Period

To set a custom expiration period for a test user access token:

  1. Go to the Dashoard and choose your app.
  2. Open Roles in the left-hand menu, and select Test User.
  3. Click Edit to the left of the test user for whose access token you want to set the expiration period, and in the drop-down list choose Change login expiration time.
  4. In the Login Expiration Time dialog box, set Use Custom Login Expiration Time to Yes.
  5. Enter the expiration period in minutes between 1 and 43,200 (30 days), and click Save.

Now, when you log in as this test user, your access token expires after the number of minutes you entered in the Login Expiration Time dialog box.

Test Your Re-login Flow

When someone's access token has expired, they must renew consent for login by tapping the Continue with Facebook button, and they must agree to permissions again.

To test your app's re-login flow:

  1. Go back to your app and tap on the “Continue with Facebook” button.
  2. Tap OK to accept the read permissions (and OK again to accept write permissions where applicable).
  3. Log out.
  4. Wait for the expiration period you chose.
  5. Open your app and verify that you see the Continue with Facebook button.
  6. Tap the Continue with Facebook button and verify that you see the permissions dialogs again.