Error validating access token: Session has expired - nexus
1

I run FB.login and get back a status of connected, an access token, and an expiration date of April. I take the access token and run it through api explorer using debug_token and it reports the token is expired. I don't know what to do. Can anyone shed light on this?

Here is the login code:

  if(response.status != 'connected'){
      FB.login(function(response){
          if(response.authResponse){
              register_page_token("365985286789584", response.authResponse.accessToken);
          }else{
              alert("Linking is required. Please try again.");
              break;
          }
      },{scope: 'email,user_likes,manage_pages'});
  }

Here is the response code:

{"authResponse":{"accessToken":"","userID":"10157697993054351","expiresIn":6261,"signedRequest":"eOXuenY89EZ6hrDVDCQffIBdsJczd3x8HBIlqQvBY90.eyJ1c2VyX2lkIjoiMTAxNTc2OTc5OTMwNTQzNTEiLCJjb2RlIjoiQVFBaE91OE91ZGpUZkdWc1BWcHFIck1aS253UmlZWHdIcHcwbUx1UVc5aG8wb2wwYVJCY3h6RDFWaUF2dlliUHRaLUE0LVpXdXR3RWZCSFcxYmw2anhmR1dXWEZRbnozQ2lncDJPb2dXN0xlNXlJMk0xUXpQX0ZJSHFYWVZQQWdOdGRhekxYMVZaU1o4VkJzRlE2VFhJbGZadzF0UUlsQlhKQ2IyVV82TGdxMVhfQ0Z1LXRwdjVRSk15ZmROMk45bzlpdlJrckl6S0Y3dkplZmZSYUljd1dwNjFsaWMwV3ZuMktDdkZVS25mYmJzQnhrc3VOdnpDNDRBRXZiZ21iQ3NnWWhRM3BLb1hlclBNQXh5SVlrWGRLNkZHZkZ0UDcxZjNRME1YaE1PS2l6cTdVQmh1VEFLNExMZXU1YWVib1F0QlBiclktZHZ2TVJuSGZZR3k0NGJmVUIiLCJvYXV0aF90b2tlbiI6IkVBQUxPaEJLeTN3TUJBTWRCZkduYm5oVFpDcEtkQnZyMjc4Z0NraTR5ZHRoUDBONmY0b3BpWkFwdUtWdkVudHBaQ1VVWkFReDEycVRLVUxPVklvQ3VrWVE1WkNZMldWblRhTnkzV3hLbTI2ZTZrTmtlc2Y3SU4yTzk4dlVtNW85SkN6dmpLMnZubE1sbk5QWkNZSTFWbTdZdlpBNkZiNkVxeGM1U1hyUEUyOU9mVFpDaWVxVUdyUDRTSjFKU29UaTJmUG9LbUpaQzJaQVZFakdnWkRaRCIsImFsZ29yaXRobSI6IkhNQUMtU0hBMjU2IiwiaXNzdWVkX2F0IjoxNTc5Mjg4NTM5fQ","data_access_expiration_time":1586901829},"status":"connected"}

This is what was run in Graph API Explorer:

debug_token?input_token=<;the access token that was returned above>

This is the response from Graph api explorer:

{ "error": { "message": "Error validating access token: Session has expired on Friday, 17-Jan-20 10:00:00 PST. The current time is Friday, 17-Jan-20 11:17:34 PST.", "type": "OAuthException", "code": 190, "error_subcode": 463, "fbtrace_id": "AaFq1F0OGgl58S2X701wjCU" } }

Here is the debug code returned:

==== Query curl -i -X GET \ "https://graph.facebook.com/v5.0/debug_token?input_token=&access_token=" ==== Access Token Info { "perms": [ "user_likes", "email", "manage_pages", "pages_show_list", "public_profile" ], "user_id": "10157697993054351", "app_id": 790016598138627 } ==== Parameters - Query Parameters

{ "input_token": } - POST Parameters

{} ==== Response { "error": { "message": "Error validating access token: Session has expired on Friday, 17-Jan-20 10:00:00 PST. The current time is Friday, 17-Jan-20 11:17:34 PST.", "type": "OAuthException", "code": 190, "error_subcode": 463, "fbtrace_id": "AaFq1F0OGgl58S2X701wjCU" } } ==== Debug Information from Graph API Explorer - https://developers.facebook.com/tools/explorer/?method=GET&path=debug_token%3Finput_token%3D&version=v5.0

Any idea why? Any help would be appreciated.

Mark
Asked about 3 months ago