How to initiate a call using freeswitch esl?

im trying to make a simple outgoing call to a simple phone number using esl. but nothing works

I receive incoming events and I can issue different commands ( answer, conference), etc., but originatejust do nothing

There are many different options in the online information itself that are currently not important to me. for now I just need to call. I think I can always add additional options later.

heres stripped-down code (im trying different versions)

SwitchApi("originate", "sofia/external/1011@mydomain.com")
SwitchApi("originate", "sofia/external/17181112222@mydomain.com")
SwitchApi("originate", "sofia/external/17181112222")

Function SwitchApi(Command As String, Arg As String) As ESLevent
    Dim esl = FreeSwitch.Api(Command, Arg)
    Return esl
End Function

ive also tried freeswitch.apiand freeswitch.bgapiif it matters

all these calls, and some other ive tried to return something like

-USAGE: < 'call url > <' exten > | & < 'application_name > (<' app_args > ) [< 'dialplan > ] [<' context > ] [< ' cid_name > ] [< 'cid_num > ] [<' timeout_sec > ]

freeswitch

!

,

SwitchApi("originate", "sofia/gateway/mygateway/1718111222 &park()")
+4

All Articles