I would like to use the Outlook REST API to display the messages in a mail folder and group messages by conversations, like you have in any modern webmail.
For example with inbox
, I would request using a first query such as <mailuri>/inbox/messages?$select=ConversationId
(by default it is reverse chronological order)
It is not sufficient to group this request results by ConversationId
because some emails may not be in inbox
(think of sentmails
) or they may be paginated and not returned in the first page.
Consequently, for each distinct ConversationId
I need to perform another REST request, for retrieving participants or simply counting the emails in the conversation. I may use the new batch request to do this.
There are a lot of requests involved. Is there a better solution ?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…