feat: Phase 3 manufacturing + firmware management
This commit is contained in:
31
backend/firmware/models.py
Normal file
31
backend/firmware/models.py
Normal file
@@ -0,0 +1,31 @@
|
||||
from pydantic import BaseModel
|
||||
from typing import Optional, List
|
||||
|
||||
|
||||
class FirmwareVersion(BaseModel):
|
||||
id: str
|
||||
hw_type: str # "vs", "vp", "vx"
|
||||
channel: str # "stable", "beta", "alpha", "testing"
|
||||
version: str # semver e.g. "1.4.2"
|
||||
filename: str
|
||||
size_bytes: int
|
||||
sha256: str
|
||||
uploaded_at: str
|
||||
notes: Optional[str] = None
|
||||
is_latest: bool = False
|
||||
|
||||
|
||||
class FirmwareListResponse(BaseModel):
|
||||
firmware: List[FirmwareVersion]
|
||||
total: int
|
||||
|
||||
|
||||
class FirmwareLatestResponse(BaseModel):
|
||||
hw_type: str
|
||||
channel: str
|
||||
version: str
|
||||
size_bytes: int
|
||||
sha256: str
|
||||
download_url: str
|
||||
uploaded_at: str
|
||||
notes: Optional[str] = None
|
||||
Reference in New Issue
Block a user