问题
I want to do a sync action in my client side, so need to know how to get all deleted contact list.
By the api (GET /me/contacts), I could get all contact list But it wastes much time when the user has large contacts.
This api (GET /me/contacts/{id}) tell us the contact is exist or not.
it is inefficient to check every contacts are deleted or not for me.
Which apis do I use? thanks for your help.
回答1:
Why not use the delta query preview in the /beta
endpoint? That should do what you want.
回答2:
More efficient way for you to check which contacts were removed is getting just the list of contact ID's and then doing the diff between list of ID's returned by graph, and local list.
You can use query parameters to retrieve just the ID's of the contacts, instead of getting the whole objects.
Method url: https://graph.microsoft.com/v1.0/me/contacts?$select=id
来源:https://stackoverflow.com/questions/43132111/how-to-list-the-deleted-contacts-by-microsoft-graph-api