From f5a08fc249ff90f6723687c5b492e28a5039969f Mon Sep 17 00:00:00 2001 From: Allen Porter Date: Wed, 15 Nov 2023 02:42:04 -0800 Subject: [PATCH] Add documentation for todo.get_items service (#29678) Co-authored-by: c0ffeeca7 <38767475+c0ffeeca7@users.noreply.github.com> --- source/_integrations/todo.markdown | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/source/_integrations/todo.markdown b/source/_integrations/todo.markdown index 4ea1d00d58f..3418365fe3d 100644 --- a/source/_integrations/todo.markdown +++ b/source/_integrations/todo.markdown @@ -34,6 +34,26 @@ incomplete items in the list. Some To-do List integrations allow Home Assistant to manage the To-do Items in the list. The services provided by some To-do List entities are described below or you can read more about [Service Calls](/docs/scripts/service-calls/). + +### Service `todo.get_items` + +Get to-do items from a to-do list. A to-do list `target` is selected with a [target selector](/docs/blueprint/selectors/#target-selector). The `data` payload supports the following fields: + +| Service data attribute | Optional | Description | Example | +| ---------------------- | -------- | ----------- | --------| +| `status` | yes | Only return to-do items with this status. | `needs_action`, `completed` + +This is a full example that returns all to-do items that have not been completed: + +```yaml +service: todo.get_items +target: + entity_id: todo.personal_tasks +data: + status: + - needs_action +``` + ### Service `todo.add_item` Add a new To-do Item. A To-do list `target` is selected with a [Target Selector](/docs/blueprint/selectors/#target-selector) and the `data` payload supports the following fields: