Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions docs/node/binary-sensor.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@ The state of the entity should be updated to

To set the Home Assistant state to `Unknown`, send a state with a js expression `null`.

### Available

- Type: `boolean`
- Default: `true`

Whether the Home Assistant entity is available. By default, every update sends available as true. On creation, or after a Home Assistant restart without Resend, the entity starts unavailable until availability is set again.

If availability comes from a message, flow, global, or expression, and that value is missing, it is not sent and Home Assistant leaves availability unchanged. In that case, set availability again after a Home Assistant or Node-RED restart or the entity will remain unavailable.

### Attributes

- Type: `Object`
Expand All @@ -30,6 +39,12 @@ Key/Value pair of attributes to update. The key should be a string and the value

Determine how input values will be handled. When merge is selected the message object values will override the configuration values.

## Partial updates

State, available, and the attribute map are updated independently. Home Assistant keeps the last value for anything omitted.

For example, you can send a new state without changing attributes, flip availability without a state, or update the attribute map alone. A message that resolves nothing for all three parts is ignored (no update is sent).

## Inputs

properties of `msg.payload`
Expand All @@ -40,6 +55,12 @@ properties of `msg.payload`

The value of the entity state will be updated.

### available

- Type: `boolean`

Optional. Sets entity availability for this update. Omit to leave availability unchanged.

### attributes

- Type: `Object`
Expand Down
4 changes: 2 additions & 2 deletions docs/node/entity-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ If the entity has already been registered with Home Assistant when no device was
- Type: `string`
- Values: `binary_sensor|button|sensor|switch`

### Resend state and attributes
### Resend state, attributes, and available

- Type: `boolean`

When the entity in Home Assistant is created the state and attributes will also be set. This is only applicable with certain entities nodes.
When the entity in Home Assistant is created the last state, attributes, and available value will also be set. This is only applicable with certain entity nodes.

### Other Properties

Expand Down
4 changes: 2 additions & 2 deletions docs/node/entity.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ Key/Value pair of attributes to update. The key should be a string and the value

Determine how input values will be handled. When merge is selected the message object values will override the configuration values.

### Resend state and attributes
### Resend state, attributes, and available

- Type: `boolean`

When creating the entity in Home Assistant this will also send the last updated state and attributes then node sent to Home Assistant
When creating the entity in Home Assistant this will also send the last updated state, attributes, and available value the node sent to Home Assistant

## Switch Configuration

Expand Down
25 changes: 23 additions & 2 deletions docs/node/sensor.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@ The state the entity should be updated to

To set the Home Assistant state to `Unknown`, send a state with a js expression `null`.

### Available

- Type: `boolean`
- Default: `true`

Whether the Home Assistant entity is available. By default, every update sends available as true. On creation, or after a Home Assistant restart without Resend, the entity starts unavailable until availability is set again.

If availability comes from a message, flow, global, or expression, and that value is missing, it is not sent and Home Assistant leaves availability unchanged. In that case, set availability again after a Home Assistant or Node-RED restart or the entity will remain unavailable.

### Attributes

- Type: `Object`
Expand All @@ -30,11 +39,17 @@ Key/Value pair of attributes to update. The key should be a string and the value

Determine how input values will be handled. When merge is selected the message object values will override the configuration values.

### Resend state and attributes
### Resend state, attributes, and available

- Type: `boolean`

When creating the entity in Home Assistant this will also send the last updated state and attributes then node sent to Home Assistant
When creating the entity in Home Assistant this will also send the last updated state, attributes, and available value the node sent to Home Assistant

## Partial updates

State, available, and the attribute map are updated independently. Home Assistant keeps the last value for anything omitted.

For example, you can send a new state without changing attributes, flip availability without a state, or update the attribute map alone. A message that resolves nothing for all three parts is ignored (no update is sent).

## Inputs

Expand All @@ -46,6 +61,12 @@ properties of `msg.payload`

The state the entity should be updated to

### available

- Type: `boolean`

Optional. Sets entity availability for this update. Omit to leave availability unchanged.

### attributes

- Type: `Object`
Expand Down
Loading