Reply To: RE: Multiple DID's on Vitalpbx

VitalPBX Community Support General Discussion Multiple DID's on Vitalpbx Reply To: RE: Multiple DID's on Vitalpbx

    TrustedbyU
    Participant
    Up
    0
    Down

    Not sure if you have sorted this, but i had a similar problem in the past with a UK SIP provider.

    It turned out that they were sending the number strangely in the headers. It didn’t matter what number was being dialled, it was reporting my customer ID / Trunk ID as the DID in the invite. However it was sending the information in the SIP headers. I had to hack together a little script that pulled the number from the header for the route to use. You will be able to tell if that’s the case by creating a default catchall route and see if it works. (any DID / CID)..

    in file /etc/asterisk/ombutel/extensions__custom.conf

    [default-trunk]
    exten => s,1,Noop(Fixing DID using information from SIP TO header)
    exten => s,n,Set(pseudodid=${SIP_HEADER(To)})
    exten => s,n,Set(pseudodid=${CUT(pseudodid,@,1)})
    exten => s,n,Set(pseudodid=${CUT(pseudodid,:,2)})
    exten => s,n,Goto(default-trunk,${pseudodid},1)

    Above fixed the issue for me if that’s the case 🙂

    HTH.

    0