更新Office365个人联系人 [英] Update Office365 personal Contacts

查看:185
本文介绍了更新Office365个人联系人的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

上下文:

我们公司有12位协调员.每个协调员管理一堆个人联系人.

  • Coordinator1管理409个个人联系人.
  • Coordinator2管理216个个人联系人.
  • 等等...

我们有一个每晚的任务,该任务将填充一个保存个人联系信息的SQL Server TABLE.

TABLE中的数据被提取到12个不同的CSV files中,然后依次将其发送给每个协调器.

协调员有责任将此CSV file 导入到他的Outlook中,以使他的个人联系人列表保持最新(是的,这些个人联系人每天都会更改).

对于大多数这些协调员来说,整个CSV文件的导入有点太多,目标是使其自动化或具有使Outlook个人联系人同步的功能,这样这些协调员就不会来完成这项日常的手动任务.

我尝试过的事情:

我创建了一个C#控制台应用程序,并添加了ADAL和Microsoft Graph客户端库NuGet程序包.

我已经在Azure中正确注册了我的应用程序,并获得了Client IdClient Secret.

我已经设置了适当的Application and Delegated permissions.

我可以运行该应用程序,获取token并调用Microsoft Graph客户端.

问题:

在撰写本文时,我的问题是Microsoft Graph不支持Contact List的创建,也不允许我在此Contact List中添加,删除或更新个人联系人.

无法使用Groups.每次您将用户添加到组中时,都会向该特定用户发送一封电子邮件,告知他已被添加到组中.

此外,同一位用户可以将自己从网上论坛中删除,而我们根本不希望这样做.

Microsoft Graph还支持创建Folders并将人员添加到这些文件夹中,但是不幸的是,我发现这些文件夹的唯一目的是用于整理东西...

对于文件夹,我无法将电子邮件发送到特定的文件夹,而该电子邮件又会向该文件夹中的每个人发送电子邮件.这就是Contact List的目的...但是,在撰写本文时,该API没有用于Contact List的任何内容.

有人可以提出更好的建议或解决方法来完成我的任务吗?

我不介意重写整个控制台应用程序,甚至不必完全改变整个方法(例如使用Powershell)

我关心的是不再手动将这12个协调器导入成为CSV file.

先谢谢了.

PS:我什至研究了Microsoft Flow,但没有找到可以更新Outlook个人联系人的Flow.

解决方案

目前,两个 Microsoft Graph Outlook REST API 均支持联系人组".

不过,您可以使用中,有一个示例C#代码的演练.如何:通过在Exchange中使用EWS创建联系人组.

The context:

Our company has 12 coordinators. Each coordinator manages a bunch of personal contacts.

  • Coordinator1 manages 409 personal contacts.
  • Coordinator2 manages 216 personal contacts.
  • Etc...

We have a nightly task that populates a SQL Server TABLE holding personal contact information.

The data in the TABLE is extracted into 12 different CSV files which in turn is sent to each coordinator.

The coordinator has the responsibility to Import this CSV file into his Outlook in order to keep his list of personal contacts up-to-date (yes, those personal contacts change daily).

The entire Importing of CSV file is a bit too much for most of these coordinators and the goal would be to automate this or have something that synchronizes Outlook personal contacts so that these coordinators won’t have to do this daily manual task.

What I’ve tried:

I’ve created a C# console application and I’ve added ADAL and Microsoft Graph client library NuGet packages.

I’ve correctly registered my application in Azure and obtained the Client Id and Client Secret.

I’ve set the appropriate Application and Delegated permissions.

I’m able to run the application, obtain a token and call the Microsoft Graph client.

The problem:

My problem, as of this writing, is that Microsoft Graph does not support the creation of Contact List nor does it allow me to Add, Remove or Update personal contacts into this Contact List.

The ability to use Groups is not possible. Each time you add a user to a group, an email is sent to that particular user letting him know that he’s been added to a group.

In addition, that same user can remove himself from a group and we simply don’t want that.

Microsoft Graph also supports the creation of Folders and adding people to these Folders but unfortunately, the only purpose I found for these Folders is for organizing stuff...

With Folders, I do not have the ability to send an email to a particular Folder which in turn would send an email to everyone in that Folder. That’s the purpose of the Contact List...but, as of this writing, the API doesn’t have anything for Contact List.

Does anyone have a better suggestion or perhaps a workaround to achieve my task?

I don’t mind having to rewrite the entire console application or even completely change the entire approach (like using Powershell)

All I care about is to not make those 12 coordinators manually Import a CSV file anymore.

Thanks in advance.

PS: I even looked into Microsoft Flow but haven't found a Flow that could update Outlook Personal Contacts.

解决方案

At the moment neither Microsoft Graph nor the Outlook REST API supports "Contact Groups".

You can however create them programmatically using the EWS Managed API. There is a walkthrough with example C# code in How to: Create contact groups by using EWS in Exchange.

这篇关于更新Office365个人联系人的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