post only visible to all other users - iphone

I have integrated facebook with my app and its connecting well. The problem is that the content which I post is not visible when I am looged into it but my friends can see that news. whats the problem?
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
#"123456789", #"app_id",
#"https://developers.facebook.com/docs/reference/dialogs/", #"link",
#"http://fbrell.com/f8.jpg", #"picture",
#"Facebook Dialogs", #"name",
#"Reference Documentation", #"caption",
#"Using Dialogs to interact with users.", #"description",
#"Facebook Dialogs are so easy!", #"message",
nil];
[facebook dialog:#"feed" andParams:params andDelegate:self];
replace 1234567 with my app id.what the problem ?

By default Facebook posts items on your wall and your friends can see those posts in their news feed. Have you tried checking your wall or news feed to see if the posts are available there?

Related

iOS: Facebook Posting Privacy

Does anyone know why when I post a status / message to the current authenticated user in my app, the default privacy that appears is "Only Me" in facebook? I've read and tried their API reference including this: http://developers.facebook.com/docs/reference/api/post/ but my app just stop working. Why is this so?
This is my code to post the user's status(pre-generated):
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
appId, #"app_id",
#"Event Invitation", #"name",
#"Event Invitation", #"caption",
eventInvitationText, #"description",
eventInvitationLink, #"link",
#"http://fbrell.com/f8.jpg", #"picture",
nil];
[self.facebook dialog:#"feed" andParams:params andDelegate:self];
Referring to the link, I had also added the:
#"EVERYONE", #"privacy"
as one of its parameter for privacy but when I add it, the fb dialog will just say that there is an error in my app.
Can you help me guys? thanks in advance..
The user can choose a maximum visibility setting for your app when authorising it to post on their behalf in the auth dialog.- your app can't choose a privacy setting more open than whatever the user chose there
(Nor can your app prompt them to increase the settings but they can change it themselves in Privacy Settings - Apps, Games & Websites on their Facebook profile)

facebook dialog feed custom picture from your app instead of an url

Is it possible to encode a picture from our iPhone to use with facebook dialog feed instead of passing an URL.. !
NSMutableDictionary *params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
#"Blablabla", #"name",
#"Blablabla", #"caption",
#"Blablabla", #"description",
#"http://google.com", #"link",
#"HTTP:CAN IT BE AN ENCODED PICTURE??", #"picture",
actionLinksStr, #"actions",
nil];
[facebook dialog:#"feed" andParams:params andDelegate:self];
There's a reference link for params:
http://developers.facebook.com/docs/reference/api/post/
I've been stuck at the same problem and was quite shocked that there's no support for uploading images. My solution was to upload the picture to my remote web server and use the link that I've got from server.
I'm uploading to Amazon s3 then using that url to post to the feed.

iOS Facebook Request Dialog Not Working

I am following the Facebook iOS tutorial. I'm trying to implement their code:
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
#"Come check out my app.", #"message",
nil];
[facebook dialog:#"apprequests"
andParams:params
andDelegate:self];
The dialog appears, I add my friends, then I click "Send". At this point nothing appears to happen. My friends (test accounts) never receive the notification.
This delegate method is called:
-(void)dialogDidComplete:(FBDialog *)dialog
{
}
Any ideas as to why my friends aren't receiving the notifications?
In essence, what I am trying to do is get people to share this app with their friends. They click on the link and it opens the app in the iTunes app store. Should I be doing this a different way?
Make sure you have a canvas url defined for your app.
This should work. Also make sure your app delegate is set up.
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
APP_ID, #"app_id",
URL_TO_SITE, #"link",
URL_TO_PIC, #"picture",
LINK_TITLE, #"name",
#" ", #"caption",
LINK_DESCRIPTION, #"description",
nil];
[facebook dialog:#"stream.publish"
andParams:params
andDelegate:self];
Claudia is right. In the app settings you do need to fill-in the 'app on facebook' section and provide a canvas URL.
I guess the point is that if you don't do that there is nothing for facebook to direct an invited user to, so it doesn't display the request.
If your app is purely a mobile app then you could just create a simple webpage for the canvas which directs users to the app store.

