-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d7c6367
commit c3e73ac
Showing
11 changed files
with
332 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
from pydantic import BaseModel, Field, validator, root_validator, EmailStr, UrlStr | ||
from typing import List, Optional | ||
from datetime import datetime | ||
|
||
|
||
class VALARMModel(BaseModel): | ||
"""A Pydantic model for RFC 5545 compliance.""" | ||
action: str = Field(default=None, title="", description="The action associated with the alarm.") | ||
trigger: str = Field(default=None, title="", description="The trigger for the alarm.") | ||
duration: str = Field(default=None, title="", description="The duration of the alarm.") | ||
repeat: int = Field(default=None, title="", description="The number of times the alarm should be repeated.", ge=0) | ||
description: str = Field(default=None, title="", description="A description of the alarm.") | ||
summary: str = Field(default=None, title="", description="A summary of the alarm.") | ||
attendees: List[str] = Field(default=None, title="", description="A list of attendees for the alarm.") | ||
acknowledged: datetime = Field(default=None, title="", description="The date and time the alarm was acknowledged.") | ||
related_to: str = Field(default=None, title="", description="The related event or to-do for the alarm.") | ||
uid: str = Field(default=None, title="", description="The unique identifier for the alarm.") | ||
created: datetime = Field(default=None, title="", description="The date and time the alarm was created.") | ||
last_modified: datetime = Field(default=None, title="", description="The date and time the alarm was last modified.") | ||
sequence: int = Field(default=None, title="", description="The sequence number for the alarm.", ge=0) | ||
x_prop: str = Field(default=None, title="", description="Any additional custom properties for the alarm.") | ||
attach: List[str] = Field(default=None, title="", description="A list of attachments for the alarm.") | ||
|
Oops, something went wrong.