Share via


TypedResults.Unauthorized Method

Definition

Produces a Status401Unauthorized response.

public static Microsoft.AspNetCore.Http.HttpResults.UnauthorizedHttpResult Unauthorized ();
static member Unauthorized : unit -> Microsoft.AspNetCore.Http.HttpResults.UnauthorizedHttpResult
Public Shared Function Unauthorized () As UnauthorizedHttpResult

Returns

The created UnauthorizedHttpResult for the response.

Applies to