diff --git a/homeassistant/components/cover/device_action.py b/homeassistant/components/cover/device_action.py index 29dd97909e3..490ce162d9a 100644 --- a/homeassistant/components/cover/device_action.py +++ b/homeassistant/components/cover/device_action.py @@ -49,7 +49,9 @@ POSITION_ACTION_SCHEMA = cv.DEVICE_ACTION_BASE_SCHEMA.extend( { vol.Required(CONF_TYPE): vol.In(POSITION_ACTION_TYPES), vol.Required(CONF_ENTITY_ID): cv.entity_domain(DOMAIN), - vol.Required("position"): vol.All(vol.Coerce(int), vol.Range(min=0, max=100)), + vol.Optional("position", default=0): vol.All( + vol.Coerce(int), vol.Range(min=0, max=100) + ), } ) diff --git a/homeassistant/helpers/config_validation.py b/homeassistant/helpers/config_validation.py index acf6139708a..d47ba30c114 100644 --- a/homeassistant/helpers/config_validation.py +++ b/homeassistant/helpers/config_validation.py @@ -266,7 +266,7 @@ def entity_id(value: Any) -> str: if valid_entity_id(str_value): return str_value - raise vol.Invalid(f"Entity ID {value} is an invalid entity id") + raise vol.Invalid(f"Entity ID {value} is an invalid entity ID") def entity_ids(value: Union[str, List]) -> List[str]: