1

I want to setup a conference call, initiating from an ESL program.

In my python script I call the first number :

freeswitchcon.api("originate","sofia/gateway/MySIP/91XXXXXXXXXX+" &conference(9099)"

then I call another number:

freeswitchcon.bgapi("originate","sofia/gateway/MySIP/91XXXXXXXXXX+" &conference(radioHealth_${strftime(%Y-%m-%d)}+flags{mute})"

My Dialplans are:

<extension name="conf_demo">
<condition field="destination_number" expression="^9099$">
<action application="conference" data="radioHealth_${strftime(%Y-%m-%d)}+flags{endconf}"/>
</condition>

<extension name="conf_demo">
<condition field="destination_number" expression="^9098$">
<action application="conference" data="radioHealth_${strftime(%Y-%m-%d)}+flags{mute}"/>
</condition>

I get a call on the first number, but not on the second number. Freeswitch logs are:

2016-04-18 05:37:26.417807 [NOTICE] switch_channel.c:1055 New Channel sofia/external/91XXXXXXXXXX [a22ea00c-0527-11e6-86df-415bf8be0d99]
2016-04-18 05:37:26.777867 [NOTICE] sofia.c:7539 Hangup sofia/external/91XXXXXXXXXX [CS_CONSUME_MEDIA] [CALL_REJECTED]
2016-04-18 05:37:26.777867 [NOTICE] switch_core_session.c:1641 Session 24 (sofia/external/91XXXXXXXXXX) Ended
2016-04-18 05:37:26.777867 [NOTICE] switch_core_session.c:1645 Close Channel sofia/external/91XXXXXXXXXX [CS_DESTROY]

Any guidance would be appreciated

1 Answers1

1

I realise this is a couple of years late, but I noticed that you are calling the normal api in your first originate command:

freeswitchcon.api("originate","sofia/gateway/MySIP/91XXXXXXXXXX+" &conference(9099)"

This means that the first call will be initiated but then python will wait for that call to return (i.e. when it is hung up) before continuing.

If you use freeswitchcon.bgapi, as in your second call, then the call will be originated in the background and python will not wait for the call to end before continuing.

3G Telecoms
  • 303
  • 1
  • 10