Merge pull request #389 from Hestia-Homes/remote-assessment-api

updated the typing of the event_type field
This commit is contained in:
KhalimCK 2025-04-14 14:36:26 +01:00 committed by GitHub
commit a28c669d0b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,5 +1,5 @@
from pydantic import BaseModel, Field, BeforeValidator
from typing import Annotated, List, Optional
from typing import Annotated, List, Optional, Literal
# Example constants for validation
TYPICAL_MEASURE_TYPES = [
@ -95,4 +95,4 @@ class PlanTriggerRequest(BaseModel):
# When performing a remote assessment, if this has been set, it will allow the engine to
# pull data from the find my epc website, to utilise as part of a remote assessment
event_type: Optional[float] = "remote_assessment",
event_type: Optional[Literal["remote_assessment"]] = None