cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements

3021
Views
35
Helpful
12
Replies
akhalil9
Beginner

Voice translation - how to strip 00 and country code from Telco incoming calls SIP Trunk

We are sharing the Cube across many sites across Europe :

 

Would like to know how to strip 00 and country code from Telco  incoming calls on SIP Trunk

 

Below is the translation rule  in use

 

voice translation-rule 1
 rule 1 /^\+\(.*\)/ /00\1/
 rule 2 // //

 

voice translation-profile Prefix_Intl_Calling
translate calling 1

4 ACCEPTED SOLUTIONS

Accepted Solutions

This would not be an all that easy feat to achieve as the country code can be all from one to three digits long depending on what countries that you accept calls for in your SBC. If all of them have a two digit country code it’s easy, just change the rules to strip out 00 and then two more digits with this.

voice translation-rule 1
rule 1 /^00..\(.*\)/ /\1/

Your original rule 2 does nothing, so that can be removed all together.

However I would strongly advise you to rethink your approach here and change the calling number presentation to keep the country code and display the calling number to the called party in E.164 format. The benefit of this is that it’s a uniform and standard way of showing the number and it’s universal routable with the proper configuration in your CM. To do this you can use this translation.

voice translation-rule 1
rule 1 /^00\(.*\)/ /+\1/



Response Signature


View solution in original post

in that case, you need to add rules to match each county.. with just one rule you wont be able to achieve it. As @Roger Kallberg mentioned county code can one, two or three digits. For US its 1, for my region its 968, for uk 44 etc...  With just single rule you wont be able to achieve it. make rules to match the countries which share your Trunk.

 

For example, if my sip trunk shared by oman, uae and uk. to remove the 00and country code.The below could be my rule. If in case isp send the calling information without 00, to strip the country code i will add rules from 4-6.

 

voice translation-rule 1
rule 1 /^\0044\(.*\)/ /\1/
rule 2 /^\00968\(.*\)/ /\1/

rule 3 /^\00971\(.*\)/ /\1/

rule 4 /^\44\(.*\)/ /\1/
rule 5 /^\968\(.*\)/ /\1/

rule 6 /^\971\(.*\)/ /\1/

 

 

 



Response Signature


View solution in original post

Many thanks for you time Nithin Eluvathingal , great help and quick response, If we have to move fast and can not wait for the carrier to update in time will use the translation patterns. Best regards

View solution in original post

12 REPLIES 12
Nithin Eluvathingal
VIP Advisor

You current rule is to add 00 in place of +.

 

voice translation-rule 1
rule 1 /^\+\(.*\)/ /00\1/
rule 2 // //
jlrvg#test voice translation-rule 1 +0012345
Matched with rule 1
Original number: +0012345 Translated number: 000012345
Original number type: none Translated number type: none
Original number plan: none Translated number plan: none

 

 

I modified your translation. See the new rule and the result  below. Not sure if this is what your are trying to achieve.

 

voice translation-rule 1
rule 1 /^\+\(.*\)/ /\1/
rule 2 /^\00\(.*\)/ /\1/
jlrvg#test voice translation-rule 1 +12345
Matched with rule 1
Original number: +12345 Translated number: 12345
Original number type: none Translated number type: none
Original number plan: none Translated number plan: none

jlrvg#test voice translation-rule 1 +0012345
Matched with rule 1
Original number: +0012345 Translated number: 0012345
Original number type: none Translated number type: none
Original number plan: none Translated number plan: none

jlrvg#test voice translation-rule 1 0012345
Matched with rule 2
Original number: 0012345 Translated number: 12345
Original number type: none Translated number type: none
Original number plan: none Translated number plan: none

 



Response Signature


Sorry I was not clear,   so after 00 we have country code 

 

like 0044   or 00 34  and 0033,

 

so per country we like to  display to use local number only with 00 and country code

with out 00 and country code I mean 

 

This would not be an all that easy feat to achieve as the country code can be all from one to three digits long depending on what countries that you accept calls for in your SBC. If all of them have a two digit country code it’s easy, just change the rules to strip out 00 and then two more digits with this.

voice translation-rule 1
rule 1 /^00..\(.*\)/ /\1/

Your original rule 2 does nothing, so that can be removed all together.

However I would strongly advise you to rethink your approach here and change the calling number presentation to keep the country code and display the calling number to the called party in E.164 format. The benefit of this is that it’s a uniform and standard way of showing the number and it’s universal routable with the proper configuration in your CM. To do this you can use this translation.

voice translation-rule 1
rule 1 /^00\(.*\)/ /+\1/



Response Signature


View solution in original post

Many thanks Roger Kallberg,   It would be handy to keep E.164 format  for Jabber and Webex calling from outlook etc but user do not prefer international codes so we will work with carrier to apply a fix on their end.

Not clear what you really need. 

 

 



Response Signature


in that case, you need to add rules to match each county.. with just one rule you wont be able to achieve it. As @Roger Kallberg mentioned county code can one, two or three digits. For US its 1, for my region its 968, for uk 44 etc...  With just single rule you wont be able to achieve it. make rules to match the countries which share your Trunk.

 

For example, if my sip trunk shared by oman, uae and uk. to remove the 00and country code.The below could be my rule. If in case isp send the calling information without 00, to strip the country code i will add rules from 4-6.

 

voice translation-rule 1
rule 1 /^\0044\(.*\)/ /\1/
rule 2 /^\00968\(.*\)/ /\1/

rule 3 /^\00971\(.*\)/ /\1/

rule 4 /^\44\(.*\)/ /\1/
rule 5 /^\968\(.*\)/ /\1/

rule 6 /^\971\(.*\)/ /\1/

 

 

 



Response Signature


View solution in original post

Many thanks for you time Nithin Eluvathingal , great help and quick response, If we have to move fast and can not wait for the carrier to update in time will use the translation patterns. Best regards

View solution in original post

Not sure if you will have a great success with having your service provider make changes for this on their end. In my experience they are pretty square and do not have much will to accommodate changes that their customer ask for. I would simplify accept the number format you get and make whatever changes you see fit on your gateway with voice translation rules.

Apart from this, why did you mark your own reply as an answer to your question?



Response Signature


Sorry for marking my reply as answer was trying to accept  your reply to stop the email chain. thanks again for  guidance.

FYI You can deselect your own answer as an answer.



Response Signature


Create
Recognize Your Peers
Content for Community-Ad