I use fbconsole for authetication on Facebook.
import fbconsole
fbconsole.APP_ID = '1234567890'
fbconsole.AUTH_SCOPE = ['publish_stream', 'publish_checkins', 'read_stream', 'offline_access']
fbconsole.authenticate()
newsfeed = fbconsole.get('/me/home', {'fields':'from,name,description,message'})
newsfeedData = newsfeed["data"]
for status in newsfeedData:
print status['from']['name'];
print status['created_time'];
#print status['name']
print status['message']
#print status.encode("utf-8")
print('##############################################################################')
The status['from']['name']
shows name of friend, but status['message']
shows KeyError. How can I print news from Facebook, if 'status'
is dictionary type and it HAS the 'message'
key??? The same error is printing on 'name'
key.