Skip to content

Commit b9a1673

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 708b0f4e of spec repo
1 parent 89297af commit b9a1673

20 files changed

Lines changed: 210 additions & 30 deletions

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-05-14 15:44:27.314895",
8-
"spec_repo_commit": "64f5e7ee"
7+
"regenerated": "2025-05-14 22:39:18.407579",
8+
"spec_repo_commit": "708b0f4e"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-14 15:44:27.373827",
13-
"spec_repo_commit": "64f5e7ee"
12+
"regenerated": "2025-05-14 22:39:18.425865",
13+
"spec_repo_commit": "708b0f4e"
1414
}
1515
}
1616
}

.generator/schemas/v1/openapi.yaml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6742,6 +6742,8 @@ components:
67426742
nullable: true
67436743
readOnly: true
67446744
type: string
6745+
draft_status:
6746+
$ref: '#/components/schemas/MonitorDraftStatus'
67456747
id:
67466748
description: ID of this monitor.
67476749
format: int64
@@ -6834,6 +6836,22 @@ components:
68346836
- FIREFOX_LAPTOP_LARGE
68356837
- FIREFOX_TABLET
68366838
- FIREFOX_MOBILE_SMALL
6839+
MonitorDraftStatus:
6840+
default: published
6841+
description: 'Whether a monitor is in draft or published state. Draft monitors
6842+
do not notify recipients. Draft monitors are currently in
6843+
6844+
preview and field is only processed for enabled customers. This accepts the
6845+
values `draft`
6846+
6847+
and `published`. Defaults to published.'
6848+
enum:
6849+
- draft
6850+
- published
6851+
type: string
6852+
x-enum-varnames:
6853+
- DRAFT
6854+
- PUBLISHED
68376855
MonitorFormulaAndFunctionCostAggregator:
68386856
description: Aggregation methods for metric queries.
68396857
enum:
@@ -7917,6 +7935,8 @@ components:
79177935
nullable: true
79187936
readOnly: true
79197937
type: string
7938+
draft_status:
7939+
$ref: '#/components/schemas/MonitorUpdateRequestDraftStatus'
79207940
id:
79217941
description: ID of this monitor.
79227942
format: int64
@@ -7975,6 +7995,22 @@ components:
79757995
type:
79767996
$ref: '#/components/schemas/MonitorType'
79777997
type: object
7998+
MonitorUpdateRequestDraftStatus:
7999+
default: published
8000+
description: 'Whether a monitor is in draft or published state. Draft monitors
8001+
do not notify recipients. Draft monitors are currently in
8002+
8003+
preview and field is only processed for enabled customers. This accepts the
8004+
values `draft`
8005+
8006+
and `published`. Defaults to published.'
8007+
enum:
8008+
- draft
8009+
- published
8010+
type: string
8011+
x-enum-varnames:
8012+
- DRAFT
8013+
- PUBLISHED
79788014
MonthlyUsageAttributionBody:
79798015
description: Usage Summary by tag for a given organization.
79808016
properties:

docs/datadog_api_client.v1.model.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2041,6 +2041,13 @@ datadog\_api\_client.v1.model.monitor\_device\_id module
20412041
:members:
20422042
:show-inheritance:
20432043

2044+
datadog\_api\_client.v1.model.monitor\_draft\_status module
2045+
-----------------------------------------------------------
2046+
2047+
.. automodule:: datadog_api_client.v1.model.monitor_draft_status
2048+
:members:
2049+
:show-inheritance:
2050+
20442051
datadog\_api\_client.v1.model.monitor\_formula\_and\_function\_cost\_aggregator module
20452052
--------------------------------------------------------------------------------------
20462053

@@ -2307,6 +2314,13 @@ datadog\_api\_client.v1.model.monitor\_update\_request module
23072314
:members:
23082315
:show-inheritance:
23092316

