Notify Facebook users from iOS app - ios

My iOS app gives the user the option to login using their Facebook account. I would like to be able to see the list with all the friends and invite the ones selected to use the app. The problem is that using the app request window, the friends get a notification that is displayed somewhere in the App Center, rather than in the Notifications panel. Unfortunately, this sort of notification is very subtle and might not be seen only after a long time.
From obvious reasons, I cannot fetch the emails of friends as this would be a great alternative.
Do you know if there is a way to send a Facebook Message or some other sort of notification that is more 'visible' to the receiver? Thanks!

I'm not sure if I completely understand your problem. If it's the problem that I think you're having, it sounds like you need to fill out more information on your Facebook App's configuration page.
From what I remember when I had this same issue, you need to have a Canvas URL set in your Facebook App's configuration page. Even if your app is not going to use Canvas, you need to have that part filled out in order for your friends to receive the app's notification jewel on Facebook.

Related

Initiate Facebook Group Chat from iOS App

I want my app to create a new Facebook group chat with certain people that opens either on Facebook's site in Safari or in the native Facebook app when the user presses a button. I want Facebook to handle the whole chat and my app only to initiate it somehow in the cleanest and least involved way possible. My app already uses the Facebook SDK to open an active FBSession, so I've already got login credentials.
Looking around online and in Facebook's docs, I can't find anything that suits my needs. The closest thing I found was in this answer containing a list of Facebook app URLs you can connect to that open the Facebook app to certain pages. There's "fb://chat/(initWithUID:)" and "fb://messaging/compose/(initWithUID:)". However, not only is there no explanation on how to use these, but people say that Facebook has changed these URLs (and does not have any documentation on them), so they don't work anymore unless I reverse-engineer new URLs (which could change again). Ugh, so close!
I also found examples on starting chats with the Facebook Chat API, but that involves logging into Facebook using some networking framework then writing my own GUI and model for sending messages, which I am only prepared to do as a last resort. There should be some way to let the Facebook app or website do all that. Does anyone know how I can do this?
I've found something very close, but I still don't see a way to make my app initialize it with the desired group of friends:
The Facebook SDK has a message dialog that can appear for sending messages to friends. This isn't exactly what I wanted but is good enough because it means that all the programming is already done for me by Facebook, and users should be able to see these messages on https://facebook.com and the Facebook apps. https://developers.facebook.com/docs/ios/share#message-dialog

Is there an iOS API that can identify which of your contacts are likely other iOS users?

... for example, by finding your contacts that have iTunes logins.
Why? We're launching an app on iOS. We'd like a feature to allow users to connect with their friends who can download and install the app.
No. The closest you might get (from the top of my head) is Game Center. All your friends on there are guaranteed to have an iOS device. Of course, not all iPhone owners use Game Center.
It is possible because Apple uses it in their own apps:
Messages - when typing in an email. The text will appear red if the email you want to iMessage is not setup with iMessage
Find My Friends - same kind of thing
However it's probably a closed API that they're using. It's possible that they use the now deprecated udid retrieval method.
You could try to query an Apple Server for the Apple ID and see what kind of response you get (just a shot in the dark there). Or you could search through GameCenter for a list of friends. Facebook might have some information on which users are iOS users too, take a look at their API and some Facebook profiles to see if theres anything you could check there.

Receive gifts fom friends while in my application

i am trying to implement a "gifting" mechanic in my game. I looked at this and i am able to send requests to friends (even with frictionless dialogs and so on)
My friends are able to receive the requests but the only described way to handle the request is to make them click on the notification in the native FB app and then handle it in my app via the application:(UIApplication *)application openURL:(NSURL *)url
That looks very inconvinient to me!
What if 2 friends sent me a request? Do i have to click them both?
What if I am in the app already? Do i have to go to the FB app click on the notification that brings me back to my app?
So the question is: Is there a way to see all the received requests for my app and handle them accordingly while I am in my app?
I'm a bit confused by your description but I'll give it a shot.
I guess you're trying to send 'gifts' to other users in your app. Do you have some sort of notification mechanism in your app? Similar to how I view a notification when someone posts to my wall on facebook. Once I tap the notification icon and see it, the notification array or whatever it is, is empty. So if I was to go to facebook's site, I wouldn't see any pending gifts.
I would create some sort of notification class that temporarily holds gifts so you can move in and not viewed/not viewed gifts.
Just to clear things:
I got a little confused about the notifications you get when receiving an apprequest and the actual requests. The requests can be viewed and managed via the graph path /me/apprequests
You can view and accept them in your app in an inbox-like way for example.

iOS TWTweetComposeViewController - Posting in background

I'm trying to integrate twitter in iOS5 app.
Using Twitter framework in my app, can I post the message in the background?
I know that using TWTweetComposeViewController, it will show a view and then it will post.
Is this possible?
The answer is no. The whole point of having the View Controller is to allow the User to see and dictate what exactly will be posted without interference from the App apart from the initial text which the user also has the option to change. It stops apps abusing the Twitter accounts from posting spam etc.
The Apple Documentation clearly states:
Although you may perform Twitter requests on behalf of the user, you cannot append text, images, or URLs to tweets without the user’s knowledge. Hence, you can set the initial text and other content before presenting the tweet to the user but cannot change the tweet after the user views it.
You can't do this using TWTweetComposeViewController. You can do this using TWRequest provided the user authorizes your app to access their Twitter account(s).

Send Facebook notification to user who registered on my site via facebook connect

Let me start by saying facebook's developer documentation sucks. Bad.
I'm using the facebooker plugin in rails to let users sign up through facebook connect. Now when certain things occur I want to send notifications to certain users through facebook. I heard some say that notifications must go from one user to another, but I've seen evidence otherwise. I signed up at the site http://www.meetingwave.com/ through fb connect, and now they send me (annoyingly) daily notifications of new things on their site. Also, using the comments widget on my own site www.tmatthew.net, when an anonymous user leaves a comment I get notified of that as well.
So uh, how do you do that? I've been googling all week long and can't seem to find anything. It seems like I should be able to send a notification from my app to one of it's users.
The api call you are looking for is called Notifications.send. The only thing is that they will be disabling it very soon so there is probably no point in implementing it into your application.

Resources