IPublicClientApplication.AcquireTokenAsync Method

Definition

Overloads

AcquireTokenAsync(IEnumerable<String>)

Interactive request to acquire token.

AcquireTokenAsync(IEnumerable<String>, UIParent)

Interactive request to acquire token.

AcquireTokenAsync(IEnumerable<String>, String)

Interactive request to acquire token.

AcquireTokenAsync(IEnumerable<String>, String, UIParent)

Interactive request to acquire token.

AcquireTokenAsync(IEnumerable<String>)

Interactive request to acquire token.

public System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> AcquireTokenAsync (System.Collections.Generic.IEnumerable<string> scopes);
abstract member AcquireTokenAsync : seq<string> -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public Function AcquireTokenAsync (scopes As IEnumerable(Of String)) As Task(Of AuthenticationResult)

Parameters

scopes
System.Collections.Generic.IEnumerable<System.String>

Array of scopes requested for resource

Returns

System.Threading.Tasks.Task<AuthenticationResult>

Authentication result containing token of the user

Applies to

AcquireTokenAsync(IEnumerable<String>, UIParent)

Interactive request to acquire token.

public System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> AcquireTokenAsync (System.Collections.Generic.IEnumerable<string> scopes, Microsoft.Identity.Client.UIParent parent);
abstract member AcquireTokenAsync : seq<string> * Microsoft.Identity.Client.UIParent -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public Function AcquireTokenAsync (scopes As IEnumerable(Of String), parent As UIParent) As Task(Of AuthenticationResult)

Parameters

scopes
System.Collections.Generic.IEnumerable<System.String>

Array of scopes requested for resource

parent
UIParent

Object contains reference to parent window/activity. REQUIRED for Xamarin.Android only.

Returns

System.Threading.Tasks.Task<AuthenticationResult>

Authentication result containing token of the user

Applies to

AcquireTokenAsync(IEnumerable<String>, String)

Interactive request to acquire token.

public System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> AcquireTokenAsync (System.Collections.Generic.IEnumerable<string> scopes, string loginHint);
abstract member AcquireTokenAsync : seq<string> * string -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public Function AcquireTokenAsync (scopes As IEnumerable(Of String), loginHint As String) As Task(Of AuthenticationResult)

Parameters

scopes
System.Collections.Generic.IEnumerable<System.String>

Array of scopes requested for resource

loginHint
System.String

Identifier of the user. Generally a UPN.

Returns

System.Threading.Tasks.Task<AuthenticationResult>

Authentication result containing token of the user

Applies to

AcquireTokenAsync(IEnumerable<String>, String, UIParent)

Interactive request to acquire token.

public System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult> AcquireTokenAsync (System.Collections.Generic.IEnumerable<string> scopes, string loginHint, Microsoft.Identity.Client.UIParent parent);
abstract member AcquireTokenAsync : seq<string> * string * Microsoft.Identity.Client.UIParent -> System.Threading.Tasks.Task<Microsoft.Identity.Client.AuthenticationResult>
Public Function AcquireTokenAsync (scopes As IEnumerable(Of String), loginHint As String, parent As UIParent) As Task(Of AuthenticationResult)

Parameters

scopes
System.Collections.Generic.IEnumerable<System.String>

Array of scopes requested for resource

loginHint
System.String

Identifier of the user. Generally a UPN.

parent
UIParent

Object contains reference to parent window/activity. REQUIRED for Xamarin.Android only.

Returns

System.Threading.Tasks.Task<AuthenticationResult>

Authentication result containing token of the user

Applies to