2024-10-23 15:35:49 +02:00
|
|
|
from typing import Union
|
2024-09-24 15:05:30 +02:00
|
|
|
|
|
|
|
from pydantic import BaseModel
|
2024-10-23 15:35:49 +02:00
|
|
|
from pydantic.json_schema import SkipJsonSchema
|
|
|
|
|
2024-12-09 16:25:45 +01:00
|
|
|
from frigate.review.types import SeverityEnum
|
2024-09-24 15:05:30 +02:00
|
|
|
|
|
|
|
|
|
|
|
class ReviewQueryParams(BaseModel):
|
2024-10-23 15:35:49 +02:00
|
|
|
cameras: str = "all"
|
|
|
|
labels: str = "all"
|
|
|
|
zones: str = "all"
|
|
|
|
reviewed: int = 0
|
|
|
|
limit: Union[int, SkipJsonSchema[None]] = None
|
|
|
|
severity: Union[SeverityEnum, SkipJsonSchema[None]] = None
|
|
|
|
before: Union[float, SkipJsonSchema[None]] = None
|
|
|
|
after: Union[float, SkipJsonSchema[None]] = None
|
2024-09-24 15:05:30 +02:00
|
|
|
|
|
|
|
|
|
|
|
class ReviewSummaryQueryParams(BaseModel):
|
2024-10-23 15:35:49 +02:00
|
|
|
cameras: str = "all"
|
|
|
|
labels: str = "all"
|
|
|
|
zones: str = "all"
|
|
|
|
timezone: str = "utc"
|
2024-09-24 15:05:30 +02:00
|
|
|
|
|
|
|
|
|
|
|
class ReviewActivityMotionQueryParams(BaseModel):
|
2024-10-23 15:35:49 +02:00
|
|
|
cameras: str = "all"
|
|
|
|
before: Union[float, SkipJsonSchema[None]] = None
|
|
|
|
after: Union[float, SkipJsonSchema[None]] = None
|
|
|
|
scale: int = 30
|