(20250116) Started upgrading the mail module (to eventually work on cron).
This commit is contained in:
@@ -74,6 +74,104 @@ import datetime
|
||||
# *****************************************************************************************************************
|
||||
|
||||
|
||||
class PaperTradingAuth(BaseModel):
|
||||
|
||||
username: str = Field(
|
||||
description = "??",
|
||||
frozen = True
|
||||
)
|
||||
|
||||
password: str = Field(
|
||||
description = "??",
|
||||
frozen = True
|
||||
)
|
||||
|
||||
# ┏┓ ┏•
|
||||
# ┃ ┏┓┏┓╋┓┏┓
|
||||
# ┗┛┗┛┛┗┛┗┗┫
|
||||
# ┛
|
||||
|
||||
class Config:
|
||||
extra = "forbid"
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
class ZerodhaKiteAuth(BaseModel):
|
||||
|
||||
userId: str = Field(
|
||||
description = "How Zerodha's Kite platform identifies this user.",
|
||||
frozen = True,
|
||||
alias = "clientId"
|
||||
)
|
||||
|
||||
apiKey: str = Field(
|
||||
description = (
|
||||
"The API key of your Kite app. "
|
||||
"This remains constant throughout the life of the app."
|
||||
),
|
||||
frozen = True
|
||||
)
|
||||
|
||||
apiSecret: str = Field(
|
||||
description = (
|
||||
"The API secret of your Kite app. "
|
||||
"This can be changed if you think the security of your app has been compromised."
|
||||
),
|
||||
frozen = True
|
||||
)
|
||||
|
||||
# ┏┓ ┏•
|
||||
# ┃ ┏┓┏┓╋┓┏┓
|
||||
# ┗┛┗┛┛┗┛┗┗┫
|
||||
# ┛
|
||||
|
||||
class Config:
|
||||
extra = "forbid"
|
||||
populate_by_name = True
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
class ICICIBreezeAuth(BaseModel):
|
||||
|
||||
userId: str = Field(
|
||||
description = "How ICICI's Breeze platform identifies this user.",
|
||||
frozen = True,
|
||||
alias = "clientId"
|
||||
)
|
||||
|
||||
apiKey: str = Field(
|
||||
description = (
|
||||
"The API key of your Breeze app. "
|
||||
"This remains constant throughout the life of the app."
|
||||
),
|
||||
frozen = True
|
||||
)
|
||||
|
||||
apiSecret: str = Field(
|
||||
description = (
|
||||
"The API secret of your Breeze app. "
|
||||
"This can be changed if you think the security of your app has been compromised."
|
||||
),
|
||||
frozen = True
|
||||
)
|
||||
|
||||
# ┏┓ ┏•
|
||||
# ┃ ┏┓┏┓╋┓┏┓
|
||||
# ┗┛┗┛┛┗┛┗┗┫
|
||||
# ┛
|
||||
|
||||
class Config:
|
||||
extra = "forbid"
|
||||
populate_by_name = True
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
class TradingOAuthCallbackResponse(BaseModel):
|
||||
|
||||
success: bool = Field(
|
||||
|
||||
@@ -220,6 +220,45 @@ class TradingSymbol(BaseModel):
|
||||
return value
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
class TradingSymbolListBrokerResponse(BaseModel):
|
||||
|
||||
success: bool = Field(
|
||||
description = "whether, or not, the symbol list request was successful",
|
||||
default = False,
|
||||
frozen = False
|
||||
)
|
||||
|
||||
message: str = Field(
|
||||
description = "a brief message to help debug in failed cases",
|
||||
default = "",
|
||||
frozen = False
|
||||
)
|
||||
|
||||
data: List[TradingSymbol] | None = Field(
|
||||
description = "the actual response from the broker with his list of tradeable symbols",
|
||||
default = None,
|
||||
frozen = False
|
||||
)
|
||||
|
||||
exception: Exception | None = Field(
|
||||
description = "if something goes wrong, the exception will be held here",
|
||||
default = None,
|
||||
frozen = False
|
||||
)
|
||||
|
||||
# ┏┓ ┏•
|
||||
# ┃ ┏┓┏┓╋┓┏┓
|
||||
# ┗┛┗┛┛┗┛┗┗┫
|
||||
# ┛
|
||||
|
||||
class Config:
|
||||
extra = "forbid"
|
||||
arbitrary_types_allowed = True
|
||||
|
||||
|
||||
# *****************************************************************************************************************
|
||||
# ***** ****
|
||||
# *** MAIN PROGRAM ***
|
||||
|
||||
Reference in New Issue
Block a user