11"""File for models used in responses from config entries."""
22
3- from enum import Enum
3+ from enum import StrEnum
44from typing import Any
55
66from .base import BaseModel
77
88
9- class FlowResultType (Enum ):
9+ class FlowResultType (StrEnum ):
1010 """Result type for a data entry flow."""
1111
1212 FORM = "form"
@@ -79,7 +79,7 @@ class DisableEnableResult(BaseModel):
7979 require_restart : bool
8080
8181
82- class IntegrationTypes (Enum ):
82+ class IntegrationTypes (StrEnum ):
8383 """Types of integrations."""
8484
8585 ENTITY = "entity"
@@ -92,7 +92,7 @@ class IntegrationTypes(Enum):
9292 VIRTUAL = "virtual"
9393
9494
95- class ConfigEntryState (str , Enum ):
95+ class ConfigEntryState (StrEnum ):
9696 """Config entry state."""
9797
9898 LOADED = "loaded"
@@ -105,7 +105,7 @@ class ConfigEntryState(str, Enum):
105105 UNLOAD_IN_PROGRESS = "unload_in_progress"
106106
107107
108- class ConfigEntryDisabler (Enum ):
108+ class ConfigEntryDisabler (StrEnum ):
109109 """What disabled a config entry."""
110110
111111 USER = "user"
@@ -144,7 +144,7 @@ class ConfigSubEntry(BaseModel):
144144 unique_id : str | None
145145
146146
147- class ConfigEntryChange (str , Enum ):
147+ class ConfigEntryChange (StrEnum ):
148148 """What was changed in a config entry."""
149149
150150 ADDED = "added"
0 commit comments