Share via


RedTeams.GetAsync Method

Definition

Overloads

Name Description
GetAsync(String, RequestOptions)

[Protocol Method] Get a redteam by name.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
GetAsync(String, CancellationToken)

Get a redteam by name.

GetAsync(String, RequestOptions)

Source:
RedTeams.cs

[Protocol Method] Get a redteam by name.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual System.Threading.Tasks.Task<System.ClientModel.ClientResult> GetAsync(string name, System.ClientModel.Primitives.RequestOptions options);
abstract member GetAsync : string * System.ClientModel.Primitives.RequestOptions -> System.Threading.Tasks.Task<System.ClientModel.ClientResult>
override this.GetAsync : string * System.ClientModel.Primitives.RequestOptions -> System.Threading.Tasks.Task<System.ClientModel.ClientResult>
Public Overridable Function GetAsync (name As String, options As RequestOptions) As Task(Of ClientResult)

Parameters

name
String

Identifier of the red team run.

options
RequestOptions

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

Returns

The response returned from the service.

Exceptions

name is null.

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

Service returned a non-success status code.

Applies to

GetAsync(String, CancellationToken)

Source:
RedTeams.cs

Get a redteam by name.

public virtual System.Threading.Tasks.Task<System.ClientModel.ClientResult<Azure.AI.Projects.RedTeam>> GetAsync(string name, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.ClientModel.ClientResult<Azure.AI.Projects.RedTeam>>
override this.GetAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.ClientModel.ClientResult<Azure.AI.Projects.RedTeam>>
Public Overridable Function GetAsync (name As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ClientResult(Of RedTeam))

Parameters

name
String

Identifier of the red team run.

cancellationToken
CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Exceptions

name is null.

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

Service returned a non-success status code.

Applies to