V
V
Vladislav2015-06-26 19:33:59
FreeSWITCH
Vladislav, 2015-06-26 19:33:59

freeswitch. Are there dialplan examples for outgoing calls?

In the near future it is planned to buy and connect a voip-gateway to a regular mini-ATC. I deal with setting up freeswitch (version for win32 in virtualbox) according to the manual with voipnones, I can't write a dialplan for outgoing calls. There is a multi-channel SIP account (at the moment it is Zadarma). Added new subscribers, included them in the voiptest group. Incoming calls come to the specified internal group of numbers, and outgoing calls do not go through at all.
Here is the /conf/dialplan/office.xml file:

<include>
<context name="office">
    <extension name="from-zadarma">
<!-- если нам звонят на любой номер не более 15 цифр -->
<condition field="destination_number" expression="^(\d{5,15})$">
<action application="bridge" data="group/[email protected]$${domain}"/>
</condition>
    </extension>
    <extension name="out-msk">
<!-- если мы звоним на +7********** -->
  <condition field="destination_number" expression="^(+7\d{10})$">
<action application="bridge" data="sofia/gateway/zadarma/$1"/>
<!-- кладём трубку -->
<!-- <action application="hangout"/> -->
  </condition>
    </extension>
</context>
</include>

Here is a piece of the log where processing is interrupted:
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Absolute Condition [outside_call]
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Action set(outside_call=true)
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Action export(RFC2822_DATE=${strftime(%a, %d %b %Y %T %z)})
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] parsing [public->call_debug] continue=true
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Regex (FAIL) [call_debug] ${call_debug}(false) =~ /^true$/ break=never
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] parsing [public->public_extensions] continue=false
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Regex (FAIL) [public_extensions] destination_number(+7123456789) =~ /^(10[01][0-9])$/ break=on-false
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] parsing [public->public_did] continue=false
a167a244-fce4-4725-9dc6-d43e377509ab Dialplan: sofia/internal/[email protected] Regex (FAIL) [public_did] destination_number(+7123456789) =~ /^(5551212)$/ break=on-false
a167a244-fce4-4725-9dc6-d43e377509ab 2015-06-26 19:09:10.167968 [DEBUG] switch_core_state_machine.c:216 (sofia/internal/[email protected]) State Change CS_ROUTING -> CS_EXECUTE
a167a244-fce4-4725-9dc6-d43e377509ab 2015-06-26 19:09:10.167968 [DEBUG] switch_core_session.c:1388 Send signal sofia/internal/[email protected] [BREAK]
a167a244-fce4-4725-9dc6-d43e377509ab 2015-06-26 19:09:10.167968 [DEBUG] switch_core_state_machine.c:528 (sofia/internal/[email protected]) State ROUTING going to sleep

Complete: pastebin.com/b3gux7rS
I don't understand why there is no "^(+7\d{10})$" in the log at all. I replaced it with 8 (I should have heard at least that the number is not correct), tried to move the plan to subfolders, commented out application="hangout" - no change.
At the same time, the second question: now (group/[email protected]$${domain}) the whole group calls when incoming, how can I send a call only to the first (or random) free internal number registered on the network from this group?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Vladimir, 2015-06-26
@Sabin

perhaps the call falls into the wrong context,
give the full log and show the user settings [email protected]

A
Artem, 2016-01-10
@Cat_Matroskin


will block your mask for nothing, you need to share the contexts for incoming and outgoing.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question