I want to alert the user about an sms while my app is running. I am a bit confused if it is possible to get an SMS notification while the app is running. Which API should I use if this is possible?
It's not possible with the public API. There is no public API for it.
You might be able to do it via private API on a jailbroken device; I really don't know. If so, keep in mind that you won't be able to ship an app using that API in the app store.
Related
When seeing EMBRACE+ , I wonder how it can get all event notifications on iOS . Some system event notifications and third-party application notifications ,without JailBreak and private APIs.
Thanks for any replies.
I thought it maybe is a BT2.1 device.So the developers can use Message Access Profile (MAP) to read the calls , messages and Email...
As for the facebook or skype,I thought that this APPs have their SDK for developers to read the notification.
Sorry for my poor English.
I need to detect on iOS the incoming number during ringing to use it into an action.
It is possible in iPhone?
No, Apple do not provide an API for this.
No its not possible to track incoming phone calls in iphone sdk. If you do this with some private API your app will get rejected from app store.
I would like to ask some suggestions to the experts who have faced similar problem as mine.
I am developing an iPhone application almost like a social networking application. This requires inviting friends to the application. The application is integrated with Facebook for login purpose. My question is that,
1) We can identify the Facebook friends who are using our application. We need to send notification (push notification) to iPhones of the friends who are using our application. Our backend is deployed in AWS. So that we have SNS and SQS for notification purpose. But it supports email and SMS notifications. I came to know from the web that there is Apple push notification services. Can we use apple push notification for this purpose? Which one is preferred here? SNS or apple push notification. Please advice. If you have any reference sites please give it to me.
To send APNS you need to have token of the device, so you can't send such notification just with the information about Facebook account. But if you are able to know that person is friend from Facebook and he uses your app, you can store some data, like token and facebook login of every user to send them APNS. But! Apple may reject it, because they hate when developers collect data that can identify a person.
APNS is nice for that situation, but risky. (Can anyone proof me wrong or right?)
Email is old-fashioned, but legal and easy to implement, i guess. Like, twitter sends push and email.
Also, you can use Facebook features (not so nice if you will integrate more social networks)
I think that you can use AWS SNS and APNS for what you want to do. You will need the pushTokens for the app/device that you are wanting to send push notifications as they act as the identifiers for the specific app/device to use as an endpoint.
You need to set up an SNS topic. Then you need to subscribe the devices (with the apps of interest) to the topic. Then you can publish to the topic (either programatically or via AWS Management console) and that message will propagate to all of the topics subscribed devices (termed endpoints).
AWS has a tutorial that walks you through this process: I have not tried it yet myself.
http://docs.aws.amazon.com/sns/latest/dg/mobile-push-apns.html
I need to create an app which enables the caller in the other end to hear music while I press hold on my iPhone. This music will be selected from my library. Is there any API or anything which can help me with this?
There is no public iOS API by with an app can either send or receive audio from the Phone app during a phone call. The security sandbox will prevent even a private API from doing this on a stock OS device.
After a review of the iPhone SDK documentation, I have not yet found a way for an application to be written such that it can programmatically process the content of an incoming SMS message within the iPhone platform. The idea would be for such an application to be running in the background and based on specifically formatted SMS messages would be able to take specific actions.
Does anybody know if this is possible with an iPhone SDK application and if so, provide a pointer to information about how this can be done?
Unfortunately, you cannot intercept - or be notified of - incoming SMS messages with the iPhone SDK.
One possible alternative, is to register a custom URL scheme that launches your application when a url with that scheme is embedded in the sms message and the user cicks on it.
to set a custom url scheme, you must implement both the CFBundleURLSchemes and CFBundleURLName keys in your application's info.plist.
In your Application's delegate, you can then implement the application:handleOpenURL: method to get any paramaters that were passed to your App from the url in the SMS message.
I believe that currently the SDK doesn't allow for background apps (except for apple ones).
BREW and J2ME had (and probably still have) ways to launch your app via specially formatted SMS, which may be what the Jeff is referring to.
Apple does have the upcoming Push Server which will allow you to send the user an alert which will give them the option of launching your app, but you cannot launch your app for them.
Unfortunately just registering an URL scheme dosn't help you at all, because the SMS app makes "http://" urls clickable only...
You can use CoreTelephony framework.But you must user some private api.And I have some demo code for this. https://github.com/edison0951/AppNotifyBySMSDemo