📆 Calendar Notifications & Actions

Is it possible to expand this to send notifications to any notify. entity? Specifically I do all my notifications through telegram.

1 Like

If you enable one of the Auto Action Options at the end of the blueprint, you can manually set it to any service you like (ej. any notify service).

Great blueprint, as always :tada:

2 Likes

Great to know, I’ll mess around with it.

Loving your blueprints thanks for all the support.

1 Like

New Update 1.1

Bugs Fixes :bug:

  • Fixed bugs in “Start Action - Action 3” missing variables input.
  • Fixed bugs in “End Action - Action 3” missing variables input.

If you like this blueprint? Consider hitting the :heart: button in the top post :+1:

If you like my blueprints, and would like to show your support or just say thank you? Click Here :smiling_face_with_three_hearts:

Enjoy

Blacky :grinning:

New Update 1.2

Performance Upgrade :rocket:

  • Automation sequence will only run when a notification or auto action is selected for start or end triggers.

Bugs Fixes :bug:

  • Fixed bugs when a confirmation message was not selected.

If you like this blueprint? Consider hitting the :heart: button in the top post :+1:

If you like my blueprints, and would like to show your support or just say thank you? Click Here :smiling_face_with_three_hearts:

Enjoy

Blacky :grinning:

1 Like

FAQ - How To Install The Official Home Assistant Calendar

Please see the link below to the official HA calendar.

When you click on the link above there is an “Add Integration” button. Click on it and follow the steps.

Enjoy

Blacky :smiley:

Back to FAQ: Click Here

Looking at this, unless I am misunderstanding, the auto actions can not have an offset. Is that true?

Does this have to be a local calendar? I am trying to use a google calendar with the below automation and appointment and nothing fired.

alias: Guests Arriving and Departing notifcation
description: >-
  Uses the entry #guest in the HA-Guest calendar to send arrival and departure
  information via telegram.
use_blueprint:
  path: Blackshome/calendar-notifications-and-actions.yaml
  input:
    calendar: calendar.ha_guests
    calendar_trigger: "#guest"
    start_calendar_offset:
      hours: 0
      minutes: 0
      seconds: 0
      days: 1
    include_start_notify: enable_start_notify_options
    start_notify_device:
      - 49a618d7a5f97bf3dc5b4db3cf1a4e44
    include_start_action_buttons: []
    include_start_auto_actions:
      - enable_start_action_1
    start_action_1:
      - service: notify.pottshomebot
        data:
          message: Would you like to turn on the guests present helper?
          data:
            inline_keyboard:
              - Guests Arriving?:/guests
    include_end_auto_actions:
      - enable_end_action_1
    end_action_1:
      - service: notify.pottshomebot
        data:
          title: Guests Are departing
          message: >-
            The calendar shows that guests are departing soon. Would you like to
            turn off the Guests Present toggle?
          data:
            inline_keyboard:
              - Yes:/Guest_present_departing
              - Remind Me Tomorrow :/Guests_present_delay
    end_notify_device:
      - 49a618d7a5f97bf3dc5b4db3cf1a4e44

image

@potts-mike

Hi Mike,

I have only tested it with HA calendar but it should work with any calendar HA can see. The thing that can catch you out is when testing you need to set the calendar at least 15 min into the future or it will not fire. Example: if it is 2pm now when you enter your calendar event in, it must be set at 2:15pm. Then you have to wait for it to fire. :wink:

Can you try this and let us know if it works with the google calendar, it would be nice to know :+1:

Thanks

Blacky :smiley:

PS: Your YAML looks good.

1 Like

I moved the calendar event to 9/13. Let’s see what happens. If it doesn’t fire I’ll change it to a local calendar.

1 Like

FAQ: How do I set up a rubbish reminder?

We will go through how to set up a rubbish / bin / trash reminder. In this example we have a 2 bin rotation but some of you may have a 4 bin rotation so you may need to change the events to suit you.

Our bins have colour lids that represents what we put in them. We have a Red, Yellow & Green bin. One week we need to put out Green and Red, and the next week we need to put out Green and Yellow.

How To Set Up The Notification Automation - Rubbish Reminder

  1. First you must have a calendar in Home Assistant (HA). HA has done a lot of work on their local calender and it works realy well with HA :heart:. This is the one I use as HA will always make sure it works. If you haven’t installed it yet you will need to add it into HA. To do this there is a link below to the Official HA Calendar. Once you click on the link there is a big blue button “Add Integration”. Click on it and follow the steps.

    Local Calendar - Home Assistant

    You will also need to make sure your mobile App allows notifications by going into the settings.

  2. Once installed go into the calendar and click on “Add Event”. Then I selected weekly under repeat.

  3. Now I added in all the information. The summary has the bins I need to take out and in the description I put the Trigger - Key Word “@bins”. Also note it is in the “Home” calendar. Make it an all day event on the day the bins get collected with a repeat interval of 2 weeks as I have a rotation of bins. Set it to never end, click save. Then I add another event for the following week with a different summary for the other bins rotation. The rest is the same and once done click save.

  4. Now that our calendar events are set up we need to create an automation. Use this blueprint. The first thing is to add the calendar, make sure “Use “Key Word” in calendar” is ticked and add the key word @bins. Because we made it an all day event we will need to put in the offset. The start is “-8 (minus 8 hours)” this works out to be 12am - 8 hours = 4pm the day before the bins are collected. So at 4pm the day before collection it will trigger the “Start” settings. I also would like a reminder to bring the bins back so I put an offset of “-9 (minus 9 hours)” this works out to be 12am - 9 = 3pm on the day the bins are collected as they always collect the bins early in the morning. So at 3pm it will trigger the “End” settings. In global conditions we will leave this blank. All the triggers settings and global conditions are now set.

  5. Next we need to set up the “Start” notify message as below. I only need one action button but you can add 3 action buttons. When adding the action buttons the cancel button will be added automaticity. This notification will be sent at 4pm the day before the bins are collected. Note in the title we have put “{{ trigger.calendar_event.summary }}” This will make sure the calendar summary is shown in the notify message. This is why I added 2 events sowing what bins that were needed to be taken out. Now the notification will let me know what bins to take out as well to take the bins out as I can never keep track of it.

  6. Because I have two people to notify I use the confirmation message as it let the other person know if the bins were taken out. The time delay is 4 hours. So our trigger was sent at 4pm + 4 hours = 8pm. If no one takes the bins out and presses an action button the automation will continue to run. So when this happens at 8pm we get another message in the “Time Delay Confirmation Message” reminding us to take the bins out again.

    If you would just like to receive the “Time Delay Confirmation Message” as a second reminder then you would need to enable this option.

  7. Below is the action part of the automation. For this automation I don’t need HA to do anything so it is left blank. If you wanted HA to do something this is where you would add it.

  8. Now we need to do the “End” notification. It is all the same as before like the “Start”. The “End” will send me a notification at 3pm on the day the bins were collected.

  9. Again confirmation is the same as the “start” but our time delay is 3:30. So our trigger was sent at 3pm + 3:30 hours = 6:30pm. At 6:30 if no action button was pressed we will get a “Time Delay Confirmation Message” reminding us again to get the bins.

  10. Again we don’t need HA to do any actions.

Now click save and your done :partying_face:.

You will now have a bin reminder that will send a notify message to the phones every week. The message will be, to take the bins out and to bring them back. It will also remind you of what bins to take out as we added 2 rotation calendar events with different summary’s. :wink:

NOTE: For the automation to fire, the calendar event must be set at least 15 min into the future or it will not trigger. So if you are testing it and can’t work out why it is not working this will probably be it. Example; if it is 3pm now and you are testing it then when you enter in a calendar event the start time must be 3:15pm or greater than 3:15pm. Then you have to wait for the calendar event to fire.

If you have set it up like this then also note the time offsets when testing. When testing and setting 15 min into the future the offsets must be “0”

Enjoy

Blacky :smiley:

Back to FAQ: Click Here

2 Likes

Even after moving the event to the 13th on the 12th this blue print didn’t fire. I guess I’ll change it to a local calendar and see what happens. Any other troubleshooting/logging that I can provide?

I have just gone through this with another community member privately and we got it to work. It took a few days but we got there in the end.

The above post yours on “How do I set up a rubbish reminder” will walk you through a lot of the settings.

One thing you could try first as it is a lot easer to test if you can receive a notify message (even if you know you can as this blueprint has the same format) it to download my :round_pushpin: State Notifications & Actions blueprint and just use a light or something with an ON / OFF state. you can turn it ON and OFF to receive messages. Once you know it works move to this blueprint.

also could please provide us your YAML of the automation? This YAML code are the settings you have selected in the automation so I can help. To do this go into your automation, top right 3 dots, Edit in YAML, copy all the code, come back to the forum and in your reply at the top tool bar click on “</>” and paste code in there.

And we will also need a screen shot of your calendar event.

@potts-mike

Hi Mike, sorry I just looked at your above post with your YAML again an just noticed one thing. You have a calendar start offset of 1 day. This will be the why it is not sending you a message. Not sure if you have worked this out our not yet but I thought I would let you know. If you test it set it to “0” then back to 1 day.

Sorry for not picking this up earlier.

Blacky :pensive:

No worries. It’s going to be a couple days before I can get back to this but I’ll test it at 0 days.

The intent is to get a notification the day before the event.

@potts-mike

No problem, it will be nice to know if it is working with the google calendar.

If you would like it the day before the event, then you must enter “-1 (minus 1 day)”. Currently you have set it to “1 ( + 1 day)” so this will notify you 1 day after the calendar event. So if you are testing 1 day before and it is 3pm now on 17 Sep 2023 then your calendar event must be set at more than 3:15pm on 18 Sep 2023. Then you would enter as below, again note the minus value.

Hope this helps and it would be nice to know how you went.

Blacky :smiley:

Question I want to use this blueprint to remind my kids it is time for bed for a school night. I know for the offset it has to be negative, so it can check the next day. Is there a place where I can use 8:40pm as the trigger to check every day to make the announcement?

@Robert_Shed

Hi Robert

No, there are no time inputs for triggers just a calendar event.

There are a few ways to do this.

Option 1

  1. Go through the year and enter all the calendar events for each night at 8:40 called something like “School Night It Is Time For Bed”. Make sure some thought goes into the calendar summary as you can use this in the notify message.
  2. In the description add a trigger key word something like @bettimeschoolnight or @child1 & @child2 etc
  3. Then create the automation and just use the start, no offset required. Or depending on your key words you could create one automation or separate automations, one for each child and have set up similar to the bin reminder in the FAQ so you could have action buttons where each child could notify you that they have received the message and or a follow up reminder.

Option 2 (recommend)

  1. Go through the year and enter all the calendar events for school called something like “School Day”. Start and End time example Start 9am End 3:30pm. Setting it up like this will allow you to also create automations at the end of a school day if the catch the bus home to let you know they are home and OK.
  2. In the description add a trigger key word something like @bedtimeschoolnight or @child1 & @child2 etc
  3. Then create the automation and just use the start, offset is required. Depending on your key words you could create one automation or separate automations, one for each child and have set up similar to the bin reminder example in the FAQ so you could have action buttons where each child could notify you that they have received the message and or a follow up reminder.

Before you go nuts and enter everything in just do one week and see if you like it, then add the rest if your happy.

PS: You could also create a different calendar just for school, that way you can filter everything much easer. To create a new calendar called “School” when adding a calendar event in and in the area you select a calendar just type a new one called “School” and when you click save it will create one for you.

This is what I already created previously, except the events are all day school days?

@Robert_Shed

Hi Robert, that is totally fine it will still work exactly the same. You will just have different offsets. I think you would like an announcement (On your speakers) the day before school at 8:40pm then your offset will be 12am - -3hh -20mm = 8:40pm so your input will be with negative values for the “start” like shown below.

You will have to select the calendar you used to enter the calendar events in and hopefully you entered in a key word. If so then you would also enter in that key word example; something like @schooldaybedtime or @schoolday or whatever key word you used. You can also use “School”, “Day” or “School Day” as this in what you used in your summary but if any calendar event has those words this automation will fire so I would strongly recommend you enter in a unique key word like “@schoolday” or “#schoolday”.

Now all your triggers are set up :+1:

Then you need to decide if you would like to have a message sent to your phone by enabling the “The Start Notify Options”. You dont need to use this for the blueprint to work it is just an option you can choose. If you do choose this option then you have another option to use the “Action Buttons Options”. Note; if you enable action buttons then all actions (action 1, 2 or 3) will wait for a press of an action button or the time delay passes before any action will be done. Because I think you would like an announcement (On your speakers) you wouldn’t use the action buttons unless you would like to choose if the announcement (On your speakers) happens or not every time and I don’t think you would like to do this. So if you would like a message sent to the phones an move onto the auto actions then don’t enable any “Action Buttons Options”. Again you don’t need to use any of the notify message options for it run any of the actions 1, 2 or 3.

Your next option is " Start Auto Action Options". This is the option that will allow the announcement (On your speakers). So you would select any of the enable options for 1, 2 or 3. Let just say for this example we will use “Enable start auto action 1”. Then in the “Start Action - Action 1” you would put in all your announcement (On your speakers). Add action / play media / pick your speakers / and the media you would like example text to speech and enter in your text. Then add more action for the other speaker if you like.

Now you would have an announcement (On your speakers) the day before every school night as per your action and your calendar :partying_face:

Hope this helps

Let us know if this is what your after and it works for you.

Blacky :smiley: