Skip to content

Commit 80a1f91

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 230d93c of spec repo
1 parent 110582d commit 80a1f91

14 files changed

+384
-24
lines changed

.generator/schemas/v1/openapi.yaml

Lines changed: 57 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3288,15 +3288,19 @@ components:
32883288
example: https://www.googleapis.com/robot/v1/metadata/x509/$CLIENT_EMAIL
32893289
type: string
32903290
cloud_run_revision_filters:
3291-
description: 'Limit the Cloud Run revisions that are pulled into Datadog
3292-
by using tags.
3291+
deprecated: true
3292+
description: 'List of filters to limit the Cloud Run revisions that are
3293+
pulled into Datadog by using tags.
32933294

32943295
Only Cloud Run revision resources that apply to specified filters are
3295-
imported into Datadog.'
3296+
imported into Datadog.
3297+
3298+
NOTE: this field is deprecated, prefer `monitored_resource_configs` with
3299+
`type=cloud_run_revision`'
32963300
example:
32973301
- $KEY:$VALUE
32983302
items:
3299-
description: Cloud Run Filters
3303+
description: Cloud Run revision filters
33003304
type: string
33013305
type: array
33023306
errors:
@@ -3309,11 +3313,16 @@ components:
33093313
type: string
33103314
type: array
33113315
host_filters:
3312-
description: 'Limit the GCE instances that are pulled into Datadog by using
3313-
tags.
3316+
deprecated: true
3317+
description: 'A comma-separated list of filters to limit the VM Instances
3318+
that are pulled into Datadog by using tags.
33143319

3315-
Only hosts that match one of the defined tags are imported into Datadog.'
3316-
example: key:value,filter:example
3320+
Only VM Instance resources that apply to specified filters are imported
3321+
into Datadog.
3322+
3323+
NOTE: this field is deprecated, prefer `monitored_resource_configs` with
3324+
`type=gce_instance`'
3325+
example: $KEY1:$VALUE1,$KEY2:$VALUE2
33173326
type: string
33183327
is_cspm_enabled:
33193328
description: 'When enabled, Datadog will activate the Cloud Security Monitoring
@@ -3334,6 +3343,15 @@ components:
33343343
account.'
33353344
example: true
33363345
type: boolean
3346+
monitored_resource_configs:
3347+
description: Configurations for GCP monitored resources.
3348+
example:
3349+
- filters:
3350+
- $KEY:$VALUE
3351+
type: gce_instance
3352+
items:
3353+
$ref: '#/components/schemas/GCPMonitoredResourceConfig'
3354+
type: array
33373355
private_key:
33383356
description: Your private key name found in your JSON service account key.
33393357
example: private_key
@@ -3366,6 +3384,37 @@ components:
33663384
items:
33673385
$ref: '#/components/schemas/GCPAccount'
33683386
type: array
3387+
GCPMonitoredResourceConfig:
3388+
description: Configuration for a GCP monitored resource.
3389+
properties:
3390+
filters:
3391+
description: 'List of filters to limit the monitored resources that are
3392+
pulled into Datadog by using tags.
3393+
3394+
Only monitored resources that apply to specified filters are imported
3395+
into Datadog.'
3396+
example:
3397+
- $KEY:$VALUE
3398+
items:
3399+
description: A monitored resource filter
3400+
type: string
3401+
type: array
3402+
type:
3403+
$ref: '#/components/schemas/GCPMonitoredResourceConfigType'
3404+
type: object
3405+
GCPMonitoredResourceConfigType:
3406+
description: The GCP monitored resource type. Only a subset of resource types
3407+
are supported.
3408+
enum:
3409+
- cloud_function
3410+
- cloud_run_revision
3411+
- gce_instance
3412+
example: gce_instance
3413+
type: string
3414+
x-enum-varnames:
3415+
- CLOUD_FUNCTION
3416+
- CLOUD_RUN_REVISION
3417+
- GCE_INSTANCE
33693418
GeomapWidgetDefinition:
33703419
description: This visualization displays a series of values by country on a
33713420
world map.

