<PackageReference Include="Microsoft.Identity.Client" Version="4.85.2" />

Microsoft.Identity.Client.WsTrust.CommonNonInteractiveHandler

public CommonNonInteractiveHandler(RequestContext requestContext, IServiceBundle serviceBundle)

public Task<string> GetPlatformUserAsync()

Gets the currently logged in user. Works for Windows when user is AD or AAD joined. Throws otherwise if cannot be found.

public Task<WsTrustResponse> PerformWsTrustMexExchangeAsync(string federationMetadataUrl, string cloudAudienceUrn, UserAuthType userAuthType, string username, string password, string federationMetadataFilename)

public Task<UserRealmDiscoveryResponse> QueryUserRealmDataAsync(string userRealmUriPrefix, string username)