extension to trunk mapping

Discussion in 'General' started by bellew, Jul 26, 2008.

  1. bellew

    Joined:
    Jul 25, 2008
    Messages:
    2
    Likes Received:
    0
    My extensions are the three last numbers from the trunk.
    I have some trunks like these (external numbers from my provider): 352111, 352112, 352113.
    The extensions (internal numbers): 111, 112, 113.
    I want to map extension to trunk - when extension 111 dial something to go though trunk 352111.
    How can I do this?
     
  2. johnryan

    Joined:
    Feb 3, 2008
    Messages:
    15
    Likes Received:
    0
    You might look here...

    It's pretty easy to setup.
     
  3. bellew

    Joined:
    Jul 25, 2008
    Messages:
    2
    Likes Received:
    0
    The described method use prefixes which is ok, but I want to do something like next example but without messing with elastix's macros.

    exten => _X.,1,NoOp()
    exten => _X.,n,Set(LAST="${CALLERID(num)}")
    exten => _X.,n,NoOp(${LAST})
    exten => _X.,n,Set(CALLERID(all)=352${LAST}<352${LAST}>)
    exten => _X.,n,Dial(SIP/${EXTEN}@352${LAST})
    exten => _X.,n,Hangup()

    In the above example if caller is 111 it will go through 352111 SIP trunk without using any prefix in extension.
     

Share This Page