web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Question about the Gra...
Power Automate
Unanswered

Question about the Graph API and filtering messages from a Teams channel from the last 7 days - is it possible?

(0) ShareShare
ReportReport
Posted on by

Hello Everyone.

 

Using the Microsoft Graph API you can get the number of messages from a chat channel, like this:

 

GET  - https://graph.microsoft.com/v1.0/teams/{group-id-for-teams}/channels/{channel-id}/messages/{message-id}

 

Can this query be expanded to then filter through all those messages and display only those which were created/modified in the last 7 days?

 

Thanks so much for any advice.

Categories:
I have the same question (0)
  • Expiscornovus Profile Picture
    33,194 Most Valuable Professional on at

    Hi @ianwuk,

     

    I would suggest to have a look at the Get channel messages delta method.

     

    That method also supports filtering on lastModifiedDateTime.

    https://graph.microsoft.com/v1.0/teams/<groupid>/channels/<channelid>/messages/delta?$filter=lastModifiedDateTime gt 2023-05-04T07:13:28.000z

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 503 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 321 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard