First the use case: I am trying to create an automation that adds a comment after a help desk issue has been waiting on a customer 13 days and then closes it after 14 days if they don't reply.
I have the structure of the rule created and working for the timing. However I am having trouble with the comment to tell a user their issue will be closed in 24 hours. Because most of our users will see the comment in their email and not click through to view the issue's history I want to have the previous comment that is awaiting their reply in the 24 hours notice comment body. I was going to just use the {{issue.comment.last.body}} smart value, but if the last comment was an internal comment that has information the user/customer shouldn't see, that smart value doesn't filter it and will share it with the customer. So I have been perusing the documentation trying to figure out how I might achieve getting the last public comment instead of just the last comment.
Thus far the only thing I can think of is some if else branches that use the {{comment.getfromend(0).internal}} to test each comment with a compare condition. But no issue will have the same amount of comments and I don't see a way to loop through them in a rule for testing, I do see it for displaying all comments. But perhaps I'm just missing the option or a built in property/smart value I can use to achieve this.