2024-09-28 21:21:42 +02:00
|
|
|
from typing import Optional
|
|
|
|
|
|
|
|
from pydantic import Field
|
|
|
|
|
2025-02-11 03:47:15 +01:00
|
|
|
from ..base import FrigateBaseModel
|
2024-09-28 21:21:42 +02:00
|
|
|
|
|
|
|
__all__ = ["NotificationConfig"]
|
|
|
|
|
|
|
|
|
|
|
|
class NotificationConfig(FrigateBaseModel):
|
|
|
|
enabled: bool = Field(default=False, title="Enable notifications")
|
|
|
|
email: Optional[str] = Field(default=None, title="Email required for push.")
|
2025-02-17 15:19:03 +01:00
|
|
|
cooldown: Optional[int] = Field(
|
|
|
|
default=0, ge=0, title="Cooldown period for notifications (time in seconds)."
|
|
|
|
)
|
2024-09-28 21:21:42 +02:00
|
|
|
enabled_in_config: Optional[bool] = Field(
|
|
|
|
default=None, title="Keep track of original state of notifications."
|
|
|
|
)
|