My question may look a bit strange.
I want to know if, in android, it is possible to know which number has been called when you receive an incoming call (I'm not speaking about caller id).
For example: let's assume that my phone number is 555-12345, my operator will route to my phone every number starting with 555-12345.
This means that you can call me by dialing 555-12345, but also by dialing 555-12345-37967 or 555-12345-34 etc.
Is there a way to know which number the caller has dialed?
If it is not possible to do this using Android API, would be possible to achieve my goal at lower level? Maybe using a customized firmware?
I was searching for this and not found any answer, the sample app (sipDemo) do not handle incoming call too. Fortunately I found the answer:
mSipManager.getSessionFor(intent).getPeerProfile().getUserName()
Good luck ;)
Related
Play store has numerous apps those creates fake call logs.But, sometimes it's important to detect is that call log real or fake to save yourself being a fool. Can anybody tell me how can we detect same?
If these apps are writing to the actual android call log, I don't think there is much you can do against that.
However, you might want to try the below solution, which can maintain your own call list based on the device behaviour.
In Android you can listen for incoming and outgoing calls, using a BroadcastReceiver. Here is a good tutorial for it:
https://www.codeproject.com/Articles/548416/Detecting-incoming-and-outgoing-phone-calls-on-And
If you implement it correctly, you will only receive events from calls being executed for real. So you can save them in your app's call log.
Is there anyway to identify when a call goes from 1-to-1 to multiparty/conference call?
Is any kind of broadcast or event called?
Thanks
Unfortunately, not at the moment. This is managed by the system and is inaccessible to developers. The closest you have is TelephonyManager, but you are only really able to access basic information about the phone. I believe this is mainly for security reasons (so people can't "bug" phones with a simple program), but also because telephony is managed on a lower level, within the kernel.
The information his phone has regarding calls is not shared with your phone at any point doing the call or otherwise, it's shared with the towers. there will be no app or software or hardware for that matter that can do what you need unless it's police sting ray
I have a big list of opt-in numbers.
Some of them are bogus or fake.
I need to write a small app that does the following:-
Read numbers from an excel file
Call each number: if the call gets through (the phone rings or is busy/engaged), we mark the number as valid in a new column in the excel sheet. If the number is invalid, we mark the number as invalid.
Is it possible to achieve this in Android?
Can we get the response status while making a call from the app?
Example: Status=Ringing, Status=Busy/Engaged, Status=Invalid etc
Is there a better way of finding if a phone number is valid or invalid?
You can't. You are unable to call any phone number other way than firing out an intent to invoke device's Phone app do the job, therefore full and smooth automation is hardly possible. You may try to do that and at the same time set up own listener to know if the call succeeded or not, but that's far from what you wanted.
You cannot do it in Android but you can develop it in a cloud-based IVR system using Call Control XML (CCXML) and a platform that has good call progress analysis, like Voxeo. Take a look at this Answer which provides more detail. Be careful with this type of solution as there are laws which govern automatic notification. Make sure people opt in for this type of notification/verification.
I would like to know how to intercept incoming calls and also how to forward them. I know there are several questions regarding this topic here and elsewhere on the net, but all the answers use the android.intent.action.PHONE_STATE action which is broadcast always after the phone begins to ring and the call screen is shown.
That's why I'm looking for a solution where i could intercept the call in an early stage before any notification (ringing etc..) has been done. I would like to know if maybe this is possible on a platform level in native code and if yes how ? Or perhaps with some kind of trick with the SDK ?
In general, if you can't do it in Java, you can't do it in the NDK. Most of the time the opposite is true: You can't do MOST things on Android in the NDK.
I don't know of a way to do that, and frankly doubt it exists: It would be a huge security hole if you could download an application that would forward calls to another number.
You may want to look at this source code, it may help you : http://code.google.com/p/auto-answer/
None of the existing apps in Android can forward a call based on a given number. All they can do is forward all or nothing. There's one app in particular (cBlocker) that can forward calls on schedule besides blocking incoming and outgoing calls and SMS based on rules.
so i was wondering if its possible to for an application that i would write to be constantly running in the background and alter regular phone operations. For example this could be something like as soon as you receive a text from anyone you forward it automatically to another number. Is something like this at all possible?
Just to be clear I don't want to solve that particular problem through some other means, just want to know if apps can accomplish that.
Also if that is possible is it possible for an app that i write to alter more immediate and instant things, like an incoming call.
thanks all for reading this, and hopefully a helpful response :)
It depends on how far you want to go, but I would expect that what you want to achieve probably isn't possible.
The Android OS does reserve some actions and prevent them from being doing programmatically. For example, you can display the Dialer with a number filled in but the user has to press the call button to make a call. Similarly, you can display the SMS app with a message already written but it is up to the user to send the message.
I don't know for sure, but I assume this is for security. For example, let's imagine you could write an application which could start a call with no user interaction. I would release my Super-Handy-Dialer application which makes quick calls for you making you life easier, but what it also would do is wait until 2am and call my premium rate phone line every night for 3 hours.