public VstsAadAuthentication(
Guid tenantId,
VstsTokenScope tokenScope,
ICredentialStore personalAccessTokenStore)
: base(tokenScope, personalAccessTokenStore)
{
if (tenantId == Guid.Empty)
{
this.VstsAuthority = new VstsAzureAuthority(AzureAuthority.DefaultAuthorityHostUrl);
}
else
{
// create an authority host URL in the format of https://login.microsoft.com/12345678-9ABC-DEF0-1234-56789ABCDEF0
string authorityHost = AzureAuthority.GetAuthorityUrl(tenantId);
this.VstsAuthority = new VstsAzureAuthority(authorityHost);
}
}