AuthenticationParameters.CreateFromResourceUrlAsync(Uri) Method

Definition

Warning

This API is now obsolete.

Sends a GET request to the url provided with no Authenticate header. If a 401 Unauthorized is received, this helper will parse the WWW-Authenticate header to retrieve the authority and resource.

[System.Obsolete("Please use the static version of this method - CreateFromUrlAsync", false)]
public System.Threading.Tasks.Task<Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationParameters> CreateFromResourceUrlAsync (Uri resourceUrl);
public static System.Threading.Tasks.Task<Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationParameters> CreateFromResourceUrlAsync (Uri resourceUrl);
member this.CreateFromResourceUrlAsync : Uri -> System.Threading.Tasks.Task<Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationParameters>
static member CreateFromResourceUrlAsync : Uri -> System.Threading.Tasks.Task<Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationParameters>
Public Function CreateFromResourceUrlAsync (resourceUrl As Uri) As Task(Of AuthenticationParameters)
Public Shared Function CreateFromResourceUrlAsync (resourceUrl As Uri) As Task(Of AuthenticationParameters)

Parameters

resourceUrl
Uri

Address of the resource

Returns

AuthenticationParameters object containing authentication parameters

Attributes

Remarks

Most protected APIs, including those owned by Microsoft, no longer advertise a resource. Authentication should be done using MSAL, which uses scopes. See https://aka.ms/msal-net-migration-adal-msal

Applies to