Facebook Graph API v2.5 : How can I find the post with object_id? Say I create a video with video_id, when I want to delete the video, also want to delete the post attached to it, how can I do that? I am thinking of /me/posts endpoint, but i can't filter the result to narrow down the search.
For who is looking for answer, my solution is to wait for 5 sec (sleep) after you create the video object, look through user's posts and find the post that has that object_id = video_id. The solution is optimized if we can limit the posts to be latest 5 posts then look up on that set.
Related
I'm trying to get all posts from a facebook page for the last two years. Access token is my own which has manage_pages, publish_pages, show_page_list.
The posts are there, they're moderately old early 2016, but, graph doesn't bring them back these older ones. They were scheduled posts, visibility=everyone and of 'photo' type. Any query on {page}\feed, {page}\photos, or {page}\posts yields only a couple of posts.
Facebook Insights Screenshot
https://pasteboard.co/Hde6ZWU.png
Graph Explorer Output Screenshot
https://pasteboard.co/Hde7iDP.png
Does anyone know how to enumerate these posts with graph, or know of the reason why graph isn't reporting them using the get/feed and get/photos command?
These aren’t photos, they are posts.
1409847682673697/posts?since=2016-01-01&until=2016-02-01
shows the first post from your dashboard screenshot, “Andrew Smith - Malta”, just fine.
This is a share of a post onto your page only - the “original” is https://www.facebook.com/andrewmsmithart/photos/a.1533059820295875.1073741827.1533035286964995/1648921165376406/ But since that is not a photo uploaded by your page nor has your page tagged in it, naturally it doesn’t show when you request your page’s photos.
The object_id field of your page post refers the actual photo object.
I am trying to get the feeds from facebook using grpah API by these steps:
Created one post in FB at 24-06-2017 9:00 AM.
I included a since parameter = - 1 day in request.(that means need all the feeds (25-06-2017 9:00 AM onwords) from from API).
Called API to get list of feeds at 26-06-2017 9:00 AM.
Did not get any feeds from API why because did not find any posts in between 25-06-2017 and 26-06-2017.
Now create a comment for existing (24-06-2017 day) post.
Now again fetch the details with same request param(since=-1 day).
Did not get feeds from API response why because API is considering always post created time not updated time.
Our expectation is we should get the feed with updated comment details.
Right now API is considering only post created_time not updated_time.
Please help me to resolve this issue.
To get all the desired information you should have a look at the Facebook Webhooks (https://developers.facebook.com/docs/graph-api/webhooks). They notify your application if a new post or comment is made and you can then poll the needed information, because you have to right ids.
There is no way to resolve your problem with simple polling the Graph API. At least without running into request limits ...
I am getting Facebook posts and their comments from the facebook graph API (I cannot use FQL). I am able to save the posts and their comments successfully into my database. However, I am not able to get the new comments where are there on the post which I dont have in my tables. I tried
postid/comments?time=2014-04-13T00:00:00+0000
postid/comments?since=2014-04-13T00:00:00+0000
postid/comments?since_id=001122334455
but it is still not giving me records after that date. I also referred this post but it does not has a solution.
If you convert your time to a unix time stamp, then it should work.
For instance, the Unix timestamp for the time above is 1428935421
postid/comments?since=1428935421
http://www.onlineconversion.com/unix_time.htm
I'm using Graph API and the closest thing I found is page_fan table. but it's page_id column is not indexable...
Yes, you can get a listing of the page fans (the latest 500) via:
https://www.facebook.com/browse/?type=page_fans&page_id=PAGE_ID
However, this is not via the Graph API.
Many of us have tried and failed to find a way to get a list of users who've liked you page. Facebook seems pretty tight about not letting that information out. Your best bet is to post on your wall and hope your page's wall post is seen on the liked personal feed by facebook algorithm.
I am interested in tracking the user IDs of those who are sharing the wall posts on my fanpage. Does the graph api now support returning the user IDs of the user who have shared the wall post on their wall like I can see who all commented & liked the post?
Any possible workarounds?
yes it's possible you can do through facebook graph api.
http://developers.facebook.com/docs/reference/api/post/
get all post with comments + comment user id + liked user id.
these data managed by your own database.