Skip to content

Commit 77ea007

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit cb847cd2 of spec repo
1 parent 6b224d2 commit 77ea007

File tree

74 files changed

+534
-504
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+534
-504
lines changed

.apigentools-info

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-02-04 14:10:06.221297",
8-
"spec_repo_commit": "4fb9047a"
7+
"regenerated": "2025-02-06 17:26:25.243976",
8+
"spec_repo_commit": "cb847cd2"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-02-04 14:10:06.239068",
13-
"spec_repo_commit": "4fb9047a"
12+
"regenerated": "2025-02-06 17:26:25.261445",
13+
"spec_repo_commit": "cb847cd2"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

+21-14
Original file line numberDiff line numberDiff line change
@@ -23184,16 +23184,15 @@ components:
2318423184
x-enum-varnames:
2318523185
- RULE
2318623186
RuleTypes:
23187-
description: Security rule types used to filter signals and vulnerabilities
23188-
generating notifications.
23187+
description: Security rule types used as filters in security rules.
2318923188
example:
2319023189
- misconfiguration
2319123190
- attack_path
2319223191
items:
2319323192
$ref: '#/components/schemas/RuleTypesItems'
2319423193
type: array
2319523194
RuleTypesItems:
23196-
description: 'Security rule types which can be used in notification rules.
23195+
description: 'Security rule type which can be used in security rules.
2319723196

2319823197
Signal-based notification rules can filter signals based on rule types application_security,
2319923198
log_detection,
@@ -40197,7 +40196,7 @@ paths:
4019740196
required: false
4019840197
schema:
4019940198
type: boolean
40200-
- description: '(Beta) Filter custom metrics that have or have not been queried
40199+
- description: '(Preview) Filter custom metrics that have or have not been queried
4020140200
in the specified window[seconds].
4020240201

4020340202
If no window is provided or the window is less than 2 hours, a default of
@@ -40218,6 +40217,14 @@ paths:
4021840217
required: false
4021940218
schema:
4022040219
type: string
40220+
- description: (Preview) Filter metrics that are used in dashboards, monitors,
40221+
notebooks, SLOs.
40222+
example: true
40223+
in: query
40224+
name: filter[related_assets]
40225+
required: false
40226+
schema:
40227+
type: boolean
4022140228
- description: 'The number of seconds of look back (from now) to apply to a
4022240229
filter[tag] or filter[queried] query.
4022340230

