Tag: outlook restapi

无法以静默方式获取令牌。 调用方法AcquireToken

我试图从outlooo 365 API获取一些日历项目 我从样本中得到的代码是这样的: public async Task Index() { // fetch from stuff user claims var signInUserId = ClaimsPrincipal.Current.FindFirst(ClaimTypes.NameIdentifier).Value; var userObjectId = ClaimsPrincipal.Current.FindFirst(SettingsHelper.ClaimTypeObjectIdentifier).Value; // discover contact endpoint var clientCredential = new ClientCredential(SettingsHelper.ClientId, SettingsHelper.ClientSecret); var userIdentifier = new UserIdentifier(userObjectId, UserIdentifierType.UniqueId); // create auth context AuthenticationContext authContext = new AuthenticationContext(SettingsHelper.AzureADAuthority, new EFADALTokenCache(signInUserId)); // create O365 discovery client […]

通过Windows窗体应用程序在线交换电子邮件(Office 365)

我试图通过Windows窗体应用程序从我的O365邮箱中读取电子邮件。 我希望我的应用程序使用我的用户名和密码从O365邮箱中读取电子邮件。 是否可以在Azure上注册应用程序的情况下访问O365 api? (仅使用用户凭据) 我在msdn上访问了这篇文章, https: //msdn.microsoft.com/en-us/library/office/dn567668( v = exchg.150)。我在这行中有一个问题: result = context.AcquireToken(resourceId, ClientID, _returnUri); // parameters are no longer valid in this method