Being able to access the list of all events for a specified date. The default value is the next day.
Use case: creating a scene triggered at a specific time (dinner), in which Gladys will cancel all the actions to be performed the next day. In my case, the voice synthesis uses a local API to which a phrase is passed, which is then spoken on a speaker or a set of selected speakers. One could imagine passing a phrase containing a variable that groups the events to the TTS URL (or finding a way to create the phrase on the fly).
There you go, itâs developed
master â claude/calendar-events-request-8g4mo8
ouvert 01:55PM - 12 Aug 26 UTC
### Description
This PR adds a new scene action **`calendar.get-events`** ("Get⊠calendar events") that fetches the events of one or more shared calendars over a relative time range and exposes them as scene variables, so a scene can announce the day's or tomorrow's agenda through a message, a TTS notification or an HTTP request to a local TTS API.
**Time range options**: today, tomorrow (the forum request's default use case), or the next X hours.
**Variables injected in the scene scope** (`calendarEvents.*`):
- `text`: a ready-to-use localized sentence listing the events, e.g. `Dentist at 9:00 AM, Meeting at 4:00 PM` (full-day events are announced without a time, events starting on another day include the full date). The "at" word is localized (en/fr/de) using the calendar creator's language, consistent with how `calendar.event-is-coming` formats dates.
- `count`: number of events found.
- `events`: the raw sorted list (name, location, description, start, end, summary) for advanced templating.
The action can optionally **stop the scene when no event is found**, which also makes it usable as a condition in if/then/else blocks (e.g. "if there are events tomorrow â announce them"), consistent with `calendar.is-event-running`.
Implementation details:
- New `calendar.findEventsInRange(calendars, from, to)` lib function: events **starting** in the range, shared calendars only (same convention as `findCurrentlyRunningEvent` and the calendar trigger), sorted chronologically.
- New action handler in `scene.actions.js`, registered in `CONDITION_ACTIONS`.
- New front component `CalendarGetEvents` (modeled on `CalendarIsEventRunning`), translations added for en/fr/de.
- MCP scene schema added so AI-generated scenes can use the action.
- Server tests: 7 tests for the scene action (all time ranges, sorting, full-day events, events without end date, empty result, abort behavior, invalid range) and 3 tests for the lib function (range filter, sorting, shared-only, calendar filter).
## Forum
Forum: https://community.gladysassistant.com/t/calendrier-pouvoir-disposer-dune-liste-des-evenements-a-une-date-a-venir/10530
### Checklist
- [x] Tests pass: `cd server && npm run coverage` (Codecov requires 100% coverage on changed lines) and Cypress (`npm run cypress:run`) if the UI changed â targeted suites are green locally (scene: 252 â, MCP: 99 â, calendar: 39 â including the 10 new tests); the only local full-suite failures are environment-related (missing `sqlite3` binary/Docker/network in the sandbox) in areas untouched by this PR. Cypress could not run in the sandbox (binary download blocked).
- [x] Linter and prettier pass on both front and server (`npm run eslint`, `npm run prettier`)
- [x] No undocumented breaking change
đ€ Generated with [Claude Code](https://claude.com/claude-code)
https://claude.ai/code/session_01ExXaNXP51WH4CJzCrXZkZt
---
_Generated by [Claude Code](https://claude.ai/code/session_01ExXaNXP51WH4CJzCrXZkZt)_
## Summary by CodeRabbit
* **New Features**
* Added a scene action to retrieve events from one or more shared calendars.
* Supports today, tomorrow, or customizable upcoming-hour ranges.
* Provides event summaries, counts, and event lists, with an option to stop when no events are found.
* Added configuration validation and English, French, and German translations.
* **Tests**
* Added coverage for date ranges, calendar selection, sorting, formatting, validation, and empty results.
Tested and approved, it will be included in the next version of Gladys
Iâm closing this post as the feature is available in Gladys Assistant 4.86:
Hi everyone!
Super excited to release Gladys Assistant 4.86.
Itâs simple, itâs the biggest version since the start of the project, with 68 PRs merged in one week
Itâs just incredible, and it shows the new pace we can keep with AI.
The goal is now clear: catch up with and surpass Home Assistant
Iâll talk about these 68 new features here:
Thanks to all the contributors!!