From 6530f3cbe2e623b40d16df763de71244f384b2a5 Mon Sep 17 00:00:00 2001 From: rubenverhoef Date: Tue, 22 Feb 2022 00:01:06 +0100 Subject: [PATCH] Mqtt light cmd template (#20941) --- source/_docs/mqtt/discovery.markdown | 2 ++ source/_integrations/light.mqtt.markdown | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/source/_docs/mqtt/discovery.markdown b/source/_docs/mqtt/discovery.markdown index 2f9fb500a39..a3793a86cfe 100644 --- a/source/_docs/mqtt/discovery.markdown +++ b/source/_docs/mqtt/discovery.markdown @@ -88,6 +88,7 @@ Supported abbreviations: 'away_mode_stat_t': 'away_mode_state_topic', 'b_tpl': 'blue_template', 'bri_cmd_t': 'brightness_command_topic', + 'bri_cmd_tpl': 'brightness_command_template', 'bri_scl': 'brightness_scale', 'bri_stat_t': 'brightness_state_topic', 'bri_tpl': 'brightness_template', @@ -126,6 +127,7 @@ Supported abbreviations: 'flsh_tlng': 'flash_time_long', 'flsh_tsht': 'flash_time_short', 'fx_cmd_t': 'effect_command_topic', + 'fx_cmd_tpl': 'effect_command_template', 'fx_list': 'effect_list', 'fx_stat_t': 'effect_state_topic', 'fx_tpl': 'effect_template', diff --git a/source/_integrations/light.mqtt.markdown b/source/_integrations/light.mqtt.markdown index 823d513d5df..df5029fd57a 100644 --- a/source/_integrations/light.mqtt.markdown +++ b/source/_integrations/light.mqtt.markdown @@ -90,6 +90,10 @@ brightness_command_topic: description: The MQTT topic to publish commands to change the light’s brightness. required: false type: string +brightness_command_template: + description: "Defines a [template](/docs/configuration/templating/) to compose message which will be sent to `brightness_command_topic`. Available variables: `value`." + required: false + type: string brightness_scale: description: "Defines the maximum brightness value (i.e., 100%) of the MQTT device." required: false @@ -191,6 +195,10 @@ effect_command_topic: description: "The MQTT topic to publish commands to change the light's effect state." required: false type: string +effect_command_template: + description: "Defines a [template](/docs/configuration/templating/) to compose message which will be sent to `effect_command_topic`. Available variables: `value`." + required: false + type: string effect_list: description: The list of effects the light supports. required: false