2317+
datadog\_api\_client.v1.model.monitor\_update\_request\_draft\_status module
2318+
----------------------------------------------------------------------------
2319+
2320+
.. automodule:: datadog_api_client.v1.model.monitor_update_request_draft_status
2321+
:members:
2322+
:show-inheritance:
2323+
23102324
datadog\_api\_client.v1.model.monthly\_usage\_attribution\_body module
23112325
----------------------------------------------------------------------
23122326

examples/v1/monitors/CreateMonitor_1539578087.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from datadog_api_client import ApiClient, Configuration
66
from datadog_api_client.v1.api.monitors_api import MonitorsApi
77
from datadog_api_client.v1.model.monitor import Monitor
8+
from datadog_api_client.v1.model.monitor_draft_status import MonitorDraftStatus
89
from datadog_api_client.v1.model.monitor_options import MonitorOptions
910
from datadog_api_client.v1.model.monitor_options_custom_schedule import MonitorOptionsCustomSchedule
1011
from datadog_api_client.v1.model.monitor_options_custom_schedule_recurrence import (
@@ -45,6 +46,7 @@
4546
),
4647
),
4748
type=MonitorType.QUERY_ALERT,
49+
draft_status=MonitorDraftStatus.PUBLISHED,
4850
)
4951

5052
configuration = Configuration()

examples/v1/monitors/CreateMonitor_440013737.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from datadog_api_client import ApiClient, Configuration
66
from datadog_api_client.v1.api.monitors_api import MonitorsApi
77
from datadog_api_client.v1.model.monitor import Monitor
8+
from datadog_api_client.v1.model.monitor_draft_status import MonitorDraftStatus
89
from datadog_api_client.v1.model.monitor_options import MonitorOptions
910
from datadog_api_client.v1.model.monitor_thresholds import MonitorThresholds
1011
from datadog_api_client.v1.model.monitor_type import MonitorType
@@ -24,6 +25,7 @@
2425
critical=1.0,
2526
),
2627
),
28+
draft_status=MonitorDraftStatus.DRAFT,
2729
)
2830

2931
configuration = Configuration()

