@@ -116,6 +116,19 @@ class DashboardType(StrEnum):
116116 custom = "custom"
117117
118118
119+ class AlertStatus (StrEnum ):
120+ """
121+ Enum for supported alert status values.
122+ """
123+
124+ AlertDefinitionStatusProvisioning = "provisioning"
125+ AlertDefinitionStatusEnabling = "enabling"
126+ AlertDefinitionStatusDisabling = "disabling"
127+ AlertDefinitionStatusEnabled = "enabled"
128+ AlertDefinitionStatusDisabled = "disabled"
129+ AlertDefinitionStatusFailed = "failed"
130+
131+
119132@dataclass
120133class Filter (JSONObject ):
121134 """
@@ -428,6 +441,40 @@ class ChannelContent(JSONObject):
428441 # Other channel types like 'webhook', 'slack' could be added here as Optional fields.
429442
430443
444+ @dataclass
445+ class EmailDetails (JSONObject ):
446+ """
447+ Represents email-specific details for an alert channel.
448+ """
449+
450+ usernames : Optional [List [str ]] = None
451+ recipient_type : Optional [str ] = None
452+
453+
454+ @dataclass
455+ class ChannelDetails (JSONObject ):
456+ """
457+ Represents the details block for an AlertChannel, which varies by channel type.
458+ """
459+
460+ email : Optional [EmailDetails ] = None
461+
462+
463+ @dataclass
464+ class AlertInfo (JSONObject ):
465+ """
466+ Represents a reference to alerts associated with an alert channel.
467+ Fields:
468+ - url: str - API URL to fetch the alerts for this channel
469+ - type: str - Type identifier (e.g., 'alerts-definitions')
470+ - alert_count: int - Number of alerts associated with this channel
471+ """
472+
473+ url : str = ""
474+ _type : str = field (default = "" , metadata = {"json_key" : "type" })
475+ alert_count : int = 0
476+
477+
431478class AlertChannel (Base ):
432479 """
433480 Represents an alert channel used to deliver notifications when alerts
@@ -450,7 +497,8 @@ class AlertChannel(Base):
450497 "label" : Property (),
451498 "type" : Property (),
452499 "channel_type" : Property (),
453- "alerts" : Property (mutable = False , json_object = Alerts ),
500+ "details" : Property (mutable = False , json_object = ChannelDetails ),
501+ "alerts" : Property (mutable = False , json_object = AlertInfo ),
454502 "content" : Property (mutable = False , json_object = ChannelContent ),
455503 "created" : Property (is_datetime = True ),
456504 "updated" : Property (is_datetime = True ),
0 commit comments