@@ -44078,7 +44085,7 @@ paths:
4407844085
appKeyAuth: []
4407944086
- AuthZ:
4408044087
- security_monitoring_notification_profiles_read
44081-
summary: Get the list of signal-based rules
44088+
summary: Get the list of signal-based notification rules
4408244089
tags:
4408344090
- Security Monitoring
4408444091
x-permission:
@@ -44120,7 +44127,7 @@ paths:
4412044127
appKeyAuth: []
4412144128
- AuthZ:
4412244129
- security_monitoring_notification_profiles_write
44123-
summary: Create a new signal-based rule
44130+
summary: Create a new signal-based notification rule
4412444131
tags:
4412544132
- Security Monitoring
4412644133
x-codegen-request-body-name: body
@@ -44153,7 +44160,7 @@ paths:
4415344160
appKeyAuth: []
4415444161
- AuthZ:
4415544162
- security_monitoring_notification_profiles_write
44156-
summary: Delete a signal-based rule
44163+
summary: Delete a signal-based notification rule
4415744164
tags:
4415844165
- Security Monitoring
4415944166
x-permission:
@@ -44190,7 +44197,7 @@ paths:
4419044197
appKeyAuth: []
4419144198
- AuthZ:
4419244199
- security_monitoring_notification_profiles_read
44193-
summary: Get details of a signal-based rule
44200+
summary: Get details of a signal-based notification rule
4419444201
tags:
4419544202
- Security Monitoring
4419644203
x-permission:
@@ -44236,7 +44243,7 @@ paths:
4423644243
appKeyAuth: []
4423744244
- AuthZ:
4423844245
- security_monitoring_notification_profiles_write
44239-
summary: Patch a signal-based rule
44246+
summary: Patch a signal-based notification rule
4424044247
tags:
4424144248
- Security Monitoring
4424244249
x-codegen-request-body-name: body
@@ -44636,7 +44643,7 @@ paths:
4463644643
appKeyAuth: []
4463744644
- AuthZ:
4463844645
- security_monitoring_notification_profiles_read
44639-
summary: Get the list of vulnerability-based rules
44646+
summary: Get the list of vulnerability notification rules
4464044647
tags:
4464144648
- Security Monitoring
4464244649
x-permission:
@@ -44678,7 +44685,7 @@ paths:
4467844685
appKeyAuth: []
4467944686
- AuthZ:
4468044687
- security_monitoring_notification_profiles_write
44681-
summary: Create a new vulnerability-based rule
44688+
summary: Create a new vulnerability-based notification rule
4468244689
tags:
4468344690
- Security Monitoring
4468444691
x-codegen-request-body-name: body
@@ -44711,7 +44718,7 @@ paths:
4471144718
appKeyAuth: []
4471244719
- AuthZ:
4471344720
- security_monitoring_notification_profiles_write
44714-
summary: Delete a vulnerability-based rule
44721+
summary: Delete a vulnerability-based notification rule
4471544722
tags:
4471644723
- Security Monitoring
4471744724
x-permission:
@@ -44748,7 +44755,7 @@ paths:
4474844755
appKeyAuth: []
4474944756
- AuthZ:
4475044757
- security_monitoring_notification_profiles_read
44751-
summary: Get details of a vulnerability-based rule
44758+
summary: Get details of a vulnerability notification rule
4475244759
tags:
4475344760
- Security Monitoring
4475444761
x-permission:
@@ -44794,7 +44801,7 @@ paths:
4479444801
appKeyAuth: []
4479544802
- AuthZ:
4479644803
- security_monitoring_notification_profiles_write
44797-
summary: Patch a vulnerability-based rule
44804+
summary: Patch a vulnerability-based notification rule
4479844805
tags:
4479944806
- Security Monitoring
4480044807
x-codegen-request-body-name: body

examples/v2_security-monitoring_CreateSignalNotificationRule.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Create a new signal-based rule returns "Successfully created the notification
2-
// rule." response
1+
// Create a new signal-based notification rule returns "Successfully created the
2+
// notification rule." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55
use datadog_api_client::datadogV2::model::CreateNotificationRuleParameters;

examples/v2_security-monitoring_CreateVulnerabilityNotificationRule.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Create a new vulnerability-based rule returns "Successfully created the
2-
// notification rule." response
1+
// Create a new vulnerability-based notification rule returns "Successfully
2+
// created the notification rule." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55
use datadog_api_client::datadogV2::model::CreateNotificationRuleParameters;

examples/v2_security-monitoring_DeleteSignalNotificationRule.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// Delete a signal-based rule returns "Rule successfully deleted." response
1+
// Delete a signal-based notification rule returns "Rule successfully deleted."
2+
// response
23
use datadog_api_client::datadog;
34
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
45

examples/v2_security-monitoring_DeleteVulnerabilityNotificationRule.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// Delete a vulnerability-based rule returns "Rule successfully deleted." response
1+
// Delete a vulnerability-based notification rule returns "Rule successfully
2+
// deleted." response
23
use datadog_api_client::datadog;
34
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
45

examples/v2_security-monitoring_GetSignalNotificationRule.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// Get details of a signal-based rule returns "Notification rule details." response
1+
// Get details of a signal-based notification rule returns "Notification rule
2+
// details." response
23
use datadog_api_client::datadog;
34
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
45

examples/v2_security-monitoring_GetSignalNotificationRules.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Get the list of signal-based rules returns "The list of notification rules."
2-
// response
1+
// Get the list of signal-based notification rules returns "The list of
2+
// notification rules." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55

