diff --git a/.generated-info b/.generated-info index 7ad4962b2d..46da9f7a2c 100644 --- a/.generated-info +++ b/.generated-info @@ -1,4 +1,4 @@ { - "spec_repo_commit": "bd643af", - "generated": "2025-07-22 16:43:14.580" + "spec_repo_commit": "04d09cb", + "generated": "2025-07-23 09:22:38.369" } diff --git a/.generator/schemas/v1/openapi.yaml b/.generator/schemas/v1/openapi.yaml index 4850f47115..5ce0fd12fc 100644 --- a/.generator/schemas/v1/openapi.yaml +++ b/.generator/schemas/v1/openapi.yaml @@ -33827,6 +33827,12 @@ paths: description: Search for Synthetic tests and Test Suites. operationId: SearchTests parameters: + - description: The search query. + in: query + name: text + required: false + schema: + type: string - description: If true, include the full configuration for each test in the response. in: query diff --git a/examples/v1/synthetics/SearchTests_195957771.py b/examples/v1/synthetics/SearchTests_195957771.py index 34cdae1e8b..069697fa9f 100644 --- a/examples/v1/synthetics/SearchTests_195957771.py +++ b/examples/v1/synthetics/SearchTests_195957771.py @@ -9,6 +9,7 @@ with ApiClient(configuration) as api_client: api_instance = SyntheticsApi(api_client) response = api_instance.search_tests( + text="tag:value", include_full_config=True, search_suites=True, facets_only=True, diff --git a/src/datadog_api_client/v1/api/synthetics_api.py b/src/datadog_api_client/v1/api/synthetics_api.py index e4b55b9ad1..3806c36289 100644 --- a/src/datadog_api_client/v1/api/synthetics_api.py +++ b/src/datadog_api_client/v1/api/synthetics_api.py @@ -685,6 +685,11 @@ def __init__(self, api_client=None): "version": "v1", }, params_map={ + "text": { + "openapi_types": (str,), + "attribute": "text", + "location": "query", + }, "include_full_config": { "openapi_types": (bool,), "attribute": "include_full_config", @@ -1431,6 +1436,7 @@ def patch_test( def search_tests( self, *, + text: Union[str, UnsetType] = unset, include_full_config: Union[bool, UnsetType] = unset, search_suites: Union[bool, UnsetType] = unset, facets_only: Union[bool, UnsetType] = unset, @@ -1442,6 +1448,8 @@ def search_tests( Search for Synthetic tests and Test Suites. + :param text: The search query. + :type text: str, optional :param include_full_config: If true, include the full configuration for each test in the response. :type include_full_config: bool, optional :param search_suites: If true, returns suites instead of tests. @@ -1457,6 +1465,9 @@ def search_tests( :rtype: SyntheticsListTestsResponse """ kwargs: Dict[str, Any] = {} + if text is not unset: + kwargs["text"] = text + if include_full_config is not unset: kwargs["include_full_config"] = include_full_config diff --git a/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.frozen b/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.frozen index 0e385540a5..e53fbb289c 100644 --- a/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.frozen +++ b/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.frozen @@ -1 +1 @@ -2025-07-01T15:52:56.329Z \ No newline at end of file +2025-07-22T14:56:49.377Z \ No newline at end of file diff --git a/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.yaml b/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.yaml index 0dc3fc0409..d016d27fe9 100644 --- a/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.yaml +++ b/tests/v1/cassettes/test_scenarios/test_search_synthetic_tests_with_boolean_query_parameters.yaml @@ -5,7 +5,7 @@ interactions: accept: - application/json method: GET - uri: https://api.datadoghq.com/api/v1/synthetics/tests/search?include_full_config=true&search_suites=true&facets_only=true&start=10&count=5&sort=name%2Cdesc + uri: https://api.datadoghq.com/api/v1/synthetics/tests/search?text=tag%3Avalue&include_full_config=true&search_suites=true&facets_only=true&start=10&count=5&sort=name%2Cdesc response: body: string: '{"tests":[],"total":0,"facets":[]}' diff --git a/tests/v1/features/synthetics.feature b/tests/v1/features/synthetics.feature index 45ee8ca241..4b254da48b 100644 --- a/tests/v1/features/synthetics.feature +++ b/tests/v1/features/synthetics.feature @@ -806,6 +806,7 @@ Feature: Synthetics @team:DataDog/synthetics-ct Scenario: Search Synthetic tests with boolean query parameters Given new "SearchTests" request + And request contains "text" parameter with value "tag:value" And request contains "include_full_config" parameter with value true And request contains "search_suites" parameter with value true And request contains "facets_only" parameter with value true