Differentiating incoming providers

Support zone
Post Reply
pablob
Posts: 14
Joined: Sun Jan 01, 2012 2:10 am

Differentiating incoming providers

Post by pablob » Sun Jan 01, 2012 2:18 am

Hi!

I am new to SIP Sorcery (another Voxalot migrant ;)), and I have things working reasonably well with a couple of different DIDs. All of my SIP providers have "myaccount@sipsorcery.com" as the register contact (that is what I want, my ATA is registered with this account so everything rings at my phone). However, I haven't found a good way to recognize from which provider the call is coming, since req.URI.User seems to have the register contact. Is there a standard way to do it?

By the way, is there any reference for all the available functions (like sys.Dial)?

Thanks a lot, and happy new year!

mnipp
Posts: 192
Joined: Sat Oct 03, 2009 9:48 am
Location: NSW Australia

Re: Differentiating incoming providers

Post by mnipp » Sun Jan 01, 2012 2:55 am

Check the help section on this.

http://www.sipsorcery.com/mainsite/Help#Incoming
billion 7404VGP
dialplan (<9*:*>[0-9*][0-9*].T<:@sipbroker>|[0-9*].T)

affinity
Posts: 27
Joined: Fri Dec 16, 2011 5:52 pm

Re: Differentiating incoming providers

Post by affinity » Sun Jan 01, 2012 3:41 am

Just a few extra notes that might help as the page linked to above hasn't been updated to address the "issues" that I had.

When you put in something like "provider_name.fredsin" you also need to add the "@sipsorcery.com" to the end of the entry. This may be an alternate domain than sipsorcery.com but only if that alternate domain was setup appropriately at SS (for use with SS).

Next, processing will look for the full entry and fail to find "provider_name.fredsin@sipsorcery.com" and then it will fall back to "fredsin@sipsorcery.com" which it will find and process as expected provided you have the appropriate "SIP Account" for fredsin and you have it otherwise set up as documented in the above link.

The last thing, a small trap, might be timing. I was getting "wrong" results because something had not fully updated with my settings, it was in the changes of the "Register Contact" in my "SIP providers".

Hopefully Aaron or whomever is responsible can fix the documentation referred to above to make it more clear and easier to get right without needing to come back to the forums again. ;-)

ozimarco
Posts: 51
Joined: Fri Nov 18, 2011 3:49 am
Location: Lower Chittering, WA

Re: Differentiating incoming providers

Post by ozimarco » Sun Jan 01, 2012 8:27 am

affinity wrote:I was getting "wrong" results because something had not fully updated with my settings, it was in the changes of the "Register Contact" in my "SIP providers".
I have learned to be careful when updating anything. When you have SIPSorcery open but haven't touched it for a while and you then go and change something, e.g. in a Dial Plan, and click Update, you may think that the update has happened when it actually has not, the reason being that SS had logged you out because it was left idle. After clicking Update, you always need to scroll up and check that the update has gone through successfully. Any red text in that field means you need to login again and repeat the exercise.
ISP: Telecube ADSL2+, $79 for 250GB (bundled with phone) on regional Telstra exchange
VSPs: MyNetFone, Telecube, Maxotel, Freshtel and others via SIPSorcery
Hardware: Asus DSL-AC68U + Siemens Gigaset A580IP and Yealink T22P.

Aaron
Site Admin
Posts: 4652
Joined: Thu Jul 12, 2007 12:13 am

Re: Differentiating incoming providers

Post by Aaron » Sun Jan 01, 2012 9:38 am

affinity wrote:Hopefully Aaron or whomever is responsible can fix the documentation referred to above to make it more clear and easier to get right without needing to come back to the forums again. ;-)
Done.

Aaron
Site Admin
Posts: 4652
Joined: Thu Jul 12, 2007 12:13 am

Re: Differentiating incoming providers

Post by Aaron » Sun Jan 01, 2012 9:41 am

ozimarco wrote:
affinity wrote:I was getting "wrong" results because something had not fully updated with my settings, it was in the changes of the "Register Contact" in my "SIP providers".
I have learned to be careful when updating anything. When you have SIPSorcery open but haven't touched it for a while and you then go and change something, e.g. in a Dial Plan, and click Update, you may think that the update has happened when it actually has not, the reason being that SS had logged you out because it was left idle. After clicking Update, you always need to scroll up and check that the update has gone through successfully. Any red text in that field means you need to login again and repeat the exercise.
That's a different bug related to session time outs that I need to fix http://sipsorcery.codeplex.com/workitem/7577.

pablob
Posts: 14
Joined: Sun Jan 01, 2012 2:10 am

Re: Differentiating incoming providers

Post by pablob » Mon Jan 02, 2012 9:52 pm

Thanks everyone for their replies! I think I got now. Now I have to think up what interesting processing I want to do. ;)

Happy New Year!

Post Reply