Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How get all fields Api-Graph v2.8 of Facebook

I want to try something that looks like this:

GET/v2.8/PageFacebook/posts?fields="all??"

This is because by default it does not bring me the "name" or "type" of the post. And I don't want to do the field-by-field consultation.

like image 918
Andy Avatar asked Mar 06 '17 19:03

Andy


1 Answers

If you want to have the list of all available fields, you need to do a query on a Post Id like this:

GET/v2.8/PostId?metadata=1

Then you can make your selection and specify which fields do you want in your future request. For instance:

/GET/v2.8/PageFacebookId/posts?fields=id,promotion_status,target,shares,message_tags,source,place,event,parent_id,reactions.limit(0).summary(true),child_attachments,message,caption,story,full_picture,picture,link,name,description,type,status_type,created_time,comments.limit(0).summary(true),sharedposts,privacy,updated_time,story_tags,permalink_url,coordinates

like image 50
SamHecquet Avatar answered Nov 02 '22 08:11

SamHecquet