Get facebook post made by my application and the number of likes/comments on it - facebook

I have a facebook application that I use to post messages on user's wall. I save the post id. I want to know the number of likes and comments on each of these posts?
Do I need a read_stream permission to access my own posts?
What is the best way to do this?

You will need read_stream permission from the user to be able to read the post since the user owns their own status update (and its likes/comments), not your application. If you have read_stream, you can then just access /postID via the Graph API.

Related

How to get my own Facebook user timeline using Graph API?

I would like to get all the posts and updates that are normally displayed in FB official application for MY account (this includes updates from my friends and liked pages).
I wasn't able to find any details how to get that, the only thing I've managed to get is my own posts.
Anyone got any experience with that using current Graph API verion (3.3)?
All the alternate FB clients (ex. Friendly) must be doing this somehow.
There is no way to get ANY data of users who did not authorized your App. Which means, there is no way to get posts of friends. You can only get your own friends, with the user_posts permission and the /me/posts endpoint. If some Apps access friend data without their authorization, they are most likely doing something that is not allowed.
Here is what I found in their API docs:
There are two scopes:
The user feed requires the user's permission
The public feed has fewer capabilities but doesn't require perms

Is there any way to reach my friends' photos in Facebook using the API?

I am trying to reach my friend's photo in an application. I gave all permissions to this application but Facebook needs friend's permission for access to photos.
So is there anyway to fix this? Can I take a special permission from Facebook?
As mentioned in the comments, your friends need to login to your application and grant the necessary permissions to access their photos.
So, no, there is no way to do it with a special permission.

Is publish_actions required to post on user own wall? Facebook API

When requesting publish_actions permission the message says the app is willing to post on your friends' wall but I actually just want my app to let the user post videos on his own wall. Do I need this permission to do so?
If you just want to share a Link (to a Youtube Video, for example), you can just use the Share Dialog - no authorization or permissions needed: https://developers.facebook.com/docs/sharing/reference/share-dialog
If you want to upload a photo or video, you will need to authorize the user with publish_actions. Keep in mind that the message must be 100% user generated.
Check out the "Publishing" part of the Facebook docs: https://developers.facebook.com/docs/graph-api/reference/v2.1/user/videos
A user access token with publish_actions permission can be used to publish new photos.
...well, that is actually a bug in the docs, it should be "videos", not "photos", of course. I´ve filed a bug report for this: https://developers.facebook.com/bugs/303448543173296/
General information about sharing: https://developers.facebook.com/docs/web/share
Do you use standards dialogs? According to the facebook api documentation you don't need this permission for theses dialogs.
(see: https://developers.facebook.com/docs/facebook-login/permissions/v2.1#reference-publish_actions)
If you use the Facebook Graph API you don't need this permission if you only want to post on the user feed.

How to post to a user's wall at a later date

I'm trying to figure out how, after a user has opted into my Facebook Application, to retain their credentials so as to post to their wall at a later time. I see apps doing this all the time, but I'm unclear where/how they store the user's login (I'm guessing they're not actually holding on to U/P but rather just have some key to post to the user's wall), and then do the post at some later time.
I'm unable to find the documentation for how to do this at the facebook developer site and am hoping someone can point me in the right direction.
TIA
Ask for publish_stream permissions then post to that user's wall using your "app" access token if the user access token has expired.
Facebook documentation here: http://developers.facebook.com/docs/reference/api/permissions/
publish_stream
Enables your app to post content, comments, and likes to a user's
stream and to the streams of the user's friends. With this permission,
you can publish content to a user's feed at any time. However, please
note that Facebook recommends a user-initiated sharing model.

Facebook privilages for getting messages from wall

I created simple facebook app which asks user for user_about_me, user_activites and user_status privilages. Now I want to get all my wall posts, so I make a request and receive only some of my profile data, but without wall posts. I noticed that my access_token is different from the one I can get in documentation: https://developers.facebook.com/docs/reference/api/.
What should I change?
You need read_stream permission.
http://developers.facebook.com/docs/reference/api/permissions/
read_stream Provides access to all the posts in the user's News Feed and
enables your application to perform searches against the user's
News Feed