feat: add BridgeInterfaceInfo and BridgeInfo models with descriptions
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 9s

This commit is contained in:
2025-11-24 17:49:02 +01:00
parent 515237d43e
commit e8d0f6692b

View File

@@ -79,12 +79,18 @@ class RouteInfo(BaseModel):
) )
class BridgeInterfaceInfo(BaseModel): class BridgeInterfaceInfo(BaseModel):
"""
Represents a network interface which is a member of an bridge.
"""
ifindex: int = Field(..., description="Interface index of a bridge member") ifindex: int = Field(..., description="Interface index of a bridge member")
ifname: str = Field(..., description="Interface name of a bridge member") ifname: str = Field(..., description="Interface name of a bridge member")
state: Optional[str] = Field(None, description="Operational state of the interface") state: Optional[str] = Field(None, description="Operational state of the interface")
mtu: Optional[int] = Field(None, description="MTU of the interface") mtu: Optional[int] = Field(None, description="MTU of the interface")
class BridgeInfo(BaseModel): class BridgeInfo(BaseModel):
"""
Represents a network bridge interface with all its properties.
"""
ifindex: int = Field(..., description="Interface index of the bridge") ifindex: int = Field(..., description="Interface index of the bridge")
ifname: str = Field(..., description="Bridge interface name") ifname: str = Field(..., description="Bridge interface name")
state: Optional[str] = Field(None, description="Operational state of the bridge") state: Optional[str] = Field(None, description="Operational state of the bridge")