# Home Assistant

> Control your smart home with Home Assistant: turn things on and off, run actions, read sensors and their history, send notifications and talk to Assist. Start a workflow when something changes.

App · 14 actions. Web page: https://docs.lodol.com/docs/integrations/home-assistant

## Actions

### Ask Assist

Tell Home Assistant's voice assistant what to do or ask it something, in plain words, such as 'turn off the kitchen lights'.

**Inputs**

- Say (`text`, text, required): What to say, as you would to Assist.
- Language (`language`, text): The language it's in, such as en or de. Defaults to the server's.

**Outputs**

- `conversation_id` (text): The conversation, to continue it
- `reply` (text): What Assist answered
- `response_type` (text): action_done, query_answer or error

**Example output**

```json
{
  "conversation_id": "01JB9X",
  "reply": "Turned off the kitchen lights",
  "response_type": "action_done"
}
```

### Fire event

Fire an event, for an automation in Home Assistant to react to. Needs an administrator's token.

**Inputs**

- Event (`event_type`, text, required): The event's name, such as lodol_order_shipped, as your automation listens for it.
- Data (`data`, object): Fields and values to send with it.

**Outputs**

- `event_type` (text): The event fired
- `fired` (true/false): True once fired

**Example output**

```json
{
  "event_type": "lodol_order_shipped",
  "fired": true
}
```

### Get entity history

Get an entity's states over a span of time, such as a temperature over the last day.

**Inputs**

- Entity (`entity`, text, required): The entity to read.
- From (`start`, date and time): The start of the span. Defaults to a day ago.
- Until (`end`, date and time): The end of the span. Defaults to now.

**Outputs**

- `changes` (list): Its states, oldest first
- `count` (number): How many states
- `entity_id` (text): The entity

**Example output**

```json
{
  "changes": [
    {
      "changed_at": "2026-10-28T08:00:00+00:00",
      "state": "11.2"
    }
  ],
  "count": 1,
  "entity_id": "sensor.outside_temperature"
}
```

### Get entity state

Get an entity's state, such as whether a light is on or a sensor's reading, with its attributes.

**Inputs**

- Entity (`entity`, text, required): The entity to read.

**Outputs**

- `attributes` (object): Its attributes, such as brightness or battery level
- `entity_id` (text): The entity's ID, such as light.kitchen
- `last_changed` (text): When its state last changed (ISO 8601)
- `last_updated` (text): When it was last updated (ISO 8601)
- `name` (text): Its name
- `state` (text): Its state, such as on, off, 21.5 or home
- `unit` (text): The state's unit, such as °C, if it has one

**Example output**

```json
{
  "attributes": {
    "brightness": 204,
    "friendly_name": "Kitchen light"
  },
  "entity_id": "light.kitchen",
  "last_changed": "2026-10-28T08:59:00+00:00",
  "last_updated": "2026-10-28T08:59:00+00:00",
  "name": "Kitchen light",
  "state": "on",
  "unit": ""
}
```

### Get server details

Get your Home Assistant's name, version, time zone and temperature unit.

**Inputs**: None.

**Outputs**

- `location_name` (text): The home's name
- `state` (text): RUNNING once it has started
- `temperature_unit` (text): Its temperature unit
- `time_zone` (text): Its time zone
- `version` (text): Home Assistant's version

**Example output**

```json
{
  "location_name": "Home",
  "state": "RUNNING",
  "temperature_unit": "\u00b0C",
  "time_zone": "Europe/London",
  "version": "2026.10.1"
}
```

### List calendar events

List the events on one of Home Assistant's calendars between two times.

**Inputs**

- Calendar (`calendar`, text, required): The calendar, such as calendar.family.
- From (`start`, date and time): The start of the span. Defaults to now.
- Until (`end`, date and time): The end of the span. Defaults to a week after 'From'.

**Outputs**

- `calendar` (text): The calendar
- `count` (number): How many events
- `events` (list): The events

**Example output**

```json
{
  "calendar": "calendar.family",
  "count": 1,
  "events": [
    {
      "all_day": true,
      "description": "",
      "end": "2026-10-30",
      "location": "",
      "start": "2026-10-29",
      "title": "Bins out"
    }
  ]
}
```

### List entities

List entities and their states, of one kind (such as light or sensor) or with names containing words.

**Inputs**

- Kind (`domain`, text): Only entities of this kind, such as light, switch or sensor.
- Name contains (`search`, text): Only entities whose name or ID contains these words.
- How many (`limit`, number): The most entities to return. Defaults to 100. From 1 to 2000.

**Outputs**

- `count` (number): How many
- `entities` (list): The entities

**Example output**

```json
{
  "count": 1,
  "entities": [
    {
      "attributes": {
        "brightness": 204,
        "friendly_name": "Kitchen light"
      },
      "entity_id": "light.kitchen",
      "last_changed": "2026-10-28T08:59:00+00:00",
      "last_updated": "2026-10-28T08:59:00+00:00",
      "name": "Kitchen light",
      "state": "on",
      "unit": ""
    }
  ]
}
```

