Transform outbound addresses with regular expressions


External trunk configuration

Prerequisites

  • Telephony Admin role

You can use regular expressions to transform the number sent on an outbound call. The normal practice is to enter the same expressions in both the Calling and Called fields. The reason being that you’re formatting the numbers to meet the requirements of your carrier. So, for example, if your carrier requires numbers in E.164 format, you would use the regular expression to force both numbers to be in E.164 format.

As you make these configuration settings, keep in mind the following points:

  • These settings apply to outbound ONLY and the are actually sub-settings under the Outbound section of the Trunk configuration.
  • The Calling address is the number that is calling.
  • The Called address is the number that was called.

Note: You can only use regular expressions to transform the number sent on an outbound call if you are using a BYOC Premises external trunk. For more information, see About BYOC Premises.

For more information, see Examples of regular expression for external trunk number transformation


To configure a regular expression:

  1. Click Admin.
  2. Under Telephony, click Trunks.
  3. Click the External Trunks tab.
  4. From the list, select the trunk you want to configure.
  5. Under External Trunk Configuration, click Identity.
  6. Under Outbound > Calling:
    • In the Match Regular Expression field enter the regular expression pattern you want to match.
    • In the Format Regular Expression field enter the regular expression format form you want your output to take.
    • Click Plus to add the regular expressions to the list.
      • If you want to specify the number of trailing digits of the outgoing address that will be sent, enter that number in the Address Digits Length field.
      • If you want to exclude the + prefix of the outgoing address that will be sent, leave the Address Omit + Prefix switch set to Enabled.
  7. Under Outbound > Called:
    • In the Match Regular Expression field enter the regular expression pattern you want to match.
    • In the Format Regular Expression field enter the regular expression format form you want your output to take.
    • Click Plus  to add the regular expressions to the list.
      • If you want to specify the number of trailing digits of the outgoing address that will be sent, enter that number in the Address Digits Length field.
      • If you want to exclude the + prefix of the outgoing address that will be sent, leave the Address Omit + Prefix switch set to Enabled.
  8. Click Save External Trunk.