Skip to content

Commit 88bd0cf

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit e59884c of spec repo
1 parent b1190b5 commit 88bd0cf

8 files changed

+36
-14
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43778,6 +43778,14 @@ components:
4377843778
for scheduled rules - in other words, when the `schedulingOptions` field
4377943779
is present in the rule payload.'
4378043780
type: string
43781+
indexes:
43782+
description: List of indexes to query when the `dataSource` is `logs`. Only
43783+
used for scheduled rules, such as when the `schedulingOptions` field is
43784+
present in the rule payload.
43785+
items:
43786+
description: Index.
43787+
type: string
43788+
type: array
4378143789
metric:
4378243790
deprecated: true
4378343791
description: '(Deprecated) The target field to aggregate over when using
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2025-07-31T07:48:27.113Z
1+
2025-10-13T21:11:45.641Z

cassettes/features/v2/security_monitoring/Create-a-scheduled-detection-rule-returns-OK-response.yml

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2025-07-31T07:49:14.474Z
1+
2025-10-13T21:12:46.212Z

cassettes/features/v2/security_monitoring/Create-a-scheduled-rule-without-rrule-returns-Bad-Request-response.yml

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/v2/security-monitoring/CreateSecurityMonitoringRule_868881438.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@
1111
aggregation: DatadogAPIClient::V2::SecurityMonitoringRuleQueryAggregation::COUNT,
1212
group_by_fields: [],
1313
distinct_fields: [],
14-
index: "main",
14+
indexes: [
15+
"main",
16+
],
1517
}),
1618
],
1719
filters: [],

features/v2/security_monitoring.feature

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ Feature: Security Monitoring
308308
@team:DataDog/k9-cloud-security-platform
309309
Scenario: Create a scheduled detection rule returns "OK" response
310310
Given new "CreateSecurityMonitoringRule" request
311-
And body with value {"name":"{{ unique }}", "queries":[{"query":"@test:true","aggregation":"count","groupByFields":[],"distinctFields":[],"index":"main"}],"filters":[],"cases":[{"name":"","status":"info","condition":"a > 0","notifications":[]}],"options":{"evaluationWindow":900,"keepAlive":3600,"maxSignalDuration":86400},"message":"Test rule","tags":[],"isEnabled":true, "type":"log_detection", "schedulingOptions": {"rrule": "FREQ=HOURLY;INTERVAL=2;", "start": "2025-06-18T12:00:00", "timezone": "Europe/Paris"}}
311+
And body with value {"name":"{{ unique }}", "queries":[{"query":"@test:true","aggregation":"count","groupByFields":[],"distinctFields":[],"indexes":["main"]}],"filters":[],"cases":[{"name":"","status":"info","condition":"a > 0","notifications":[]}],"options":{"evaluationWindow":900,"keepAlive":3600,"maxSignalDuration":86400},"message":"Test rule","tags":[],"isEnabled":true, "type":"log_detection", "schedulingOptions": {"rrule": "FREQ=HOURLY;INTERVAL=2;", "start": "2025-06-18T12:00:00", "timezone": "Europe/Paris"}}
312312
When the request is sent
313313
Then the response status is 200 OK
314314
And the response "name" is equal to "{{ unique }}"
@@ -319,7 +319,7 @@ Feature: Security Monitoring
319319
@team:DataDog/k9-cloud-security-platform
320320
Scenario: Create a scheduled rule without rrule returns "Bad Request" response
321321
Given new "CreateSecurityMonitoringRule" request
322-
And body with value {"name":"{{ unique }}", "queries":[{"query":"@test:true","aggregation":"count","groupByFields":[],"distinctFields":[],"index":"main"}],"filters":[],"cases":[{"name":"","status":"info","condition":"a > 0","notifications":[]}],"options":{"evaluationWindow":900,"keepAlive":3600,"maxSignalDuration":86400},"message":"Test rule","tags":[],"isEnabled":true, "type":"log_detection", "schedulingOptions": {"start": "2025-06-18T12:00:00", "timezone": "Europe/Paris"}}
322+
And body with value {"name":"{{ unique }}", "queries":[{"query":"@test:true","aggregation":"count","groupByFields":[],"distinctFields":[],"indexes":["main"]}],"filters":[],"cases":[{"name":"","status":"info","condition":"a > 0","notifications":[]}],"options":{"evaluationWindow":900,"keepAlive":3600,"maxSignalDuration":86400},"message":"Test rule","tags":[],"isEnabled":true, "type":"log_detection", "schedulingOptions": {"start": "2025-06-18T12:00:00", "timezone": "Europe/Paris"}}
323323
When the request is sent
324324
Then the response status is 400 Bad Request
325325

lib/datadog_api_client/v2/models/security_monitoring_standard_rule_query.rb

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ class SecurityMonitoringStandardRuleQuery
4343
# The index to run the query on, if the `dataSource` is `logs`. Only used for scheduled rules - in other words, when the `schedulingOptions` field is present in the rule payload.
4444
attr_accessor :index
4545

46+
# List of indexes to query when the `dataSource` is `logs`. Only used for scheduled rules, such as when the `schedulingOptions` field is present in the rule payload.
47+
attr_accessor :indexes
48+
4649
# (Deprecated) The target field to aggregate over when using the sum or max
4750
# aggregations. `metrics` field should be used instead.
4851
attr_accessor :metric
@@ -69,6 +72,7 @@ def self.attribute_map
6972
:'group_by_fields' => :'groupByFields',
7073
:'has_optional_group_by_fields' => :'hasOptionalGroupByFields',
7174
:'index' => :'index',
75+
:'indexes' => :'indexes',
7276
:'metric' => :'metric',
7377
:'metrics' => :'metrics',
7478
:'name' => :'name',
@@ -87,6 +91,7 @@ def self.openapi_types
8791
:'group_by_fields' => :'Array<String>',
8892
:'has_optional_group_by_fields' => :'Boolean',
8993
:'index' => :'String',
94+
:'indexes' => :'Array<String>',
9095
:'metric' => :'String',
9196
:'metrics' => :'Array<String>',
9297
:'name' => :'String',
@@ -144,6 +149,12 @@ def initialize(attributes = {})
144149
self.index = attributes[:'index']
145150
end
146151

152+
if attributes.key?(:'indexes')
153+
if (value = attributes[:'indexes']).is_a?(Array)
154+
self.indexes = value
155+
end
156+
end
157+
147158
if attributes.key?(:'metric')
148159
self.metric = attributes[:'metric']
149160
end
@@ -196,6 +207,7 @@ def ==(o)
196207
group_by_fields == o.group_by_fields &&
197208
has_optional_group_by_fields == o.has_optional_group_by_fields &&
198209
index == o.index &&
210+
indexes == o.indexes &&
199211
metric == o.metric &&
200212
metrics == o.metrics &&
201213
name == o.name &&
@@ -207,7 +219,7 @@ def ==(o)
207219
# @return [Integer] Hash code
208220
# @!visibility private
209221
def hash
210-
[aggregation, custom_query_extension, data_source, distinct_fields, group_by_fields, has_optional_group_by_fields, index, metric, metrics, name, query, additional_properties].hash
222+
[aggregation, custom_query_extension, data_source, distinct_fields, group_by_fields, has_optional_group_by_fields, index, indexes, metric, metrics, name, query, additional_properties].hash
211223
end
212224
end
213225
end

0 commit comments

Comments
 (0)