Skip to content

Commit 831713b

Browse files
dd-octo-sts[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit 6d974ce of spec repo (#4122)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent e02e8d9 commit 831713b

8 files changed

Lines changed: 13 additions & 37 deletions

File tree

‎.generator/schemas/v2/openapi.yaml‎

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -145694,13 +145694,11 @@ paths:
145694145694
operator: OR
145695145695
permissions:
145696145696
- bits_investigations_read
145697-
x-unstable: |-
145698-
**Note**: This endpoint is in preview and is subject to change.
145699-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
145700145697
post:
145701145698
description: |-
145702145699
Trigger a Bits AI investigation from a monitor alert or a general investigation.
145703-
The `monitors_read` permission is required when the trigger type is `monitor_alert_trigger`.
145700+
This endpoint requires the `bits_investigations_write` permission. When the trigger type is
145701+
`monitor_alert_trigger`, the `monitors_read` permission is also required.
145704145702
operationId: TriggerInvestigation
145705145703
requestBody:
145706145704
content:
@@ -145760,19 +145758,14 @@ paths:
145760145758
appKeyAuth: []
145761145759
- AuthZ:
145762145760
- bits_investigations_write
145763-
- monitors_read
145764145761
summary: Trigger a Bits AI investigation
145765145762
tags:
145766145763
- Bits AI
145767145764
x-codegen-request-body-name: body
145768145765
"x-permission":
145769-
operator: AND
145766+
operator: OR
145770145767
permissions:
145771145768
- bits_investigations_write
145772-
- monitors_read
145773-
x-unstable: |-
145774-
**Note**: This endpoint is in preview and is subject to change.
145775-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
145776145769
/api/v2/bits-ai/investigations/{id}:
145777145770
get:
145778145771
description: Get a specific Bits AI investigation by ID.
@@ -145833,9 +145826,6 @@ paths:
145833145826
operator: OR
145834145827
permissions:
145835145828
- bits_investigations_read
145836-
x-unstable: |-
145837-
**Note**: This endpoint is in preview and is subject to change.
145838-
If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
145839145829
/api/v2/cases:
145840145830
get:
145841145831
description: >-

‎examples/v2/bits-ai/GetInvestigation.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
configuration = Configuration()
1010
configuration.access_token = environ["DD_BEARER_TOKEN"]
11-
configuration.unstable_operations["get_investigation"] = True
1211
with ApiClient(configuration) as api_client:
1312
api_instance = BitsAIApi(api_client)
1413
response = api_instance.get_investigation(

‎examples/v2/bits-ai/ListInvestigations.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
configuration = Configuration()
1010
configuration.access_token = environ["DD_BEARER_TOKEN"]
11-
configuration.unstable_operations["list_investigations"] = True
1211
with ApiClient(configuration) as api_client:
1312
api_instance = BitsAIApi(api_client)
1413
response = api_instance.list_investigations()

‎examples/v2/bits-ai/ListInvestigations_130750454.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
configuration = Configuration()
1010
configuration.access_token = environ["DD_BEARER_TOKEN"]
11-
configuration.unstable_operations["list_investigations"] = True
1211
with ApiClient(configuration) as api_client:
1312
api_instance = BitsAIApi(api_client)
1413
items = api_instance.list_investigations_with_pagination()

‎examples/v2/bits-ai/TriggerInvestigation.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333

3434
configuration = Configuration()
3535
configuration.access_token = environ["DD_BEARER_TOKEN"]
36-
configuration.unstable_operations["trigger_investigation"] = True
3736
with ApiClient(configuration) as api_client:
3837
api_instance = BitsAIApi(api_client)
3938
response = api_instance.trigger_investigation(body=body)

‎src/datadog_api_client/configuration.py‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -352,9 +352,6 @@ def __init__(
352352
"v2.get_open_api": False,
353353
"v2.list_apis": False,
354354
"v2.update_open_api": False,
355-
"v2.get_investigation": False,
356-
"v2.list_investigations": False,
357-
"v2.trigger_investigation": False,
358355
"v2.create_change_request": False,
359356
"v2.create_change_request_branch": False,
360357
"v2.delete_change_request_decision": False,

‎src/datadog_api_client/v2/api/bits_ai_api.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,8 @@ def trigger_investigation(
207207
"""Trigger a Bits AI investigation.
208208
209209
Trigger a Bits AI investigation from a monitor alert or a general investigation.
210-
The ``monitors_read`` permission is required when the trigger type is ``monitor_alert_trigger``.
210+
This endpoint requires the ``bits_investigations_write`` permission. When the trigger type is
211+
``monitor_alert_trigger`` , the ``monitors_read`` permission is also required.
211212
212213
:param body: Trigger investigation request body.
213214
:type body: TriggerInvestigationRequest

‎tests/v2/features/bits_ai.feature‎

Lines changed: 8 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,61 +9,53 @@ Feature: Bits AI
99

1010
@generated @skip @team:ddoghq/bits-ai
1111
Scenario: Get a Bits AI investigation returns "Bad Request" response
12-
Given operation "GetInvestigation" enabled
13-
And new "GetInvestigation" request
12+
Given new "GetInvestigation" request
1413
And request contains "id" parameter from "REPLACE.ME"
1514
When the request is sent
1615
Then the response status is 400 Bad Request
1716

1817
@generated @skip @team:ddoghq/bits-ai
1918
Scenario: Get a Bits AI investigation returns "Not Found" response
20-
Given operation "GetInvestigation" enabled
21-
And new "GetInvestigation" request
19+
Given new "GetInvestigation" request
2220
And request contains "id" parameter from "REPLACE.ME"
2321
When the request is sent
2422
Then the response status is 404 Not Found
2523

2624
@generated @skip @team:ddoghq/bits-ai
2725
Scenario: Get a Bits AI investigation returns "OK" response
28-
Given operation "GetInvestigation" enabled
29-
And new "GetInvestigation" request
26+
Given new "GetInvestigation" request
3027
And request contains "id" parameter from "REPLACE.ME"
3128
When the request is sent
3229
Then the response status is 200 OK
3330

3431
@generated @skip @team:ddoghq/bits-ai
3532
Scenario: List Bits AI investigations returns "Bad Request" response
36-
Given operation "ListInvestigations" enabled
37-
And new "ListInvestigations" request
33+
Given new "ListInvestigations" request
3834
When the request is sent
3935
Then the response status is 400 Bad Request
4036

4137
@generated @skip @team:ddoghq/bits-ai
4238
Scenario: List Bits AI investigations returns "OK" response
43-
Given operation "ListInvestigations" enabled
44-
And new "ListInvestigations" request
39+
Given new "ListInvestigations" request
4540
When the request is sent
4641
Then the response status is 200 OK
4742

4843
@generated @skip @team:ddoghq/bits-ai @with-pagination
4944
Scenario: List Bits AI investigations returns "OK" response with pagination
50-
Given operation "ListInvestigations" enabled
51-
And new "ListInvestigations" request
45+
Given new "ListInvestigations" request
5246
When the request with pagination is sent
5347
Then the response status is 200 OK
5448

5549
@generated @skip @team:ddoghq/bits-ai
5650
Scenario: Trigger a Bits AI investigation returns "Bad Request" response
57-
Given operation "TriggerInvestigation" enabled
58-
And new "TriggerInvestigation" request
51+
Given new "TriggerInvestigation" request
5952
And body with value {"data": {"attributes": {"trigger": {"monitor_alert_trigger": {"event_id": "1234567890123456789", "event_ts": 1700000000000, "monitor_id": 12345678}, "type": "monitor_alert_trigger"}}, "type": "trigger_investigation_request"}}
6053
When the request is sent
6154
Then the response status is 400 Bad Request
6255

6356
@generated @skip @team:ddoghq/bits-ai
6457
Scenario: Trigger a Bits AI investigation returns "OK" response
65-
Given operation "TriggerInvestigation" enabled
66-
And new "TriggerInvestigation" request
58+
Given new "TriggerInvestigation" request
6759
And body with value {"data": {"attributes": {"trigger": {"monitor_alert_trigger": {"event_id": "1234567890123456789", "event_ts": 1700000000000, "monitor_id": 12345678}, "type": "monitor_alert_trigger"}}, "type": "trigger_investigation_request"}}
6860
When the request is sent
6961
Then the response status is 200 OK

0 commit comments

Comments
 (0)