examples/v1/monitors/ValidateMonitor_4247196452.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from datadog_api_client import ApiClient, Configuration
66
from datadog_api_client.v1.api.monitors_api import MonitorsApi
77
from datadog_api_client.v1.model.monitor import Monitor
8+
from datadog_api_client.v1.model.monitor_draft_status import MonitorDraftStatus
89
from datadog_api_client.v1.model.monitor_options import MonitorOptions
910
from datadog_api_client.v1.model.monitor_thresholds import MonitorThresholds
1011
from datadog_api_client.v1.model.monitor_type import MonitorType
@@ -20,6 +21,7 @@
2021
"env:ci",
2122
],
2223
priority=3,
24+
draft_status=MonitorDraftStatus.PUBLISHED,
2325
options=MonitorOptions(
2426
enable_logs_sample=True,
2527
escalation_message="the situation has escalated",

src/datadog_api_client/v1/model/monitor.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
if TYPE_CHECKING:
1919
from datadog_api_client.v1.model.creator import Creator
20+
from datadog_api_client.v1.model.monitor_draft_status import MonitorDraftStatus
2021
from datadog_api_client.v1.model.matching_downtime import MatchingDowntime
2122
from datadog_api_client.v1.model.monitor_options import MonitorOptions
2223
from datadog_api_client.v1.model.monitor_overall_states import MonitorOverallStates
@@ -28,6 +29,7 @@ class Monitor(ModelNormal):
2829
@cached_property
2930
def openapi_types(_):
3031
from datadog_api_client.v1.model.creator import Creator
32+
from datadog_api_client.v1.model.monitor_draft_status import MonitorDraftStatus
3133
from datadog_api_client.v1.model.matching_downtime import MatchingDowntime
3234
from datadog_api_client.v1.model.monitor_options import MonitorOptions
3335
from datadog_api_client.v1.model.monitor_overall_states import MonitorOverallStates
@@ -38,6 +40,7 @@ def openapi_types(_):
3840
"created": (datetime,),
3941
"creator": (Creator,),
4042
"deleted": (datetime, none_type),
43+
"draft_status": (MonitorDraftStatus,),
4144
"id": (int,),
4245
"matching_downtimes": ([MatchingDowntime],),
4346
"message": (str,),
@@ -58,6 +61,7 @@ def openapi_types(_):
5861
"created": "created",
5962
"creator": "creator",
6063
"deleted": "deleted",
64+
"draft_status": "draft_status",
6165
"id": "id",
6266
"matching_downtimes": "matching_downtimes",
6367
"message": "message",
@@ -91,6 +95,7 @@ def __init__(
9195
created: Union[datetime, UnsetType] = unset,
9296
creator: Union[Creator, UnsetType] = unset,
9397
deleted: Union[datetime, none_type, UnsetType] = unset,
98+
draft_status: Union[MonitorDraftStatus, UnsetType] = unset,
9499
id: Union[int, UnsetType] = unset,
95100
matching_downtimes: Union[List[MatchingDowntime], UnsetType] = unset,
96101
message: Union[str, UnsetType] = unset,
@@ -117,6 +122,11 @@ def __init__(
117122
:param deleted: Whether or not the monitor is deleted. (Always ``null`` )
118123
:type deleted: datetime, none_type, optional
119124
125+
:param draft_status: Whether a monitor is in draft or published state. Draft monitors do not notify recipients. Draft monitors are currently in
126+
preview and field is only processed for enabled customers. This accepts the values ``draft``
127+
and ``published``. Defaults to published.
128+
:type draft_status: MonitorDraftStatus, optional
129+
120130
:param id: ID of this monitor.
121131
:type id: int, optional
122132
@@ -165,6 +175,8 @@ def __init__(
165175
kwargs["creator"] = creator
166176
if deleted is not unset:
167177
kwargs["deleted"] = deleted
178+
if draft_status is not unset:
179+
kwargs["draft_status"] = draft_status
168180
if id is not unset:
169181
kwargs["id"] = id
170182
if matching_downtimes is not unset:
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
7+
from datadog_api_client.model_utils import (
8+
ModelSimple,
9+
cached_property,
10+
)
11+
12+
from typing import ClassVar
13+
14+
15+
class MonitorDraftStatus(ModelSimple):
16+
"""
17+
Whether a monitor is in draft or published state. Draft monitors do not notify recipients. Draft monitors are currently in
18+
preview and field is only processed for enabled customers. This accepts the values `draft`
19+
and `published`. Defaults to published.
20+
21+
:param value: If omitted defaults to "published". Must be one of ["draft", "published"].
22+
:type value: str
23+
"""
24+
25+
allowed_values = {
26+
"draft",
27+
"published",
28+
}
29+
DRAFT: ClassVar["MonitorDraftStatus"]
30+
PUBLISHED: ClassVar["MonitorDraftStatus"]
31+
32+
@cached_property
33+
def openapi_types(_):
34+
return {
35+
"value": (str,),
36+
}
37+
38+
39+
MonitorDraftStatus.DRAFT = MonitorDraftStatus("draft")
40+
MonitorDraftStatus.PUBLISHED = MonitorDraftStatus("published")

src/datadog_api_client/v1/model/monitor_update_request.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
if TYPE_CHECKING:
1919
from datadog_api_client.v1.model.creator import Creator
20+
from datadog_api_client.v1.model.monitor_update_request_draft_status import MonitorUpdateRequestDraftStatus
2021
from datadog_api_client.v1.model.monitor_options import MonitorOptions
2122
from datadog_api_client.v1.model.monitor_overall_states import MonitorOverallStates
2223
from datadog_api_client.v1.model.monitor_state import MonitorState
@@ -27,6 +28,7 @@ class MonitorUpdateRequest(ModelNormal):
2728
@cached_property
2829
def openapi_types(_):
2930
from datadog_api_client.v1.model.creator import Creator
31+
from datadog_api_client.v1.model.monitor_update_request_draft_status import MonitorUpdateRequestDraftStatus
3032
from datadog_api_client.v1.model.monitor_options import MonitorOptions
3133
from datadog_api_client.v1.model.monitor_overall_states import MonitorOverallStates
3234
from datadog_api_client.v1.model.monitor_state import MonitorState
@@ -36,6 +38,7 @@ def openapi_types(_):
3638
"created": (datetime,),
3739
"creator": (Creator,),
3840
"deleted": (datetime, none_type),
41+
"draft_status": (MonitorUpdateRequestDraftStatus,),
3942
"id": (int,),
4043
"message": (str,),
4144
"modified": (datetime,),
@@ -55,6 +58,7 @@ def openapi_types(_):
5558
"created": "created",
5659
"creator": "creator",
5760
"deleted": "deleted",
61+
"draft_status": "draft_status",
5862
"id": "id",
5963
"message": "message",
6064
"modified": "modified",
@@ -85,6 +89,7 @@ def __init__(
8589
created: Union[datetime, UnsetType] = unset,
8690
creator: Union[Creator, UnsetType] = unset,
8791
deleted: Union[datetime, none_type, UnsetType] = unset,
92+
draft_status: Union[MonitorUpdateRequestDraftStatus, UnsetType] = unset,
8893
id: Union[int, UnsetType] = unset,
8994
message: Union[str, UnsetType] = unset,
9095
modified: Union[datetime, UnsetType] = unset,
@@ -112,6 +117,11 @@ def __init__(
112117
:param deleted: Whether or not the monitor is deleted. (Always ``null`` )
113118
:type deleted: datetime, none_type, optional
114119
120+
:param draft_status: Whether a monitor is in draft or published state. Draft monitors do not notify recipients. Draft monitors are currently in
121+
preview and field is only processed for enabled customers. This accepts the values ``draft``
122+
and ``published``. Defaults to published.
123+
:type draft_status: MonitorUpdateRequestDraftStatus, optional
124+
115125
:param id: ID of this monitor.
116126
:type id: int, optional
117127
@@ -157,6 +167,8 @@ def __init__(
157167
kwargs["creator"] = creator
158168
if deleted is not unset:
159169
kwargs["deleted"] = deleted
170+
if draft_status is not unset:
171+
kwargs["draft_status"] = draft_status
160172
if id is not unset:
161173
kwargs["id"] = id
162174
if message is not unset:
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
7+
from datadog_api_client.model_utils import (
8+
ModelSimple,
9+
cached_property,
10+
)
11+
12+
from typing import ClassVar
13+
14+
15+
class MonitorUpdateRequestDraftStatus(ModelSimple):
16+
"""
17+
Whether a monitor is in draft or published state. Draft monitors do not notify recipients. Draft monitors are currently in
18+
preview and field is only processed for enabled customers. This accepts the values `draft`
19+
and `published`. Defaults to published.
20+
21+
:param value: If omitted defaults to "published". Must be one of ["draft", "published"].
22+
:type value: str
23+
"""
24+
25+
allowed_values = {
26+
"draft",
27+
"published",
28+
}
29+
DRAFT: ClassVar["MonitorUpdateRequestDraftStatus"]
30+
PUBLISHED: ClassVar["MonitorUpdateRequestDraftStatus"]
31+
32+
@cached_property
33+
def openapi_types(_):
34+
return {
35+
"value": (str,),
36+
}
37+
38+
39+
MonitorUpdateRequestDraftStatus.DRAFT = MonitorUpdateRequestDraftStatus("draft")
40+
MonitorUpdateRequestDraftStatus.PUBLISHED = MonitorUpdateRequestDraftStatus("published")

0 commit comments

Comments
 (0)