examples/v2_security-monitoring_GetVulnerabilityNotificationRule.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Get details of a vulnerability-based rule returns "Notification rule details."
2-
// response
1+
// Get details of a vulnerability notification rule returns "Notification rule
2+
// details." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55

examples/v2_security-monitoring_GetVulnerabilityNotificationRules.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Get the list of vulnerability-based rules returns "The list of notification
2-
// rules." response
1+
// Get the list of vulnerability notification rules returns "The list of
2+
// notification rules." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55

examples/v2_security-monitoring_PatchSignalNotificationRule.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Patch a signal-based rule returns "Notification rule successfully patched."
2-
// response
1+
// Patch a signal-based notification rule returns "Notification rule successfully
2+
// patched." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55
use datadog_api_client::datadogV2::model::NotificationRulesType;

examples/v2_security-monitoring_PatchVulnerabilityNotificationRule.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// Patch a vulnerability-based rule returns "Notification rule successfully
2-
// patched." response
1+
// Patch a vulnerability-based notification rule returns "Notification rule
2+
// successfully patched." response
33
use datadog_api_client::datadog;
44
use datadog_api_client::datadogV2::api_security_monitoring::SecurityMonitoringAPI;
55
use datadog_api_client::datadogV2::model::NotificationRulesType;

src/datadogV2/api/api_metrics.rs