.generator/schemas/v2/openapi.yaml

Lines changed: 58 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17626,6 +17626,37 @@ components:
1762617626
example: aiplatform
1762717627
type: string
1762817628
type: object
17629+
GCPMonitoredResourceConfig:
17630+
description: Configuration for a GCP monitored resource.
17631+
properties:
17632+
filters:
17633+
description: 'List of filters to limit the monitored resources that are
17634+
pulled into Datadog by using tags.
17635+
17636+
Only monitored resources that apply to specified filters are imported
17637+
into Datadog.'
17638+
example:
17639+
- $KEY:$VALUE
17640+
items:
17641+
description: A monitored resource filter
17642+
type: string
17643+
type: array
17644+
type:
17645+
$ref: '#/components/schemas/GCPMonitoredResourceConfigType'
17646+
type: object
17647+
GCPMonitoredResourceConfigType:
17648+
description: The GCP monitored resource type. Only a subset of resource types
17649+
are supported.
17650+
enum:
17651+
- cloud_function
17652+
- cloud_run_revision
17653+
- gce_instance
17654+
example: gce_instance
17655+
type: string
17656+
x-enum-varnames:
17657+
- CLOUD_FUNCTION
17658+
- CLOUD_RUN_REVISION
17659+
- GCE_INSTANCE
1762917660
GCPSTSDelegateAccount:
1763017661
description: Datadog principal service account info.
1763117662
properties:
@@ -17693,21 +17724,35 @@ components:
1769317724
example: datadog-service-account@test-project.iam.gserviceaccount.com
1769417725
type: string
1769517726
cloud_run_revision_filters:
17727+
deprecated: true
1769617728
description: 'List of filters to limit the Cloud Run revisions that are
1769717729
pulled into Datadog by using tags.
1769817730

1769917731
Only Cloud Run revision resources that apply to specified filters are
17700-
imported into Datadog.'
17732+
imported into Datadog.
17733+
17734+
NOTE: this field is deprecated, prefer `monitored_resource_configs` with
17735+
`type=cloud_run_revision`'
1770117736
example:
1770217737
- $KEY:$VALUE
1770317738
items:
17704-
description: Cloud Run Filters
17739+
description: Cloud Run revision filters
1770517740
type: string
1770617741
type: array
1770717742
host_filters:
17708-
description: Your Host Filters.
17743+
deprecated: true
17744+
description: 'List of filters to limit the VM Instances that are pulled
17745+
into Datadog by using tags.
17746+
17747+
Only VM Instance resources that apply to specified filters are imported
17748+
into Datadog.
17749+
17750+
NOTE: this field is deprecated, prefer `monitored_resource_configs` with
17751+
`type=gce_instance`'
17752+
example:
17753+
- $KEY:$VALUE
1770917754
items:
17710-
description: Host Filters
17755+
description: VM Instance filters
1771117756
type: string
1771217757
type: array
1771317758
is_cspm_enabled:
@@ -17743,6 +17788,15 @@ components:
1774317788
items:
1774417789
$ref: '#/components/schemas/GCPMetricNamespaceConfig'
1774517790
type: array
17791+
monitored_resource_configs:
17792+
description: Configurations for GCP monitored resources.
17793+
example:
17794+
- filters:
17795+
- $KEY:$VALUE
17796+
type: gce_instance
17797+
items:
17798+
$ref: '#/components/schemas/GCPMonitoredResourceConfig'
17799+
type: array
1774617800
resource_collection_enabled:
1774717801
description: When enabled, Datadog scans for all resources in your GCP environment.
1774817802
type: boolean

docs/datadog_api_client.v1.model.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1040,6 +1040,20 @@ datadog\_api\_client.v1.model.gcp\_account\_list\_response module
10401040
:members:
10411041
:show-inheritance:
10421042

