Graph API : delete calendar events in trash bin

CHATILLON Laurent 0 Reputation points
2023-01-16T10:16:33.3233333+00:00

With Graph API, I'm try to access to the content of Outlook trash bin and remove deleted calendar events.
Example of an Graph API Request :

[https://graph.microsoft.com/v1.0/me/mailFolders/XXX

where XXX is the ID of the trash bin directory.

This request gives the result below :

{
    "@odata.context": ...
    "id": ...
    "displayName": "Éléments supprimés",
    "parentFolderId": ...
    "childFolderCount": 0,
    "unreadItemCount": 0,
    
    "isHidden": false
}

So, there is 70 items in trash bin. I know this 70 items are mainly removed item calendars.

But when I make a Graph API query to get all the content of trash bin :

[https://graph.microsoft.com/v1.0/me/mailFolders/XXX/messages

I got only one item. The only item I got in an email.
All the 69 remaining items (which are removed calendar items) are not fetched by graph API.

Why this ?

I need to retrieve them with Graph API, and remove them from trash bin.

Thanks for your help,

Laurent

Microsoft Security Microsoft Graph
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Bhanu Kiran 3,616 Reputation points
    2023-01-16T23:38:11.22+00:00

    Hi @CHATILLON Laurent ,

    I tried to create few events and delete/cancel them using graph. After checking the Attendees deleted folder, I can see all the deleted events. And I was also able to get the deleted events using Graph API.

    Please note that the deleted events will be stored in Attendees deleted folder only and not organizer.

    Deleted Event

    Graph Event

    I would recommend you raise a support case with Microsoft Graph, a Support Engineer will be able to assist you better. You can raise support ticket from
    http://aad.portal.azure.com/ or https://admin.microsoft.com/#/support/requests.

    Hope this helps.

    If the answer is helpful, please click Accept Answer and kindly upvote. If you have any further questions about this answer, please click Comment.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.