java - How to extract on the public page owner's posts on restfb? -


i have working restfb java program can extract posts. extract posts posted in wall, including owner of page. ok less popular pages, popular pages, fan posts. example, if extract posts https://www.facebook.com/gameofthrones, 199 out of 200 posts fan posts.

i have if loop check name of person page id different post owner's id.

is there generic , efficient way of doing this? hoping there parameter or filters out fan posts on public page.

here have now:

    facebookclient fbclient = new defaultfacebookclient(access_token, version.version_2_3);       connection<post> message = fbclient.fetchconnection(name + "/feed", com.restfb.types.post.class, parameter.with("limit", 200));      list<post> detailedpost = message.getdata();      ....     (int = 0; < detailedpost.size(); i++) {         string id = message.getdata().get(i).getid();         personposted[i] = detailedpost.get(i).getfrom().getname().tostring();          if (personposted[i].equals(name)) {         ...         }    } 

https://developers.facebook.com/docs/graph-api/reference/v2.3/page/feed:

/{page-id}/feed

the feed of posts (including status updates) , links published page, or others on page. there other edges provide more specific sets of posts:

  • /{page-id}/posts shows posts published page.
  • […]

Comments

Popular posts from this blog

c# - Validate object ID from GET to POST -

node.js - Custom Model Validator SailsJS -

php - Find a regex to take part of Email -