diff --git a/.apigentools-info b/.apigentools-info index ed387e3458..68f371b102 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.6.6", - "regenerated": "2025-06-26 17:56:18.417997", - "spec_repo_commit": "76086f13" + "regenerated": "2025-06-26 21:05:33.669388", + "spec_repo_commit": "3211ca1b" }, "v2": { "apigentools_version": "1.6.6", - "regenerated": "2025-06-26 17:56:18.433709", - "spec_repo_commit": "76086f13" + "regenerated": "2025-06-26 21:05:33.684429", + "spec_repo_commit": "3211ca1b" } } } \ No newline at end of file diff --git a/.generator/schemas/v1/openapi.yaml b/.generator/schemas/v1/openapi.yaml index 3ff83bedc5..9c8dd33e03 100644 --- a/.generator/schemas/v1/openapi.yaml +++ b/.generator/schemas/v1/openapi.yaml @@ -3439,13 +3439,28 @@ components: example: focus: WORLD properties: + custom_extent: + description: A custom extent of the map defined by an array of four numbers + in the order `[minLongitude, minLatitude, maxLongitude, maxLatitude]`. + Mutually exclusive with `focus`. + example: + - -30 + - -40 + - 40 + - 30 + items: + description: The longitudinal or latitudinal coordinates of the bounding + box. + format: double + type: number + maxItems: 4 + minItems: 4 + type: array focus: description: The 2-letter ISO code of a country to focus the map on. Or - `WORLD`. + `WORLD`. Mutually exclusive with `custom_extent`. example: WORLD type: string - required: - - focus type: object GeomapWidgetRequest: description: An updated geomap widget. diff --git a/src/datadog_api_client/v1/model/geomap_widget_definition_view.py b/src/datadog_api_client/v1/model/geomap_widget_definition_view.py index da0d9b6936..2008a0a891 100644 --- a/src/datadog_api_client/v1/model/geomap_widget_definition_view.py +++ b/src/datadog_api_client/v1/model/geomap_widget_definition_view.py @@ -3,31 +3,50 @@ # Copyright 2019-Present Datadog, Inc. from __future__ import annotations +from typing import List, Union from datadog_api_client.model_utils import ( ModelNormal, cached_property, + unset, + UnsetType, ) class GeomapWidgetDefinitionView(ModelNormal): + validations = { + "custom_extent": { + "max_items": 4, + "min_items": 4, + }, + } + @cached_property def openapi_types(_): return { + "custom_extent": ([float],), "focus": (str,), } attribute_map = { + "custom_extent": "custom_extent", "focus": "focus", } - def __init__(self_, focus: str, **kwargs): + def __init__( + self_, custom_extent: Union[List[float], UnsetType] = unset, focus: Union[str, UnsetType] = unset, **kwargs + ): """ The view of the world that the map should render. - :param focus: The 2-letter ISO code of a country to focus the map on. Or ``WORLD``. - :type focus: str + :param custom_extent: A custom extent of the map defined by an array of four numbers in the order ``[minLongitude, minLatitude, maxLongitude, maxLatitude]``. Mutually exclusive with ``focus``. + :type custom_extent: [float], optional + + :param focus: The 2-letter ISO code of a country to focus the map on. Or ``WORLD``. Mutually exclusive with ``custom_extent``. + :type focus: str, optional """ + if custom_extent is not unset: + kwargs["custom_extent"] = custom_extent + if focus is not unset: + kwargs["focus"] = focus super().__init__(kwargs) - - self_.focus = focus