AcquireTokenByIntegratedWindowsAuthParameterBuilder.WithUsername Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Specifies the username.
public Microsoft.Identity.Client.AcquireTokenByIntegratedWindowsAuthParameterBuilder WithUsername (string username);
member this.WithUsername : string -> Microsoft.Identity.Client.AcquireTokenByIntegratedWindowsAuthParameterBuilder
Public Function WithUsername (username As String) As AcquireTokenByIntegratedWindowsAuthParameterBuilder
Parameters
- username
- String
Identifier of the user account for which to acquire a token with
Integrated Windows Authentication. Generally in UserPrincipalName (UPN) format,
e.g. john.doe@contoso.com
Returns
The builder to chain the .With methods.
Remarks
Specifying the username explicitly is normally not needed, but some Windows administrators set policies preventing applications from looking up the signed-in user and in that case the username needs to be passed.