datadog_api_client 2.14.0 → 2.15.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.apigentools-info +4 -4
- data/.generator/schemas/v1/openapi.yaml +165 -20
- data/.generator/schemas/v2/openapi.yaml +45 -23
- data/.generator/src/generator/openapi.py +3 -1
- data/.generator/src/generator/templates/api.j2 +8 -2
- data/CHANGELOG.md +26 -0
- data/examples/v1/dashboards/CreateDashboard_2618036642.rb +36 -0
- data/examples/v1/dashboards/CreateDashboard_2705593938.rb +3 -0
- data/examples/v1/dashboards/CreateDashboard_3777304439.rb +50 -0
- data/examples/v1/dashboards/ListDashboards_1062671515.rb +8 -0
- data/examples/v1/monitors/ListMonitors_2966492814.rb +8 -0
- data/examples/v1/notebooks/ListNotebooks_788665428.rb +8 -0
- data/examples/v1/service-level-objective-corrections/ListSLOCorrection_2647266873.rb +8 -0
- data/examples/v1/service-level-objectives/ListSLOs_3036942817.rb +8 -0
- data/examples/v1/synthetics/CreateSyntheticsAPITest_1487281163.rb +1 -0
- data/examples/v1/synthetics/ListTests_1938827783.rb +8 -0
- data/examples/v2/downtimes/CancelDowntime.rb +0 -3
- data/examples/v2/downtimes/CreateDowntime.rb +0 -3
- data/examples/v2/downtimes/GetDowntime.rb +0 -3
- data/examples/v2/downtimes/ListDowntimes.rb +0 -3
- data/examples/v2/downtimes/ListDowntimes_805770330.rb +8 -0
- data/examples/v2/downtimes/ListMonitorDowntimes.rb +0 -3
- data/examples/v2/downtimes/ListMonitorDowntimes_128979780.rb +0 -3
- data/examples/v2/downtimes/UpdateDowntime.rb +0 -3
- data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_1092490364.rb +1 -1
- data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule_428087276.rb +1 -1
- data/examples/v2/teams/ListTeams_3592098458.rb +8 -0
- data/examples/v2/users/ListUsers_4075885358.rb +8 -0
- data/lib/datadog_api_client/configuration.rb +0 -6
- data/lib/datadog_api_client/inflector.rb +1 -0
- data/lib/datadog_api_client/v1/api/dashboards_api.rb +25 -0
- data/lib/datadog_api_client/v1/api/monitors_api.rb +22 -0
- data/lib/datadog_api_client/v1/api/notebooks_api.rb +21 -0
- data/lib/datadog_api_client/v1/api/service_level_objective_corrections_api.rb +21 -0
- data/lib/datadog_api_client/v1/api/service_level_objectives_api.rb +21 -0
- data/lib/datadog_api_client/v1/api/synthetics_api.rb +25 -3
- data/lib/datadog_api_client/v1/api/usage_metering_api.rb +3 -3
- data/lib/datadog_api_client/v1/models/heat_map_widget_request.rb +35 -1
- data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +1 -0
- data/lib/datadog_api_client/v1/models/list_stream_source.rb +1 -0
- data/lib/datadog_api_client/v1/models/monitor.rb +1 -1
- data/lib/datadog_api_client/v1/models/monitor_options.rb +1 -1
- data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +2 -0
- data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +21 -1
- data/lib/datadog_api_client/v1/models/sunburst_widget_request.rb +14 -4
- data/lib/datadog_api_client/v1/models/synthetics_assertion_target.rb +11 -1
- data/lib/datadog_api_client/v1/models/synthetics_assertion_timings_scope.rb +27 -0
- data/lib/datadog_api_client/v1/models/usage_profiling_hour.rb +12 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date.rb +21 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +21 -1
- data/lib/datadog_api_client/v1/models/usage_summary_response.rb +21 -1
- data/lib/datadog_api_client/v2/api/audit_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/ci_visibility_pipelines_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/ci_visibility_tests_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/downtimes_api.rb +25 -36
- data/lib/datadog_api_client/v2/api/events_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/logs_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/processes_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/rum_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +3 -3
- data/lib/datadog_api_client/v2/api/service_definition_api.rb +2 -2
- data/lib/datadog_api_client/v2/api/spans_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/teams_api.rb +22 -0
- data/lib/datadog_api_client/v2/api/usage_metering_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/users_api.rb +22 -0
- data/lib/datadog_api_client/v2/models/downtime_relationships_monitor_data.rb +1 -1
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +14 -2
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,31 @@
|
|
1
1
|
# CHANGELOG
|
2
2
|
|
3
|
+
## 2.15.0 / 2023-09-14
|
4
|
+
|
5
|
+
### Fixed
|
6
|
+
* Fix downtimes monitor relationship id schema type by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1524
|
7
|
+
### Added
|
8
|
+
* Add trace_stream to dashboard ListStreamSource by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1499
|
9
|
+
* Add pagination extension to SLO corrections by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1509
|
10
|
+
* Adding aas count to the documentation for summary and hourly usage endpoints by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1511
|
11
|
+
* Add pagination extension to SLOs by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1510
|
12
|
+
* Add pagination extension to monitors by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1512
|
13
|
+
* Add pagination extension to synthetics tests by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1516
|
14
|
+
* Add 'style' to sunburst requests by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1515
|
15
|
+
* Add pagination extension to notebook by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1517
|
16
|
+
* Add support for dashboard listing pagination parameters by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1521
|
17
|
+
* Add pagination parameters to downtimes listing by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1523
|
18
|
+
* Add pagination extension to user list by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1522
|
19
|
+
* Add pagination extension to team listing by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1525
|
20
|
+
* Remove private beta for Downtimes v2 by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1519
|
21
|
+
* Update v1 monitor api docs to exclude downtimes v2 by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1534
|
22
|
+
* Add timing scope for response time assertions by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1526
|
23
|
+
* Add Formula and Function query support to heatmap widgets by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1535
|
24
|
+
* Add synthetics mobile application testing to usage metering API by @api-clients-generation-pipeline in https://github.com/DataDog/datadog-api-client-ruby/pull/1531
|
25
|
+
|
26
|
+
|
27
|
+
**Full Changelog**: https://github.com/DataDog/datadog-api-client-ruby/compare/v2.14.0...v2.15.0
|
28
|
+
|
3
29
|
## 2.14.0 / 2023-08-23
|
4
30
|
|
5
31
|
### Fixed
|
@@ -0,0 +1,36 @@
|
|
1
|
+
# Create a new dashboard with trace_stream widget
|
2
|
+
|
3
|
+
require "datadog_api_client"
|
4
|
+
api_instance = DatadogAPIClient::V1::DashboardsAPI.new
|
5
|
+
|
6
|
+
body = DatadogAPIClient::V1::Dashboard.new({
|
7
|
+
layout_type: DatadogAPIClient::V1::DashboardLayoutType::ORDERED,
|
8
|
+
title: "Example-Dashboard with list_stream widget",
|
9
|
+
widgets: [
|
10
|
+
DatadogAPIClient::V1::Widget.new({
|
11
|
+
definition: DatadogAPIClient::V1::ListStreamWidgetDefinition.new({
|
12
|
+
type: DatadogAPIClient::V1::ListStreamWidgetDefinitionType::LIST_STREAM,
|
13
|
+
requests: [
|
14
|
+
DatadogAPIClient::V1::ListStreamWidgetRequest.new({
|
15
|
+
columns: [
|
16
|
+
DatadogAPIClient::V1::ListStreamColumn.new({
|
17
|
+
width: DatadogAPIClient::V1::ListStreamColumnWidth::AUTO,
|
18
|
+
field: "timestamp",
|
19
|
+
}),
|
20
|
+
DatadogAPIClient::V1::ListStreamColumn.new({
|
21
|
+
width: DatadogAPIClient::V1::ListStreamColumnWidth::AUTO,
|
22
|
+
field: "service",
|
23
|
+
}),
|
24
|
+
],
|
25
|
+
query: DatadogAPIClient::V1::ListStreamQuery.new({
|
26
|
+
data_source: DatadogAPIClient::V1::ListStreamSource::TRACE_STREAM,
|
27
|
+
query_string: "",
|
28
|
+
}),
|
29
|
+
response_format: DatadogAPIClient::V1::ListStreamResponseFormat::EVENT_LIST,
|
30
|
+
}),
|
31
|
+
],
|
32
|
+
}),
|
33
|
+
}),
|
34
|
+
],
|
35
|
+
})
|
36
|
+
p api_instance.create_dashboard(body)
|
@@ -0,0 +1,50 @@
|
|
1
|
+
# Create a new dashboard with formula and function heatmap widget
|
2
|
+
|
3
|
+
require "datadog_api_client"
|
4
|
+
api_instance = DatadogAPIClient::V1::DashboardsAPI.new
|
5
|
+
|
6
|
+
body = DatadogAPIClient::V1::Dashboard.new({
|
7
|
+
title: "Example-Dashboard",
|
8
|
+
widgets: [
|
9
|
+
DatadogAPIClient::V1::Widget.new({
|
10
|
+
layout: DatadogAPIClient::V1::WidgetLayout.new({
|
11
|
+
x: 0,
|
12
|
+
y: 0,
|
13
|
+
width: 47,
|
14
|
+
height: 15,
|
15
|
+
}),
|
16
|
+
definition: DatadogAPIClient::V1::HeatMapWidgetDefinition.new({
|
17
|
+
title: "",
|
18
|
+
title_size: "16",
|
19
|
+
title_align: DatadogAPIClient::V1::WidgetTextAlign::LEFT,
|
20
|
+
time: DatadogAPIClient::V1::WidgetTime.new({}),
|
21
|
+
type: DatadogAPIClient::V1::HeatMapWidgetDefinitionType::HEATMAP,
|
22
|
+
requests: [
|
23
|
+
DatadogAPIClient::V1::HeatMapWidgetRequest.new({
|
24
|
+
response_format: DatadogAPIClient::V1::FormulaAndFunctionResponseFormat::TIMESERIES,
|
25
|
+
queries: [
|
26
|
+
DatadogAPIClient::V1::FormulaAndFunctionMetricQueryDefinition.new({
|
27
|
+
data_source: DatadogAPIClient::V1::FormulaAndFunctionMetricDataSource::METRICS,
|
28
|
+
name: "query1",
|
29
|
+
query: "avg:system.cpu.user{*}",
|
30
|
+
}),
|
31
|
+
],
|
32
|
+
formulas: [
|
33
|
+
DatadogAPIClient::V1::WidgetFormula.new({
|
34
|
+
formula: "query1",
|
35
|
+
}),
|
36
|
+
],
|
37
|
+
style: DatadogAPIClient::V1::WidgetStyle.new({
|
38
|
+
palette: "dog_classic",
|
39
|
+
}),
|
40
|
+
}),
|
41
|
+
],
|
42
|
+
}),
|
43
|
+
}),
|
44
|
+
],
|
45
|
+
template_variables: [],
|
46
|
+
layout_type: DatadogAPIClient::V1::DashboardLayoutType::FREE,
|
47
|
+
is_read_only: false,
|
48
|
+
notify_list: [],
|
49
|
+
})
|
50
|
+
p api_instance.create_dashboard(body)
|
@@ -0,0 +1,8 @@
|
|
1
|
+
# Get all SLO corrections returns "OK" response with pagination
|
2
|
+
|
3
|
+
require "datadog_api_client"
|
4
|
+
api_instance = DatadogAPIClient::V1::ServiceLevelObjectiveCorrectionsAPI.new
|
5
|
+
opts = {
|
6
|
+
limit: 2,
|
7
|
+
}
|
8
|
+
api_instance.list_slo_correction_with_pagination(opts) { |item| puts item }
|
@@ -16,6 +16,7 @@ body = DatadogAPIClient::V1::SyntheticsAPITest.new({
|
|
16
16
|
operator: DatadogAPIClient::V1::SyntheticsAssertionOperator::LESS_THAN,
|
17
17
|
target: 2000,
|
18
18
|
type: DatadogAPIClient::V1::SyntheticsAssertionType::RESPONSE_TIME,
|
19
|
+
timings_scope: DatadogAPIClient::V1::SyntheticsAssertionTimingsScope::WITHOUT_DNS,
|
19
20
|
}),
|
20
21
|
DatadogAPIClient::V1::SyntheticsAssertionJSONPathTarget.new({
|
21
22
|
operator: DatadogAPIClient::V1::SyntheticsAssertionJSONPathOperator::VALIDATES_JSON_PATH,
|
@@ -0,0 +1,8 @@
|
|
1
|
+
# Get the list of all Synthetic tests returns "OK - Returns the list of all Synthetic tests." response with pagination
|
2
|
+
|
3
|
+
require "datadog_api_client"
|
4
|
+
api_instance = DatadogAPIClient::V1::SyntheticsAPI.new
|
5
|
+
opts = {
|
6
|
+
page_size: 2,
|
7
|
+
}
|
8
|
+
api_instance.list_tests_with_pagination(opts) { |item| puts item }
|
@@ -1,9 +1,6 @@
|
|
1
1
|
# Cancel a downtime returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.cancel_downtime".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
|
9
6
|
# there is a valid "downtime_v2" in the system
|
@@ -1,9 +1,6 @@
|
|
1
1
|
# Schedule a downtime returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.create_downtime".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
|
9
6
|
body = DatadogAPIClient::V2::DowntimeCreateRequest.new({
|
@@ -1,9 +1,6 @@
|
|
1
1
|
# Get a downtime returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.get_downtime".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
|
9
6
|
# there is a valid "downtime_v2" in the system
|
@@ -1,8 +1,5 @@
|
|
1
1
|
# Get all downtimes returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.list_downtimes".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
p api_instance.list_downtimes()
|
@@ -1,8 +1,5 @@
|
|
1
1
|
# Get active downtimes for a monitor returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.list_monitor_downtimes".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
p api_instance.list_monitor_downtimes(9223372036854775807)
|
@@ -1,8 +1,5 @@
|
|
1
1
|
# Get all downtimes for a monitor returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.list_monitor_downtimes".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
p api_instance.list_monitor_downtimes(35534610)
|
@@ -1,9 +1,6 @@
|
|
1
1
|
# Update a downtime returns "OK" response
|
2
2
|
|
3
3
|
require "datadog_api_client"
|
4
|
-
DatadogAPIClient.configure do |config|
|
5
|
-
config.unstable_operations["v2.update_downtime".to_sym] = true
|
6
|
-
end
|
7
4
|
api_instance = DatadogAPIClient::V2::DowntimesAPI.new
|
8
5
|
|
9
6
|
# there is a valid "downtime_v2" in the system
|
@@ -20,7 +20,7 @@ body = DatadogAPIClient::V2::CloudConfigurationRuleCreatePayload.new({
|
|
20
20
|
resource_type: "gcp_compute_disk",
|
21
21
|
complex_rule: false,
|
22
22
|
rego_rule: DatadogAPIClient::V2::CloudConfigurationRegoRule.new({
|
23
|
-
policy: 'package datadog\n',
|
23
|
+
policy: 'package datadog\n\nimport data.datadog.output as dd_output\n\nimport future.keywords.contains\nimport future.keywords.if\nimport future.keywords.in\n\nmilliseconds_in_a_day := ((1000 * 60) * 60) * 24\n\neval(iam_service_account_key) = "skip" if {\n\tiam_service_account_key.disabled\n} else = "pass" if {\n\t(iam_service_account_key.resource_seen_at / milliseconds_in_a_day) - (iam_service_account_key.valid_after_time / milliseconds_in_a_day) <= 90\n} else = "fail"\n\n# This part remains unchanged for all rules\nresults contains result if {\n\tsome resource in input.resources[input.main_resource_type]\n\tresult := dd_output.format(resource, eval(resource))\n}\n',
|
24
24
|
resource_types: [
|
25
25
|
"gcp_compute_disk",
|
26
26
|
],
|
@@ -19,7 +19,7 @@ body = DatadogAPIClient::V2::SecurityMonitoringRuleUpdatePayload.new({
|
|
19
19
|
compliance_rule_options: DatadogAPIClient::V2::CloudConfigurationComplianceRuleOptions.new({
|
20
20
|
resource_type: "gcp_compute_disk",
|
21
21
|
rego_rule: DatadogAPIClient::V2::CloudConfigurationRegoRule.new({
|
22
|
-
policy: 'package datadog\n',
|
22
|
+
policy: 'package datadog\n\nimport data.datadog.output as dd_output\n\nimport future.keywords.contains\nimport future.keywords.if\nimport future.keywords.in\n\nmilliseconds_in_a_day := ((1000 * 60) * 60) * 24\n\neval(iam_service_account_key) = "skip" if {\n\tiam_service_account_key.disabled\n} else = "pass" if {\n\t(iam_service_account_key.resource_seen_at / milliseconds_in_a_day) - (iam_service_account_key.valid_after_time / milliseconds_in_a_day) <= 90\n} else = "fail"\n\n# This part remains unchanged for all rules\nresults contains result if {\n\tsome resource in input.resources[input.main_resource_type]\n\tresult := dd_output.format(resource, eval(resource))\n}\n',
|
23
23
|
resource_types: [
|
24
24
|
"gcp_compute_disk",
|
25
25
|
],
|
@@ -190,12 +190,6 @@ module DatadogAPIClient
|
|
190
190
|
@logger = defined?(Rails) ? Rails.logger : Logger.new(STDOUT)
|
191
191
|
@unstable_operations = {
|
192
192
|
"v2.create_ci_app_pipeline_event": false,
|
193
|
-
"v2.cancel_downtime": false,
|
194
|
-
"v2.create_downtime": false,
|
195
|
-
"v2.get_downtime": false,
|
196
|
-
"v2.list_downtimes": false,
|
197
|
-
"v2.list_monitor_downtimes": false,
|
198
|
-
"v2.update_downtime": false,
|
199
193
|
"v2.list_events": false,
|
200
194
|
"v2.search_events": false,
|
201
195
|
"v2.create_incident": false,
|
@@ -517,6 +517,7 @@ module DatadogAPIClient
|
|
517
517
|
"v1.synthetics_assertion_json_path_target_target" => "SyntheticsAssertionJSONPathTargetTarget",
|
518
518
|
"v1.synthetics_assertion_operator" => "SyntheticsAssertionOperator",
|
519
519
|
"v1.synthetics_assertion_target" => "SyntheticsAssertionTarget",
|
520
|
+
"v1.synthetics_assertion_timings_scope" => "SyntheticsAssertionTimingsScope",
|
520
521
|
"v1.synthetics_assertion_type" => "SyntheticsAssertionType",
|
521
522
|
"v1.synthetics_assertion_x_path_operator" => "SyntheticsAssertionXPathOperator",
|
522
523
|
"v1.synthetics_assertion_x_path_target" => "SyntheticsAssertionXPathTarget",
|
@@ -644,6 +644,8 @@ module DatadogAPIClient::V1
|
|
644
644
|
# @param opts [Hash] the optional parameters
|
645
645
|
# @option opts [Boolean] :filter_shared When `true`, this query only returns shared custom created or cloned dashboards.
|
646
646
|
# @option opts [Boolean] :filter_deleted When `true`, this query returns only deleted custom-created or cloned dashboards. This parameter is incompatible with `filter[shared]`.
|
647
|
+
# @option opts [Integer] :count The maximum number of dashboards returned in the list.
|
648
|
+
# @option opts [Integer] :start The specific offset to use as the beginning of the returned response.
|
647
649
|
# @return [Array<(DashboardSummary, Integer, Hash)>] DashboardSummary data, response status code and response headers
|
648
650
|
def list_dashboards_with_http_info(opts = {})
|
649
651
|
|
@@ -657,6 +659,8 @@ module DatadogAPIClient::V1
|
|
657
659
|
query_params = opts[:query_params] || {}
|
658
660
|
query_params[:'filter[shared]'] = opts[:'filter_shared'] if !opts[:'filter_shared'].nil?
|
659
661
|
query_params[:'filter[deleted]'] = opts[:'filter_deleted'] if !opts[:'filter_deleted'].nil?
|
662
|
+
query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
|
663
|
+
query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil?
|
660
664
|
|
661
665
|
# header parameters
|
662
666
|
header_params = opts[:header_params] || {}
|
@@ -693,6 +697,27 @@ module DatadogAPIClient::V1
|
|
693
697
|
return data, status_code, headers
|
694
698
|
end
|
695
699
|
|
700
|
+
# Get all dashboards.
|
701
|
+
#
|
702
|
+
# Provide a paginated version of {#list_dashboards}, returning all items.
|
703
|
+
#
|
704
|
+
# To use it you need to use a block: list_dashboards_with_pagination { |item| p item }
|
705
|
+
#
|
706
|
+
# @yield [DashboardSummaryDefinition] Paginated items
|
707
|
+
def list_dashboards_with_pagination(opts = {})
|
708
|
+
api_version = "V1"
|
709
|
+
page_size = @api_client.get_attribute_from_path(opts, "count", 100)
|
710
|
+
@api_client.set_attribute_from_path(api_version, opts, "count", Integer, page_size)
|
711
|
+
while true do
|
712
|
+
response = list_dashboards(opts)
|
713
|
+
@api_client.get_attribute_from_path(response, "dashboards").each { |item| yield(item) }
|
714
|
+
if @api_client.get_attribute_from_path(response, "dashboards").length < page_size
|
715
|
+
break
|
716
|
+
end
|
717
|
+
@api_client.set_attribute_from_path(api_version, opts, "start", Integer, @api_client.get_attribute_from_path(opts, "start", 0) + page_size)
|
718
|
+
end
|
719
|
+
end
|
720
|
+
|
696
721
|
# Restore deleted dashboards.
|
697
722
|
#
|
698
723
|
# @see #restore_dashboards_with_http_info
|
@@ -569,6 +569,28 @@ module DatadogAPIClient::V1
|
|
569
569
|
return data, status_code, headers
|
570
570
|
end
|
571
571
|
|
572
|
+
# Get all monitor details.
|
573
|
+
#
|
574
|
+
# Provide a paginated version of {#list_monitors}, returning all items.
|
575
|
+
#
|
576
|
+
# To use it you need to use a block: list_monitors_with_pagination { |item| p item }
|
577
|
+
#
|
578
|
+
# @yield [Monitor] Paginated items
|
579
|
+
def list_monitors_with_pagination(opts = {})
|
580
|
+
api_version = "V1"
|
581
|
+
page_size = @api_client.get_attribute_from_path(opts, "page_size", 100)
|
582
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
|
583
|
+
@api_client.set_attribute_from_path(api_version, opts, "page", Integer, 0)
|
584
|
+
while true do
|
585
|
+
response = list_monitors(opts)
|
586
|
+
@api_client.get_attribute_from_path(response, "").each { |item| yield(item) }
|
587
|
+
if @api_client.get_attribute_from_path(response, "").length < page_size
|
588
|
+
break
|
589
|
+
end
|
590
|
+
@api_client.set_attribute_from_path(api_version, opts, "page", Integer, @api_client.get_attribute_from_path(opts, "page", 0) + 1)
|
591
|
+
end
|
592
|
+
end
|
593
|
+
|
572
594
|
# Monitors group search.
|
573
595
|
#
|
574
596
|
# @see #search_monitor_groups_with_http_info
|
@@ -301,6 +301,27 @@ module DatadogAPIClient::V1
|
|
301
301
|
return data, status_code, headers
|
302
302
|
end
|
303
303
|
|
304
|
+
# Get all notebooks.
|
305
|
+
#
|
306
|
+
# Provide a paginated version of {#list_notebooks}, returning all items.
|
307
|
+
#
|
308
|
+
# To use it you need to use a block: list_notebooks_with_pagination { |item| p item }
|
309
|
+
#
|
310
|
+
# @yield [NotebooksResponseData] Paginated items
|
311
|
+
def list_notebooks_with_pagination(opts = {})
|
312
|
+
api_version = "V1"
|
313
|
+
page_size = @api_client.get_attribute_from_path(opts, "count", 100)
|
314
|
+
@api_client.set_attribute_from_path(api_version, opts, "count", Integer, page_size)
|
315
|
+
while true do
|
316
|
+
response = list_notebooks(opts)
|
317
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
318
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
319
|
+
break
|
320
|
+
end
|
321
|
+
@api_client.set_attribute_from_path(api_version, opts, "start", Integer, @api_client.get_attribute_from_path(opts, "start", 0) + page_size)
|
322
|
+
end
|
323
|
+
end
|
324
|
+
|
304
325
|
# Update a notebook.
|
305
326
|
#
|
306
327
|
# @see #update_notebook_with_http_info
|
@@ -284,6 +284,27 @@ module DatadogAPIClient::V1
|
|
284
284
|
return data, status_code, headers
|
285
285
|
end
|
286
286
|
|
287
|
+
# Get all SLO corrections.
|
288
|
+
#
|
289
|
+
# Provide a paginated version of {#list_slo_correction}, returning all items.
|
290
|
+
#
|
291
|
+
# To use it you need to use a block: list_slo_correction_with_pagination { |item| p item }
|
292
|
+
#
|
293
|
+
# @yield [SLOCorrection] Paginated items
|
294
|
+
def list_slo_correction_with_pagination(opts = {})
|
295
|
+
api_version = "V1"
|
296
|
+
page_size = @api_client.get_attribute_from_path(opts, "limit", 25)
|
297
|
+
@api_client.set_attribute_from_path(api_version, opts, "limit", Integer, page_size)
|
298
|
+
while true do
|
299
|
+
response = list_slo_correction(opts)
|
300
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
301
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
302
|
+
break
|
303
|
+
end
|
304
|
+
@api_client.set_attribute_from_path(api_version, opts, "offset", Integer, @api_client.get_attribute_from_path(opts, "offset", 0) + page_size)
|
305
|
+
end
|
306
|
+
end
|
307
|
+
|
287
308
|
# Update an SLO correction.
|
288
309
|
#
|
289
310
|
# @see #update_slo_correction_with_http_info
|
@@ -596,6 +596,27 @@ module DatadogAPIClient::V1
|
|
596
596
|
return data, status_code, headers
|
597
597
|
end
|
598
598
|
|
599
|
+
# Get all SLOs.
|
600
|
+
#
|
601
|
+
# Provide a paginated version of {#list_slos}, returning all items.
|
602
|
+
#
|
603
|
+
# To use it you need to use a block: list_slos_with_pagination { |item| p item }
|
604
|
+
#
|
605
|
+
# @yield [ServiceLevelObjective] Paginated items
|
606
|
+
def list_slos_with_pagination(opts = {})
|
607
|
+
api_version = "V1"
|
608
|
+
page_size = @api_client.get_attribute_from_path(opts, "limit", 1000)
|
609
|
+
@api_client.set_attribute_from_path(api_version, opts, "limit", Integer, page_size)
|
610
|
+
while true do
|
611
|
+
response = list_slos(opts)
|
612
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
613
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
614
|
+
break
|
615
|
+
end
|
616
|
+
@api_client.set_attribute_from_path(api_version, opts, "offset", Integer, @api_client.get_attribute_from_path(opts, "offset", 0) + page_size)
|
617
|
+
end
|
618
|
+
end
|
619
|
+
|
599
620
|
# Search for SLOs.
|
600
621
|
#
|
601
622
|
# @see #search_slo_with_http_info
|
@@ -1209,7 +1209,7 @@ module DatadogAPIClient::V1
|
|
1209
1209
|
return_type = opts[:debug_return_type] || 'Array<String>'
|
1210
1210
|
|
1211
1211
|
# auth_names
|
1212
|
-
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth
|
1212
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth]
|
1213
1213
|
|
1214
1214
|
new_options = opts.merge(
|
1215
1215
|
:operation => :get_synthetics_default_locations,
|
@@ -1428,8 +1428,8 @@ module DatadogAPIClient::V1
|
|
1428
1428
|
# Get the list of all Synthetic tests.
|
1429
1429
|
#
|
1430
1430
|
# @param opts [Hash] the optional parameters
|
1431
|
-
# @option opts [
|
1432
|
-
# @option opts [
|
1431
|
+
# @option opts [Integer] :page_size Used for pagination. The number of tests returned in the page.
|
1432
|
+
# @option opts [Integer] :page_number Used for pagination. Which page you want to retrieve. Starts at zero.
|
1433
1433
|
# @return [Array<(SyntheticsListTestsResponse, Integer, Hash)>] SyntheticsListTestsResponse data, response status code and response headers
|
1434
1434
|
def list_tests_with_http_info(opts = {})
|
1435
1435
|
|
@@ -1479,6 +1479,28 @@ module DatadogAPIClient::V1
|
|
1479
1479
|
return data, status_code, headers
|
1480
1480
|
end
|
1481
1481
|
|
1482
|
+
# Get the list of all Synthetic tests.
|
1483
|
+
#
|
1484
|
+
# Provide a paginated version of {#list_tests}, returning all items.
|
1485
|
+
#
|
1486
|
+
# To use it you need to use a block: list_tests_with_pagination { |item| p item }
|
1487
|
+
#
|
1488
|
+
# @yield [SyntheticsTestDetails] Paginated items
|
1489
|
+
def list_tests_with_pagination(opts = {})
|
1490
|
+
api_version = "V1"
|
1491
|
+
page_size = @api_client.get_attribute_from_path(opts, "page_size", 100)
|
1492
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
|
1493
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, 0)
|
1494
|
+
while true do
|
1495
|
+
response = list_tests(opts)
|
1496
|
+
@api_client.get_attribute_from_path(response, "tests").each { |item| yield(item) }
|
1497
|
+
if @api_client.get_attribute_from_path(response, "tests").length < page_size
|
1498
|
+
break
|
1499
|
+
end
|
1500
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, @api_client.get_attribute_from_path(opts, "page_number", 0) + 1)
|
1501
|
+
end
|
1502
|
+
end
|
1503
|
+
|
1482
1504
|
# Trigger tests from CI/CD pipelines.
|
1483
1505
|
#
|
1484
1506
|
# @see #trigger_ci_tests_with_http_info
|
@@ -152,7 +152,7 @@ module DatadogAPIClient::V1
|
|
152
152
|
fail ArgumentError, "Missing the required parameter 'usage_type' when calling UsageMeteringAPI.get_hourly_usage_attribution"
|
153
153
|
end
|
154
154
|
# verify enum value
|
155
|
-
allowable_values = ['api_usage', 'apm_fargate_usage', 'apm_host_usage', 'apm_usm_usage', 'appsec_fargate_usage', 'appsec_usage', 'browser_usage', 'container_excl_agent_usage', 'ci_visibility_itr_usage', 'container_usage', 'cspm_containers_usage', 'cspm_hosts_usage', 'custom_ingested_timeseries_usage', 'custom_timeseries_usage', 'cws_containers_usage', 'cws_hosts_usage', 'dbm_hosts_usage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_ingested_logs_usage', 'estimated_indexed_spans_usage', 'estimated_ingested_spans_usage', 'fargate_usage', 'functions_usage', 'infra_host_usage', 'invocations_usage', 'npm_host_usage', 'obs_pipeline_bytes_usage', 'profiled_container_usage', 'profiled_fargate_usage', 'profiled_host_usage', 'snmp_usage', 'estimated_rum_sessions_usage', 'universal_service_monitoring_usage', 'vuln_management_hosts_usage', 'sds_scanned_bytes_usage']
|
155
|
+
allowable_values = ['api_usage', 'apm_fargate_usage', 'apm_host_usage', 'apm_usm_usage', 'appsec_fargate_usage', 'appsec_usage', 'browser_usage', 'container_excl_agent_usage', 'ci_visibility_itr_usage', 'container_usage', 'cspm_containers_usage', 'cspm_hosts_usage', 'custom_ingested_timeseries_usage', 'custom_timeseries_usage', 'cws_containers_usage', 'cws_hosts_usage', 'dbm_hosts_usage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_ingested_logs_usage', 'estimated_indexed_spans_usage', 'estimated_ingested_spans_usage', 'fargate_usage', 'functions_usage', 'infra_host_usage', 'invocations_usage', 'mobile_app_testing_usage', 'npm_host_usage', 'obs_pipeline_bytes_usage', 'profiled_container_usage', 'profiled_fargate_usage', 'profiled_host_usage', 'snmp_usage', 'estimated_rum_sessions_usage', 'universal_service_monitoring_usage', 'vuln_management_hosts_usage', 'sds_scanned_bytes_usage']
|
156
156
|
if @api_client.config.client_side_validation && !allowable_values.include?(usage_type)
|
157
157
|
fail ArgumentError, "invalid value for \"usage_type\", must be one of #{allowable_values}"
|
158
158
|
end
|
@@ -472,7 +472,7 @@ module DatadogAPIClient::V1
|
|
472
472
|
fail ArgumentError, "Missing the required parameter 'fields' when calling UsageMeteringAPI.get_monthly_usage_attribution"
|
473
473
|
end
|
474
474
|
# verify enum value
|
475
|
-
allowable_values = ['api_usage', 'api_percentage', 'apm_fargate_usage', 'apm_fargate_percentage', 'appsec_fargate_usage', 'appsec_fargate_percentage', 'apm_host_usage', 'apm_host_percentage', 'apm_usm_usage', 'apm_usm_percentage', 'appsec_usage', 'appsec_percentage', 'browser_usage', 'browser_percentage', 'ci_visibility_itr_usage', 'ci_visibility_itr_percentage', 'container_excl_agent_usage', 'container_excl_agent_percentage', 'container_usage', 'container_percentage', 'cspm_containers_percentage', 'cspm_containers_usage', 'cspm_hosts_percentage', 'cspm_hosts_usage', 'custom_timeseries_usage', 'custom_timeseries_percentage', 'custom_ingested_timeseries_usage', 'custom_ingested_timeseries_percentage', 'cws_containers_percentage', 'cws_containers_usage', 'cws_hosts_percentage', 'cws_hosts_usage', 'dbm_hosts_percentage', 'dbm_hosts_usage', 'dbm_queries_percentage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_indexed_logs_percentage', 'estimated_ingested_logs_usage', 'estimated_ingested_logs_percentage', 'estimated_indexed_spans_usage', 'estimated_indexed_spans_percentage', 'estimated_ingested_spans_usage', 'estimated_ingested_spans_percentage', 'fargate_usage', 'fargate_percentage', 'functions_usage', 'functions_percentage', 'infra_host_usage', 'infra_host_percentage', 'invocations_usage', 'invocations_percentage', 'npm_host_usage', 'npm_host_percentage', 'obs_pipeline_bytes_usage', 'obs_pipeline_bytes_percentage', 'profiled_container_usage', 'profiled_container_percentage', 'profiled_fargate_usage', 'profiled_fargate_percentage', 'profiled_host_usage', 'profiled_host_percentage', 'snmp_usage', 'snmp_percentage', 'estimated_rum_sessions_usage', 'estimated_rum_sessions_percentage', 'universal_service_monitoring_usage', 'universal_service_monitoring_percentage', 'vuln_management_hosts_usage', 'vuln_management_hosts_percentage', 'sds_scanned_bytes_usage', 'sds_scanned_bytes_percentage', '*']
|
475
|
+
allowable_values = ['api_usage', 'api_percentage', 'apm_fargate_usage', 'apm_fargate_percentage', 'appsec_fargate_usage', 'appsec_fargate_percentage', 'apm_host_usage', 'apm_host_percentage', 'apm_usm_usage', 'apm_usm_percentage', 'appsec_usage', 'appsec_percentage', 'browser_usage', 'browser_percentage', 'ci_visibility_itr_usage', 'ci_visibility_itr_percentage', 'container_excl_agent_usage', 'container_excl_agent_percentage', 'container_usage', 'container_percentage', 'cspm_containers_percentage', 'cspm_containers_usage', 'cspm_hosts_percentage', 'cspm_hosts_usage', 'custom_timeseries_usage', 'custom_timeseries_percentage', 'custom_ingested_timeseries_usage', 'custom_ingested_timeseries_percentage', 'cws_containers_percentage', 'cws_containers_usage', 'cws_hosts_percentage', 'cws_hosts_usage', 'dbm_hosts_percentage', 'dbm_hosts_usage', 'dbm_queries_percentage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_indexed_logs_percentage', 'estimated_ingested_logs_usage', 'estimated_ingested_logs_percentage', 'estimated_indexed_spans_usage', 'estimated_indexed_spans_percentage', 'estimated_ingested_spans_usage', 'estimated_ingested_spans_percentage', 'fargate_usage', 'fargate_percentage', 'functions_usage', 'functions_percentage', 'infra_host_usage', 'infra_host_percentage', 'invocations_usage', 'invocations_percentage', 'mobile_app_testing_percentage', 'mobile_app_testing_usage', 'npm_host_usage', 'npm_host_percentage', 'obs_pipeline_bytes_usage', 'obs_pipeline_bytes_percentage', 'profiled_container_usage', 'profiled_container_percentage', 'profiled_fargate_usage', 'profiled_fargate_percentage', 'profiled_host_usage', 'profiled_host_percentage', 'snmp_usage', 'snmp_percentage', 'estimated_rum_sessions_usage', 'estimated_rum_sessions_percentage', 'universal_service_monitoring_usage', 'universal_service_monitoring_percentage', 'vuln_management_hosts_usage', 'vuln_management_hosts_percentage', 'sds_scanned_bytes_usage', 'sds_scanned_bytes_percentage', '*']
|
476
476
|
if @api_client.config.client_side_validation && !allowable_values.include?(fields)
|
477
477
|
fail ArgumentError, "invalid value for \"fields\", must be one of #{allowable_values}"
|
478
478
|
end
|
@@ -480,7 +480,7 @@ module DatadogAPIClient::V1
|
|
480
480
|
if @api_client.config.client_side_validation && opts[:'sort_direction'] && !allowable_values.include?(opts[:'sort_direction'])
|
481
481
|
fail ArgumentError, "invalid value for \"sort_direction\", must be one of #{allowable_values}"
|
482
482
|
end
|
483
|
-
allowable_values = ['api_usage', 'api_percentage', 'apm_fargate_usage', 'apm_fargate_percentage', 'appsec_fargate_usage', 'appsec_fargate_percentage', 'apm_host_usage', 'apm_host_percentage', 'apm_usm_usage', 'apm_usm_percentage', 'appsec_usage', 'appsec_percentage', 'browser_usage', 'browser_percentage', 'ci_visibility_itr_usage', 'ci_visibility_itr_percentage', 'container_excl_agent_usage', 'container_excl_agent_percentage', 'container_usage', 'container_percentage', 'cspm_containers_percentage', 'cspm_containers_usage', 'cspm_hosts_percentage', 'cspm_hosts_usage', 'custom_timeseries_usage', 'custom_timeseries_percentage', 'custom_ingested_timeseries_usage', 'custom_ingested_timeseries_percentage', 'cws_containers_percentage', 'cws_containers_usage', 'cws_hosts_percentage', 'cws_hosts_usage', 'dbm_hosts_percentage', 'dbm_hosts_usage', 'dbm_queries_percentage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_indexed_logs_percentage', 'estimated_ingested_logs_usage', 'estimated_ingested_logs_percentage', 'estimated_indexed_spans_usage', 'estimated_indexed_spans_percentage', 'estimated_ingested_spans_usage', 'estimated_ingested_spans_percentage', 'fargate_usage', 'fargate_percentage', 'functions_usage', 'functions_percentage', 'infra_host_usage', 'infra_host_percentage', 'invocations_usage', 'invocations_percentage', 'npm_host_usage', 'npm_host_percentage', 'obs_pipeline_bytes_usage', 'obs_pipeline_bytes_percentage', 'profiled_container_usage', 'profiled_container_percentage', 'profiled_fargate_usage', 'profiled_fargate_percentage', 'profiled_host_usage', 'profiled_host_percentage', 'snmp_usage', 'snmp_percentage', 'estimated_rum_sessions_usage', 'estimated_rum_sessions_percentage', 'universal_service_monitoring_usage', 'universal_service_monitoring_percentage', 'vuln_management_hosts_usage', 'vuln_management_hosts_percentage', 'sds_scanned_bytes_usage', 'sds_scanned_bytes_percentage', '*']
|
483
|
+
allowable_values = ['api_usage', 'api_percentage', 'apm_fargate_usage', 'apm_fargate_percentage', 'appsec_fargate_usage', 'appsec_fargate_percentage', 'apm_host_usage', 'apm_host_percentage', 'apm_usm_usage', 'apm_usm_percentage', 'appsec_usage', 'appsec_percentage', 'browser_usage', 'browser_percentage', 'ci_visibility_itr_usage', 'ci_visibility_itr_percentage', 'container_excl_agent_usage', 'container_excl_agent_percentage', 'container_usage', 'container_percentage', 'cspm_containers_percentage', 'cspm_containers_usage', 'cspm_hosts_percentage', 'cspm_hosts_usage', 'custom_timeseries_usage', 'custom_timeseries_percentage', 'custom_ingested_timeseries_usage', 'custom_ingested_timeseries_percentage', 'cws_containers_percentage', 'cws_containers_usage', 'cws_hosts_percentage', 'cws_hosts_usage', 'dbm_hosts_percentage', 'dbm_hosts_usage', 'dbm_queries_percentage', 'dbm_queries_usage', 'estimated_indexed_logs_usage', 'estimated_indexed_logs_percentage', 'estimated_ingested_logs_usage', 'estimated_ingested_logs_percentage', 'estimated_indexed_spans_usage', 'estimated_indexed_spans_percentage', 'estimated_ingested_spans_usage', 'estimated_ingested_spans_percentage', 'fargate_usage', 'fargate_percentage', 'functions_usage', 'functions_percentage', 'infra_host_usage', 'infra_host_percentage', 'invocations_usage', 'invocations_percentage', 'mobile_app_testing_percentage', 'mobile_app_testing_usage', 'npm_host_usage', 'npm_host_percentage', 'obs_pipeline_bytes_usage', 'obs_pipeline_bytes_percentage', 'profiled_container_usage', 'profiled_container_percentage', 'profiled_fargate_usage', 'profiled_fargate_percentage', 'profiled_host_usage', 'profiled_host_percentage', 'snmp_usage', 'snmp_percentage', 'estimated_rum_sessions_usage', 'estimated_rum_sessions_percentage', 'universal_service_monitoring_usage', 'universal_service_monitoring_percentage', 'vuln_management_hosts_usage', 'vuln_management_hosts_percentage', 'sds_scanned_bytes_usage', 'sds_scanned_bytes_percentage', '*']
|
484
484
|
if @api_client.config.client_side_validation && opts[:'sort_name'] && !allowable_values.include?(opts[:'sort_name'])
|
485
485
|
fail ArgumentError, "invalid value for \"sort_name\", must be one of #{allowable_values}"
|
486
486
|
end
|