SipRoutingClient.GetRoutesForNumberAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the list of routes matching the target phone number, ordered by priority.
public virtual System.Threading.Tasks.Task<Azure.Response<System.Collections.Generic.IReadOnlyList<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute>>> GetRoutesForNumberAsync(string targetPhoneNumber, System.Collections.Generic.IEnumerable<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute> routes, System.Threading.CancellationToken cancellationToken = default);
abstract member GetRoutesForNumberAsync : string * seq<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<System.Collections.Generic.IReadOnlyList<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute>>>
override this.GetRoutesForNumberAsync : string * seq<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<System.Collections.Generic.IReadOnlyList<Azure.Communication.PhoneNumbers.SipRouting.SipTrunkRoute>>>
Public Overridable Function GetRoutesForNumberAsync (targetPhoneNumber As String, routes As IEnumerable(Of SipTrunkRoute), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of IReadOnlyList(Of SipTrunkRoute)))
Parameters
- targetPhoneNumber
- String
Phone number to test routing patterns against.
- routes
- IEnumerable<SipTrunkRoute>
New list of SipTrunkRoute.
- cancellationToken
- CancellationToken
Optional cancellation token.