diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index e8bb5351a8..fc6f224d3b 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -120748,6 +120748,19 @@ components: description: The name of the feature flag. example: "Updated Feature Flag XYZ789" type: string + tags: + description: |- + Tags associated with the feature flag. This field replaces the full set of + existing tags; omit it to leave tags unchanged, or pass an empty array to + clear all tags. The owning team is set by including a tag of the form + `team:` in this array. + example: ["team:feature-flagging"] + items: + description: A tag associated with the feature flag. + maxLength: 200 + type: string + maxItems: 100 + type: array type: object UpdateFeatureFlagData: description: Data for updating a feature flag. @@ -149224,6 +149237,11 @@ paths: description: |- Updates an existing feature flag's metadata such as name and description. Does not modify targeting rules or allocations. + + To change the owning team, update `tags` and include a tag of the form + `team:` in the array. `tags` is a full replacement of the + existing tag set (including any `team:` tag), so include every tag you + want to keep, not just the ones you're adding. operationId: UpdateFeatureFlag parameters: - $ref: "#/components/parameters/feature_flag_id" @@ -149238,6 +149256,7 @@ paths: description: Updated description for the feature flag enabled: true name: Updated Feature Flag XYZ789 + tags: ["team:feature-flagging"] type: feature-flags schema: $ref: "#/components/schemas/UpdateFeatureFlagRequest" diff --git a/src/datadog_api_client/v2/api/feature_flags_api.py b/src/datadog_api_client/v2/api/feature_flags_api.py index 611336ffde..37ca6958ba 100644 --- a/src/datadog_api_client/v2/api/feature_flags_api.py +++ b/src/datadog_api_client/v2/api/feature_flags_api.py @@ -1069,6 +1069,11 @@ def update_feature_flag( Updates an existing feature flag's metadata such as name and description. Does not modify targeting rules or allocations. + To change the owning team, update ``tags`` and include a tag of the form + ``team:`` in the array. ``tags`` is a full replacement of the + existing tag set (including any ``team:`` tag), so include every tag you + want to keep, not just the ones you're adding. + :param feature_flag_id: The ID of the feature flag. :type feature_flag_id: UUID :type body: UpdateFeatureFlagRequest diff --git a/src/datadog_api_client/v2/model/update_feature_flag_attributes.py b/src/datadog_api_client/v2/model/update_feature_flag_attributes.py index 89ce1d0b3a..1537b9aa81 100644 --- a/src/datadog_api_client/v2/model/update_feature_flag_attributes.py +++ b/src/datadog_api_client/v2/model/update_feature_flag_attributes.py @@ -3,7 +3,7 @@ # Copyright 2019-Present Datadog, Inc. from __future__ import annotations -from typing import Union +from typing import List, Union from datadog_api_client.model_utils import ( ModelNormal, @@ -15,18 +15,26 @@ class UpdateFeatureFlagAttributes(ModelNormal): + validations = { + "tags": { + "max_items": 100, + }, + } + @cached_property def openapi_types(_): return { "description": (str,), "json_schema": (str, none_type), "name": (str,), + "tags": ([str],), } attribute_map = { "description": "description", "json_schema": "json_schema", "name": "name", + "tags": "tags", } def __init__( @@ -34,6 +42,7 @@ def __init__( description: Union[str, UnsetType] = unset, json_schema: Union[str, none_type, UnsetType] = unset, name: Union[str, UnsetType] = unset, + tags: Union[List[str], UnsetType] = unset, **kwargs, ): """ @@ -47,6 +56,12 @@ def __init__( :param name: The name of the feature flag. :type name: str, optional + + :param tags: Tags associated with the feature flag. This field replaces the full set of + existing tags; omit it to leave tags unchanged, or pass an empty array to + clear all tags. The owning team is set by including a tag of the form + ``team:`` in this array. + :type tags: [str], optional """ if description is not unset: kwargs["description"] = description @@ -54,4 +69,6 @@ def __init__( kwargs["json_schema"] = json_schema if name is not unset: kwargs["name"] = name + if tags is not unset: + kwargs["tags"] = tags super().__init__(kwargs)