Facebook Graph API (Tell people about my app) - iphone

Is it possible using the Graph API to tell the my friends about the an app?
I looked through the documentation and I can't find any, maybe I missed it. I can see I can post onmy wall, but nothing regarding sharing a link/app. Thanks

Sharing a link is a part of the Graph API. You can add a lot of variables to a Post request. See the official documentation here:
http://developers.facebook.com/docs/reference/api/post/
As an example, I used the message, link, name, caption, description, and icon properties with the graph API to create this dialog (using the Facebook iOS SDK).

Related

Threads about FB -object, JavaScript SDK, OAauth 2.0 and Graph API?

I cannot understand the FB API. I feel the problem is because I cannot understand the protocals OAouth draft page (source, page 19). Well firstly it was so but now I understand that OAouth 1.0 and OAuth 2.0 are totally different protocols although for the same goal, apparently..
Perhaps the most essential stuff are FB docs about authentication here and a blog post
here. I am trying to categorize here threads to dig deeper into the FB API.
I cannot find things such as picture or friends in the Graph API -object
That’s because you didn’t ask for them …
To get a user’s friends, you have to query the /userid/friends connection.
And for the user’s picture, you can just use the address https://graph.facebook.com/userid/picture as the image src – this will redirect to the actual picture.
It’s all described here: https://developers.facebook.com/docs/reference/api/user/ under „Connections”
I am trying to organize here things.
Trials and some Confusing Points with Questions
Some code here and in history. Logs in history.
[solved] Trial 1 shows a cover picture from FB but not using FB API. FB -object does not store the picture URL! You need to use the POST -url.
[solved] Trial 2 with /userId does not request friends (thanks to one answer) but now a new problem with authorization, solved by this answer here.
[solved] Trial 3 with /userID/friends does not work due to no access-token. Solution here.
[solved] how do the many inner-most FB.login here
to get the access token? Moved this q here.
[solved] what does the __PROTO__ mean? -Unreliable, you are not going to use it (according to the chat -msg in history).
THIRD-PARTY MATERIAL
Manuals
Graph API here
JS SDK here
The OAuth draft paper about the webserver flow here.
FB.login here
Perhaps related
[URL -method] facebook graph api picture
[URL -method] facebook graph api photos retrieve
[URL -method] facebook graph api retrieve wall photos
[PHP] How to use Facebook graph API to retrieve fan photos uploaded to wall of fan page?
[PHP] Pulling in photos via Facebook Graph API
[Unsolved] https://stackoverflow.com/questions/7819091/can-i-retrieve-facebook-photos-through-graph-api-that-are-only-shared-with-frien

Adding facebook comments to my website object

Is there any way I can create comments related to my object, without using the comments plugin? The Facebook Graph API seems like the correct way, but can I link to an object on my web site without actually "posting" that object as a post on facebook? Amazingly, I can't find anyone on the Net with this problem, so perhaps I'm simply doing it wrong.
I'm trying to post to:
https://graph.facebook.com/comments/?ids=http://iesgroup.ca/myappbeta/Item/1799633&message=test&access_token....
I do have the publish_stream permission in the access_token. All I get back is "An unknown error has occurred".
Essentially, I have set up my own web site using the Open Graph protocols. Each item that I have has its own URL with the proper OG tags. For each item, I am able to fetch the comments that facebook has associated with it. But I am unable to actually attach new comments to that object, without using the facebook comment plugin. I'm using my own look-and-feel commenting system, so I am not interested in using facebook's module. I'm using the JavaScript API to fetch the existing comments.
Note, that if I use the Open Graph protocol, users are able to post actions to their timeline, but not actually associate new comments to the object.
Thoughts? Thanks.
The only way I know of is to use the Facebook Graph API and have a Facebook website application and use server-side code to directly re-post comments from your website to the facebook page on an existing Facebook object. It is much more in-depth than the simple Open Graph implementation. But if you don't want to use Facebook's comment module, I don't see any other option. This is a link to the area of making comments, http://developers.facebook.com/docs/reference/api/Comment/ , but this is only useful after you have everything else set up. This is a huge undertaking to get your website to this point, but you will have full control over every aspect of how you interact with Facebook, cause you write your own code. Here is a link to the top level of the FB Graph API so you can read more about it. http://developers.facebook.com/docs/reference/api/
Nick - www.meltedjoystick.com

Post Facebook Comment with Link Preview via Facebook API

Facebook recently added link previews to user comments.
http://www.insidefacebook.com/2011/07/21/facebook-comment-previews/
My question: is there a way to display this link preview using any of the Facebook APIs and publish_stream permission? (Graph, rest, etc)?
I've tried posting a URL in the body of a comment using the Graph API /comments endpoint, but no link preview is shown.
The feature might still be too immature to allow this, but I'm wondering if any one has tried it and got it to work in some way.
Sure. Just post a comment (for example) with youtube video and it will transfer to embed one

Programmatically posting Facebook comments

My application has obtained publish_stream permissions for a Facebook user.
I'd like to allow the user to post comments for a target URL directly from my mobile application, rather than opening up an embedded browser that then shows the Comment Box plugin. That is, the user doesn't necessarily want to post the link to their feed -- rather they want to participate in any Facebook comment discussion that surrounds that URL.
Naturally, I can read the comments for any URL via the Graph API (eg: a techcrunch article) but I do not know how, or if I can add comments to an arbitrary URL programmatically.
Would love to hear any other suggestions or workarounds as well. My hope is to piggy back on Facebook comments to allow my users to have a conversation surrounding URLs of interest to them. If at all possible, I'd also prefer to use Facebook, though I can see using Disqus or similar services would be another possibility.
Use graph api, demo comments here
make POST to
http://graph.facebook.com/comments/?ids=http://techcrunch.com/2011/07/22/big-surprise-the-ipad-trumps-android-tablets-at-the-office/
with field message and value "yourmessage"
I genuine Facebook API bug.
Cannot comment via Graph API on Comments Plugin (Probably try Legacy API)
Graph API

Facebook Graph Post link problems

I'm trying to post a link to the wall of a facebook Page through the graph api.
http://developers.facebook.com/docs/reference/api/post/
Unfortunately the api is not very well documentet so i have some problems:
How do i get the "Share"-action to appear under a link i've posted?
How can i disable thumbnails for the link?
How can i make the caption linked
All those works when posting manually but i havn't found a way to do it through the api. I know it's possible though since i've seen other apps do it.