+14-2
Original file line numberDiff line numberDiff line change
@@ -88,12 +88,14 @@ pub struct ListTagConfigurationsOptionalParams {
8888
/// Filter distributions with additional percentile
8989
/// aggregations enabled or disabled.
9090
pub filter_include_percentiles: Option<bool>,
91-
/// (Beta) Filter custom metrics that have or have not been queried in the specified window[seconds].
91+
/// (Preview) Filter custom metrics that have or have not been queried in the specified window[seconds].
9292
/// If no window is provided or the window is less than 2 hours, a default of 2 hours will be applied.
9393
pub filter_queried: Option<bool>,
9494
/// Filter metrics that have been submitted with the given tags. Supports boolean and wildcard expressions.
9595
/// Can only be combined with the filter[queried] filter.
9696
pub filter_tags: Option<String>,
97+
/// (Preview) Filter metrics that are used in dashboards, monitors, notebooks, SLOs.
98+
pub filter_related_assets: Option<bool>,
9799
/// The number of seconds of look back (from now) to apply to a filter[tag] or filter[queried] query.
98100
/// Default value is 3600 (1 hour), maximum value is 2,592,000 (30 days).
99101
pub window_seconds: Option<i64>,
@@ -130,7 +132,7 @@ impl ListTagConfigurationsOptionalParams {
130132
self.filter_include_percentiles = Some(value);
131133
self
132134
}
133-
/// (Beta) Filter custom metrics that have or have not been queried in the specified window[seconds].
135+
/// (Preview) Filter custom metrics that have or have not been queried in the specified window[seconds].
134136
/// If no window is provided or the window is less than 2 hours, a default of 2 hours will be applied.
135137
pub fn filter_queried(mut self, value: bool) -> Self {
136138
self.filter_queried = Some(value);
@@ -142,6 +144,11 @@ impl ListTagConfigurationsOptionalParams {
142144
self.filter_tags = Some(value);
143145
self
144146
}
147+
/// (Preview) Filter metrics that are used in dashboards, monitors, notebooks, SLOs.
148+
pub fn filter_related_assets(mut self, value: bool) -> Self {
149+
self.filter_related_assets = Some(value);
150+
self
151+
}
145152
/// The number of seconds of look back (from now) to apply to a filter[tag] or filter[queried] query.
146153
/// Default value is 3600 (1 hour), maximum value is 2,592,000 (30 days).
147154
pub fn window_seconds(mut self, value: i64) -> Self {
@@ -1545,6 +1552,7 @@ impl MetricsAPI {
15451552
let filter_include_percentiles = params.filter_include_percentiles;
15461553
let filter_queried = params.filter_queried;
15471554
let filter_tags = params.filter_tags;
1555+
let filter_related_assets = params.filter_related_assets;
15481556
let window_seconds = params.window_seconds;
15491557
let page_size = params.page_size;
15501558
let page_cursor = params.page_cursor;
@@ -1584,6 +1592,10 @@ impl MetricsAPI {
15841592
local_req_builder =
15851593
local_req_builder.query(&[("filter[tags]", &local_query_param.to_string())]);
15861594
};
1595+
if let Some(ref local_query_param) = filter_related_assets {
1596+
local_req_builder = local_req_builder
1597+
.query(&[("filter[related_assets]", &local_query_param.to_string())]);
1598+
};
15871599
if let Some(ref local_query_param) = window_seconds {
15881600
local_req_builder =
15891601
local_req_builder.query(&[("window[seconds]", &local_query_param.to_string())]);

src/datadogV2/model/model_selectors.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ pub struct Selectors {
1616
/// The query is composed of one or several key:value pairs, which can be used to filter security issues on tags and attributes.
1717
#[serde(rename = "query")]
1818
pub query: Option<String>,
19-
/// Security rule types used to filter signals and vulnerabilities generating notifications.
19+
/// Security rule types used as filters in security rules.
2020
#[serde(rename = "rule_types")]
2121
pub rule_types: Option<Vec<crate::datadogV2::model::RuleTypesItems>>,
2222
/// The security rules severities to consider.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2025-02-05T13:45:37.454Z
+4-4
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"response": {
2121
"body": {
22-
"string": "{\"data\":{\"id\":\"xen-2ux-w4q\",\"type\":\"notification_rules\",\"attributes\":{\"created_at\":1737628559636,\"created_by\":{\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"enabled\":true,\"modified_at\":1737628559636,\"modified_by\":{\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"name\":\"Rule 1\",\"selectors\":{\"severities\":[\"critical\"],\"rule_types\":[\"misconfiguration\",\"attack_path\"],\"query\":\"(source:production_service OR env:prod)\",\"trigger_source\":\"security_findings\"},\"targets\":[\"@[email protected]\"],\"time_aggregation\":86400,\"version\":1}}}",
22+
"string": "{\"data\":{\"id\":\"hvb-for-lpm\",\"type\":\"notification_rules\",\"attributes\":{\"created_at\":1738763137979,\"created_by\":{\"name\":\"\",\"handle\":\"\"},\"enabled\":true,\"modified_at\":1738763137979,\"modified_by\":{\"name\":\"\",\"handle\":\"\"},\"name\":\"Rule 1\",\"selectors\":{\"severities\":[\"critical\"],\"rule_types\":[\"misconfiguration\",\"attack_path\"],\"query\":\"(source:production_service OR env:prod)\",\"trigger_source\":\"security_findings\"},\"targets\":[\"@[email protected]\"],\"time_aggregation\":86400,\"version\":1}}}",
2323
"encoding": null
2424
},
2525
"headers": {
@@ -32,7 +32,7 @@
3232
"message": "Created"
3333
}
3434
},
35-
"recorded_at": "Thu, 23 Jan 2025 10:35:59 GMT"
35+
"recorded_at": "Wed, 05 Feb 2025 13:45:37 GMT"
3636
},
3737
{
3838
"request": {
@@ -43,7 +43,7 @@
4343
]
4444
},
4545
"method": "delete",
46-
"uri": "https://api.datadoghq.com/api/v2/security/signals/notification_rules/xen-2ux-w4q"
46+
"uri": "https://api.datadoghq.com/api/v2/security/signals/notification_rules/hvb-for-lpm"
4747
},
4848
"response": {
4949
"body": {
@@ -56,7 +56,7 @@
5656
"message": "No Content"
5757
}
5858
},
59-
"recorded_at": "Thu, 23 Jan 2025 10:35:59 GMT"
59+
"recorded_at": "Wed, 05 Feb 2025 13:45:37 GMT"
6060
}
6161
],
6262
"recorded_with": "VCR 6.0.0"

tests/scenarios/cassettes/v2/security_monitoring/Create-a-new-signal-based-rule-returns-Successfully-created-the-notification-rule-response.frozen

-1
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2025-02-05T13:45:38.493Z
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"response": {
2121
"body": {
22-
"string": "{\"data\":{\"id\":\"757-rvr-pnu\",\"type\":\"notification_rules\",\"attributes\":{\"created_at\":1737628559864,\"created_by\":{\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"enabled\":true,\"modified_at\":1737628559864,\"modified_by\":{\"name\":\"CI Account\",\"handle\":\"9919ec9b-ebc7-49ee-8dc8-03626e717cca\"},\"name\":\"Rule 1\",\"selectors\":{\"severities\":[\"critical\"],\"rule_types\":[\"misconfiguration\",\"attack_path\"],\"query\":\"(source:production_service OR env:prod)\",\"trigger_source\":\"security_findings\"},\"targets\":[\"@[email protected]\"],\"time_aggregation\":86400,\"version\":1}}}",
22+
"string": "{\"data\":{\"id\":\"iwz-k3b-tpk\",\"type\":\"notification_rules\",\"attributes\":{\"created_at\":1738763138982,\"created_by\":{\"name\":\"\",\"handle\":\"\"},\"enabled\":true,\"modified_at\":1738763138982,\"modified_by\":{\"name\":\"\",\"handle\":\"\"},\"name\":\"Rule 1\",\"selectors\":{\"severities\":[\"critical\"],\"rule_types\":[\"misconfiguration\",\"attack_path\"],\"query\":\"(source:production_service OR env:prod)\",\"trigger_source\":\"security_findings\"},\"targets\":[\"@[email protected]\"],\"time_aggregation\":86400,\"version\":1}}}",
2323
"encoding": null
2424
},
2525
"headers": {
@@ -32,7 +32,7 @@
3232
"message": "Created"
3333
}
3434
},
35-
"recorded_at": "Thu, 23 Jan 2025 10:35:59 GMT"
35+
"recorded_at": "Wed, 05 Feb 2025 13:45:38 GMT"
3636
},
3737
{
3838
"request": {
@@ -43,7 +43,7 @@
4343
]
4444
},
4545
"method": "delete",
46-
"uri": "https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/757-rvr-pnu"
46+
"uri": "https://api.datadoghq.com/api/v2/security/vulnerabilities/notification_rules/iwz-k3b-tpk"
4747
},
4848
"response": {
4949
"body": {
@@ -56,7 +56,7 @@
5656
"message": "No Content"
5757
}
5858
},
59-
"recorded_at": "Thu, 23 Jan 2025 10:35:59 GMT"
59+
"recorded_at": "Wed, 05 Feb 2025 13:45:38 GMT"
6060
}
6161
],
6262
"recorded_with": "VCR 6.0.0"

tests/scenarios/cassettes/v2/security_monitoring/Create-a-new-vulnerability-based-rule-returns-Successfully-created-the-notification-rule-response.frozen

-1
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2025-02-05T13:45:43.873Z

tests/scenarios/cassettes/v2/security_monitoring/Delete-a-signal-based-rule-returns-Not-Found-response.json tests/scenarios/cassettes/v2/security_monitoring/Delete-a-signal-based-notification-rule-returns-Not-Found-response.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
"message": "Not Found"
2727
}
2828
},
29-
"recorded_at": "Wed, 22 Jan 2025 09:50:04 GMT"
29+
"recorded_at": "Wed, 05 Feb 2025 13:45:43 GMT"
3030
}
3131
],
3232
"recorded_with": "VCR 6.0.0"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2025-02-05T13:45:44.348Z

0 commit comments

Comments
 (0)