|
792 | 792 | { |
793 | 793 | "name": "ha_rename_entity", |
794 | 794 | "title": "Rename Entity", |
795 | | - "description": "Rename a Home Assistant entity by changing its entity_id.\n\nChanges the entity_id (e.g., light.old_name -> light.new_name).\nThe domain must remain the same - you cannot change a light to a switch.\n\nVOICE ASSISTANT EXPOSURE:\nBy default, this function preserves voice assistant exposure settings\n(Alexa, Google Assistant, Assist) when renaming. The exposure settings\nare stored separately from the entity registry and must be migrated\nmanually. Set preserve_voice_exposure=False to skip this migration.\n\nIMPORTANT LIMITATIONS:\n- References in automations/scripts/dashboards are NOT automatically updated\n- Entity history is preserved (HA 2022.4+)\n- Some entities cannot be renamed:\n - Entities without unique IDs\n - Entities disabled by integration\n\nEXAMPLES:\n- Rename light: ha_rename_entity(\"light.bedroom_1\", \"light.master_bedroom\")\n- Rename with friendly name: ha_rename_entity(\"sensor.temp\", \"sensor.living_room_temp\", name=\"Living Room Temperature\")\n- Rename without exposure migration: ha_rename_entity(\"light.old\", \"light.new\", preserve_voice_exposure=False)\n\nNOTE: This is different from renaming a device. Device and entity renaming are independent.\nRenaming a device does NOT rename its entities. See ha_update_device() for device renaming.\nFor renaming both entity and device together, use ha_rename_entity_and_device().", |
| 795 | + "description": "Rename a Home Assistant entity by changing its entity_id, optionally renaming its device too.\n\nChanges the entity_id (e.g., light.old_name -> light.new_name).\nThe domain must remain the same - you cannot change a light to a switch.\n\nDEVICE RENAME:\nProvide new_device_name to also rename the device associated with this entity.\nThe device is looked up automatically from the entity registry.\n\nVOICE ASSISTANT EXPOSURE:\nBy default, this function preserves voice assistant exposure settings\n(Alexa, Google Assistant, Assist) when renaming. The exposure settings\nare stored separately from the entity registry and must be migrated\nmanually. Set preserve_voice_exposure=False to skip this migration.\n\nIMPORTANT LIMITATIONS:\n- References in automations/scripts/dashboards are NOT automatically updated\n- Entity history is preserved (HA 2022.4+)\n- Some entities cannot be renamed:\n - Entities without unique IDs\n - Entities disabled by integration\n\nEXAMPLES:\n- Rename light: ha_rename_entity(\"light.bedroom_1\", \"light.master_bedroom\")\n- Rename with friendly name: ha_rename_entity(\"sensor.temp\", \"sensor.living_room_temp\", name=\"Living Room Temperature\")\n- Rename entity and device: ha_rename_entity(\"light.bedroom_1\", \"light.master_bedroom\", new_device_name=\"Master Bedroom Lamp\")\n- Rename without exposure migration: ha_rename_entity(\"light.old\", \"light.new\", preserve_voice_exposure=False)\n\nNOTE: Device and entity renaming are independent in HA. Renaming a device does\nNOT rename its entities. See ha_update_device() for device-only renaming.", |
796 | 796 | "inputSchema": { |
797 | 797 | "properties": { |
798 | 798 | "entity_id": { |
|
809 | 809 | "type": "Annotated[str | None, Field(description=\"Optional: New icon (e.g., 'mdi:lightbulb')\", default=None)]", |
810 | 810 | "default": null |
811 | 811 | }, |
812 | | - "preserve_voice_exposure": { |
813 | | - "type": "Annotated[bool | str | None, Field(description='Migrate voice assistant exposure settings to the new entity_id. Defaults to True. Set to False to skip exposure migration.', default=None)]", |
814 | | - "default": null |
815 | | - } |
816 | | - }, |
817 | | - "required": [ |
818 | | - "entity_id", |
819 | | - "new_entity_id" |
820 | | - ] |
821 | | - }, |
822 | | - "annotations": { |
823 | | - "destructiveHint": true |
824 | | - }, |
825 | | - "tags": [ |
826 | | - "Device Registry" |
827 | | - ], |
828 | | - "source_file": "tools_registry.py" |
829 | | - }, |
830 | | - { |
831 | | - "name": "ha_rename_entity_and_device", |
832 | | - "title": "Rename Entity and Device", |
833 | | - "description": "Convenience tool to rename both an entity and its associated device in one operation.\n\nThis tool:\n1. Finds the device associated with the entity\n2. Renames the entity (changing entity_id)\n3. Renames the device (changing display name)\n4. Preserves voice assistant exposure settings (by default)\n\nWHEN TO USE:\n- When you want to rename a device and its primary entity together\n- For smart home devices where device and entity should have matching names\n\nIMPORTANT:\n- If the entity has multiple associated entities (e.g., a smart bulb with brightness, color, etc.),\n only the specified entity is renamed. Other entities retain their original IDs.\n- If the entity has no associated device, only the entity is renamed.\n\nEXAMPLES:\n- Rename lamp: ha_rename_entity_and_device(\"light.bedroom_1\", \"light.master_bedroom\", \"Master Bedroom Lamp\")\n- Rename only entity_id: ha_rename_entity_and_device(\"sensor.temp\", \"sensor.living_room_temp\")\n\nSee also:\n- ha_rename_entity() - Rename only the entity\n- ha_update_device() - Update only the device", |
834 | | - "inputSchema": { |
835 | | - "properties": { |
836 | | - "entity_id": { |
837 | | - "type": "Annotated[str, Field(description=\"Entity ID to rename (e.g., 'light.bedroom_lamp'). Used to find associated device.\")]" |
838 | | - }, |
839 | | - "new_entity_id": { |
840 | | - "type": "Annotated[str, Field(description=\"New entity ID (e.g., 'light.master_bedroom_lamp'). Domain must match.\")]" |
841 | | - }, |
842 | 812 | "new_device_name": { |
843 | | - "type": "Annotated[str | None, Field(description='New display name for the device. If not provided, device name is not changed.', default=None)]", |
844 | | - "default": null |
845 | | - }, |
846 | | - "new_entity_name": { |
847 | | - "type": "Annotated[str | None, Field(description='New friendly name for the entity. If not provided, entity name is not changed.', default=None)]", |
| 813 | + "type": "Annotated[str | None, Field(description='Optional: New display name for the associated device. If provided, both entity and device are renamed in one operation.', default=None)]", |
848 | 814 | "default": null |
849 | 815 | }, |
850 | 816 | "preserve_voice_exposure": { |
851 | | - "type": "Annotated[bool | str | None, Field(description='Migrate voice assistant exposure settings to the new entity_id. Defaults to True.', default=None)]", |
| 817 | + "type": "Annotated[bool | str | None, Field(description='Migrate voice assistant exposure settings to the new entity_id. Defaults to True. Set to False to skip exposure migration.', default=None)]", |
852 | 818 | "default": null |
853 | 819 | } |
854 | 820 | }, |
|
2368 | 2334 | ], |
2369 | 2335 | "source_file": "tools_service.py" |
2370 | 2336 | }, |
2371 | | - { |
2372 | | - "name": "ha_get_bulk_status", |
2373 | | - "title": "Get Bulk Operation Status", |
2374 | | - "description": "Check status of multiple device control operations.\n\nUse this tool to check the status of operations initiated by ha_bulk_control\nor control_device_smart. Each of these tools returns unique operation_ids\nthat can be tracked here.\n\n**IMPORTANT:** This tool is for tracking async device operations, NOT for\nchecking current entity states. To get current states of entities, use\nha_get_state instead.\n\n**Args:**\n operation_ids: List of operation IDs returned by ha_bulk_control or\n control_device_smart (e.g., [\"op_1234\", \"op_5678\"])\n\n**Returns:**\n Status summary with completion/pending/failed counts and detailed\n results for each operation.\n\n**Example:**\n # After calling control_device_smart\n result = control_device_smart(\"light.kitchen\", \"on\")\n op_id = result[\"operation_id\"] # e.g., \"op_1234\"\n\n # Check operation status\n status = ha_get_bulk_status([op_id])", |
2375 | | - "inputSchema": { |
2376 | | - "properties": { |
2377 | | - "operation_ids": { |
2378 | | - "type": "list[str]" |
2379 | | - } |
2380 | | - }, |
2381 | | - "required": [ |
2382 | | - "operation_ids" |
2383 | | - ] |
2384 | | - }, |
2385 | | - "annotations": { |
2386 | | - "readOnlyHint": true |
2387 | | - }, |
2388 | | - "tags": [ |
2389 | | - "Service & Device Control" |
2390 | | - ], |
2391 | | - "source_file": "tools_service.py" |
2392 | | - }, |
2393 | 2337 | { |
2394 | 2338 | "name": "ha_get_operation_status", |
2395 | 2339 | "title": "Get Operation Status", |
2396 | | - "description": "Check status of device operation with real-time WebSocket verification.", |
| 2340 | + "description": "Check status of one or more device operations with real-time WebSocket verification.\n\nPass a single operation_id string to check one operation, or a list of IDs\nto check multiple operations at once (bulk status).\n\nThe timeout_seconds parameter applies to single-operation checks only.\nBulk checks poll each operation individually with a short internal timeout.\n\nUse this to track operations initiated by ha_bulk_control or ha_call_service.\nFor current entity states, use ha_get_state instead.", |
2397 | 2341 | "inputSchema": { |
2398 | 2342 | "properties": { |
2399 | 2343 | "operation_id": { |
2400 | | - "type": "str" |
| 2344 | + "type": "Annotated[str | list[str], Field(description='Single operation ID or list of operation IDs to check. Use a single string for one operation, or a list for bulk status checks.')]" |
2401 | 2345 | }, |
2402 | 2346 | "timeout_seconds": { |
2403 | 2347 | "type": "int", |
|
0 commit comments