Can we play prerecorded message in a call through iPhone app? - iphone

I want to create an iPhone app with following features:
User should be able to make a call to number.
App will play the prerecorded message when call get connected.
After playing the message, line will be connected and user will be able to communicate with the person to whom he made the call.
I heard that Apple doesn't allow the developers to interact with the calling functionality of iPhone but is there any way to achieve this. Please suggest!
Thanks-

You have heard correctly, According to Apple Developer Library, it is not possible to intercept the calling functionality.
Simple Apple does not allow such stuff with current sdk.
Not so sure but, May be possible for jailbroken iPhone app.

Related

Getting notification of iOS device usage in background

Might be i am using a wrong title but i will try to explain here what i want.
In iOS i need to implement a functionality to get notify if the user is using their iOS device.
My app will be running in background using location services and i need to find out if the the user is using their device. It is doable as i have looked into this application which is sending notifications in background to the drivers who is suing their devices while driving.
https://itunes.apple.com/fr/app/cellcontrol/id661169580?l=en&mt=8&ign-mpt=uo=2
So i need similar kind of functionality to find out if a user is using iOS device or not. If anyone of you can suggest me any approach then it would be great for me to start.
Thank you!
Note: I have tried to find out touch events in background but that is not possible as i have done some research on this.
You won't be able to receive touch events when the app is in background using public API's. However, you can do that with the help of mobileSubstrate library ( http://iphonedevwiki.net/index.php/MobileSubstrate - The MobileHooker component is the one that would be used). by hooking your process to the OS. As an example, the display recorder app in Cydia tracks global gestures while recording the screen. This will be a cydia tweak and you will need to jailbreak your device to do all that.
Coming to your specific use-case, the example app you cited should be using one of the exceptions for background applications mentioned in https://developer.apple.com/library/ios/documentation/iphone/conceptual/iphoneosprogrammingguide/ManagingYourApplicationsFlow/ManagingYourApplicationsFlow.html (see the section - "Implementing Long-Running Background Tasks"), probably the one to receive updates from external accessories.

Is there a way/framework to track the SMS (Number/day) and Call data (Minutes/day) on a normal iPhone (Not Jailbroken)

I am a beginner iOS developer and I am trying to build an app which tracks the users SMS (Number) and Call data (Minutes/day) only but have no clue which framework to use. CoreTelephony is of no use as per my knowledge. Any help would be appreciated!
Call Statistics and SMS Statistics are handled by the cell carrier, but are also recorded by the phone and are visible in the settings application. However, there is no way for your app to access this information (as far as i know). It would be a privacy concern and probably won't ever be available. Im sure there is a way to do it on a jailbroken device, but it sounds like thats not what you want. What exactly does your app do?

Incoming call wakes iOS background App?

is it possible to wake an App in the background up, when a call comes in, and access CoreTelephony to send some infos over the web?
I'm practically a n00b in iOS development right now, but got asked a question if iOS is capable to do this. I searched in the iOS reference too, but with no luck.
It would be great if someone with more experience could answer it. Thanks a lot!
Steno
Please, have a look at the document about executing code in the background.
If you go to section "Implementing a VoIP Application", you will see that it is actually possible for your app to be awaken periodically so that it can check if it has anything to do (in your case, if I understand you correctly you would use CTCall to check for calling state).
So, basically, when awaken, your app could check for any incoming call and then use Core Telephony, as you say.
The only trouble about this is that if your app cannot be considered to a a VOIP app, Apple will not let it into the App Store.
It is not possible to have your code run when a call is received.

Are there new API's in the iPhone SDK which allow you to access the iPhone's Call log (Like Agile Reply in the App Store)?

I saw a new app called Agile Reply which allows you to send a sms to the person whom just called you. I didn't buy the app but I don't understand how it would work since as far as I know you can't access the call log through the official iPhone SDK. So my main question is:
Are there new API's in the iPhone SDK which allow you to access the iPhone's Call log?
I know there are similar questions here and here however I didn't know if I should hijack those or start a new one.
Take a look at CoreTelephony. While it won't give you arbitrary access to call logs, you can get notifications of call transitions, which if you can keep at least in the suspended state, may be enough. I don't know how accurate Agile Reply is.
I found the solution here but it doesn't work for iOS5.
http://iosstuff.wordpress.com/2011/08/19/accessing-iphone-call-history/

iPhone answering machine

Is it possible to create an iPhone application to answer incoming voice calls and play audio files back to the caller? If yes, before answering the call, is it possible to determine the caller id?
Thanks!
This is not possible using the SDK. You can most likely do it with a jailbroken app.
iPhone applications (non-jailbreak apps, at least) cannot intercept phone calls. When a phone call is initiated, your app is paused and cannot execute any commands.
Essentially, count on never being able to prevent basic functionality of the iPhone. You can't override texting behaviour, Mail.app behaviour, Safari behavior, etc. because Apple wants the user experience to be consistent (not to mention security issues in allowing an app to answer calls on someone's behalf).