Feb 29 2024 12:02 AM
Hi,
we want to do a report of all our Teams and Channels.
With that it would be nice to get when it was lastly updated/used so we could do some cleanup afterwards.
Via Powershell and also GraphaAPI check i know that channels do not save data of when they have been lastly updated, the only chance I have is to use GraphAPI and check messages for similar data.
This call https://graph.microsoft.com/v1.0/teams/{team-id}/channels/{channel-id}/messages should help me out BUT it always returns with 403. I have all needed permissions consented (as I am global admin in our tenant), I have correct ID's added (checked with checking the channel and returning details of the channel). Request token is valid.
MS Teams API export is one of the possible option but since I need to check way long in the past, it is limited by retention policy. I really just need to get last message (not the text, but just details about it) from each channel to get a "time stamp" of last activity.
Ideally when and who.
Can you please help me out?
Thank you
Feb 29 2024 08:46 AM
Feb 29 2024 09:27 AM
Feb 29 2024 10:09 AM