<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#339999" bgcolor="#FFFFFF">
    <font face="Verdana">Hi list,<br>
      <br>
      I have found the solution by myself. It will be useful to have
      answer here. The correct DIALPLAN extension is in this case<br>
    </font><br>
    <font face="Verdana"><font face="Verdana"><extension
        name="Loopback"><br>
            <condition field="destination_number"
        expression="^(5000)$"><br>
            <action application="bridge"
        data=<a class="moz-txt-link-rfc2396E" href="mailto:sofia/internal/${destination_number}@192.168.8.29">"sofia/internal/${destination_number}@192.168.8.29"</a>/><br>
        </extension><br>
        <br>
        Where device at 192.168.8.29 is the SIP client registered to FS
        at 192.168.8.6 like user 1005. Using such DIALPLAN
        <extension> the call incoming from SIP client with
        destination number 5000 is immediately routed back to the SIP
        client at 192.168.8.29.<br>
        <br>
        My estimation is that FS in this case searches in SIP profile
        "internal" for all registered clients and when founds the one
        with IP 192.168.8.29 it is used to route the call there using
        destination number for this outbound call.<br>
        <br>
        Regards<br>
        Petr B.<br>
        <br>
      </font></font>
    <div class="moz-cite-prefix">Dne 29.05.2018 v 18:31 Petr Both
      napsal(a):<br>
    </div>
    <blockquote type="cite"
      cite="mid:f60a967e-0d72-5eb3-21b5-a085f7b8a09e@antek.it">
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
      <font face="Verdana">Hi list,<br>
        <br>
        I'm already searching in FS manual several hours but cannot find
        the solution.<br>
        <br>
        My task is to receive SIP call from remote SIP device
        (registered to FS like User: <a
          class="moz-txt-link-abbreviated"
          href="mailto:1005@192.168.8.6" moz-do-not-send="true">1005@192.168.8.6</a>),
        using DIALPLAN route it back to SIP channel with the same (or
        increased) destination_number back to the remote SIP device.
        I.e. make such simple loopback in FS.<br>
        <br>
        Tested DIALPLAN extension is <br>
        <br>
        <extension name="Loopback"><br>
            <condition field="destination_number"
        expression="^(5000)$"><br>
            <action application="bridge"
        data="sofia/$${domain}/1005"/><br>
        </extension><br>
      </font><br>
      <font size="+1">The call is looped back to SIP channel but with
        destination_number 1005. Is there any way to enforce to this
        bridged outbound call the destination_number based on
        destination number of inbound call (which comes with destination
        number 5000) ?<br>
        <br>
        Thank you in advance<br>
        <br>
        Petr B.</font><br>
      <br>
      <!--'"--><br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
<a class="moz-txt-link-abbreviated" href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a>

Official FreeSWITCH Sites
<a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://confluence.freeswitch.org">http://confluence.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://www.cluecon.com">http://www.cluecon.com</a>

FreeSWITCH-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a>
UNSUBSCRIBE:<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a>
<a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a></pre>
    </blockquote>
    <br>
  </body>
</html>