Talk:Stream.remove

From Facebook Developer Wiki

Jump to: navigation, search

It says the session id is optional, but via REST it's currently erroring: 'FacebookRestClientException' with message 'A session key is required for calling this method'

Sorry, you need to specify either a session key or a UID. I just updated the doc. Pete (563683308 11:32, 28 April 2009 (PDT))
I tried calling this from the app that created the post, passing in the UID for the post and the post_id, but it still gave the error 'A session key is required for calling this method'. I filed a bug: http://bugs.developers.facebook.com/show_bug.cgi?id=6253. -- Scott
Just making sure, your app has the publish_stream permission? Pete (563683308 00:08, 16 September 2009 (PDT))
Yes, it has publish_stream permission. Once I add a session_key (in my case I'm using a infinite key gained through the offline_access extended permission) I'm able to remove posts, but when I try without passing in a session_key, I get the error. Are you able to delete without a session key? It's also possible its a bug in the library I'm using (Facebooker, a Ruby lib). -- Scott
K, thanks. We'll track it in the bug you filed. And let us know if it is something in Facebooker. Pete (563683308 10:55, 29 September 2009 (PDT))

[edit] Stream.removeComment is more liberal than Stream.remove

Stream.removeComment allows an application to remove any comment on the user's wall (or in my case, page). However Stream.remove only allows application to remove their own posts. So, if you're trying to do moderation via the api, you can remove content, but only comments, not posts. Why the limit?

This is so a malicious application doesn't go around removing posts by other applications. There isn't really an incentive for an application to remove a user's comments as it would to remove another application's story. Pete (563683308 17:41, 6 August 2009 (PDT))


I have publish_stream permission, but still can not remove comment. Is it a bug?
facebook_permissions: ["read_stream","offline_access","publish_stream"]
id 196069581415_160877525591_6710094
text 11/2. good day.
com.google.code.facebookapi.FacebookException: Permissions error
at com.google.code.facebookapi.JsonHelper.parseCallResult(JsonHelper.java:59)
at com.google.code.facebookapi.FacebookJsonRestClientBase.parseCallResult(FacebookJsonRestClientBase.java:51)
at com.google.code.facebookapi.FacebookJsonRestClient.stream_removeComment(FacebookJsonRestClient.java:175)
at com.google.code.facebookapi.FacebookJsonRestClient.stream_removeComment(FacebookJsonRestClient.java:3)
Wei 2009-11-04
Wei, are you calling stream.removeComment or stream.remove? Pete -- 563683308 12:02, 4 November 2009 (PST)
reference