Skip to content
Merged
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-06-17 14:56:02.884286",
"spec_repo_commit": "b359fdcc"
"regenerated": "2025-06-17 18:21:59.760405",
"spec_repo_commit": "b1a1c000"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2025-06-17 14:56:02.899290",
"spec_repo_commit": "b359fdcc"
"regenerated": "2025-06-17 18:21:59.775701",
"spec_repo_commit": "b1a1c000"
}
}
}
18 changes: 18 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35002,6 +35002,11 @@ components:
items:
$ref: '#/components/schemas/SensitiveDataScannerProduct'
type: array
samplings:
description: List of sampling rates per product type.
items:
$ref: '#/components/schemas/SensitiveDataScannerSamplings'
type: array
type: object
SensitiveDataScannerGroupCreate:
description: Data related to the creation of a group.
Expand Down Expand Up @@ -35433,6 +35438,19 @@ components:
meta:
$ref: '#/components/schemas/SensitiveDataScannerMetaVersionOnly'
type: object
SensitiveDataScannerSamplings:
description: Sampling configurations for the Scanning Group.
properties:
product:
$ref: '#/components/schemas/SensitiveDataScannerProduct'
rate:
description: Rate at which data in product type will be scanned, as a percentage.
example: 100.0
format: double
maximum: 100.0
minimum: 0.0
type: number
type: object
SensitiveDataScannerStandardPattern:
description: Data containing the standard pattern id.
properties:
Expand Down
7 changes: 7 additions & 0 deletions docs/datadog_api_client.v2.model.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15334,6 +15334,13 @@ datadog\_api\_client.v2.model.sensitive\_data\_scanner\_rule\_update\_response m
:members:
:show-inheritance:

datadog\_api\_client.v2.model.sensitive\_data\_scanner\_samplings module
------------------------------------------------------------------------

.. automodule:: datadog_api_client.v2.model.sensitive_data_scanner_samplings
:members:
:show-inheritance:

datadog\_api\_client.v2.model.sensitive\_data\_scanner\_standard\_pattern module
--------------------------------------------------------------------------------

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,23 @@
if TYPE_CHECKING:
from datadog_api_client.v2.model.sensitive_data_scanner_filter import SensitiveDataScannerFilter
from datadog_api_client.v2.model.sensitive_data_scanner_product import SensitiveDataScannerProduct
from datadog_api_client.v2.model.sensitive_data_scanner_samplings import SensitiveDataScannerSamplings


class SensitiveDataScannerGroupAttributes(ModelNormal):
@cached_property
def openapi_types(_):
from datadog_api_client.v2.model.sensitive_data_scanner_filter import SensitiveDataScannerFilter
from datadog_api_client.v2.model.sensitive_data_scanner_product import SensitiveDataScannerProduct
from datadog_api_client.v2.model.sensitive_data_scanner_samplings import SensitiveDataScannerSamplings

return {
"description": (str,),
"filter": (SensitiveDataScannerFilter,),
"is_enabled": (bool,),
"name": (str,),
"product_list": ([SensitiveDataScannerProduct],),
"samplings": ([SensitiveDataScannerSamplings],),
}

attribute_map = {
Expand All @@ -38,6 +41,7 @@ def openapi_types(_):
"is_enabled": "is_enabled",
"name": "name",
"product_list": "product_list",
"samplings": "samplings",
}

def __init__(
Expand All @@ -47,6 +51,7 @@ def __init__(
is_enabled: Union[bool, UnsetType] = unset,
name: Union[str, UnsetType] = unset,
product_list: Union[List[SensitiveDataScannerProduct], UnsetType] = unset,
samplings: Union[List[SensitiveDataScannerSamplings], UnsetType] = unset,
**kwargs,
):
"""
Expand All @@ -66,6 +71,9 @@ def __init__(

:param product_list: List of products the scanning group applies.
:type product_list: [SensitiveDataScannerProduct], optional

:param samplings: List of sampling rates per product type.
:type samplings: [SensitiveDataScannerSamplings], optional
"""
if description is not unset:
kwargs["description"] = description
Expand All @@ -77,4 +85,6 @@ def __init__(
kwargs["name"] = name
if product_list is not unset:
kwargs["product_list"] = product_list
if samplings is not unset:
kwargs["samplings"] = samplings
super().__init__(kwargs)
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
# This product includes software developed at Datadog (https://www.datadoghq.com/).
# Copyright 2019-Present Datadog, Inc.
from __future__ import annotations

from typing import Union, TYPE_CHECKING

from datadog_api_client.model_utils import (
ModelNormal,
cached_property,
unset,
UnsetType,
)


if TYPE_CHECKING:
from datadog_api_client.v2.model.sensitive_data_scanner_product import SensitiveDataScannerProduct


class SensitiveDataScannerSamplings(ModelNormal):
validations = {
"rate": {
"inclusive_maximum": 100.0,
"inclusive_minimum": 0.0,
},
}

@cached_property
def openapi_types(_):
from datadog_api_client.v2.model.sensitive_data_scanner_product import SensitiveDataScannerProduct

return {
"product": (SensitiveDataScannerProduct,),
"rate": (float,),
}

attribute_map = {
"product": "product",
"rate": "rate",
}

def __init__(
self_,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 Code Quality Violation

Suggested change
self_,
self,
first parameter of a class function should be self (...read more)

In a class method (that is not a class method nor a static method), the first argument must be self by convention.

Learn More

View in Datadog  Leave us feedback  Documentation

product: Union[SensitiveDataScannerProduct, UnsetType] = unset,
rate: Union[float, UnsetType] = unset,
**kwargs,
):
"""
Sampling configurations for the Scanning Group.

:param product: Datadog product onto which Sensitive Data Scanner can be activated.
:type product: SensitiveDataScannerProduct, optional

:param rate: Rate at which data in product type will be scanned, as a percentage.
:type rate: float, optional
"""
if product is not unset:
kwargs["product"] = product
if rate is not unset:
kwargs["rate"] = rate
super().__init__(kwargs)
2 changes: 2 additions & 0 deletions src/datadog_api_client/v2/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3053,6 +3053,7 @@
from datadog_api_client.v2.model.sensitive_data_scanner_rule_update_response import (
SensitiveDataScannerRuleUpdateResponse,
)
from datadog_api_client.v2.model.sensitive_data_scanner_samplings import SensitiveDataScannerSamplings
from datadog_api_client.v2.model.sensitive_data_scanner_standard_pattern import SensitiveDataScannerStandardPattern
from datadog_api_client.v2.model.sensitive_data_scanner_standard_pattern_attributes import (
SensitiveDataScannerStandardPatternAttributes,
Expand Down Expand Up @@ -5692,6 +5693,7 @@
"SensitiveDataScannerRuleUpdate",
"SensitiveDataScannerRuleUpdateRequest",
"SensitiveDataScannerRuleUpdateResponse",
"SensitiveDataScannerSamplings",
"SensitiveDataScannerStandardPattern",
"SensitiveDataScannerStandardPatternAttributes",
"SensitiveDataScannerStandardPatternData",
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2022-12-15T14:50:52.745Z
2025-05-30T17:17:05.785Z
Loading