iOS SDK posting a link & displaying a thumbnail

I've managed to get the Facebook iOS SDK implemented into my project quite nicely with the assistance of the provided FB documentation.
My app's FB integration is quite simple: A Facebook share button, which allows a user to post a link to their FB wall with a user-supplied comment. Nothing earth-shattering or ground breaking.
However, I would like to go one step further. I don't have a thumbnail to display for the link (i.e. my own image URL), but I would like the thumbnail to be automatically selected by Facebook.
Similar to how, from Facebook in a web browser, if you choose to Share a link from CNN.com, Facebook will automatically select thumbnails for the desired page to be shared, AND it even gives you the option to checkbox "no thumbnail".
From the iOS dialog to share the link, I would like the thumbnail to automatically be selected (presumably it's generated from the link that you're trying to share, i.e. FB just grabs images from the page).
Is this possible? Again, I do not want to display "picture" with a supplied image URL in the 'attachment' NSDictionary below because I won't have the image URL. I just want to display a hyperlink and have FB post the link on the user's wall with their comment and have FB supply the thumbnail image (similar to how it would if you posted from a web browser).
Basically the code from Stack Overflow is:
SBJSON *jsonWriter = [[SBJSON new] autorelease];
NSDictionary* actionLinks = [NSArray arrayWithObjects:[NSDictionary
dictionaryWithObjectsAndKeys: #"Always Running", #"text", #"http://itsti.me/", #"href",
nil], nil];
NSString *actionLinksStr = [jsonWriter stringWithObject:actionLinks];
NSDictionary* attachment = [NSDictionary dictionaryWithObjectsAndKeys:
#"a long run", #"name",
#"The Facebook Running app", #"caption",
#"it is fun", #"description",
#"http://itsti.me/", #"href", nil];
NSString *attachmentStr = [jsonWriter stringWithObject:attachment];
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObjectsAndKeys:
#"Share on Facebook", #"user_message_prompt",
actionLinksStr, #"action_links",
attachmentStr, #"attachment",
nil];
[_facebook dialog:#"stream.publish" andParams:params andDelegate:self];
A different approach to this would be to call the Graph API instead of using a dialog. So if you make an HTTP POST to https://graph.facebook.com/me/feed and supply the message and link parameters the image should be automatically selected by Facebook. See https://developers.facebook.com/docs/reference/api/user/#links.
You will have to generate the UI to ask the user to enter the message. If that can work for you then this is the way to go.
I don't think you have to post a picture. Also, what Facebook is doing is getting Open Graph tags (meta tags in the beginning of web documents just for this purpose). You should be able to simply post a link and a message, and it will "lint"- read the meta tags and post the picture, summary, etc. for that web page.
You may try using Open Graph graph actions instead of share dialogs. It will do more of what you want.http://developers.facebook.com/docs/opengraph/

How to post both text, image and link at once on friends' walls via facebook API

How to let someone post on his/her friends' walls via facebook API, similar to instagr.am iPhone application lets you post on your own wall?
How to show a list of friends and allow selecting them?
How to post both text, image and link at once?
As it happens, Facebook has an iOS SDK available, and instructions on how to use that to post feed items (either with an interactive dialog, or with their Graph API).
i did this way. it works fine.. u can post for multiple frnds as well.
NSMutableDictionary* params1 = [NSMutableDictionary dictionaryWithObjectsAndKeys:
<appId>, #"api_key",
#"Happy Birthday....", #"message",
#"http://www.youtube.com/watch?v=wFh-rX_Sfhs", #"link",
#"http://www.99desi.com/wp-content/uploads/2011/03/Happy-Birthday.jpg", #"picture",
#"Many More Happy returns Of the Day...", #"name",
#" Believing hear, what you deserve to hear..", #"description",nil];
[facebook requestWithGraphPath:#"<frnd-ID>/feed" andParams:params1 andHttpMethod:#"POST" andDelegate:self];
u can iterate the above step to post same to multi friends.
hope it helps you...