Starting USSD session after a call - ussd

How can I initiate a ussd session from within a call to a phone number in my ivr?
For example, if a user calls a number and it is answered with a recording, when the call is ended I want to display on the caller's handset (using ussd) a PIN code.
I know this sort of mechanism should be possible as I have tried a demo on site globalussd.com

Related

Answer the second incoming call/conference

I am working with Twilio Voice JS SDK. Every incoming calls are converted to conferences. I can do this.
If there is a second incoming call, I want a user can answer it.
But if I invoke call.accept(), the first call will disconnect.
So I tried to hold the first call by update ParticipantResource.Update() with hold = true. This doesn't help. I listen hold music from browser and the first call is still active.
Is it possible to answer the 2nd incoming call/conference?

Get caller number from app when it is in background or in open state in iOS 10 or below?

I am looking for some source code for iOS 10 and below by which I can get the caller number when some phone call arrived and that call can be rejected by the application, if call is some fraud call (checking the local database). 

I have followed following post but did not get any fruitful result.
Via call kit: how to get the incoming call number by using callkit

True caller app already added that feature:
https://blog.truecaller.com/2016/10/26/truecaller-now-available-on-ios-10/

I think it is possible, can anyone help me by giving some idea or source code by which that can be achieved?
It is not possible to get caller's number when user receives a call. Truecaller has a lot of conditions for it to be able to show caller's details. The truecaller app should be active. The caller should call using the truecaller app. Both the calling and call receiving devices should be connected to the internet.
So what it basically does is that when a user presses the call button on the app to call somebody, they simply send him a notification that this person is calling you. It has nothing to do with CallKit and the caller id is not displayed on the call receiving screen.

Stop / Start call recording on Twilio

Is there an API that I can use to stop recording an ongoing call?
We have a feature here where you can record only pieces of a call. So you can click a button to stop recording, and then after some time you can click another button to start recording again.
How can I accomplish that on Twilio? I didn't find anything in their docs.
Twilio developer evangelist here.
There's no direct way to start and stop recording a call, however you could manage this using <Gather> and <Conference>.
The idea would be that callers would join a conference (even if there's just two of them) which recorded their call using the record attribute.
You would wrap that <Conference> in a <Gather> that was waiting for a caller to dial a particular digit which stops recording by redirecting the caller who pressed the digit to a new <Conference> without the record attribute set.
You will also need to redirect the other call to that conference too. When you get the webhook after the first caller pressed a digit to stop recording you can fire off a REST API call to redirect the second caller to the new non-recorded conference.
If you wrap this second <Conference> in a <Gather> too, you can reverse this process to start recording again.
Let me know if that helps at all.
[edit]
As a further consideration, I realised that you indicated you need a user to press a button to start or stop recording. I initially thought of this as a button on your phone, which is why I suggested using <Gather>. If, however, the user in control of recording is an agent in a call centre, for example, you could build an easier interface using Twilio Client to make or receive the calls.
Then, when the calls are connected into the initial conference you'd need to record both the Call SIDs.
You could then implement a button in your interface that when pressed transfers both calls from a recording conference to a non recording conference (or vice versa). Again, this would use the REST API to redirect the calls.

Phone Call Recording in iOS

In phone.app (iOS Native calling app), Is there any mean by which I can perform task like
1.Identify the caller (Incoming and Outgoing), so that on the behalf of caller I can perform some task.
2.Recording of call.
3.If some audio recording already in running state then how a call record can be handled.?
In my finding a reached at below outcome
1. CTCallCenter class have the information about call but i don't get phone number.
2. Call recording is not possible as there is no Apple API to do so.There are some apps on app store but they are not capable to record the call from phone.app. I think they are recording the call by their server (3 Way call.)
3. I think it will lead towards a crash as phone call is a high priority task so that the control of mic and speaker is given to phone call.
Is there any way to get expected result ? Is it possible with call kit.?
Thanks.
Unfortunately, what you're asking for is not possible as far as I know. Your app can be aware of incoming calls and their states, but not access the phone number. Using the CallKit APIs introduced in iOS 10, you can provide a label for an incoming phone number, but even then you have to set up a predefined list of numbers and labels. Your app won't know which number called. See "Identifying Incoming Callers" in the documentation and this SO question.
As for recording calls, there are no ways to do this without introducing a third party to the call, or routing the call to a service you control.
Regards,
Martin

Use Record and Dial together in Twilio API

I am using Twilio to create call tracking phone numbers that redirect to another number using the Dial verb. I am also recording these calls. Here is an example of my TWIML
<Response><Dial record="true" action="http://example.com/PostCall">555-555-5555</Dial></Response>
I want to be able to terminate the call recording but not the call using something like the Record verb's finishOnKey option. Is this possible?
The reason is, a call comes in to a call center and is transferred to a lawyer. I want to record the call center part of the call but not the attorney/client part of the call. If pressing # during the call could stop the recording but keep the call active it would solve my problem.
Is there a way to stop recording without terminating the call?
Can the record verb be used in conjunction with the dial verb?
The <Record> TwiML verb is best if you want to record one person talking. I'm assuming you want to record both parties connected via <Dial> in the call center so you would rely on the record attribute as you have above.
Read the FAQ for the full breakdown on the difference in recording settings.
Is there a way to stop recording without terminating the call?
Depending on the flow of your call center you might modify the live call via the REST API and redirect the call to new TwiML where you set recording to "false".
call = client.calls.update("CALL_SID", url="https://example.com/no-record.xml",
method="POST")
Alternatively, you could add Twilio itself as a 3rd call leg in a <Conference> call, and let it handle recording. This way you can use the REST API to modify that leg without disrupting the primary 2 callers, including stopping recording of the call midway through while the other 2 callers are still live.

Resources