diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 34aa893e3e..2c0f436fe3 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -1773,23 +1773,6 @@ components: required: true schema: $ref: "#/components/schemas/RumPermanentRetentionFilterID" - RumRateLimitScopeIDParameter: - description: |- - The identifier of the scope the rate limit configuration applies to. - For the `application` scope, this is the RUM application ID. - in: path - name: scope_id - required: true - schema: - example: cd73a516-a481-4af5-8352-9b577465c77b - type: string - RumRateLimitScopeTypeParameter: - description: The type of scope the rate limit configuration applies to. - in: path - name: scope_type - required: true - schema: - $ref: "#/components/schemas/RumRateLimitScopeType" RumRetentionFilterIDParameter: description: Retention filter ID. in: path @@ -89425,179 +89408,6 @@ components: $ref: "#/components/schemas/RumPermanentRetentionFilterData" type: array type: object - RumRateLimitAdaptiveConfig: - description: The configuration used when `mode` is `adaptive`. - properties: - max_retention_rate: - description: The maximum fraction of sessions to retain, in the range `(0, 1]`. - example: 0.5 - exclusiveMinimum: true - format: double - maximum: 1 - minimum: 0 - type: number - required: - - max_retention_rate - type: object - RumRateLimitConfigAttributes: - description: The RUM rate limit configuration properties. - properties: - adaptive: - $ref: "#/components/schemas/RumRateLimitAdaptiveConfig" - custom: - $ref: "#/components/schemas/RumRateLimitCustomConfig" - mode: - $ref: "#/components/schemas/RumRateLimitMode" - org_id: - description: The ID of the organization the rate limit configuration belongs to. - example: 2 - format: int64 - type: integer - updated_at: - description: The date the rate limit configuration was last updated. - example: "2026-03-04T15:37:54.951447Z" - type: string - updated_by: - description: The handle of the user who last updated the rate limit configuration. - example: test@example.com - type: string - required: - - mode - - org_id - type: object - RumRateLimitConfigData: - description: The RUM rate limit configuration object. - properties: - attributes: - $ref: "#/components/schemas/RumRateLimitConfigAttributes" - id: - description: The identifier of the scope the rate limit configuration applies to. - example: cd73a516-a481-4af5-8352-9b577465c77b - type: string - type: - $ref: "#/components/schemas/RumRateLimitConfigType" - required: - - id - - type - - attributes - type: object - RumRateLimitConfigResponse: - description: The RUM rate limit configuration response. - properties: - data: - $ref: "#/components/schemas/RumRateLimitConfigData" - required: - - data - type: object - RumRateLimitConfigType: - default: rum_rate_limit_config - description: The type of the resource, always `rum_rate_limit_config`. - enum: - - rum_rate_limit_config - example: rum_rate_limit_config - type: string - x-enum-varnames: ["RUM_RATE_LIMIT_CONFIG"] - RumRateLimitConfigUpdateAttributes: - description: The RUM rate limit configuration properties to create or update. - properties: - adaptive: - $ref: "#/components/schemas/RumRateLimitAdaptiveConfig" - custom: - $ref: "#/components/schemas/RumRateLimitCustomConfig" - mode: - $ref: "#/components/schemas/RumRateLimitMode" - required: - - mode - type: object - RumRateLimitConfigUpdateData: - description: The RUM rate limit configuration to create or update. - properties: - attributes: - $ref: "#/components/schemas/RumRateLimitConfigUpdateAttributes" - id: - description: |- - The identifier of the scope the rate limit configuration applies to. - Must match `scope_id` in the path. - example: cd73a516-a481-4af5-8352-9b577465c77b - type: string - type: - $ref: "#/components/schemas/RumRateLimitConfigType" - required: - - id - - type - - attributes - type: object - RumRateLimitConfigUpdateRequest: - description: The body of a request to create or update a RUM rate limit configuration. - properties: - data: - $ref: "#/components/schemas/RumRateLimitConfigUpdateData" - required: - - data - type: object - RumRateLimitCustomConfig: - description: The configuration used when `mode` is `custom`. - properties: - daily_reset_time: - description: The time of day when the daily quota resets, in `HH:MM` 24-hour format. - example: "08:00" - pattern: "^([01]\\d|2[0-3]):[0-5]\\d$" - type: string - daily_reset_timezone: - description: The timezone offset used for the daily reset time, in `±HH:MM` format. - example: "+09:00" - pattern: "^[+-](0\\d|1[0-4]):[0-5]\\d$" - type: string - quota_reached_action: - $ref: "#/components/schemas/RumRateLimitQuotaReachedAction" - session_limit: - description: The maximum number of sessions allowed within the window. - example: 1000000 - format: int64 - minimum: 1 - type: integer - window_type: - $ref: "#/components/schemas/RumRateLimitWindowType" - required: - - window_type - - session_limit - - daily_reset_time - - daily_reset_timezone - - quota_reached_action - type: object - RumRateLimitMode: - description: |- - The rate limit mode. `custom` enforces a fixed session limit, while - `adaptive` dynamically adjusts retention. - enum: - - custom - - adaptive - example: custom - type: string - x-enum-varnames: ["CUSTOM", "ADAPTIVE"] - RumRateLimitQuotaReachedAction: - description: The action to take when the session quota is reached. - enum: - - stop - - slowdown - example: stop - type: string - x-enum-varnames: ["STOP", "SLOWDOWN"] - RumRateLimitScopeType: - default: application - description: The type of scope the rate limit configuration applies to. - enum: - - application - example: application - type: string - x-enum-varnames: ["APPLICATION"] - RumRateLimitWindowType: - description: The window type over which the session limit is enforced. - enum: - - daily - example: daily - type: string - x-enum-varnames: ["DAILY"] RumRetentionFilterAttributes: description: The object describing attributes of a RUM retention filter. properties: @@ -182977,142 +182787,6 @@ paths: tags: - Rum Metrics x-codegen-request-body-name: body - /api/v2/rum/config/rate-limit/{scope_type}/{scope_id}: - delete: - description: Delete the RUM rate limit configuration for a given scope. - operationId: DeleteRumRateLimitConfig - parameters: - - $ref: "#/components/parameters/RumRateLimitScopeTypeParameter" - - $ref: "#/components/parameters/RumRateLimitScopeIDParameter" - responses: - "204": - description: No Content - "400": - $ref: "#/components/responses/BadRequestResponse" - "403": - $ref: "#/components/responses/NotAuthorizedResponse" - "404": - $ref: "#/components/responses/NotFoundResponse" - "429": - $ref: "#/components/responses/TooManyRequestsResponse" - summary: Delete a RUM rate limit configuration - tags: - - Rum Rate Limit - x-unstable: |- - **Note**: This endpoint is in preview and is subject to change. - If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). - get: - description: Get the RUM rate limit configuration for a given scope. - operationId: GetRumRateLimitConfig - parameters: - - $ref: "#/components/parameters/RumRateLimitScopeTypeParameter" - - $ref: "#/components/parameters/RumRateLimitScopeIDParameter" - responses: - "200": - content: - application/json: - examples: - default: - value: - data: - attributes: - custom: - daily_reset_time: "08:00" - daily_reset_timezone: "+09:00" - quota_reached_action: stop - session_limit: 1000000 - window_type: daily - mode: custom - org_id: 2 - updated_at: "2026-03-04T15:37:54.951447Z" - updated_by: test@example.com - id: cd73a516-a481-4af5-8352-9b577465c77b - type: rum_rate_limit_config - schema: - $ref: "#/components/schemas/RumRateLimitConfigResponse" - description: OK - "400": - $ref: "#/components/responses/BadRequestResponse" - "403": - $ref: "#/components/responses/NotAuthorizedResponse" - "404": - $ref: "#/components/responses/NotFoundResponse" - "429": - $ref: "#/components/responses/TooManyRequestsResponse" - summary: Get a RUM rate limit configuration - tags: - - Rum Rate Limit - x-unstable: |- - **Note**: This endpoint is in preview and is subject to change. - If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). - put: - description: |- - Create or update the RUM rate limit configuration for a given scope. - Returns the rate limit configuration object when the request is successful. - operationId: UpdateRumRateLimitConfig - parameters: - - $ref: "#/components/parameters/RumRateLimitScopeTypeParameter" - - $ref: "#/components/parameters/RumRateLimitScopeIDParameter" - requestBody: - content: - application/json: - examples: - default: - value: - data: - attributes: - custom: - daily_reset_time: "08:00" - daily_reset_timezone: "+09:00" - quota_reached_action: stop - session_limit: 1000000 - window_type: daily - mode: custom - id: cd73a516-a481-4af5-8352-9b577465c77b - type: rum_rate_limit_config - schema: - $ref: "#/components/schemas/RumRateLimitConfigUpdateRequest" - description: The definition of the RUM rate limit configuration to create or update. - required: true - responses: - "200": - content: - application/json: - examples: - default: - value: - data: - attributes: - custom: - daily_reset_time: "08:00" - daily_reset_timezone: "+09:00" - quota_reached_action: stop - session_limit: 1000000 - window_type: daily - mode: custom - org_id: 2 - updated_at: "2026-03-04T21:52:53.526022Z" - updated_by: test@example.com - id: cd73a516-a481-4af5-8352-9b577465c77b - type: rum_rate_limit_config - schema: - $ref: "#/components/schemas/RumRateLimitConfigResponse" - description: OK - "400": - $ref: "#/components/responses/BadRequestResponse" - "403": - $ref: "#/components/responses/NotAuthorizedResponse" - "404": - $ref: "#/components/responses/NotFoundResponse" - "429": - $ref: "#/components/responses/TooManyRequestsResponse" - summary: Create or update a RUM rate limit configuration - tags: - - Rum Rate Limit - x-codegen-request-body-name: body - x-unstable: |- - **Note**: This endpoint is in preview and is subject to change. - If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/rum/events: get: description: |- @@ -213532,9 +213206,6 @@ tags: description: Find out more at url: https://docs.datadoghq.com/real_user_monitoring/platform/generate_metrics/ name: Rum Metrics - - description: |- - Manage RUM rate limit configurations for your organization's RUM applications. - name: Rum Rate Limit - description: Manage heatmap snapshots for RUM replay sessions. Create, update, delete, and retrieve snapshots to visualize user interactions on specific views. name: Rum Replay Heatmaps - description: Create and manage playlists of RUM replay sessions. Organize, categorize, and share collections of replay sessions for analysis and collaboration. diff --git a/docs/datadog_api_client.v2.api.rst b/docs/datadog_api_client.v2.api.rst index c74f2573bf..68c301229c 100644 --- a/docs/datadog_api_client.v2.api.rst +++ b/docs/datadog_api_client.v2.api.rst @@ -725,13 +725,6 @@ datadog\_api\_client.v2.api.rum\_operations\_api module :members: :show-inheritance: -datadog\_api\_client.v2.api.rum\_rate\_limit\_api module --------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.api.rum_rate_limit_api - :members: - :show-inheritance: - datadog\_api\_client.v2.api.rum\_remote\_config\_api module ----------------------------------------------------------- diff --git a/docs/datadog_api_client.v2.model.rst b/docs/datadog_api_client.v2.model.rst index dd56032ba7..5339b07ae2 100644 --- a/docs/datadog_api_client.v2.model.rst +++ b/docs/datadog_api_client.v2.model.rst @@ -38119,97 +38119,6 @@ datadog\_api\_client.v2.model.rum\_query\_page\_options module :members: :show-inheritance: -datadog\_api\_client.v2.model.rum\_rate\_limit\_adaptive\_config module ------------------------------------------------------------------------ - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_adaptive_config - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_attributes module -------------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_attributes - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_data module -------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_data - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_response module ------------------------------------------------------------------------ - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_response - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_type module -------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_type - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_update\_attributes module ---------------------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_update_attributes - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_update\_data module ---------------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_update_data - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_config\_update\_request module ------------------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_config_update_request - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_custom\_config module ---------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_custom_config - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_mode module ------------------------------------------------------------ - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_mode - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_quota\_reached\_action module ------------------------------------------------------------------------------ - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_quota_reached_action - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_scope\_type module ------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_scope_type - :members: - :show-inheritance: - -datadog\_api\_client.v2.model.rum\_rate\_limit\_window\_type module -------------------------------------------------------------------- - -.. automodule:: datadog_api_client.v2.model.rum_rate_limit_window_type - :members: - :show-inheritance: - datadog\_api\_client.v2.model.rum\_response\_links module --------------------------------------------------------- diff --git a/examples/v2/rum-rate-limit/DeleteRumRateLimitConfig.py b/examples/v2/rum-rate-limit/DeleteRumRateLimitConfig.py deleted file mode 100644 index ed0f3c5c4b..0000000000 --- a/examples/v2/rum-rate-limit/DeleteRumRateLimitConfig.py +++ /dev/null @@ -1,16 +0,0 @@ -""" -Delete a RUM rate limit configuration returns "No Content" response -""" - -from datadog_api_client import ApiClient, Configuration -from datadog_api_client.v2.api.rum_rate_limit_api import RumRateLimitApi -from datadog_api_client.v2.model.rum_rate_limit_scope_type import RumRateLimitScopeType - -configuration = Configuration() -configuration.unstable_operations["delete_rum_rate_limit_config"] = True -with ApiClient(configuration) as api_client: - api_instance = RumRateLimitApi(api_client) - api_instance.delete_rum_rate_limit_config( - scope_type=RumRateLimitScopeType.APPLICATION, - scope_id="cd73a516-a481-4af5-8352-9b577465c77b", - ) diff --git a/examples/v2/rum-rate-limit/GetRumRateLimitConfig.py b/examples/v2/rum-rate-limit/GetRumRateLimitConfig.py deleted file mode 100644 index 78b28bc67f..0000000000 --- a/examples/v2/rum-rate-limit/GetRumRateLimitConfig.py +++ /dev/null @@ -1,18 +0,0 @@ -""" -Get a RUM rate limit configuration returns "OK" response -""" - -from datadog_api_client import ApiClient, Configuration -from datadog_api_client.v2.api.rum_rate_limit_api import RumRateLimitApi -from datadog_api_client.v2.model.rum_rate_limit_scope_type import RumRateLimitScopeType - -configuration = Configuration() -configuration.unstable_operations["get_rum_rate_limit_config"] = True -with ApiClient(configuration) as api_client: - api_instance = RumRateLimitApi(api_client) - response = api_instance.get_rum_rate_limit_config( - scope_type=RumRateLimitScopeType.APPLICATION, - scope_id="cd73a516-a481-4af5-8352-9b577465c77b", - ) - - print(response) diff --git a/examples/v2/rum-rate-limit/UpdateRumRateLimitConfig.py b/examples/v2/rum-rate-limit/UpdateRumRateLimitConfig.py deleted file mode 100644 index a90f5883a3..0000000000 --- a/examples/v2/rum-rate-limit/UpdateRumRateLimitConfig.py +++ /dev/null @@ -1,46 +0,0 @@ -""" -Create or update a RUM rate limit configuration returns "OK" response -""" - -from datadog_api_client import ApiClient, Configuration -from datadog_api_client.v2.api.rum_rate_limit_api import RumRateLimitApi -from datadog_api_client.v2.model.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig -from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType -from datadog_api_client.v2.model.rum_rate_limit_config_update_attributes import RumRateLimitConfigUpdateAttributes -from datadog_api_client.v2.model.rum_rate_limit_config_update_data import RumRateLimitConfigUpdateData -from datadog_api_client.v2.model.rum_rate_limit_config_update_request import RumRateLimitConfigUpdateRequest -from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig -from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode -from datadog_api_client.v2.model.rum_rate_limit_quota_reached_action import RumRateLimitQuotaReachedAction -from datadog_api_client.v2.model.rum_rate_limit_scope_type import RumRateLimitScopeType -from datadog_api_client.v2.model.rum_rate_limit_window_type import RumRateLimitWindowType - -body = RumRateLimitConfigUpdateRequest( - data=RumRateLimitConfigUpdateData( - attributes=RumRateLimitConfigUpdateAttributes( - adaptive=RumRateLimitAdaptiveConfig( - max_retention_rate=0.5, - ), - custom=RumRateLimitCustomConfig( - daily_reset_time="08:00", - daily_reset_timezone="+09:00", - quota_reached_action=RumRateLimitQuotaReachedAction.STOP, - session_limit=1000000, - window_type=RumRateLimitWindowType.DAILY, - ), - mode=RumRateLimitMode.CUSTOM, - ), - id="cd73a516-a481-4af5-8352-9b577465c77b", - type=RumRateLimitConfigType.RUM_RATE_LIMIT_CONFIG, - ), -) - -configuration = Configuration() -configuration.unstable_operations["update_rum_rate_limit_config"] = True -with ApiClient(configuration) as api_client: - api_instance = RumRateLimitApi(api_client) - response = api_instance.update_rum_rate_limit_config( - scope_type=RumRateLimitScopeType.APPLICATION, scope_id="cd73a516-a481-4af5-8352-9b577465c77b", body=body - ) - - print(response) diff --git a/src/datadog_api_client/configuration.py b/src/datadog_api_client/configuration.py index 0f400f6576..3678cf3e2a 100644 --- a/src/datadog_api_client/configuration.py +++ b/src/datadog_api_client/configuration.py @@ -730,9 +730,6 @@ def __init__( "v2.create_rum_config": False, "v2.get_rum_config": False, "v2.update_rum_config": False, - "v2.delete_rum_rate_limit_config": False, - "v2.get_rum_rate_limit_config": False, - "v2.update_rum_rate_limit_config": False, "v2.create_rum_operation": False, "v2.create_rum_operation_strong_link": False, "v2.delete_rum_operation": False, diff --git a/src/datadog_api_client/v2/api/rum_rate_limit_api.py b/src/datadog_api_client/v2/api/rum_rate_limit_api.py deleted file mode 100644 index 54dbb83398..0000000000 --- a/src/datadog_api_client/v2/api/rum_rate_limit_api.py +++ /dev/null @@ -1,188 +0,0 @@ -# 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 Any, Dict - -from datadog_api_client.api_client import ApiClient, Endpoint as _Endpoint -from datadog_api_client.configuration import Configuration -from datadog_api_client.v2.model.rum_rate_limit_scope_type import RumRateLimitScopeType -from datadog_api_client.v2.model.rum_rate_limit_config_response import RumRateLimitConfigResponse -from datadog_api_client.v2.model.rum_rate_limit_config_update_request import RumRateLimitConfigUpdateRequest - - -class RumRateLimitApi: - """ - Manage RUM rate limit configurations for your organization's RUM applications. - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient(Configuration()) - self.api_client = api_client - - self._delete_rum_rate_limit_config_endpoint = _Endpoint( - settings={ - "response_type": None, - "auth": ["apiKeyAuth", "appKeyAuth"], - "endpoint_path": "/api/v2/rum/config/rate-limit/{scope_type}/{scope_id}", - "operation_id": "delete_rum_rate_limit_config", - "http_method": "DELETE", - "version": "v2", - }, - params_map={ - "scope_type": { - "required": True, - "openapi_types": (RumRateLimitScopeType,), - "attribute": "scope_type", - "location": "path", - }, - "scope_id": { - "required": True, - "openapi_types": (str,), - "attribute": "scope_id", - "location": "path", - }, - }, - headers_map={ - "accept": ["*/*"], - }, - api_client=api_client, - ) - - self._get_rum_rate_limit_config_endpoint = _Endpoint( - settings={ - "response_type": (RumRateLimitConfigResponse,), - "auth": ["apiKeyAuth", "appKeyAuth"], - "endpoint_path": "/api/v2/rum/config/rate-limit/{scope_type}/{scope_id}", - "operation_id": "get_rum_rate_limit_config", - "http_method": "GET", - "version": "v2", - }, - params_map={ - "scope_type": { - "required": True, - "openapi_types": (RumRateLimitScopeType,), - "attribute": "scope_type", - "location": "path", - }, - "scope_id": { - "required": True, - "openapi_types": (str,), - "attribute": "scope_id", - "location": "path", - }, - }, - headers_map={ - "accept": ["application/json"], - }, - api_client=api_client, - ) - - self._update_rum_rate_limit_config_endpoint = _Endpoint( - settings={ - "response_type": (RumRateLimitConfigResponse,), - "auth": ["apiKeyAuth", "appKeyAuth"], - "endpoint_path": "/api/v2/rum/config/rate-limit/{scope_type}/{scope_id}", - "operation_id": "update_rum_rate_limit_config", - "http_method": "PUT", - "version": "v2", - }, - params_map={ - "scope_type": { - "required": True, - "openapi_types": (RumRateLimitScopeType,), - "attribute": "scope_type", - "location": "path", - }, - "scope_id": { - "required": True, - "openapi_types": (str,), - "attribute": "scope_id", - "location": "path", - }, - "body": { - "required": True, - "openapi_types": (RumRateLimitConfigUpdateRequest,), - "location": "body", - }, - }, - headers_map={"accept": ["application/json"], "content_type": ["application/json"]}, - api_client=api_client, - ) - - def delete_rum_rate_limit_config( - self, - scope_type: RumRateLimitScopeType, - scope_id: str, - ) -> None: - """Delete a RUM rate limit configuration. - - Delete the RUM rate limit configuration for a given scope. - - :param scope_type: The type of scope the rate limit configuration applies to. - :type scope_type: RumRateLimitScopeType - :param scope_id: The identifier of the scope the rate limit configuration applies to. - For the ``application`` scope, this is the RUM application ID. - :type scope_id: str - :rtype: None - """ - kwargs: Dict[str, Any] = {} - kwargs["scope_type"] = scope_type - - kwargs["scope_id"] = scope_id - - return self._delete_rum_rate_limit_config_endpoint.call_with_http_info(**kwargs) - - def get_rum_rate_limit_config( - self, - scope_type: RumRateLimitScopeType, - scope_id: str, - ) -> RumRateLimitConfigResponse: - """Get a RUM rate limit configuration. - - Get the RUM rate limit configuration for a given scope. - - :param scope_type: The type of scope the rate limit configuration applies to. - :type scope_type: RumRateLimitScopeType - :param scope_id: The identifier of the scope the rate limit configuration applies to. - For the ``application`` scope, this is the RUM application ID. - :type scope_id: str - :rtype: RumRateLimitConfigResponse - """ - kwargs: Dict[str, Any] = {} - kwargs["scope_type"] = scope_type - - kwargs["scope_id"] = scope_id - - return self._get_rum_rate_limit_config_endpoint.call_with_http_info(**kwargs) - - def update_rum_rate_limit_config( - self, - scope_type: RumRateLimitScopeType, - scope_id: str, - body: RumRateLimitConfigUpdateRequest, - ) -> RumRateLimitConfigResponse: - """Create or update a RUM rate limit configuration. - - Create or update the RUM rate limit configuration for a given scope. - Returns the rate limit configuration object when the request is successful. - - :param scope_type: The type of scope the rate limit configuration applies to. - :type scope_type: RumRateLimitScopeType - :param scope_id: The identifier of the scope the rate limit configuration applies to. - For the ``application`` scope, this is the RUM application ID. - :type scope_id: str - :param body: The definition of the RUM rate limit configuration to create or update. - :type body: RumRateLimitConfigUpdateRequest - :rtype: RumRateLimitConfigResponse - """ - kwargs: Dict[str, Any] = {} - kwargs["scope_type"] = scope_type - - kwargs["scope_id"] = scope_id - - kwargs["body"] = body - - return self._update_rum_rate_limit_config_endpoint.call_with_http_info(**kwargs) diff --git a/src/datadog_api_client/v2/apis/__init__.py b/src/datadog_api_client/v2/apis/__init__.py index c6b9db7d12..f3bf514ec4 100644 --- a/src/datadog_api_client/v2/apis/__init__.py +++ b/src/datadog_api_client/v2/apis/__init__.py @@ -102,7 +102,6 @@ from datadog_api_client.v2.api.roles_api import RolesApi from datadog_api_client.v2.api.rum_audience_management_api import RumAudienceManagementApi from datadog_api_client.v2.api.rum_metrics_api import RumMetricsApi -from datadog_api_client.v2.api.rum_rate_limit_api import RumRateLimitApi from datadog_api_client.v2.api.rum_replay_heatmaps_api import RumReplayHeatmapsApi from datadog_api_client.v2.api.rum_replay_playlists_api import RumReplayPlaylistsApi from datadog_api_client.v2.api.rum_replay_sessions_api import RumReplaySessionsApi @@ -245,7 +244,6 @@ "RolesApi", "RumAudienceManagementApi", "RumMetricsApi", - "RumRateLimitApi", "RumReplayHeatmapsApi", "RumReplayPlaylistsApi", "RumReplaySessionsApi", diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_adaptive_config.py b/src/datadog_api_client/v2/model/rum_rate_limit_adaptive_config.py deleted file mode 100644 index 7215246800..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_adaptive_config.py +++ /dev/null @@ -1,40 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -class RumRateLimitAdaptiveConfig(ModelNormal): - validations = { - "max_retention_rate": { - "inclusive_maximum": 1, - "exclusive_minimum": 0, - }, - } - - @cached_property - def openapi_types(_): - return { - "max_retention_rate": (float,), - } - - attribute_map = { - "max_retention_rate": "max_retention_rate", - } - - def __init__(self_, max_retention_rate: float, **kwargs): - """ - The configuration used when ``mode`` is ``adaptive``. - - :param max_retention_rate: The maximum fraction of sessions to retain, in the range ``(0, 1]``. - :type max_retention_rate: float - """ - super().__init__(kwargs) - - self_.max_retention_rate = max_retention_rate diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_attributes.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_attributes.py deleted file mode 100644 index 41a415c4fe..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_attributes.py +++ /dev/null @@ -1,90 +0,0 @@ -# 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.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig - from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig - from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode - - -class RumRateLimitConfigAttributes(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig - from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig - from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode - - return { - "adaptive": (RumRateLimitAdaptiveConfig,), - "custom": (RumRateLimitCustomConfig,), - "mode": (RumRateLimitMode,), - "org_id": (int,), - "updated_at": (str,), - "updated_by": (str,), - } - - attribute_map = { - "adaptive": "adaptive", - "custom": "custom", - "mode": "mode", - "org_id": "org_id", - "updated_at": "updated_at", - "updated_by": "updated_by", - } - - def __init__( - self_, - mode: RumRateLimitMode, - org_id: int, - adaptive: Union[RumRateLimitAdaptiveConfig, UnsetType] = unset, - custom: Union[RumRateLimitCustomConfig, UnsetType] = unset, - updated_at: Union[str, UnsetType] = unset, - updated_by: Union[str, UnsetType] = unset, - **kwargs, - ): - """ - The RUM rate limit configuration properties. - - :param adaptive: The configuration used when ``mode`` is ``adaptive``. - :type adaptive: RumRateLimitAdaptiveConfig, optional - - :param custom: The configuration used when ``mode`` is ``custom``. - :type custom: RumRateLimitCustomConfig, optional - - :param mode: The rate limit mode. ``custom`` enforces a fixed session limit, while - ``adaptive`` dynamically adjusts retention. - :type mode: RumRateLimitMode - - :param org_id: The ID of the organization the rate limit configuration belongs to. - :type org_id: int - - :param updated_at: The date the rate limit configuration was last updated. - :type updated_at: str, optional - - :param updated_by: The handle of the user who last updated the rate limit configuration. - :type updated_by: str, optional - """ - if adaptive is not unset: - kwargs["adaptive"] = adaptive - if custom is not unset: - kwargs["custom"] = custom - if updated_at is not unset: - kwargs["updated_at"] = updated_at - if updated_by is not unset: - kwargs["updated_by"] = updated_by - super().__init__(kwargs) - - self_.mode = mode - self_.org_id = org_id diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_data.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_data.py deleted file mode 100644 index d57ee1f548..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_data.py +++ /dev/null @@ -1,54 +0,0 @@ -# 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 TYPE_CHECKING - -from datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -if TYPE_CHECKING: - from datadog_api_client.v2.model.rum_rate_limit_config_attributes import RumRateLimitConfigAttributes - from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType - - -class RumRateLimitConfigData(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_config_attributes import RumRateLimitConfigAttributes - from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType - - return { - "attributes": (RumRateLimitConfigAttributes,), - "id": (str,), - "type": (RumRateLimitConfigType,), - } - - attribute_map = { - "attributes": "attributes", - "id": "id", - "type": "type", - } - - def __init__(self_, attributes: RumRateLimitConfigAttributes, id: str, type: RumRateLimitConfigType, **kwargs): - """ - The RUM rate limit configuration object. - - :param attributes: The RUM rate limit configuration properties. - :type attributes: RumRateLimitConfigAttributes - - :param id: The identifier of the scope the rate limit configuration applies to. - :type id: str - - :param type: The type of the resource, always ``rum_rate_limit_config``. - :type type: RumRateLimitConfigType - """ - super().__init__(kwargs) - - self_.attributes = attributes - self_.id = id - self_.type = type diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_response.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_response.py deleted file mode 100644 index 9ab5a38e71..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_response.py +++ /dev/null @@ -1,40 +0,0 @@ -# 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 TYPE_CHECKING - -from datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -if TYPE_CHECKING: - from datadog_api_client.v2.model.rum_rate_limit_config_data import RumRateLimitConfigData - - -class RumRateLimitConfigResponse(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_config_data import RumRateLimitConfigData - - return { - "data": (RumRateLimitConfigData,), - } - - attribute_map = { - "data": "data", - } - - def __init__(self_, data: RumRateLimitConfigData, **kwargs): - """ - The RUM rate limit configuration response. - - :param data: The RUM rate limit configuration object. - :type data: RumRateLimitConfigData - """ - super().__init__(kwargs) - - self_.data = data diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_type.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_type.py deleted file mode 100644 index be60502c53..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_type.py +++ /dev/null @@ -1,35 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelSimple, - cached_property, -) - -from typing import ClassVar - - -class RumRateLimitConfigType(ModelSimple): - """ - The type of the resource, always `rum_rate_limit_config`. - - :param value: If omitted defaults to "rum_rate_limit_config". Must be one of ["rum_rate_limit_config"]. - :type value: str - """ - - allowed_values = { - "rum_rate_limit_config", - } - RUM_RATE_LIMIT_CONFIG: ClassVar["RumRateLimitConfigType"] - - @cached_property - def openapi_types(_): - return { - "value": (str,), - } - - -RumRateLimitConfigType.RUM_RATE_LIMIT_CONFIG = RumRateLimitConfigType("rum_rate_limit_config") diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_attributes.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_update_attributes.py deleted file mode 100644 index 159fbe55f6..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_attributes.py +++ /dev/null @@ -1,67 +0,0 @@ -# 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.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig - from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig - from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode - - -class RumRateLimitConfigUpdateAttributes(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig - from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig - from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode - - return { - "adaptive": (RumRateLimitAdaptiveConfig,), - "custom": (RumRateLimitCustomConfig,), - "mode": (RumRateLimitMode,), - } - - attribute_map = { - "adaptive": "adaptive", - "custom": "custom", - "mode": "mode", - } - - def __init__( - self_, - mode: RumRateLimitMode, - adaptive: Union[RumRateLimitAdaptiveConfig, UnsetType] = unset, - custom: Union[RumRateLimitCustomConfig, UnsetType] = unset, - **kwargs, - ): - """ - The RUM rate limit configuration properties to create or update. - - :param adaptive: The configuration used when ``mode`` is ``adaptive``. - :type adaptive: RumRateLimitAdaptiveConfig, optional - - :param custom: The configuration used when ``mode`` is ``custom``. - :type custom: RumRateLimitCustomConfig, optional - - :param mode: The rate limit mode. ``custom`` enforces a fixed session limit, while - ``adaptive`` dynamically adjusts retention. - :type mode: RumRateLimitMode - """ - if adaptive is not unset: - kwargs["adaptive"] = adaptive - if custom is not unset: - kwargs["custom"] = custom - super().__init__(kwargs) - - self_.mode = mode diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_data.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_update_data.py deleted file mode 100644 index 2adbc841e2..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_data.py +++ /dev/null @@ -1,59 +0,0 @@ -# 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 TYPE_CHECKING - -from datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -if TYPE_CHECKING: - from datadog_api_client.v2.model.rum_rate_limit_config_update_attributes import RumRateLimitConfigUpdateAttributes - from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType - - -class RumRateLimitConfigUpdateData(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_config_update_attributes import ( - RumRateLimitConfigUpdateAttributes, - ) - from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType - - return { - "attributes": (RumRateLimitConfigUpdateAttributes,), - "id": (str,), - "type": (RumRateLimitConfigType,), - } - - attribute_map = { - "attributes": "attributes", - "id": "id", - "type": "type", - } - - def __init__( - self_, attributes: RumRateLimitConfigUpdateAttributes, id: str, type: RumRateLimitConfigType, **kwargs - ): - """ - The RUM rate limit configuration to create or update. - - :param attributes: The RUM rate limit configuration properties to create or update. - :type attributes: RumRateLimitConfigUpdateAttributes - - :param id: The identifier of the scope the rate limit configuration applies to. - Must match ``scope_id`` in the path. - :type id: str - - :param type: The type of the resource, always ``rum_rate_limit_config``. - :type type: RumRateLimitConfigType - """ - super().__init__(kwargs) - - self_.attributes = attributes - self_.id = id - self_.type = type diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_request.py b/src/datadog_api_client/v2/model/rum_rate_limit_config_update_request.py deleted file mode 100644 index 6ccf869a0e..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_config_update_request.py +++ /dev/null @@ -1,40 +0,0 @@ -# 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 TYPE_CHECKING - -from datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -if TYPE_CHECKING: - from datadog_api_client.v2.model.rum_rate_limit_config_update_data import RumRateLimitConfigUpdateData - - -class RumRateLimitConfigUpdateRequest(ModelNormal): - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_config_update_data import RumRateLimitConfigUpdateData - - return { - "data": (RumRateLimitConfigUpdateData,), - } - - attribute_map = { - "data": "data", - } - - def __init__(self_, data: RumRateLimitConfigUpdateData, **kwargs): - """ - The body of a request to create or update a RUM rate limit configuration. - - :param data: The RUM rate limit configuration to create or update. - :type data: RumRateLimitConfigUpdateData - """ - super().__init__(kwargs) - - self_.data = data diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_custom_config.py b/src/datadog_api_client/v2/model/rum_rate_limit_custom_config.py deleted file mode 100644 index 8e888415f1..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_custom_config.py +++ /dev/null @@ -1,82 +0,0 @@ -# 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 TYPE_CHECKING - -from datadog_api_client.model_utils import ( - ModelNormal, - cached_property, -) - - -if TYPE_CHECKING: - from datadog_api_client.v2.model.rum_rate_limit_quota_reached_action import RumRateLimitQuotaReachedAction - from datadog_api_client.v2.model.rum_rate_limit_window_type import RumRateLimitWindowType - - -class RumRateLimitCustomConfig(ModelNormal): - validations = { - "daily_reset_time": {}, - "daily_reset_timezone": {}, - "session_limit": { - "inclusive_minimum": 1, - }, - } - - @cached_property - def openapi_types(_): - from datadog_api_client.v2.model.rum_rate_limit_quota_reached_action import RumRateLimitQuotaReachedAction - from datadog_api_client.v2.model.rum_rate_limit_window_type import RumRateLimitWindowType - - return { - "daily_reset_time": (str,), - "daily_reset_timezone": (str,), - "quota_reached_action": (RumRateLimitQuotaReachedAction,), - "session_limit": (int,), - "window_type": (RumRateLimitWindowType,), - } - - attribute_map = { - "daily_reset_time": "daily_reset_time", - "daily_reset_timezone": "daily_reset_timezone", - "quota_reached_action": "quota_reached_action", - "session_limit": "session_limit", - "window_type": "window_type", - } - - def __init__( - self_, - daily_reset_time: str, - daily_reset_timezone: str, - quota_reached_action: RumRateLimitQuotaReachedAction, - session_limit: int, - window_type: RumRateLimitWindowType, - **kwargs, - ): - """ - The configuration used when ``mode`` is ``custom``. - - :param daily_reset_time: The time of day when the daily quota resets, in ``HH:MM`` 24-hour format. - :type daily_reset_time: str - - :param daily_reset_timezone: The timezone offset used for the daily reset time, in ``±HH:MM`` format. - :type daily_reset_timezone: str - - :param quota_reached_action: The action to take when the session quota is reached. - :type quota_reached_action: RumRateLimitQuotaReachedAction - - :param session_limit: The maximum number of sessions allowed within the window. - :type session_limit: int - - :param window_type: The window type over which the session limit is enforced. - :type window_type: RumRateLimitWindowType - """ - super().__init__(kwargs) - - self_.daily_reset_time = daily_reset_time - self_.daily_reset_timezone = daily_reset_timezone - self_.quota_reached_action = quota_reached_action - self_.session_limit = session_limit - self_.window_type = window_type diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_mode.py b/src/datadog_api_client/v2/model/rum_rate_limit_mode.py deleted file mode 100644 index 7e8b051586..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_mode.py +++ /dev/null @@ -1,39 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelSimple, - cached_property, -) - -from typing import ClassVar - - -class RumRateLimitMode(ModelSimple): - """ - The rate limit mode. `custom` enforces a fixed session limit, while - `adaptive` dynamically adjusts retention. - - :param value: Must be one of ["custom", "adaptive"]. - :type value: str - """ - - allowed_values = { - "custom", - "adaptive", - } - CUSTOM: ClassVar["RumRateLimitMode"] - ADAPTIVE: ClassVar["RumRateLimitMode"] - - @cached_property - def openapi_types(_): - return { - "value": (str,), - } - - -RumRateLimitMode.CUSTOM = RumRateLimitMode("custom") -RumRateLimitMode.ADAPTIVE = RumRateLimitMode("adaptive") diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_quota_reached_action.py b/src/datadog_api_client/v2/model/rum_rate_limit_quota_reached_action.py deleted file mode 100644 index 2500b3df18..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_quota_reached_action.py +++ /dev/null @@ -1,38 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelSimple, - cached_property, -) - -from typing import ClassVar - - -class RumRateLimitQuotaReachedAction(ModelSimple): - """ - The action to take when the session quota is reached. - - :param value: Must be one of ["stop", "slowdown"]. - :type value: str - """ - - allowed_values = { - "stop", - "slowdown", - } - STOP: ClassVar["RumRateLimitQuotaReachedAction"] - SLOWDOWN: ClassVar["RumRateLimitQuotaReachedAction"] - - @cached_property - def openapi_types(_): - return { - "value": (str,), - } - - -RumRateLimitQuotaReachedAction.STOP = RumRateLimitQuotaReachedAction("stop") -RumRateLimitQuotaReachedAction.SLOWDOWN = RumRateLimitQuotaReachedAction("slowdown") diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_scope_type.py b/src/datadog_api_client/v2/model/rum_rate_limit_scope_type.py deleted file mode 100644 index 48a1f2d1f7..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_scope_type.py +++ /dev/null @@ -1,35 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelSimple, - cached_property, -) - -from typing import ClassVar - - -class RumRateLimitScopeType(ModelSimple): - """ - The type of scope the rate limit configuration applies to. - - :param value: If omitted defaults to "application". Must be one of ["application"]. - :type value: str - """ - - allowed_values = { - "application", - } - APPLICATION: ClassVar["RumRateLimitScopeType"] - - @cached_property - def openapi_types(_): - return { - "value": (str,), - } - - -RumRateLimitScopeType.APPLICATION = RumRateLimitScopeType("application") diff --git a/src/datadog_api_client/v2/model/rum_rate_limit_window_type.py b/src/datadog_api_client/v2/model/rum_rate_limit_window_type.py deleted file mode 100644 index a3f4e68f5f..0000000000 --- a/src/datadog_api_client/v2/model/rum_rate_limit_window_type.py +++ /dev/null @@ -1,35 +0,0 @@ -# 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 datadog_api_client.model_utils import ( - ModelSimple, - cached_property, -) - -from typing import ClassVar - - -class RumRateLimitWindowType(ModelSimple): - """ - The window type over which the session limit is enforced. - - :param value: If omitted defaults to "daily". Must be one of ["daily"]. - :type value: str - """ - - allowed_values = { - "daily", - } - DAILY: ClassVar["RumRateLimitWindowType"] - - @cached_property - def openapi_types(_): - return { - "value": (str,), - } - - -RumRateLimitWindowType.DAILY = RumRateLimitWindowType("daily") diff --git a/src/datadog_api_client/v2/models/__init__.py b/src/datadog_api_client/v2/models/__init__.py index 6dcd30db0f..d24ea0d032 100644 --- a/src/datadog_api_client/v2/models/__init__.py +++ b/src/datadog_api_client/v2/models/__init__.py @@ -7664,19 +7664,6 @@ RumPermanentRetentionFilterUpdateRequest, ) from datadog_api_client.v2.model.rum_permanent_retention_filters_response import RumPermanentRetentionFiltersResponse -from datadog_api_client.v2.model.rum_rate_limit_adaptive_config import RumRateLimitAdaptiveConfig -from datadog_api_client.v2.model.rum_rate_limit_config_attributes import RumRateLimitConfigAttributes -from datadog_api_client.v2.model.rum_rate_limit_config_data import RumRateLimitConfigData -from datadog_api_client.v2.model.rum_rate_limit_config_response import RumRateLimitConfigResponse -from datadog_api_client.v2.model.rum_rate_limit_config_type import RumRateLimitConfigType -from datadog_api_client.v2.model.rum_rate_limit_config_update_attributes import RumRateLimitConfigUpdateAttributes -from datadog_api_client.v2.model.rum_rate_limit_config_update_data import RumRateLimitConfigUpdateData -from datadog_api_client.v2.model.rum_rate_limit_config_update_request import RumRateLimitConfigUpdateRequest -from datadog_api_client.v2.model.rum_rate_limit_custom_config import RumRateLimitCustomConfig -from datadog_api_client.v2.model.rum_rate_limit_mode import RumRateLimitMode -from datadog_api_client.v2.model.rum_rate_limit_quota_reached_action import RumRateLimitQuotaReachedAction -from datadog_api_client.v2.model.rum_rate_limit_scope_type import RumRateLimitScopeType -from datadog_api_client.v2.model.rum_rate_limit_window_type import RumRateLimitWindowType from datadog_api_client.v2.model.rum_retention_filter_attributes import RumRetentionFilterAttributes from datadog_api_client.v2.model.rum_retention_filter_create_attributes import RumRetentionFilterCreateAttributes from datadog_api_client.v2.model.rum_retention_filter_create_data import RumRetentionFilterCreateData @@ -16007,19 +15994,6 @@ "RumPermanentRetentionFilterUpdateData", "RumPermanentRetentionFilterUpdateRequest", "RumPermanentRetentionFiltersResponse", - "RumRateLimitAdaptiveConfig", - "RumRateLimitConfigAttributes", - "RumRateLimitConfigData", - "RumRateLimitConfigResponse", - "RumRateLimitConfigType", - "RumRateLimitConfigUpdateAttributes", - "RumRateLimitConfigUpdateData", - "RumRateLimitConfigUpdateRequest", - "RumRateLimitCustomConfig", - "RumRateLimitMode", - "RumRateLimitQuotaReachedAction", - "RumRateLimitScopeType", - "RumRateLimitWindowType", "RumRetentionFilterAttributes", "RumRetentionFilterCreateAttributes", "RumRetentionFilterCreateData", diff --git a/tests/v2/features/rum_rate_limit.feature b/tests/v2/features/rum_rate_limit.feature deleted file mode 100644 index 90869ed178..0000000000 --- a/tests/v2/features/rum_rate_limit.feature +++ /dev/null @@ -1,93 +0,0 @@ -@endpoint(rum-rate-limit) @endpoint(rum-rate-limit-v2) -Feature: Rum Rate Limit - Manage RUM rate limit configurations for your organization's RUM - applications. - - Background: - Given a valid "apiKeyAuth" key in the system - And a valid "appKeyAuth" key in the system - And an instance of "RumRateLimit" API - - @generated @skip @team:DataDog/rum-backend - Scenario: Create or update a RUM rate limit configuration returns "Bad Request" response - Given operation "UpdateRumRateLimitConfig" enabled - And new "UpdateRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"adaptive": {"max_retention_rate": 0.5}, "custom": {"daily_reset_time": "08:00", "daily_reset_timezone": "+09:00", "quota_reached_action": "stop", "session_limit": 1000000, "window_type": "daily"}, "mode": "custom"}, "id": "cd73a516-a481-4af5-8352-9b577465c77b", "type": "rum_rate_limit_config"}} - When the request is sent - Then the response status is 400 Bad Request - - @generated @skip @team:DataDog/rum-backend - Scenario: Create or update a RUM rate limit configuration returns "Not Found" response - Given operation "UpdateRumRateLimitConfig" enabled - And new "UpdateRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"adaptive": {"max_retention_rate": 0.5}, "custom": {"daily_reset_time": "08:00", "daily_reset_timezone": "+09:00", "quota_reached_action": "stop", "session_limit": 1000000, "window_type": "daily"}, "mode": "custom"}, "id": "cd73a516-a481-4af5-8352-9b577465c77b", "type": "rum_rate_limit_config"}} - When the request is sent - Then the response status is 404 Not Found - - @generated @skip @team:DataDog/rum-backend - Scenario: Create or update a RUM rate limit configuration returns "OK" response - Given operation "UpdateRumRateLimitConfig" enabled - And new "UpdateRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"adaptive": {"max_retention_rate": 0.5}, "custom": {"daily_reset_time": "08:00", "daily_reset_timezone": "+09:00", "quota_reached_action": "stop", "session_limit": 1000000, "window_type": "daily"}, "mode": "custom"}, "id": "cd73a516-a481-4af5-8352-9b577465c77b", "type": "rum_rate_limit_config"}} - When the request is sent - Then the response status is 200 OK - - @generated @skip @team:DataDog/rum-backend - Scenario: Delete a RUM rate limit configuration returns "Bad Request" response - Given operation "DeleteRumRateLimitConfig" enabled - And new "DeleteRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 400 Bad Request - - @generated @skip @team:DataDog/rum-backend - Scenario: Delete a RUM rate limit configuration returns "No Content" response - Given operation "DeleteRumRateLimitConfig" enabled - And new "DeleteRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 204 No Content - - @generated @skip @team:DataDog/rum-backend - Scenario: Delete a RUM rate limit configuration returns "Not Found" response - Given operation "DeleteRumRateLimitConfig" enabled - And new "DeleteRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 404 Not Found - - @generated @skip @team:DataDog/rum-backend - Scenario: Get a RUM rate limit configuration returns "Bad Request" response - Given operation "GetRumRateLimitConfig" enabled - And new "GetRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 400 Bad Request - - @generated @skip @team:DataDog/rum-backend - Scenario: Get a RUM rate limit configuration returns "Not Found" response - Given operation "GetRumRateLimitConfig" enabled - And new "GetRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 404 Not Found - - @generated @skip @team:DataDog/rum-backend - Scenario: Get a RUM rate limit configuration returns "OK" response - Given operation "GetRumRateLimitConfig" enabled - And new "GetRumRateLimitConfig" request - And request contains "scope_type" parameter from "REPLACE.ME" - And request contains "scope_id" parameter from "REPLACE.ME" - When the request is sent - Then the response status is 200 OK diff --git a/tests/v2/features/undo.json b/tests/v2/features/undo.json index 9903d959ff..1060e48a48 100644 --- a/tests/v2/features/undo.json +++ b/tests/v2/features/undo.json @@ -7039,24 +7039,6 @@ "type": "idempotent" } }, - "DeleteRumRateLimitConfig": { - "tag": "Rum Rate Limit", - "undo": { - "type": "idempotent" - } - }, - "GetRumRateLimitConfig": { - "tag": "Rum Rate Limit", - "undo": { - "type": "safe" - } - }, - "UpdateRumRateLimitConfig": { - "tag": "Rum Rate Limit", - "undo": { - "type": "idempotent" - } - }, "ListRUMEvents": { "tag": "RUM", "undo": {