This payload is coming from an RSS feed being read by the Home Assistant RSS Feed Reader integration. I have a node watching the event bus, filtering out all messages that don't have the event_type feedreader
.
The idea is this...create a push notification to specific Home Assistant users based upon whether or not a Blog Post was categorized or tagged with a specific value, which will be found under msg.payload.event.tags
as an object (index) inside of an array (tags) inside of an object (event) inside of an object (payload).
I want to search msg.payload.event.tags
for specific strings under term:
then direct the flow based upon that/those findings.
If, for example, the category is "Household" then the flow would proceed one direction, and if the category is "Family" then it would go down a different flow.
The reason I need a search is because the index position of each category/tag may or may not change for each event (i.e. blog post) depending upon the category/tags on the blog post, so simply assigning a value to an index won't work.
{
"event_type": "feedreader",
"event": {
"title": "Test Post 5",
},
"link": "https://domain.com/legacy/test-post-5/",
"author": "Author Guy",
"published": "Mon, 12 Sep 2022 03:03:24 +0000",
"tags": [
{
"term": "Home Assistant",
"scheme": null,
"label": null
},
{
"term": "Information Technology",
"scheme": null,
"label": null
}
]
}
Is this something that would require the Function node or can it be done without any coding? Either way, I can adapt. Thanks!