From 639cf7294ecb5e2795a42d6e6cf91c9f59f20adc Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Thu, 22 Oct 2026 11:21:41 +0000 Subject: [PATCH] Regenerate client from commit 1828d5d of spec repo --- .generator/schemas/v1/openapi.yaml | 3 +++ .generator/schemas/v2/openapi.yaml | 4 +--- src/datadog_api_client/v1/api/events_api.py | 6 +++++- src/datadog_api_client/v2/api/events_api.py | 4 +--- 4 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.generator/schemas/v1/openapi.yaml b/.generator/schemas/v1/openapi.yaml index 4e0c285360..c9c9b16f97 100644 --- a/.generator/schemas/v1/openapi.yaml +++ b/.generator/schemas/v1/openapi.yaml @@ -32332,7 +32332,10 @@ paths: permissions: - events_read post: + deprecated: true description: |- + This endpoint is deprecated and is available only to organizations that have previously used it. Use the V2 endpoint instead. + This endpoint allows you to post events to the stream. Tag them, set priority and event aggregate them with other events. operationId: CreateEvent diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index c597b104fe..ea9a531002 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -167370,9 +167370,7 @@ paths: **Important:** Upgrade to the latest client library version to use the updated endpoint at `https://event-management-intake.{site}/api/v2/events`. Older client library versions of the Post an event (v2) API send requests to a deprecated endpoint (`https://api.{site}/api/v2/events`). - ✅ **Only events with the `change` or `alert` category** are in General Availability. For change events, see [Change Tracking](https://docs.datadoghq.com/change_tracking) for more details. - - ❌ For use cases involving other event categories, use the V1 endpoint or reach out to [support](https://www.datadoghq.com/support/). + Supported event categories are `change` and `alert`. For more information about change events, see [Change Tracking](https://docs.datadoghq.com/change_tracking). operationId: CreateEvent requestBody: content: diff --git a/src/datadog_api_client/v1/api/events_api.py b/src/datadog_api_client/v1/api/events_api.py index bb6b80d6ee..bb6c9ca9f0 100644 --- a/src/datadog_api_client/v1/api/events_api.py +++ b/src/datadog_api_client/v1/api/events_api.py @@ -4,6 +4,7 @@ from __future__ import annotations from typing import Any, Dict, Union +import warnings from datadog_api_client.api_client import ApiClient, Endpoint as _Endpoint from datadog_api_client.configuration import Configuration @@ -139,7 +140,9 @@ def create_event( self, body: EventCreateRequest, ) -> EventCreateResponse: - """Post an event. + """Post an event. **Deprecated**. + + This endpoint is deprecated and is available only to organizations that have previously used it. Use the V2 endpoint instead. This endpoint allows you to post events to the stream. Tag them, set priority and event aggregate them with other events. @@ -151,6 +154,7 @@ def create_event( kwargs: Dict[str, Any] = {} kwargs["body"] = body + warnings.warn("create_event is deprecated", DeprecationWarning, stacklevel=2) return self._create_event_endpoint.call_with_http_info(**kwargs) def get_event( diff --git a/src/datadog_api_client/v2/api/events_api.py b/src/datadog_api_client/v2/api/events_api.py index 29a768317f..b2266ceea1 100644 --- a/src/datadog_api_client/v2/api/events_api.py +++ b/src/datadog_api_client/v2/api/events_api.py @@ -211,9 +211,7 @@ def create_event( **Important:** Upgrade to the latest client library version to use the updated endpoint at ``https://event-management-intake.{site}/api/v2/events``. Older client library versions of the Post an event (v2) API send requests to a deprecated endpoint ( ``https://api.{site}/api/v2/events`` ). - ✅ **Only events with the change or alert category** are in General Availability. For change events, see `Change Tracking `_ for more details. - - ❌ For use cases involving other event categories, use the V1 endpoint or reach out to `support `_. + Supported event categories are ``change`` and ``alert``. For more information about change events, see `Change Tracking `_. :param body: Event creation request payload. :type body: EventCreateRequestPayload