Last week the blog was to automate the Microsoft RSS feed. This week the concept is same but the power automate flow is simplified and the RSS feed that is automated is with security podcast SmashingSecurity
Implementation:
- Collection of data: The RSS connector would enable you to get a JSON data which we would manipulate in the following steps
- Condition: Instead of leveraging filter array, condition is leveraged to pull the needed content. We will Parse the Publish Date field from the RSS feed leveraging function as below. Grabbing the last published feed would be using the [0] index and the object is ['publishDate']
body('List_all_RSS_feed_items')[0]?['publishDate']
Compare the latest publishDate and validated if its published in the last 7 days.
addDays(utcNow(),-7)
- Yes - If the condition above is satisfied , post the message in a Microsoft TEAMS channel
- If the condition is not met then no action
- Email Composition Mapping the Subject of email as the RSS feed title
body('List_all_RSS_feed_items')[0]?['title']
- Extracting Test for body of email The split() function returns an array of substrings. We have used 2 delimiters with the split function ('Sponsored by:' or 'Episode links:'). [0]: This specifies that we want to access the first item in the resulting array, which is the substring before "Sponsored by:".[1]: This specifies that we want to access the second item in the resulting array, which is the substring after "Episode links:".
split(split(body('List_all_RSS_feed_items')[0]?['summary'],'Sponsored by:')[0],'Episode links:')[1]
The simplified PowerAutomate flow would be
The result !! automated the PodCast summary as a weekly newsletter to the team to learn and enrich the knowledge ....