Save previous run state?

Is there any way to store the status/result of a previous workflow run (success/failure) and access it in the next run? More specifically, I have a cronjob that runs every hour and sends a Slack message with the results of the run, but I’d like to only send a “success” message if the previous run was a failure (like a “back to normal” message, rather than sending a “success” every hour forever). Is this possible?

Nevermind, just hitting the API to get the latest run data instead