Hi, have you found the answer?
I am having a similar issue. I am not getting all the sub mailfolders of the parents unless the sub mailfolders were created by the application user that I used to access the inbox.
I have applied all required permission for the application user.
- Mail.ReadBasic.All
- Mail.Read
- Mail.ReadWrite
I used the following code:
var queryOptions = new List<QueryOption>()
{
new QueryOption("includeHiddenFolders", "true")
};
var TestOCFolders = await graphClient.Users[destination.Email].MailFolders[FolderId].ChildFolders.Request().GetAsync();
var OCFolders = await graphClient.Users[destination.Email].MailFolders[FolderId].ChildFolders.Request(queryOptions).Top(250).GetAsync();