From c252758ac2dc825972b65f0951d28a3e06a44d92 Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Tue, 11 Jul 2023 23:06:32 +0200 Subject: [PATCH] Migrate integration services (B-D) to support translations (#96363) --- homeassistant/components/alert/services.yaml | 6 -- homeassistant/components/alert/strings.json | 14 ++++ .../components/blackbird/services.yaml | 6 -- .../components/blackbird/strings.json | 18 +++++ homeassistant/components/blink/services.yaml | 21 ------ homeassistant/components/blink/strings.json | 52 +++++++++++++- .../components/bluesound/services.yaml | 18 ----- .../components/bluesound/strings.json | 48 +++++++++++++ .../bluetooth_tracker/services.yaml | 2 - .../components/bluetooth_tracker/strings.json | 8 +++ homeassistant/components/bond/services.yaml | 30 -------- homeassistant/components/bond/strings.json | 70 +++++++++++++++++++ .../components/browser/services.yaml | 4 -- homeassistant/components/browser/strings.json | 14 ++++ homeassistant/components/cast/services.yaml | 8 --- homeassistant/components/cast/strings.json | 22 +++++- .../components/channels/services.yaml | 8 --- .../components/channels/strings.json | 22 ++++++ .../components/cloudflare/services.yaml | 2 - .../components/cloudflare/strings.json | 6 ++ .../components/color_extractor/services.yaml | 12 ---- .../components/color_extractor/strings.json | 18 +++++ .../components/command_line/services.yaml | 2 - .../components/command_line/strings.json | 6 ++ .../components/counter/services.yaml | 10 --- homeassistant/components/counter/strings.json | 24 +++++++ .../components/debugpy/services.yaml | 2 - homeassistant/components/debugpy/strings.json | 8 +++ homeassistant/components/deconz/services.yaml | 32 --------- homeassistant/components/deconz/strings.json | 44 ++++++++++++ .../components/denonavr/services.yaml | 9 --- .../components/denonavr/strings.json | 26 +++++++ .../components/dominos/services.yaml | 4 -- homeassistant/components/dominos/strings.json | 14 ++++ .../components/downloader/services.yaml | 10 --- .../components/downloader/strings.json | 26 +++++++ .../components/duckdns/services.yaml | 4 -- homeassistant/components/duckdns/strings.json | 14 ++++ .../components/dynalite/services.yaml | 13 ---- .../components/dynalite/strings.json | 38 ++++++++++ 40 files changed, 490 insertions(+), 205 deletions(-) create mode 100644 homeassistant/components/blackbird/strings.json create mode 100644 homeassistant/components/bluesound/strings.json create mode 100644 homeassistant/components/bluetooth_tracker/strings.json create mode 100644 homeassistant/components/browser/strings.json create mode 100644 homeassistant/components/channels/strings.json create mode 100644 homeassistant/components/color_extractor/strings.json create mode 100644 homeassistant/components/debugpy/strings.json create mode 100644 homeassistant/components/dominos/strings.json create mode 100644 homeassistant/components/downloader/strings.json create mode 100644 homeassistant/components/duckdns/strings.json diff --git a/homeassistant/components/alert/services.yaml b/homeassistant/components/alert/services.yaml index 3242a9cedb4..e1d842f5bc4 100644 --- a/homeassistant/components/alert/services.yaml +++ b/homeassistant/components/alert/services.yaml @@ -1,20 +1,14 @@ toggle: - name: Toggle - description: Toggle alert's notifications. target: entity: domain: alert turn_off: - name: Turn off - description: Silence alert's notifications. target: entity: domain: alert turn_on: - name: Turn on - description: Reset alert's notifications. target: entity: domain: alert diff --git a/homeassistant/components/alert/strings.json b/homeassistant/components/alert/strings.json index 4d948b2f4d1..16192d5d595 100644 --- a/homeassistant/components/alert/strings.json +++ b/homeassistant/components/alert/strings.json @@ -9,5 +9,19 @@ "on": "[%key:common::state::active%]" } } + }, + "services": { + "toggle": { + "name": "Toggle", + "description": "Toggles alert's notifications." + }, + "turn_off": { + "name": "Turn off", + "description": "Silences alert's notifications." + }, + "turn_on": { + "name": "Turn on", + "description": "Resets alert's notifications." + } } } diff --git a/homeassistant/components/blackbird/services.yaml b/homeassistant/components/blackbird/services.yaml index 7b3096c25e4..00425c93eb6 100644 --- a/homeassistant/components/blackbird/services.yaml +++ b/homeassistant/components/blackbird/services.yaml @@ -1,10 +1,6 @@ set_all_zones: - name: Set all zones - description: Set all Blackbird zones to a single source. fields: entity_id: - name: Entity - description: Name of any blackbird zone. required: true example: "media_player.zone_1" selector: @@ -12,8 +8,6 @@ set_all_zones: integration: blackbird domain: media_player source: - name: Source - description: Name of source to switch to. required: true example: "Source 1" selector: diff --git a/homeassistant/components/blackbird/strings.json b/homeassistant/components/blackbird/strings.json new file mode 100644 index 00000000000..93c0e6ef23d --- /dev/null +++ b/homeassistant/components/blackbird/strings.json @@ -0,0 +1,18 @@ +{ + "services": { + "set_all_zones": { + "name": "Set all zones", + "description": "Sets all Blackbird zones to a single source.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name of any blackbird zone." + }, + "source": { + "name": "Source", + "description": "Name of source to switch to." + } + } + } + } +} diff --git a/homeassistant/components/blink/services.yaml b/homeassistant/components/blink/services.yaml index 3d51ba2f7bb..95f4d33f91f 100644 --- a/homeassistant/components/blink/services.yaml +++ b/homeassistant/components/blink/services.yaml @@ -1,62 +1,41 @@ # Describes the format for available Blink services blink_update: - name: Update - description: Force a refresh. - trigger_camera: - name: Trigger camera - description: Request camera to take new image. target: entity: integration: blink domain: camera save_video: - name: Save video - description: Save last recorded video clip to local file. fields: name: - name: Name - description: Name of camera to grab video from. required: true example: "Living Room" selector: text: filename: - name: File name - description: Filename to writable path (directory may need to be included in allowlist_external_dirs in config) required: true example: "/tmp/video.mp4" selector: text: save_recent_clips: - name: Save recent clips - description: 'Save all recent video clips to local directory with file pattern "%Y%m%d_%H%M%S_{name}.mp4"' fields: name: - name: Name - description: Name of camera to grab recent clips from. required: true example: "Living Room" selector: text: file_path: - name: Output directory - description: Directory name of writable path (directory may need to be included in allowlist_external_dirs in config) required: true example: "/tmp" selector: text: send_pin: - name: Send pin - description: Send a new PIN to blink for 2FA. fields: pin: - name: Pin - description: PIN received from blink. Leave empty if you only received a verification email. example: "abc123" selector: text: diff --git a/homeassistant/components/blink/strings.json b/homeassistant/components/blink/strings.json index 61c9a21af37..6c07d1fea55 100644 --- a/homeassistant/components/blink/strings.json +++ b/homeassistant/components/blink/strings.json @@ -10,7 +10,9 @@ }, "2fa": { "title": "Two-factor authentication", - "data": { "2fa": "Two-factor code" }, + "data": { + "2fa": "Two-factor code" + }, "description": "Enter the PIN sent via email or SMS" } }, @@ -46,5 +48,53 @@ "name": "Camera armed" } } + }, + "services": { + "blink_update": { + "name": "Update", + "description": "Forces a refresh." + }, + "trigger_camera": { + "name": "Trigger camera", + "description": "Requests camera to take new image." + }, + "save_video": { + "name": "Save video", + "description": "Saves last recorded video clip to local file.", + "fields": { + "name": { + "name": "Name", + "description": "Name of camera to grab video from." + }, + "filename": { + "name": "File name", + "description": "Filename to writable path (directory may need to be included in allowlist_external_dirs in config)." + } + } + }, + "save_recent_clips": { + "name": "Save recent clips", + "description": "Saves all recent video clips to local directory with file pattern \"%Y%m%d_%H%M%S_{name}.mp4\".", + "fields": { + "name": { + "name": "Name", + "description": "Name of camera to grab recent clips from." + }, + "file_path": { + "name": "Output directory", + "description": "Directory name of writable path (directory may need to be included in allowlist_external_dirs in config)." + } + } + }, + "send_pin": { + "name": "Send pin", + "description": "Sends a new PIN to blink for 2FA.", + "fields": { + "pin": { + "name": "Pin", + "description": "PIN received from blink. Leave empty if you only received a verification email." + } + } + } } } diff --git a/homeassistant/components/bluesound/services.yaml b/homeassistant/components/bluesound/services.yaml index 7c04cc00f39..7ab69a82124 100644 --- a/homeassistant/components/bluesound/services.yaml +++ b/homeassistant/components/bluesound/services.yaml @@ -1,54 +1,36 @@ join: - name: Join - description: Group player together. fields: master: - name: Master - description: Entity ID of the player that should become the master of the group. required: true selector: entity: integration: bluesound domain: media_player entity_id: - name: Entity - description: Name of entity that will coordinate the grouping. Platform dependent. selector: entity: integration: bluesound domain: media_player unjoin: - name: Unjoin - description: Unjoin the player from a group. fields: entity_id: - name: Entity - description: Name of entity that will be unjoined from their group. Platform dependent. selector: entity: integration: bluesound domain: media_player set_sleep_timer: - name: Set sleep timer - description: "Set a Bluesound timer. It will increase timer in steps: 15, 30, 45, 60, 90, 0" fields: entity_id: - name: Entity - description: Name(s) of entities that will have a timer set. selector: entity: integration: bluesound domain: media_player clear_sleep_timer: - name: Clear sleep timer - description: Clear a Bluesound timer. fields: entity_id: - name: Entity - description: Name(s) of entities that will have the timer cleared. selector: entity: integration: bluesound diff --git a/homeassistant/components/bluesound/strings.json b/homeassistant/components/bluesound/strings.json new file mode 100644 index 00000000000..f41c34a7449 --- /dev/null +++ b/homeassistant/components/bluesound/strings.json @@ -0,0 +1,48 @@ +{ + "services": { + "join": { + "name": "Join", + "description": "Group player together.", + "fields": { + "master": { + "name": "Master", + "description": "Entity ID of the player that should become the master of the group." + }, + "entity_id": { + "name": "Entity", + "description": "Name of entity that will coordinate the grouping. Platform dependent." + } + } + }, + "unjoin": { + "name": "Unjoin", + "description": "Unjoin the player from a group.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name of entity that will be unjoined from their group. Platform dependent." + } + } + }, + "set_sleep_timer": { + "name": "Set sleep timer", + "description": "Set a Bluesound timer. It will increase timer in steps: 15, 30, 45, 60, 90, 0.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities that will have a timer set." + } + } + }, + "clear_sleep_timer": { + "name": "Clear sleep timer", + "description": "Clear a Bluesound timer.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities that will have the timer cleared." + } + } + } + } +} diff --git a/homeassistant/components/bluetooth_tracker/services.yaml b/homeassistant/components/bluetooth_tracker/services.yaml index 3150403dbf1..91b8669505b 100644 --- a/homeassistant/components/bluetooth_tracker/services.yaml +++ b/homeassistant/components/bluetooth_tracker/services.yaml @@ -1,3 +1 @@ update: - name: Update - description: Trigger manual tracker update diff --git a/homeassistant/components/bluetooth_tracker/strings.json b/homeassistant/components/bluetooth_tracker/strings.json new file mode 100644 index 00000000000..bf22845d054 --- /dev/null +++ b/homeassistant/components/bluetooth_tracker/strings.json @@ -0,0 +1,8 @@ +{ + "services": { + "update": { + "name": "Update", + "description": "Triggers manual tracker update." + } + } +} diff --git a/homeassistant/components/bond/services.yaml b/homeassistant/components/bond/services.yaml index 6be18eaa1ef..bda0bc5835f 100644 --- a/homeassistant/components/bond/services.yaml +++ b/homeassistant/components/bond/services.yaml @@ -1,13 +1,9 @@ # Describes the format for available bond services set_fan_speed_tracked_state: - name: Set fan speed tracked state - description: Sets the tracked fan speed for a bond fan fields: entity_id: - description: Name(s) of entities to set the tracked fan speed. example: "fan.living_room_fan" - name: Entity required: true selector: entity: @@ -15,8 +11,6 @@ set_fan_speed_tracked_state: domain: fan speed: required: true - name: Fan Speed - description: Fan Speed as %. example: 50 selector: number: @@ -26,13 +20,9 @@ set_fan_speed_tracked_state: mode: slider set_switch_power_tracked_state: - name: Set switch power tracked state - description: Sets the tracked power state of a bond switch fields: entity_id: - description: Name(s) of entities to set the tracked power state of. example: "switch.whatever" - name: Entity required: true selector: entity: @@ -40,20 +30,14 @@ set_switch_power_tracked_state: domain: switch power_state: required: true - name: Power state - description: Power state example: true selector: boolean: set_light_power_tracked_state: - name: Set light power tracked state - description: Sets the tracked power state of a bond light fields: entity_id: - description: Name(s) of entities to set the tracked power state of. example: "light.living_room_lights" - name: Entity required: true selector: entity: @@ -61,20 +45,14 @@ set_light_power_tracked_state: domain: light power_state: required: true - name: Power state - description: Power state example: true selector: boolean: set_light_brightness_tracked_state: - name: Set light brightness tracked state - description: Sets the tracked brightness state of a bond light fields: entity_id: - description: Name(s) of entities to set the tracked brightness state of. example: "light.living_room_lights" - name: Entity required: true selector: entity: @@ -82,8 +60,6 @@ set_light_brightness_tracked_state: domain: light brightness: required: true - name: Brightness - description: Brightness example: 50 selector: number: @@ -93,24 +69,18 @@ set_light_brightness_tracked_state: mode: slider start_increasing_brightness: - name: Start increasing brightness - description: "Start increasing the brightness of the light. (deprecated)" target: entity: integration: bond domain: light start_decreasing_brightness: - name: Start decreasing brightness - description: "Start decreasing the brightness of the light. (deprecated)" target: entity: integration: bond domain: light stop: - name: Stop - description: "Stop any in-progress action and empty the queue. (deprecated)" target: entity: integration: bond diff --git a/homeassistant/components/bond/strings.json b/homeassistant/components/bond/strings.json index e923ded939e..9cbd895683c 100644 --- a/homeassistant/components/bond/strings.json +++ b/homeassistant/components/bond/strings.json @@ -24,5 +24,75 @@ "abort": { "already_configured": "[%key:common::config_flow::abort::already_configured_device%]" } + }, + "services": { + "set_fan_speed_tracked_state": { + "name": "Set fan speed tracked state", + "description": "Sets the tracked fan speed for a bond fan.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities to set the tracked fan speed." + }, + "speed": { + "name": "Fan Speed", + "description": "Fan Speed as %." + } + } + }, + "set_switch_power_tracked_state": { + "name": "Set switch power tracked state", + "description": "Sets the tracked power state of a bond switch.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities to set the tracked power state of." + }, + "power_state": { + "name": "Power state", + "description": "Power state." + } + } + }, + "set_light_power_tracked_state": { + "name": "Set light power tracked state", + "description": "Sets the tracked power state of a bond light.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities to set the tracked power state of." + }, + "power_state": { + "name": "Power state", + "description": "Power state." + } + } + }, + "set_light_brightness_tracked_state": { + "name": "Set light brightness tracked state", + "description": "Sets the tracked brightness state of a bond light.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Name(s) of entities to set the tracked brightness state of." + }, + "brightness": { + "name": "Brightness", + "description": "Brightness." + } + } + }, + "start_increasing_brightness": { + "name": "Start increasing brightness", + "description": "Start increasing the brightness of the light. (deprecated)." + }, + "start_decreasing_brightness": { + "name": "Start decreasing brightness", + "description": "Start decreasing the brightness of the light. (deprecated)." + }, + "stop": { + "name": "Stop", + "description": "Stop any in-progress action and empty the queue. (deprecated)." + } } } diff --git a/homeassistant/components/browser/services.yaml b/homeassistant/components/browser/services.yaml index dd3ddd095cc..c2192911eea 100644 --- a/homeassistant/components/browser/services.yaml +++ b/homeassistant/components/browser/services.yaml @@ -1,10 +1,6 @@ browse_url: - name: Browse - description: Open a URL in the default browser on the host machine of Home Assistant. fields: url: - name: URL - description: The URL to open. required: true example: "https://www.home-assistant.io" selector: diff --git a/homeassistant/components/browser/strings.json b/homeassistant/components/browser/strings.json new file mode 100644 index 00000000000..fafd5fb96b0 --- /dev/null +++ b/homeassistant/components/browser/strings.json @@ -0,0 +1,14 @@ +{ + "services": { + "browse_url": { + "name": "Browse", + "description": "Opens a URL in the default browser on the host machine of Home Assistant.", + "fields": { + "url": { + "name": "URL", + "description": "The URL to open." + } + } + } + } +} diff --git a/homeassistant/components/cast/services.yaml b/homeassistant/components/cast/services.yaml index f0fbcf4a8d7..e2e23ad40a2 100644 --- a/homeassistant/components/cast/services.yaml +++ b/homeassistant/components/cast/services.yaml @@ -1,25 +1,17 @@ show_lovelace_view: - name: Show lovelace view - description: Show a Lovelace view on a Chromecast. fields: entity_id: - name: Entity - description: Media Player entity to show the Lovelace view on. required: true selector: entity: integration: cast domain: media_player dashboard_path: - name: Dashboard path - description: The URL path of the Lovelace dashboard to show. required: true example: lovelace-cast selector: text: view_path: - name: View Path - description: The path of the Lovelace view to show. example: downstairs selector: text: diff --git a/homeassistant/components/cast/strings.json b/homeassistant/components/cast/strings.json index 719465e98ca..4de0f85851f 100644 --- a/homeassistant/components/cast/strings.json +++ b/homeassistant/components/cast/strings.json @@ -30,7 +30,7 @@ }, "advanced_options": { "title": "Advanced Google Cast configuration", - "description": "Allowed UUIDs - A comma-separated list of UUIDs of Cast devices to add to Home Assistant. Use only if you don’t want to add all available cast devices.\nIgnore CEC - A comma-separated list of Chromecasts that should ignore CEC data for determining the active input. This will be passed to pychromecast.IGNORE_CEC.", + "description": "Allowed UUIDs - A comma-separated list of UUIDs of Cast devices to add to Home Assistant. Use only if you don\u2019t want to add all available cast devices.\nIgnore CEC - A comma-separated list of Chromecasts that should ignore CEC data for determining the active input. This will be passed to pychromecast.IGNORE_CEC.", "data": { "ignore_cec": "Ignore CEC", "uuid": "Allowed UUIDs" @@ -40,5 +40,25 @@ "error": { "invalid_known_hosts": "Known hosts must be a comma separated list of hosts." } + }, + "services": { + "show_lovelace_view": { + "name": "Show dashboard view", + "description": "Shows a dashboard view on a Chromecast device.", + "fields": { + "entity_id": { + "name": "Entity", + "description": "Media player entity to show the dashboard view on." + }, + "dashboard_path": { + "name": "Dashboard path", + "description": "The URL path of the dashboard to show." + }, + "view_path": { + "name": "View path", + "description": "The path of the dashboard view to show." + } + } + } } } diff --git a/homeassistant/components/channels/services.yaml b/homeassistant/components/channels/services.yaml index 5aa2f1ebda7..73ac6675ccf 100644 --- a/homeassistant/components/channels/services.yaml +++ b/homeassistant/components/channels/services.yaml @@ -1,30 +1,22 @@ seek_forward: - name: Seek forward - description: Seek forward by a set number of seconds. target: entity: integration: channels domain: media_player seek_backward: - name: Seek backward - description: Seek backward by a set number of seconds. target: entity: integration: channels domain: media_player seek_by: - name: Seek by - description: Seek by an inputted number of seconds. target: entity: integration: channels domain: media_player fields: seconds: - name: Seconds - description: Number of seconds to seek by. Negative numbers seek backwards. required: true selector: number: diff --git a/homeassistant/components/channels/strings.json b/homeassistant/components/channels/strings.json new file mode 100644 index 00000000000..0eceed8a8e0 --- /dev/null +++ b/homeassistant/components/channels/strings.json @@ -0,0 +1,22 @@ +{ + "services": { + "seek_forward": { + "name": "Seek forward", + "description": "Seeks forward by a set number of seconds." + }, + "seek_backward": { + "name": "Seek backward", + "description": "Seeks backward by a set number of seconds." + }, + "seek_by": { + "name": "Seek by", + "description": "Seeks by an inputted number of seconds.", + "fields": { + "seconds": { + "name": "Seconds", + "description": "Number of seconds to seek by. Negative numbers seek backwards." + } + } + } + } +} diff --git a/homeassistant/components/cloudflare/services.yaml b/homeassistant/components/cloudflare/services.yaml index f9465e788d8..e800a3a3eee 100644 --- a/homeassistant/components/cloudflare/services.yaml +++ b/homeassistant/components/cloudflare/services.yaml @@ -1,3 +1 @@ update_records: - name: Update records - description: Manually trigger update to Cloudflare records diff --git a/homeassistant/components/cloudflare/strings.json b/homeassistant/components/cloudflare/strings.json index 89bc67feeed..080be414b5c 100644 --- a/homeassistant/components/cloudflare/strings.json +++ b/homeassistant/components/cloudflare/strings.json @@ -38,5 +38,11 @@ "single_instance_allowed": "[%key:common::config_flow::abort::single_instance_allowed%]", "unknown": "[%key:common::config_flow::error::unknown%]" } + }, + "services": { + "update_records": { + "name": "Update records", + "description": "Manually trigger update to Cloudflare records." + } } } diff --git a/homeassistant/components/color_extractor/services.yaml b/homeassistant/components/color_extractor/services.yaml index be278a59059..2fd0b0db815 100644 --- a/homeassistant/components/color_extractor/services.yaml +++ b/homeassistant/components/color_extractor/services.yaml @@ -1,25 +1,13 @@ turn_on: - name: Turn on - description: - Set the light RGB to the predominant color found in the image provided by - URL or file path. target: entity: domain: light fields: color_extract_url: - name: URL - description: - The URL of the image we want to extract RGB values from. Must be allowed - in allowlist_external_urls. example: https://www.example.com/images/logo.png selector: text: color_extract_path: - name: Path - description: - The full system path to the image we want to extract RGB values from. - Must be allowed in allowlist_external_dirs. example: /opt/images/logo.png selector: text: diff --git a/homeassistant/components/color_extractor/strings.json b/homeassistant/components/color_extractor/strings.json new file mode 100644 index 00000000000..df720586631 --- /dev/null +++ b/homeassistant/components/color_extractor/strings.json @@ -0,0 +1,18 @@ +{ + "services": { + "turn_on": { + "name": "Turn on", + "description": "Sets the light RGB to the predominant color found in the image provided by URL or file path.", + "fields": { + "color_extract_url": { + "name": "URL", + "description": "The URL of the image we want to extract RGB values from. Must be allowed in allowlist_external_urls." + }, + "color_extract_path": { + "name": "Path", + "description": "The full system path to the image we want to extract RGB values from. Must be allowed in allowlist_external_dirs." + } + } + } + } +} diff --git a/homeassistant/components/command_line/services.yaml b/homeassistant/components/command_line/services.yaml index f4cec426860..c983a105c93 100644 --- a/homeassistant/components/command_line/services.yaml +++ b/homeassistant/components/command_line/services.yaml @@ -1,3 +1 @@ reload: - name: Reload - description: Reload all command_line entities diff --git a/homeassistant/components/command_line/strings.json b/homeassistant/components/command_line/strings.json index dab4a77a6ec..e249ad877d5 100644 --- a/homeassistant/components/command_line/strings.json +++ b/homeassistant/components/command_line/strings.json @@ -4,5 +4,11 @@ "title": "Command Line YAML configuration has moved", "description": "Configuring Command Line `{platform}` using YAML has moved.\n\nConsult the documentation to move your YAML configuration to integration key and restart Home Assistant to fix this issue." } + }, + "services": { + "reload": { + "name": "Reload", + "description": "Reloads command line configuration from the YAML-configuration." + } } } diff --git a/homeassistant/components/counter/services.yaml b/homeassistant/components/counter/services.yaml index 835d39c9d2e..643fc223083 100644 --- a/homeassistant/components/counter/services.yaml +++ b/homeassistant/components/counter/services.yaml @@ -1,37 +1,27 @@ # Describes the format for available counter services decrement: - name: Decrement - description: Decrement a counter. target: entity: domain: counter increment: - name: Increment - description: Increment a counter. target: entity: domain: counter reset: - name: Reset - description: Reset a counter. target: entity: domain: counter set_value: - name: Set - description: Set the counter value target: entity: domain: counter fields: value: - name: Value required: true - description: The new counter value the entity should be set to. selector: number: min: 0 diff --git a/homeassistant/components/counter/strings.json b/homeassistant/components/counter/strings.json index 6dcfe14a03a..0446b244787 100644 --- a/homeassistant/components/counter/strings.json +++ b/homeassistant/components/counter/strings.json @@ -38,5 +38,29 @@ } } } + }, + "services": { + "decrement": { + "name": "Decrement", + "description": "Decrements a counter." + }, + "increment": { + "name": "Increment", + "description": "Increments a counter." + }, + "reset": { + "name": "Reset", + "description": "Resets a counter." + }, + "set_value": { + "name": "Set", + "description": "Sets the counter value.", + "fields": { + "value": { + "name": "Value", + "description": "The new counter value the entity should be set to." + } + } + } } } diff --git a/homeassistant/components/debugpy/services.yaml b/homeassistant/components/debugpy/services.yaml index c864684226f..453b3af46bd 100644 --- a/homeassistant/components/debugpy/services.yaml +++ b/homeassistant/components/debugpy/services.yaml @@ -1,4 +1,2 @@ # Describes the format for available Remote Python Debugger services start: - name: Start - description: Start the Remote Python Debugger diff --git a/homeassistant/components/debugpy/strings.json b/homeassistant/components/debugpy/strings.json new file mode 100644 index 00000000000..b03a57a51dc --- /dev/null +++ b/homeassistant/components/debugpy/strings.json @@ -0,0 +1,8 @@ +{ + "services": { + "start": { + "name": "Start", + "description": "Starts the Remote Python Debugger." + } + } +} diff --git a/homeassistant/components/deconz/services.yaml b/homeassistant/components/deconz/services.yaml index 9084728a216..d08312852b3 100644 --- a/homeassistant/components/deconz/services.yaml +++ b/homeassistant/components/deconz/services.yaml @@ -1,65 +1,33 @@ configure: - name: Configure - description: >- - Configure attributes of either a device endpoint in deCONZ - or the deCONZ service itself. fields: entity: - name: Entity - description: Represents a specific device endpoint in deCONZ. selector: entity: integration: deconz field: - name: Path - description: >- - String representing a full path to deCONZ endpoint (when - entity is not specified) or a subpath of the device path for the - entity (when entity is specified). example: '"/lights/1/state" or "/state"' selector: text: data: - name: Configuration payload - description: JSON object with what data you want to alter. required: true example: '{"on": true}' selector: object: bridgeid: - name: Bridge identifier - description: >- - Unique string for each deCONZ hardware. - It can be found as part of the integration name. - Useful if you run multiple deCONZ integrations. example: "00212EFFFF012345" selector: text: device_refresh: - name: Device refresh - description: Refresh available devices from deCONZ. fields: bridgeid: - name: Bridge identifier - description: >- - Unique string for each deCONZ hardware. - It can be found as part of the integration name. - Useful if you run multiple deCONZ integrations. example: "00212EFFFF012345" selector: text: remove_orphaned_entries: - name: Remove orphaned entries - description: Clean up device and entity registry entries orphaned by deCONZ. fields: bridgeid: - name: Bridge identifier - description: >- - Unique string for each deCONZ hardware. - It can be found as part of the integration name. - Useful if you run multiple deCONZ integrations. example: "00212EFFFF012345" selector: text: diff --git a/homeassistant/components/deconz/strings.json b/homeassistant/components/deconz/strings.json index 45a19b0466d..448a221b2ca 100644 --- a/homeassistant/components/deconz/strings.json +++ b/homeassistant/components/deconz/strings.json @@ -105,5 +105,49 @@ "side_5": "Side 5", "side_6": "Side 6" } + }, + "services": { + "configure": { + "name": "Configure", + "description": "Configures attributes of either a device endpoint in deCONZ or the deCONZ service itself.", + "fields": { + "entity": { + "name": "Entity", + "description": "Represents a specific device endpoint in deCONZ." + }, + "field": { + "name": "Path", + "description": "String representing a full path to deCONZ endpoint (when entity is not specified) or a subpath of the device path for the entity (when entity is specified)." + }, + "data": { + "name": "Configuration payload", + "description": "JSON object with what data you want to alter." + }, + "bridgeid": { + "name": "Bridge identifier", + "description": "Unique string for each deCONZ hardware. It can be found as part of the integration name. Useful if you run multiple deCONZ integrations." + } + } + }, + "device_refresh": { + "name": "Device refresh", + "description": "Refreshes available devices from deCONZ.", + "fields": { + "bridgeid": { + "name": "Bridge identifier", + "description": "Unique string for each deCONZ hardware. It can be found as part of the integration name. Useful if you run multiple deCONZ integrations." + } + } + }, + "remove_orphaned_entries": { + "name": "Remove orphaned entries", + "description": "Cleans up device and entity registry entries orphaned by deCONZ.", + "fields": { + "bridgeid": { + "name": "Bridge identifier", + "description": "Unique string for each deCONZ hardware. It can be found as part of the integration name. Useful if you run multiple deCONZ integrations." + } + } + } } } diff --git a/homeassistant/components/denonavr/services.yaml b/homeassistant/components/denonavr/services.yaml index ee35732e311..9c53ff9994a 100644 --- a/homeassistant/components/denonavr/services.yaml +++ b/homeassistant/components/denonavr/services.yaml @@ -1,36 +1,27 @@ # Describes the format for available denonavr services get_command: - name: Get command - description: "Send a generic HTTP get command." target: entity: integration: denonavr domain: media_player fields: command: - name: Command - description: Endpoint of the command, including associated parameters. example: "/goform/formiPhoneAppDirect.xml?RCKSK0410370" required: true selector: text: set_dynamic_eq: - name: Set dynamic equalizer - description: "Enable or disable DynamicEQ." target: entity: integration: denonavr domain: media_player fields: dynamic_eq: - description: "True/false for enable/disable." default: true selector: boolean: update_audyssey: - name: Update audyssey - description: "Update Audyssey settings." target: entity: integration: denonavr diff --git a/homeassistant/components/denonavr/strings.json b/homeassistant/components/denonavr/strings.json index 1c85efc9ff4..a4e07e33a6a 100644 --- a/homeassistant/components/denonavr/strings.json +++ b/homeassistant/components/denonavr/strings.json @@ -46,5 +46,31 @@ } } } + }, + "services": { + "get_command": { + "name": "Get command", + "description": "Send sa generic HTTP get command.", + "fields": { + "command": { + "name": "Command", + "description": "Endpoint of the command, including associated parameters." + } + } + }, + "set_dynamic_eq": { + "name": "Set dynamic equalizer", + "description": "Enables or disables DynamicEQ.", + "fields": { + "dynamic_eq": { + "name": "Dynamic equalizer", + "description": "True/false for enable/disable." + } + } + }, + "update_audyssey": { + "name": "Update Audyssey", + "description": "Updates Audyssey settings." + } } } diff --git a/homeassistant/components/dominos/services.yaml b/homeassistant/components/dominos/services.yaml index 6a354bc3a63..f2261072ddd 100644 --- a/homeassistant/components/dominos/services.yaml +++ b/homeassistant/components/dominos/services.yaml @@ -1,10 +1,6 @@ order: - name: Order - description: Places a set of orders with Dominos Pizza. fields: order_entity_id: - name: Order Entity - description: The ID (as specified in the configuration) of an order to place. If provided as an array, all of the identified orders will be placed. example: dominos.medium_pan selector: text: diff --git a/homeassistant/components/dominos/strings.json b/homeassistant/components/dominos/strings.json new file mode 100644 index 00000000000..0ceabd7abe8 --- /dev/null +++ b/homeassistant/components/dominos/strings.json @@ -0,0 +1,14 @@ +{ + "services": { + "order": { + "name": "Order", + "description": "Places a set of orders with Dominos Pizza.", + "fields": { + "order_entity_id": { + "name": "Order entity", + "description": "The ID (as specified in the configuration) of an order to place. If provided as an array, all of the identified orders will be placed." + } + } + } + } +} diff --git a/homeassistant/components/downloader/services.yaml b/homeassistant/components/downloader/services.yaml index cecb3804227..54d06db5627 100644 --- a/homeassistant/components/downloader/services.yaml +++ b/homeassistant/components/downloader/services.yaml @@ -1,29 +1,19 @@ download_file: - name: Download file - description: Download a file to the download location. fields: url: - name: URL - description: The URL of the file to download. required: true example: "http://example.org/myfile" selector: text: subdir: - name: Subdirectory - description: Download into subdirectory. example: "download_dir" selector: text: filename: - name: Filename - description: Determine the filename. example: "my_file_name" selector: text: overwrite: - name: Overwrite - description: Whether to overwrite the file or not. default: false selector: boolean: diff --git a/homeassistant/components/downloader/strings.json b/homeassistant/components/downloader/strings.json new file mode 100644 index 00000000000..49a7388add2 --- /dev/null +++ b/homeassistant/components/downloader/strings.json @@ -0,0 +1,26 @@ +{ + "services": { + "download_file": { + "name": "Download file", + "description": "Downloads a file to the download location.", + "fields": { + "url": { + "name": "URL", + "description": "The URL of the file to download." + }, + "subdir": { + "name": "Subdirectory", + "description": "Download into subdirectory." + }, + "filename": { + "name": "Filename", + "description": "Determine the filename." + }, + "overwrite": { + "name": "Overwrite", + "description": "Whether to overwrite the file or not." + } + } + } + } +} diff --git a/homeassistant/components/duckdns/services.yaml b/homeassistant/components/duckdns/services.yaml index 6c8b5af8199..485afa44a03 100644 --- a/homeassistant/components/duckdns/services.yaml +++ b/homeassistant/components/duckdns/services.yaml @@ -1,10 +1,6 @@ set_txt: - name: Set TXT - description: Set the TXT record of your DuckDNS subdomain. fields: txt: - name: TXT - description: Payload for the TXT record. required: true example: "This domain name is reserved for use in documentation" selector: diff --git a/homeassistant/components/duckdns/strings.json b/homeassistant/components/duckdns/strings.json new file mode 100644 index 00000000000..d560b760e47 --- /dev/null +++ b/homeassistant/components/duckdns/strings.json @@ -0,0 +1,14 @@ +{ + "services": { + "set_txt": { + "name": "Set TXT", + "description": "Sets the TXT record of your DuckDNS subdomain.", + "fields": { + "txt": { + "name": "TXT", + "description": "Payload for the TXT record." + } + } + } + } +} diff --git a/homeassistant/components/dynalite/services.yaml b/homeassistant/components/dynalite/services.yaml index d34335ca1d3..97c5d9c2486 100644 --- a/homeassistant/components/dynalite/services.yaml +++ b/homeassistant/components/dynalite/services.yaml @@ -1,21 +1,16 @@ request_area_preset: - name: Request area preset - description: "Requests Dynalite to report the preset for an area." fields: host: - description: "Host gateway IP to send to or all configured gateways if not specified." example: "192.168.0.101" selector: text: area: - description: "Area to request the preset reported" required: true selector: number: min: 1 max: 9999 channel: - description: "Channel to request the preset to be reported from." default: 1 selector: number: @@ -23,26 +18,18 @@ request_area_preset: max: 9999 request_channel_level: - name: Request channel level - description: "Requests Dynalite to report the level of a specific channel." fields: host: - name: Host - description: "Host gateway IP to send to or all configured gateways if not specified." example: "192.168.0.101" selector: text: area: - name: Area - description: "Area for the requested channel" required: true selector: number: min: 1 max: 9999 channel: - name: Channel - description: "Channel to request the level for." required: true selector: number: diff --git a/homeassistant/components/dynalite/strings.json b/homeassistant/components/dynalite/strings.json index 8ad7deacd92..512e00237d9 100644 --- a/homeassistant/components/dynalite/strings.json +++ b/homeassistant/components/dynalite/strings.json @@ -14,5 +14,43 @@ "already_configured": "[%key:common::config_flow::abort::already_configured_device%]", "cannot_connect": "[%key:common::config_flow::error::cannot_connect%]" } + }, + "services": { + "request_area_preset": { + "name": "Request area preset", + "description": "Requests Dynalite to report the preset for an area.", + "fields": { + "host": { + "name": "Host", + "description": "Host gateway IP to send to or all configured gateways if not specified." + }, + "area": { + "name": "Area", + "description": "Area to request the preset reported." + }, + "channel": { + "name": "Channel", + "description": "Channel to request the preset to be reported from." + } + } + }, + "request_channel_level": { + "name": "Request channel level", + "description": "Requests Dynalite to report the level of a specific channel.", + "fields": { + "host": { + "name": "Host", + "description": "Host gateway IP to send to or all configured gateways if not specified." + }, + "area": { + "name": "Area", + "description": "Area for the requested channel." + }, + "channel": { + "name": "Channel", + "description": "Channel to request the level for." + } + } + } } }