1043+
datadog\_api\_client.v1.model.gcp\_monitored\_resource\_config module
1044+
---------------------------------------------------------------------
1045+
1046+
.. automodule:: datadog_api_client.v1.model.gcp_monitored_resource_config
1047+
:members:
1048+
:show-inheritance:
1049+
1050+
datadog\_api\_client.v1.model.gcp\_monitored\_resource\_config\_type module
1051+
---------------------------------------------------------------------------
1052+
1053+
.. automodule:: datadog_api_client.v1.model.gcp_monitored_resource_config_type
1054+
:members:
1055+
:show-inheritance:
1056+
10431057
datadog\_api\_client.v1.model.geomap\_widget\_definition module
10441058
---------------------------------------------------------------
10451059

docs/datadog_api_client.v2.model.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7403,6 +7403,20 @@ datadog\_api\_client.v2.model.gcp\_metric\_namespace\_config module
74037403
:members:
74047404
:show-inheritance:
74057405

7406+
datadog\_api\_client.v2.model.gcp\_monitored\_resource\_config module
7407+
---------------------------------------------------------------------
7408+
7409+
.. automodule:: datadog_api_client.v2.model.gcp_monitored_resource_config
7410+
:members:
7411+
:show-inheritance:
7412+
7413+
datadog\_api\_client.v2.model.gcp\_monitored\_resource\_config\_type module
7414+
---------------------------------------------------------------------------
7415+
7416+
.. automodule:: datadog_api_client.v2.model.gcp_monitored_resource_config_type
7417+
:members:
7418+
:show-inheritance:
7419+
74067420
datadog\_api\_client.v2.model.gcp\_service\_account module
74077421
----------------------------------------------------------
74087422

src/datadog_api_client/v1/model/gcp_account.py

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Copyright 2019-Present Datadog, Inc.
44
from __future__ import annotations
55

6-
from typing import List, Union
6+
from typing import List, Union, TYPE_CHECKING
77

88
from datadog_api_client.model_utils import (
99
ModelNormal,
@@ -13,9 +13,15 @@
1313
)
1414

1515

16+
if TYPE_CHECKING:
17+
from datadog_api_client.v1.model.gcp_monitored_resource_config import GCPMonitoredResourceConfig
18+
19+
1620
class GCPAccount(ModelNormal):
1721
@cached_property
1822
def openapi_types(_):
23+
from datadog_api_client.v1.model.gcp_monitored_resource_config import GCPMonitoredResourceConfig
24+
1925
return {
2026
"auth_provider_x509_cert_url": (str,),
2127
"auth_uri": (str,),
@@ -29,6 +35,7 @@ def openapi_types(_):
2935
"is_cspm_enabled": (bool,),
3036
"is_resource_change_collection_enabled": (bool,),
3137
"is_security_command_center_enabled": (bool,),
38+
"monitored_resource_configs": ([GCPMonitoredResourceConfig],),
3239
"private_key": (str,),
3340
"private_key_id": (str,),
3441
"project_id": (str,),
@@ -50,6 +57,7 @@ def openapi_types(_):
5057
"is_cspm_enabled": "is_cspm_enabled",
5158
"is_resource_change_collection_enabled": "is_resource_change_collection_enabled",
5259
"is_security_command_center_enabled": "is_security_command_center_enabled",
60+
"monitored_resource_configs": "monitored_resource_configs",
5361
"private_key": "private_key",
5462
"private_key_id": "private_key_id",
5563
"project_id": "project_id",
@@ -72,6 +80,7 @@ def __init__(
7280
is_cspm_enabled: Union[bool, UnsetType] = unset,
7381
is_resource_change_collection_enabled: Union[bool, UnsetType] = unset,
7482
is_security_command_center_enabled: Union[bool, UnsetType] = unset,
83+
monitored_resource_configs: Union[List[GCPMonitoredResourceConfig], UnsetType] = unset,
7584
private_key: Union[str, UnsetType] = unset,
7685
private_key_id: Union[str, UnsetType] = unset,
7786
project_id: Union[str, UnsetType] = unset,
@@ -102,15 +111,17 @@ def __init__(
102111
where ``$CLIENT_EMAIL`` is the email found in your JSON service account key.
103112
:type client_x509_cert_url: str, optional
104113
105-
:param cloud_run_revision_filters: Limit the Cloud Run revisions that are pulled into Datadog by using tags.
114+
:param cloud_run_revision_filters: List of filters to limit the Cloud Run revisions that are pulled into Datadog by using tags.
106115
Only Cloud Run revision resources that apply to specified filters are imported into Datadog.
116+
NOTE: this field is deprecated, prefer ``monitored_resource_configs`` with ``type=cloud_run_revision`` **Deprecated**.
107117
:type cloud_run_revision_filters: [str], optional
108118
109119
:param errors: An array of errors.
110120
:type errors: [str], optional
111121
112-
:param host_filters: Limit the GCE instances that are pulled into Datadog by using tags.
113-
Only hosts that match one of the defined tags are imported into Datadog.
122+
:param host_filters: A comma-separated list of filters to limit the VM Instances that are pulled into Datadog by using tags.
123+
Only VM Instance resources that apply to specified filters are imported into Datadog.
124+
NOTE: this field is deprecated, prefer ``monitored_resource_configs`` with ``type=gce_instance`` **Deprecated**.
114125
:type host_filters: str, optional
115126
116127
:param is_cspm_enabled: When enabled, Datadog will activate the Cloud Security Monitoring product for this service account. Note: This requires resource_collection_enabled to be set to true.
@@ -122,6 +133,9 @@ def __init__(
122133
:param is_security_command_center_enabled: When enabled, Datadog will attempt to collect Security Command Center Findings. Note: This requires additional permissions on the service account.
123134
:type is_security_command_center_enabled: bool, optional
124135
136+
:param monitored_resource_configs: Configurations for GCP monitored resources.
137+
:type monitored_resource_configs: [GCPMonitoredResourceConfig], optional
138+
125139
:param private_key: Your private key name found in your JSON service account key.
126140
:type private_key: str, optional
127141
@@ -164,6 +178,8 @@ def __init__(
164178
kwargs["is_resource_change_collection_enabled"] = is_resource_change_collection_enabled
165179
if is_security_command_center_enabled is not unset:
166180
kwargs["is_security_command_center_enabled"] = is_security_command_center_enabled
181+
if monitored_resource_configs is not unset:
182+
kwargs["monitored_resource_configs"] = monitored_resource_configs
167183
if private_key is not unset:
168184
kwargs["private_key"] = private_key
169185
if private_key_id is not unset:
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
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+
from typing import List, Union, TYPE_CHECKING
7+
8+
from datadog_api_client.model_utils import (
9+
ModelNormal,
10+
cached_property,
11+
unset,
12+
UnsetType,
13+
)
14+
15+
16+
if TYPE_CHECKING:
17+
from datadog_api_client.v1.model.gcp_monitored_resource_config_type import GCPMonitoredResourceConfigType
18+
19+
20+
class GCPMonitoredResourceConfig(ModelNormal):
21+
@cached_property
22+
def openapi_types(_):
23+
from datadog_api_client.v1.model.gcp_monitored_resource_config_type import GCPMonitoredResourceConfigType
24+
25+
return {
26+
"filters": ([str],),
27+
"type": (GCPMonitoredResourceConfigType,),
28+
}
29+
30+
attribute_map = {
31+
"filters": "filters",
32+
"type": "type",
33+
}
34+
35+
def __init__(
36+
self_,
37+
filters: Union[List[str], UnsetType] = unset,
38+
type: Union[GCPMonitoredResourceConfigType, UnsetType] = unset,
39+
**kwargs,
40+
):
41+
"""
42+
Configuration for a GCP monitored resource.
43+
44+
:param filters: List of filters to limit the monitored resources that are pulled into Datadog by using tags.
45+
Only monitored resources that apply to specified filters are imported into Datadog.
46+
:type filters: [str], optional
47+
48+
:param type: The GCP monitored resource type. Only a subset of resource types are supported.
49+
:type type: GCPMonitoredResourceConfigType, optional
50+
"""
51+
if filters is not unset:
52+
kwargs["filters"] = filters
53+
if type is not unset:
54+
kwargs["type"] = type
55+
super().__init__(kwargs)

0 commit comments

Comments
 (0)