Whats the best way to run an automation when a blog post goes live? We schedule our posts so we are unsure of the best way to approach this issue. There is no "When Blog Post Goes Live" API event.
Whats the best way to run an automation when a blog post goes live? We schedule our posts so we are unsure of the best way to approach this issue. There is no "When Blog Post Goes Live" API event.
Have you had a look at `BlogPost.BeforeUpdate` ? You may then be able to check things such as context_v2_automationTrigger.Arguments.IsPostEnabled and context_v2_automationTrigger.Arguments.PublishedDate in the automation.
We use these kinds of checks when blogs are posted on the element14 Community to synchronise the actual publish date with the current date when a blog post is published from draft, as otherwise the blog publish date ends up being when the draft was first created, but these properties may help steer you towards acting on the blog's intended publish date to know when it's published.
This is an interesting idea. I didn't think the post going live would trigger the BeforeUpdate event. Is context_v2_automationTrigger.Arguments.IsPostEnabled set to true when the post is published?
Stephen Vicino That's how we're able to compare and check it, yes.
Stephen Vicino That's how we're able to compare and check it, yes.
Thank you! We ended up going with Luke R Davidson 's solution and it worked well because it runs every 5 mins to check for newly posted blogs.
Excellent!