Forum Discussion
Error applying retention policy to specific user's chats
I am getting an error applying retention policy to a specific user's Teams chats. I'd appreciate any help fixing it.
Specifically, I am trying to delete all chats of a specific user (let's call him "Dave") after one day. When I try to apply that retention policy, I receive the following error message:
The specified recipient "Dave" couldn't be found. Reason: The recipient Dave isn't the expected type.
I can apply the same policy to other users without error. Dave is licensed for Office 365 E3. The only unusual thing I can think of for Dave is that he has limited administrative rights (Message Center Read, Office Apps admin).
For the record, I have reproduced a summary of the policy below.
Has anyone seen this problem before? Any ideas what I should try next?
(Suggestion was from this thread: https://techcommunity.microsoft.com/t5/microsoft-teams/how-to-permanently-delete-chat-conversation-after-scheduled/m-p/1256110)
Rob
-----
Policy name
Delete Dave's chats
Description
Delete Dave's chats after one day
Locations to apply the policy
Teams chats (1 User)
Retention settings
Delete items at end of retention period​
Delete items that are older than 1 days based on when they were created
- So again, what's the deal with his mailbox? And which identifier are you specifying when trying to add him, try the ExternalDirectoryObjectId.
4 Replies
- Admin privileges should make no difference. Where is the user's mailbox located? You can try adding him to the policy via PowerShell, see if it makes a difference: https://docs.microsoft.com/en-us/powershell/module/exchange/set-retentioncompliancepolicy?view=exchange-ps
- rhelm2024Iron ContributorThanks, Vasil, for the suggestion. In PowerShell, I tried both creating the policy from scratch, and adding Dave to a policy I created interactively. I both cases, I got an error message along the following lines:
The specified recipient "Dave" couldn't be found. Reason: The recipient Dave isn't the
expected type.
Followed by a bunch of details specific to our Office 365 instance.
Thanks for helping out here, I really appreciate it.
Rob- So again, what's the deal with his mailbox? And which identifier are you specifying when trying to add him, try the ExternalDirectoryObjectId.