Hello everyone.
I initialy proposed this in the core but unfortunately my PR was closed due to potential future conflicts. In the meantime I released it as a custom component.
This custom component adds support for the due_date and due_datetime parameters when adding items to a todo-list with Assist (text or voice).
It adds a new TodoDueAddItem intent that can be called with the same name and item inputs as the core HassListAddItem but with additional inputs.
In “absolute” mode:
due_day: one oftoday,tomorrow,mon,tue,wed,thu,fri,sat,sundue_hour: between 0 and 23due_minute: between 0 and 59mode: one ofh24(default),am,pm
In “relative” mode:
due_day_offsetdue_hour_offsetdue_minute_offset
This allows sentences like:
- “Remind me to buy bread for tomorrow”
- “Remind hairdresser next tuesday at 9 AM”
- “Remind me to clean the bathroom in 2 hours”
Not all inputs are required, the intent will try to naturally set the best due date depending on what is provided and the current time.
For example “Add xxx at 6 PM” when the current time is 8 PM, will automatically set the item for the next day.
The repository includes sentences examples in English and French. In these examples the name of the todo-list is hardcoded in slots.name in order to have a simpler syntax.
You will probably need to adapt this, so don’t hesite to read the guide to Setting up custom sentences in configuration.yaml - Home Assistant
I hope you find this useful ![]()