### Render template

Work out a Home Assistant template, such as {{ states('sensor.outside_temperature') }}. Needs an administrator's token.

**Inputs**

- Template (`template`, text, required): The template, in Home Assistant's Jinja syntax.

**Outputs**

- `result` (text): What the template works out to

**Example output**

```json
{
  "result": "11.2"
}
```

### Run action

Run any Home Assistant action, such as setting a thermostat or locking a door, with its data.

**Inputs**

- Action (`action_id`, text, required): The action to run, such as climate.set_temperature.
- Entities (`entity`, list): The entities to run it on, if it takes any.
- Data (`data`, object): The action's fields and values, such as temperature: 21.
- Return its answer (`return_response`, true/false): Return the data the action answers with, for actions that give one, such as weather.get_forecasts. Default: `false`.

**Outputs**

- `action` (text): The action that ran
- `changed` (list): The entities whose state changed
- `response` (object): What the action answered, when asked to return it

**Example output**

```json
{
  "action": "climate.set_temperature",
  "changed": [],
  "response": {}
}
```

### Send notification

Send a notification to a phone with the Home Assistant app, or another target set up in Home Assistant.

**Inputs**

- Send to (`notifier`, text, required): Where to send it, such as a phone's mobile_app target.
- Message (`message`, text, required): What the notification says.
- Title (`title`, text): A title above the message.

**Outputs**

- `notifier` (text): Where it was sent
- `sent` (true/false): True once sent

**Example output**

```json
{
  "notifier": "mobile_app_pixel_8",
  "sent": true
}
```

### Set entity state

Set what Home Assistant shows for an entity, such as a sensor's value. It doesn't control a device. Needs an administrator's token.

**Inputs**

- Entity (`entity`, text, required): The entity, such as sensor.open_orders. One that doesn't exist yet is made.
- State (`state`, text, required): The value to show.
- Attributes (`attributes`, object): Attributes to show with it, such as unit_of_measurement: orders.

**Outputs**

- `attributes` (object): Its attributes, such as brightness or battery level
- `created` (true/false): True if the entity was new
- `entity_id` (text): The entity's ID, such as light.kitchen
- `last_changed` (text): When its state last changed (ISO 8601)
- `last_updated` (text): When it was last updated (ISO 8601)
- `name` (text): Its name
- `state` (text): Its state, such as on, off, 21.5 or home
- `unit` (text): The state's unit, such as °C, if it has one

**Example output**

```json
{
  "attributes": {
    "brightness": 204,
    "friendly_name": "Kitchen light"
  },
  "created": false,
  "entity_id": "sensor.open_orders",
  "last_changed": "2026-10-28T08:59:00+00:00",
  "last_updated": "2026-10-28T08:59:00+00:00",
  "name": "Kitchen light",
  "state": "12",
  "unit": ""
}
```

### Toggle

Turn things on if they're off, and off if they're on.

**Inputs**

- Entities (`entity`, list, required): What to toggle.

**Outputs**

- `changed` (list): The entities whose state changed
- `entities` (list): The entities asked for

**Example output**

```json
{
  "changed": [
    {
      "attributes": {
        "brightness": 204,
        "friendly_name": "Kitchen light"
      },
      "entity_id": "light.kitchen",
      "last_changed": "2026-10-28T08:59:00+00:00",
      "last_updated": "2026-10-28T08:59:00+00:00",
      "name": "Kitchen light",
      "state": "on",
      "unit": ""
    }
  ],
  "entities": [
    "light.kitchen"
  ]
}
```

### Turn off

Turn off lights, switches, fans and more.

**Inputs**

- Entities (`entity`, list, required): What to turn off.

**Outputs**

- `changed` (list): The entities whose state changed
- `entities` (list): The entities asked for

**Example output**

```json
{
  "changed": [
    {
      "attributes": {},
      "entity_id": "light.kitchen",
      "last_changed": "2026-10-28T08:59:00+00:00",
      "last_updated": "2026-10-28T08:59:00+00:00",
      "name": "Kitchen light",
      "state": "off",
      "unit": ""
    }
  ],
  "entities": [
    "light.kitchen"
  ]
}
```

### Turn on

Turn on lights, switches, fans, scenes, scripts and more.

**Inputs**

- Entities (`entity`, list, required): What to turn on.
- Brightness (`brightness_percent`, number): For lights, how bright, from 0 to 100 percent. From 0 to 100.

**Outputs**

- `changed` (list): The entities whose state changed
- `entities` (list): The entities asked for

**Example output**

```json
{
  "changed": [
    {
      "attributes": {
        "brightness": 204,
        "friendly_name": "Kitchen light"
      },
      "entity_id": "light.kitchen",
      "last_changed": "2026-10-28T08:59:00+00:00",
      "last_updated": "2026-10-28T08:59:00+00:00",
      "name": "Kitchen light",
      "state": "on",
      "unit": ""
    }
  ],
  "entities": [
    "light.kitchen"
  ]
}
```
