Share via


JobRouterClient.GetJobAsync Method

Definition

Overloads

GetJobAsync(String, CancellationToken)

Retrieves an existing job by Id.

GetJobAsync(String, RequestContext)

[Protocol Method] Retrieves an existing job by Id.

GetJobAsync(String, CancellationToken)

Source:
JobRouterClient.cs
Source:
JobRouterClient.cs

Retrieves an existing job by Id.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Communication.JobRouter.RouterJob>> GetJobAsync (string jobId, System.Threading.CancellationToken cancellationToken = default);
abstract member GetJobAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Communication.JobRouter.RouterJob>>
override this.GetJobAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Communication.JobRouter.RouterJob>>
Public Overridable Function GetJobAsync (jobId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of RouterJob))

Parameters

jobId
String

Id of a job.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

The server returned an error. See Message for details returned from the server.

jobId is null.

jobId is an empty string, and was expected to be non-empty.

Applies to

GetJobAsync(String, RequestContext)

Source:
JobRouterClient.cs
Source:
JobRouterClient.cs

[Protocol Method] Retrieves an existing job by Id.

public virtual System.Threading.Tasks.Task<Azure.Response> GetJobAsync (string jobId, Azure.RequestContext context);
abstract member GetJobAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.GetJobAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function GetJobAsync (jobId As String, context As RequestContext) As Task(Of Response)

Parameters

jobId
String

Id of a job.

context
RequestContext

The request context, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

jobId is null.

jobId is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to