facebook - Trying to authenticate and read newsfeed/timeline (C# Desktop application) -


i trying write c# desktop/forms application reads user's timeline and/or newsfeed.

i have created app user , have used access token tool generate access code app/user.

this code worked ok few days ago

var accesstoken = "<user token goes here>"; var client = new facebook.facebookclient(accesstoken); dynamic me = client.get("me");       string tz = me["timezone"].tostring(); 

but today have error oauthexception - #190 error validating access token: session has expired

from token tool (https://developers.facebook.com/tools/accesstoken/) cannot see how extend token lifespan. nor can delete create new one,

  1. is there way refresh or recreate own token c# desktop application
  2. assuming 1 possible can point me in right direction on how go reading timeline and/or newsfeed.

thanks in advance!

in general, quite hard authenticate user in desktop application. have @ answer question obtaining facebook auth token command-line (desktop) application chance using webview.

it possible exchange short-lived access tokens long-lived ones: https://developers.facebook.com/docs/facebook-login/access-tokens/#extending

concerning questions:

  1. yes, in way descibed in answer linked above
  2. you can use following endpoints, depending on want achieve:


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -