Google Calendar search option

Hi,

I have an imported calendar in my Google Calendar with entries like this:

I’m only trying to catch the entries with “vakantie” in the name, but cant seem to get the search option set correctly.

In google_calendar.yaml I have this config:

- cal_id: [email protected]
  entities:
  - device_id: schoolvakanties
    ignore_availability: true
    name: Belgie Schoolvakanties
    track: true

This works, I get everything. I tried to configure the search option, but after I set it I don’t get anything. Already tried these configs:

search: vakantie
search: "vakantie"
search: "#vakantie#"

Any thoughts?

try

search: "*vakantie*"

Doesn’t work either.

If I try this I get a result.

search: "2020"

Knipsel

So it seems that it is not possible to search a part of a word?

It’s possible. I haven’t looked at the code. They aren’t using glob because word didn’t work. Is there a way you can add #blah to your calendar events? That’s how it seems to search for items, based on tags. I don’t use the integration and I haven’t really setup my calendars. So it’s hard to tell.

I have also two question about search in calendar,

  • Search for events where a word is not included

Is it possible to make a search without a keyword, so I got only events for example with out the word vakantie?
What code can I use to do this?

  • Search with wildcards at the beginning and end
    If I try:
    search: “.reise
    or
    search: “reise
    I don´t go the event with the titel Grimm Busreisen

If I try:
search: “Grimm*”
it works. But why reise not work?

I would suggest checking out these recipes: Calendar - Home Assistant as examples for automations that can apply arbitrary logic to different event fields and not using the google calendar search. You can make a template binary sensor if you still want an entity.

1 Like