7

I am using Twilio for inbound calls, where user can call an application through Twilio-Number (brought from Twilio) and will be redirected to admin.

Now, We want Admin to call User using same Twilio-Number. We wabt to call this as <Twilio_Number>#<user_id>. We want to pass <user_id> as extension, so that when Admin clicks on the link with tel=<Twilio_Number>#<user_id>, it will initiate a phone-call to twilio-number.

In our app, we will find user's mobile using his id and redirect call to user's mobile number.

I have referred this doc: https://www.twilio.com/docs/howto/companydirectory

But would need few more details like:

How will Twilio recognize the extension number? And by which name is it provided in call-request parameters?

Currently, we received these parameters in twilio-voice call request CallSid, AccountSid, ApiVersion, Direction, To, Called, Caller, From. In the same request-parameters, how I can get extension digits?

Thanks.

Swati
  • 842
  • 10
  • 26

2 Answers2

1

Have you had the chance to review the IVR information provided on Twilio's site? I believe it is a better solution for what you are trying to accomplish.

https://www.twilio.com/docs/howto/ivrs-the-basics

(Please follow the links to the next section at the bottom of the pages.)

After reviewing the documents, please open a support request with specific questions via https://www.twilio.com/user/account/support/ticket/create

Look forward to your ticket.

Take care!

  • Thanks @twilio-technical-support. Yeah I have used dial, gather and other verb in our application for other calls. I just wanted to know is it possible to pass some extra information while calling to twilio-number (may be in the form of extension)? does twilio allows to have it? I will add support ticket for it. Once again thank you for the reply :) – Swati Aug 04 '15 at 08:20
  • @swati: have they answered you something? I have very similar usecase and consider different variants. – gli Nov 20 '17 at 13:29
  • 1
    Here's the archived URL for IVR: The Basics http://web.archive.org/web/20150423204622/https://www.twilio.com/docs/howto/ivrs-the-basics – chemturion Feb 23 '22 at 01:44
1

I don't know if you solved this problem yet (probably yes) but what you can do is, create a record in DB with the extension (id agent) and when Twilio go to your callback url updated the records depending of the state.

Hope this works to you. I'm doing this with the same scenario.