Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add classification read-only parameter for monitor object #2418

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2025-02-14 15:03:51.274934",
"spec_repo_commit": "a739b49f"
"regenerated": "2025-02-18 09:41:21.670827",
"spec_repo_commit": "f9205865"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2025-02-14 15:03:51.291086",
"spec_repo_commit": "a739b49f"
"regenerated": "2025-02-18 09:41:21.686992",
"spec_repo_commit": "f9205865"
}
}
}
5 changes: 5 additions & 0 deletions .generator/schemas/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6688,6 +6688,11 @@ components:
Monitor:
description: Object describing a monitor.
properties:
classification:
description: The classification of the monitor.
example: log
readOnly: true
type: string
created:
description: Timestamp of the monitor creation.
format: date-time
Expand Down
9 changes: 9 additions & 0 deletions src/datadog_api_client/v1/model/monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ def openapi_types(_):
from datadog_api_client.v1.model.monitor_type import MonitorType

return {
"classification": (str,),
"created": (datetime,),
"creator": (Creator,),
"deleted": (datetime, none_type),
Expand All @@ -55,6 +56,7 @@ def openapi_types(_):
}

attribute_map = {
"classification": "classification",
"created": "created",
"creator": "creator",
"deleted": "deleted",
Expand All @@ -74,6 +76,7 @@ def openapi_types(_):
"type": "type",
}
read_only_vars = {
"classification",
"created",
"creator",
"deleted",
Expand All @@ -88,6 +91,7 @@ def __init__(
self_,
query: str,
type: MonitorType,
classification: Union[str, UnsetType] = unset,
created: Union[datetime, UnsetType] = unset,
creator: Union[Creator, UnsetType] = unset,
deleted: Union[datetime, none_type, UnsetType] = unset,
Expand All @@ -108,6 +112,9 @@ def __init__(
"""
Object describing a monitor.

:param classification: The classification of the monitor.
:type classification: str, optional

:param created: Timestamp of the monitor creation.
:type created: datetime, optional

Expand Down Expand Up @@ -159,6 +166,8 @@ def __init__(
:param type: The type of the monitor. For more information about ``type`` , see the `monitor options <https://docs.datadoghq.com/monitors/guide/monitor_api_options/>`_ docs.
:type type: MonitorType
"""
if classification is not unset:
kwargs["classification"] = classification
if created is not unset:
kwargs["created"] = created
if creator is not unset:
Expand Down
Loading