Check if calendar event took place yesterday

I’m using the Google Calendar integration to run some automations based on calendar events. This template lets me check whether an all-day event called “Reserved” is happening today:

{{is_state_attr('calendar.calendar_name', 'message', 'Reserved') }}

Is there a way to check if an event with that name took place yesterday?

You might be able to use the history stats sensor to pull that info from your history if you have the calendar configured in the recorder.

Otherwise, you would have to have saved that event to some sort of input_text or variable along with the date then you could check it like that. That way is going to be a lot of fiddling around tho.