simple-ocpp-cs/src/schemas/connector.py

18 lines
365 B
Python
Raw Normal View History

2024-03-28 21:23:25 +01:00
import enum
from pydantic import BaseModel
class ConnectorStatus(enum.Enum):
AVAILABLE = "Available"
OCCUPIED = "Occupied"
RESERVED = "Reserved"
UNAVAILABLE = "Unavailable"
FAULTED = "Faulted"
class Connector(BaseModel):
id: str
evse: int
index: int
status: ConnectorStatus
class Config:
from_attributes = True