I am using Graph API and I have searched these message boards for hours. I can't seem to figure out How To Delete A Comment From A Blog Post Step-By-Step. Right now, the url I'm putting into the browser is: https://graph.facebook.com/{my_ID}?method=delete&access_token={my_access_token}
(the parts in the parentheses is my actual information)
This is the reply I get: "(#200) Users can only delete their own comments"
I got the public_stream access token by clicking 'Get Access Token" and checking the box that says "public_stream".
Anyone know what I'm doing wrong? Also, once I get past this webpage that allows me access, what is my next step?
Are you trying to delete a comment created by you itself?
In Facebook, delete permission is given to objects (events, comments etc) created by you and those comments and posts created by others on objects owned by you.(comments/posts on your wall, events created by you etc.).
If you want to delete those comments and posts created by others you will need the access token of the owner of those objects.
"once I get past this webpage that allows me access, what is my next step?" this is not clear. Please be specific. Will try to help.
Related
I have a Facebook comment and I would like to get the user ID of the author of the comment. I am able to get this information when the comment is posted on the page that I own with this query:
https://graph.facebook.com/v2.11/comment_id?fields=from&access_token=access_token
However, the same does not work when I am accessing a comment that is not posted on my own page, the from field is never returned. Is it possible to get the author of a comment that is posted on a different page?
Is it possible to get the author of a comment that is posted on a different page?
No, that information is not available to you any more.
https://developers.facebook.com/docs/graph-api/changelog/version2.11#gapi-90-pages:
/page/* — User information will not be included in GET responses for any objects owned by (on) a Page unless the request is made with a Page access token. This affects all nodes and edges that return data for objects owned by a Page.
If you are using a development account you cannot get the from user details of a user who comments on your posts. You can however create test users from your developer account, login with the test account, comment and retrieve their from details.
According to this document an app can delete a post only if it published it. But in this document it is reported that
Extended Permissions give access to more sensitive information and give your app the ability to publish and delete data. All extended permissions appear on a separate screen during the login flow so a person can decide if they want to grant them.
I don't understand if I can I delete users posts logged in with my app?
You can delete any post made via the application you want to issue the delete request from.
Say you use Application A to post status X.
Application B cannot delete status X only Application A can.
The quoted section doesn't really contradict anything. The data it is referring to is any data that application has posted on your behalf.
I am currently attempting to retrieve all the posts on my Timeline via Facebook's Graph API. My Likes and Links and Posts appear to retrieve just fine, but posts from friends do not appear to be displaying.
For instance, a friend shared a link on my timeline, and that is currently not displaying in the returned data in my request to /me/feed.
I've tried turning on all permissions, but can't seem to get that particular post in my return data. Is there something obvious I'm overlooking?
Thank you for any assistance,
Michael
If a users permissions for a post are set to anything other than public if could be omitted from the result set.
Check the privacy for that missing post.
refer to: https://developers.facebook.com/docs/reference/api/privacy-parameter/
me/feed privacy: https://developers.facebook.com/tools/explorer/145634995501895/?method=GET&path=me%2Ffeed%3Ffields%3Dprivacy
Please test with Graph API explorer, https://developers.facebook.com/tools/explorer/?method=GET&path=me%2Ffeed, click "Get access token" button and tick "read_stream" check box under "Extended Permissions" tab. Then submit and proceed authentication process.
After authentication dialog done, click "Submit" and try to test to get the link shared by your friend. I've no problem to see this kind of feed. Of course, you can create a new account and behave as your friend for easier to test, otherwise you need go through pagination to get the target feed.
This is for a page I have the admin rights to. I'm trying to figure out a way to get a list of all of the post IDs and then run a query that deletes them? Basically, I want to purge all of the posts I've ever made on this page without having to do it one by one...because that will take forever.
Is this possible? What's the easiest way? I think there must be a way to use the graph api to grab the IDs and then run the DEL command
Thanks!
Scott
If all posts were made by one application then you can run a loop through https://graph.facebook.com/PAGE_ID/posts and call HTTP DELETE on each post
https://graph.facebook.com/POST_ID?access_token=ACCESS_TOKEN
You can delete a post as long as your application created the post. You delete a post by issuing an HTTP DELETE request to the POST_ID object with publish_stream permission.
So if all posts were not made by an application, this is not possible.
I found a very similar question here: Actions do not appear on timeline, but the solutions offered there are not working for me.
I created a custom graph action and a custom graph object through my Facebook application, and the process of publishing seems to be working fine. When I post the data using the JavaScript SDK with my access token and the object ID, the Facebook API returns the ID of the action, which I can then access on the graph. This side of things is clearly working, since accessing the object via the graph with my app's access token returns all the information it is supposed to.
However, I see no record of this action on Facebook itself; not on my app's timeline, not on the aggregation I set up for this action. The solutions offered in the link above entail double-checking the validity of the meta tags, which I did using the debugger, and also ensuring that there are no URLs within the meta tags that are inaccessible, which is also not the case. Is there anything else that could prevent these actions from showing up on the timeline?
Thanks!
There can be some permission error for facebook (and thus global users) for some url. If you get the action response id, it has to be in your facebook timeline at least (not in others excluding the developers and testers of your app) and it really occurs almost real time.
PS: If you found a similar questions elsewhere, please try to go on with the discussion there instead of creating a duplicate question.