Skip to main content

Notifications

Power Automate - Building Flows
Suggested answer

Get more than 25 emails for monitoring process

Posted on by 2

For a monitoring proceess, I want to get all emails for a month from a shared mailbox. This mailbox receeives more than 3000 email (on average) per month and I want to extract with specific wording in subject line.

Then I want to store the one with specific subject line into an excel and use it to compare against the system records that we are sending out correct emails.

BIG problem I am facing is using Get email (V3), I am restricted to get only 25 emails.

What I have tried:

Understand that we can monitor all the future emails using the When an email arrived in a shared mailbox connector but I want to make sure past emails are also sent out correctly

Using HTTP is not allowed because of the data loss protection policy.

Please help

  • Suggested answer
    Mark Nanneman Profile Picture
    Mark Nanneman 329 on at
    Get more than 25 emails for monitoring process
    One thing you could do is create an array of past dates to iterate through in an "Apply to Each" loop.  For each date range you cycle through, you submit a new "Get Emails" action using the "Search Query" to search for something like "received: <currentDateString>"

    As long as the number of emails with the specific Subject Line wording per day is under 25, this will work.

    Here's a demo--I use an "Apply to each" loop, inputing just a simple array of integers from -30 to 0 using the Range() function.

    the formula to create a simple array of 30 integers starting with -30
     
    next we need to get a past date by adding the current integer (which is a negative) to the current date.
     
     
    This is the formula that I used:
    formatDateTime(addDays(utcNow(),item()),
    'MM-dd-yyyy')

    After this we need to put this past date into the "Search Query" for the "Get Emails" action:
     
    Finally I append the date and number of emails found to an array for demo purposes:

    And convert the array into an HTML table once the "Apply to Each" loop is completed:




    If this helped you, please click "Does this answer your question" and give it a like to help others in the community (+ close the ticket)!

    Power Platform Developer | LinkedIn: Mark Nanneman | Blog: Power Stuff  | YouTube: Mark's Power Stuff  | Buy me a coffee

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

November 2024 Newsletter…

November 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #7 Community Profile Tips…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 143,246

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,884

Leaderboard