MakeCall functionality in WebApplication with using 3cx webAPI

Status
Not open for further replies.

Ankit

Joined
Aug 27, 2018
Messages
7
Reaction score
0
Good Day,

I am a programer working with .NET Framwork using Visual Studio .NET 2015.

I had Develop a One project called Dialer . it has functionality for calling system . so now we need to integrate 3cx for controliing phone system with external and internal using our web application.

So I need MakeCall functionality from my WebApplication with using 3cx webapi.

is it possible to make call from our web application interface to external client Or customer ? if yes then please guide us which document Or concept we need to go through ?

Now we had already use Softphone functionality with click to call extension... but now required to develop functionality as described above .
so please guide us and if possible then provide us SDK OR web api where we can setup configuration and integrate 3cx with our web application .

Now I follow this example https://www.3cx.com/docs/call-control-api/

Kind regards
Rohit
 
To do this, there is a example given for MakeCall in the OMSamples folder. Alternatively, you can take a look at our VoIPTools HTTP API which includes an expanded version of MakeCall and MakeCallPlayFile.
 
  • Like
Reactions: Ankit
@voiptoys

So how can i get VoIPTools HTTP API?
And how i'm Using OMSample in my Web Application?

Do you have any suggestions?
 
Last edited:
In order to use the Call Control API to perform actions such as MakeCall, you will need to use the examples in OMSample as a guide. But in general, you will need to connect to the API and then expose they method via a REST API that you create. That's what we did when we created our HTTP API which is part of our Universal Suite of add-ons for 3CX.
 
Hello

i'm Using OMSample in my Web Application
When i Make a call on externsion to Ouside Mobile number, call are going but i can't hear Ringing or voice..
So Do you have any suggestions?

I using this code

Code:
static void Bootstrap(string filePath, string[] args)
        {
            {
                var a = new Random(Environment.TickCount);
                PhoneSystem.ApplicationName = PhoneSystem.ApplicationName + a.Next().ToString();
            }

            #region phone system initialization(init db server)
            var value = Utilities.GetKeyValue("ConfService", "ConfPort", filePath);
            var port = 0;
            PhoneSystem.CfgServerHost = "127.0.0.1";
            if (!string.IsNullOrEmpty(value))
            {
                int.TryParse(value.Trim(), out port);
                PhoneSystem.CfgServerPort = port;
            }
            value = Utilities.GetKeyValue("ConfService", "confUser", filePath);
            if (!string.IsNullOrEmpty(value))
                PhoneSystem.CfgServerUser = value;
            value = Utilities.GetKeyValue("ConfService", "confPass", filePath);
            if (!string.IsNullOrEmpty(value))
                PhoneSystem.CfgServerPassword = value;
            #endregion


            var dns1 = PhoneSystem.Root.Connected;


            Console.WriteLine("result :" + dns1);

        
            OMSamples.Samples.MakeCallSample mk = new Samples.MakeCallSample();

            mk.Run("1129", "8014701087", "8015454196");


            PhoneSystem.Root.Disconnect();
        }

1129 = is my extension
8014701087= daskphone number
8015454196 = my number
 
Last edited:
First, try making a call between two extensions. Your challenge may be because the call is coming from MakeCall rather than an extension so it might not have an outbound rule that matches if your rules restrict by extension number.
 
Also, in my experience with MakeCall, it takes 2 parameters, the extension, and the outside party. I'm surprised to see 3 parameters in your code.
 
Thanks @voiptoys


Yes, I take 3 parameter for make call, because first it ring to deskphone and same time its call to OtherParty number..
The calling are perfact, calls are going to other party but at my side i can't here ringing and anykind of side.. but other side they get call.. but not getting any voice.
 
You should only have 2 parameters: (1) your extension, and (2) the outside party's number. You should not have 3 parameters.
 
  • Like
Reactions: Ankit
upload_2018-9-11_15-47-33.png


When i pass 2 parameter i get that type of issue..

any suggestion?
 
@YiannisH_3CX

Can you help me to integrate 3cx WebApi with webapplication??
 
Hello

I have integrate 3cx web api in my web application
we using MakeCall funtionality in 'OMSamples'
We follow that url and download sample webapi :- https://www.3cx.com/docs/call-control-api/

But when I run "OMSamples". It calls my phone(Deskphone) and when I answer it puts me on hold, then calls my cell. Call does complete successfully but still puts me on hold instead of hearing the ringing

So any suggestion?
 
That's how the Make Call functionality works. It's by design.
 
Status
Not open for further replies.

Latest Posts

Forum statistics

Threads
112,323
Messages
591,896
Members
165,474
Latest member
costionofrei