DeviceCodeCredential.Authenticate Method

Definition

Overloads

Authenticate(CancellationToken)

Interactively authenticates a user via the default browser.

Authenticate(TokenRequestContext, CancellationToken)

Interactively authenticates a user via the default browser.

Authenticate(CancellationToken)

Source:
DeviceCodeCredential.cs
Source:
DeviceCodeCredential.cs

Interactively authenticates a user via the default browser.

public virtual Azure.Identity.AuthenticationRecord Authenticate (System.Threading.CancellationToken cancellationToken = default);

Parameters

cancellationToken
CancellationToken

A CancellationToken controlling the request lifetime.

Returns

The result of the authentication request, containing the acquired AccessToken, and the AuthenticationRecord which can be used to silently authenticate the account.

Exceptions

Thrown when the authentication failed.

Applies to

Azure SDK for .NET Preview e Azure SDK for .NET Latest
Prodotto Versioni
Azure SDK for .NET Latest, Preview

Authenticate(TokenRequestContext, CancellationToken)

Source:
DeviceCodeCredential.cs
Source:
DeviceCodeCredential.cs

Interactively authenticates a user via the default browser.

public virtual Azure.Identity.AuthenticationRecord Authenticate (Azure.Core.TokenRequestContext requestContext, System.Threading.CancellationToken cancellationToken = default);

Parameters

requestContext
TokenRequestContext

The details of the authentication request.

cancellationToken
CancellationToken

A CancellationToken controlling the request lifetime.

Returns

The AuthenticationRecord of the authenticated account.

Exceptions

Thrown when the authentication failed.

Applies to

Azure SDK for .NET Preview e Azure SDK for .NET Latest
Prodotto Versioni
Azure SDK for .NET Latest, Preview