add state_class to rest sensor & device_class to rest switch (#19860)

This commit is contained in:
Chris Browet 2021-10-22 22:57:24 +02:00 committed by GitHub
parent 8087cea274
commit 8a8564272b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 2 deletions

View File

@ -86,7 +86,7 @@ name:
type: string
default: REST Binary Sensor
device_class:
description: Sets the [class of the device](/integrations/binary_sensor/), changing the device state and icon that is displayed on the frontend.
description: Sets the [class of the device](/integrations/binary_sensor/#device-class), changing the device state and icon that is displayed on the frontend.
required: false
type: string
value_template:

View File

@ -65,7 +65,11 @@ name:
type: string
default: REST Sensor
device_class:
description: Sets the [class of the device](/integrations/sensor/), changing the device state and icon that is displayed on the frontend.
description: Sets the [class of the device](/integrations/sensor#device-class), changing the device state and icon that is displayed on the frontend.
required: false
type: string
state_class:
description: The [state_class](https://developers.home-assistant.io/docs/core/entity/sensor#available-state-classes) of the sensor.
required: false
type: string
value_template:

View File

@ -40,6 +40,10 @@ name:
required: false
type: string
default: REST Switch
device_class:
description: Sets the [class of the device](/integrations/switch/#device-class), changing the device state and icon that is displayed on the frontend.
required: false
type: string
timeout:
description: Timeout for the request.
required: false