0

We are using the node package "@microsoft/microsoft-graph-client" to access Graph API from node environment.

Actually the purpose is to fetch the user contacts (outlook,live,office, hotmail) into our system through API,

API "/me/contacts" by default fetches only 10 contacts per call, so in our system we are iterating the API using "skip & @odata.nextLink" until all the contacts are received.

While referencing the API document it says API request will default provide 10 contacts, so fetching 4k contacts from my account it takes 5+ minutes.

So here there are 3 questions from our side,

  1. Is there any query options to fetch maximum contacts in API?
  2. To reduce the delay in fetching huge contact list say 8k contacts, is there any other API available to reduce the time delay?
  3. We are trying to fetch contact list from multiple O365 account with the volume of more than 3000 contacts in each account, but we are facing lot of delay in getting those contact list through Graph API. Is there any way to get the results or data sets faster from O365 account ?
4

1 回答 1

0
  1. 您应该使用 $Top 和 $Skip 来控制页面大小https://github.com/Microsoft/api-guidelines/blob/master/Guidelines.md#98-pagination默认页面大小为 10 但使用邮箱但您应该能够上升到 1000,此时节流限制将不再在一次调用中返回。

  2. 图形数据连接可能是一个选项https://docs.microsoft.com/en-us/graph/data-connect-concept-overview

于 2019-06-12T04:43:18.957 回答