如何正确读取 Microsoft Graph 发送的电子邮件文件夹?

How to read the email Sent folder by Microsoft Graph correctly?

我正在尝试阅读我的电子邮件 已发送 文件夹。

GET https://graph.microsoft.com/v1.0/me/mailfolders('outbox')/messages

Graph Explorer中,我总是得到一个空数组:

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users('16f5a7b6-5a15-4568-aa5a-31bb117e9967')/mailFolders('outbox')/messages",
    "value": []
}

当我运行

GET https://graph.microsoft.com/v1.0/me/mailfolders

仅已发件夹(发件箱)显示0封邮件,但实际上文件夹中有邮件。

如何正确读取 Sent 文件夹?谢谢

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users('576552d5-3bc0-42a6-a53d-bfceb405db23')/mailFolders",
    "@odata.nextLink": "https://graph.microsoft.com/v1.0/me/mailfolders?$skip=10",
    "value": [
        {
            "id": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAHurthAAA=",
            "displayName": "Archive",
            "parentFolderId": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAAAAEIAAA=",
            "childFolderCount": 0,
            "unreadItemCount": 0,
            "totalItemCount": 3510
        },
        {
            "id": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAAAAEMAAA=",
            "displayName": "Inbox",
            "parentFolderId": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAAAAEIAAA=",
            "childFolderCount": 5,
            "unreadItemCount": 1,
            "totalItemCount": 44
        },
        {
            "id": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAAAAELAAA=",
            "displayName": "Outbox",
            "parentFolderId": "AAMkADBlZTUwNTkxLWVmODgtNDVhNC1iZjhlLTdjNjA1ODZlMDI5MgAuAAAAAACUbnk-iwQZRbXMgkfKtmYhAQCpTc-InBsuTYwTUBb_VIb4AAAAAAEIAAA=",
            "childFolderCount": 0,
            "unreadItemCount": 0,
            "totalItemCount": 0
        }
    ]
}

发件箱不是已发邮件。我希望发件箱几乎总是有 0 条消息,因为发件箱只在发送消息时保存消息,所以消息只在那里停留很短的时间。

要获取已发送的邮件,请使用 https://graph.microsoft.com/v1.0/me/mailFolders/SentItems