datadog_api_client 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.apigentools-info +6 -6
- data/.generator/templates/api.mustache +2 -2
- data/.generator/templates/api_client.mustache +7 -0
- data/.generator/templates/api_client_typhoeus_partial.mustache +7 -0
- data/.generator/templates/configuration.mustache +4 -0
- data/.openapi-generator/VERSION +1 -1
- data/CHANGELOG.md +27 -0
- data/README.md +12 -1
- data/data/v1/openapi.yaml +866 -119
- data/data/v2/openapi.yaml +113 -0
- data/docs/v1/AWSAccount.md +6 -0
- data/docs/v1/DowntimeRecurrence.md +1 -1
- data/docs/v1/Event.md +1 -1
- data/docs/v1/FormulaAndFunctionApmDependencyStatName.md +15 -0
- data/docs/v1/FormulaAndFunctionApmDependencyStatsDataSource.md +15 -0
- data/docs/v1/FormulaAndFunctionApmDependencyStatsQueryDefinition.md +36 -0
- data/docs/v1/FormulaAndFunctionApmResourceStatName.md +15 -0
- data/docs/v1/FormulaAndFunctionApmResourceStatsDataSource.md +15 -0
- data/docs/v1/FormulaAndFunctionApmResourceStatsQueryDefinition.md +36 -0
- data/docs/v1/FormulaAndFunctionQueryDefinition.md +5 -1
- data/docs/v1/FunnelQuery.md +22 -0
- data/docs/v1/FunnelRequestType.md +15 -0
- data/docs/v1/FunnelSource.md +15 -0
- data/docs/v1/FunnelWidgetDefinition.md +28 -0
- data/docs/v1/FunnelWidgetDefinitionType.md +15 -0
- data/docs/v1/FunnelWidgetRequest.md +20 -0
- data/docs/v1/LogsAPI.md +1 -1
- data/docs/v1/MetricContentEncoding.md +15 -0
- data/docs/v1/MetricsAPI.md +10 -6
- data/docs/v1/MetricsPayload.md +1 -1
- data/docs/v1/MonitorOptions.md +5 -1
- data/docs/v1/MonitorRenotifyStatusType.md +15 -0
- data/docs/v1/MonitorsAPI.md +9 -9
- data/docs/v1/NotebookCreateDataAttributes.md +2 -0
- data/docs/v1/NotebookMetadata.md +22 -0
- data/docs/v1/NotebookMetadataType.md +15 -0
- data/docs/v1/NotebookResponseDataAttributes.md +2 -0
- data/docs/v1/NotebookUpdateDataAttributes.md +2 -0
- data/docs/v1/NotebooksAPI.md +7 -3
- data/docs/v1/NotebooksResponseDataAttributes.md +2 -0
- data/docs/v1/ProcessQueryDefinition.md +1 -1
- data/docs/v1/README.md +31 -3
- data/docs/v1/SLOCorrection.md +1 -1
- data/docs/v1/SLOCorrectionCreateData.md +1 -1
- data/docs/v1/SLOCorrectionCreateRequestAttributes.md +4 -4
- data/docs/v1/SLOCorrectionListResponse.md +1 -1
- data/docs/v1/SLOCorrectionResponseAttributes.md +4 -4
- data/docs/v1/SLOCorrectionUpdateRequestAttributes.md +3 -3
- data/docs/v1/ScatterPlotWidgetDefinitionRequests.md +4 -2
- data/docs/v1/ScatterplotDimension.md +15 -0
- data/docs/v1/ScatterplotTableRequest.md +22 -0
- data/docs/v1/ScatterplotWidgetFormula.md +22 -0
- data/docs/v1/Series.md +1 -1
- data/docs/v1/ServiceChecksAPI.md +1 -1
- data/docs/v1/ServiceLevelObjectiveCorrectionsAPI.md +11 -11
- data/docs/v1/SyntheticsAPI.md +61 -0
- data/docs/v1/SyntheticsAPIStep.md +1 -1
- data/docs/v1/SyntheticsBatchDetails.md +18 -0
- data/docs/v1/SyntheticsBatchDetailsData.md +22 -0
- data/docs/v1/SyntheticsBatchResult.md +36 -0
- data/docs/v1/SyntheticsBrowserError.md +3 -3
- data/docs/v1/SyntheticsCIBatchMetadata.md +20 -0
- data/docs/v1/{SyntheticsCITestMetadataCi.md → SyntheticsCIBatchMetadataCI.md} +2 -2
- data/docs/v1/SyntheticsCIBatchMetadataGit.md +20 -0
- data/docs/v1/SyntheticsCITest.md +1 -1
- data/docs/v1/SyntheticsStatus.md +15 -0
- data/docs/v1/SyntheticsTestDetails.md +2 -0
- data/docs/v1/SyntheticsTestExecutionRule.md +15 -0
- data/docs/v1/SyntheticsTestRequest.md +2 -0
- data/docs/v1/UsageAttributionValues.md +4 -4
- data/docs/v1/UsageMeteringAPI.md +65 -0
- data/docs/v1/UsageSDSHour.md +22 -0
- data/docs/v1/UsageSDSResponse.md +18 -0
- data/docs/v1/UsageSummaryDate.md +4 -0
- data/docs/v1/UsageSummaryDateOrg.md +6 -2
- data/docs/v1/UsageSummaryResponse.md +6 -2
- data/docs/v1/UsageTimeseriesHour.md +1 -1
- data/docs/v1/WebhooksIntegration.md +1 -1
- data/docs/v1/WebhooksIntegrationUpdateRequest.md +1 -1
- data/docs/v1/WidgetDefinition.md +2 -0
- data/docs/v2/IncidentServicesAPI.md +5 -5
- data/docs/v2/IncidentTeamsAPI.md +5 -5
- data/docs/v2/IncidentsAPI.md +5 -5
- data/docs/v2/README.md +5 -0
- data/docs/v2/SecurityMonitoringAPI.md +5 -5
- data/examples/v1/metrics/SubmitMetrics.rbbeta +14 -0
- data/extract-code-blocks.awk +4 -0
- data/lib/datadog_api_client/v1/api/logs_api.rb +1 -1
- data/lib/datadog_api_client/v1/api/metrics_api.rb +5 -2
- data/lib/datadog_api_client/v1/api/monitors_api.rb +9 -9
- data/lib/datadog_api_client/v1/api/notebooks_api.rb +8 -2
- data/lib/datadog_api_client/v1/api/service_checks_api.rb +1 -1
- data/lib/datadog_api_client/v1/api/service_level_objective_corrections_api.rb +16 -16
- data/lib/datadog_api_client/v1/api/synthetics_api.rb +73 -0
- data/lib/datadog_api_client/v1/api/usage_metering_api.rb +77 -0
- data/lib/datadog_api_client/v1/api_client.rb +14 -0
- data/lib/datadog_api_client/v1/configuration.rb +7 -0
- data/lib/datadog_api_client/v1/models/aws_account.rb +37 -1
- data/lib/datadog_api_client/v1/models/content_encoding.rb +2 -2
- data/lib/datadog_api_client/v1/models/creator.rb +1 -0
- data/lib/datadog_api_client/v1/models/dashboard_summary_definition.rb +1 -0
- data/lib/datadog_api_client/v1/models/downtime_recurrence.rb +1 -1
- data/lib/datadog_api_client/v1/models/event.rb +1 -16
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_dependency_stat_name.rb +44 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_dependency_stats_data_source.rb +38 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_dependency_stats_query_definition.rb +356 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_resource_stat_name.rb +47 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_resource_stats_data_source.rb +38 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_apm_resource_stats_query_definition.rb +348 -0
- data/lib/datadog_api_client/v1/models/formula_and_function_query_definition.rb +2 -0
- data/lib/datadog_api_client/v1/models/funnel_query.rb +271 -0
- data/lib/datadog_api_client/v1/models/funnel_request_type.rb +38 -0
- data/lib/datadog_api_client/v1/models/funnel_source.rb +38 -0
- data/lib/datadog_api_client/v1/models/funnel_widget_definition.rb +322 -0
- data/lib/datadog_api_client/v1/models/funnel_widget_definition_type.rb +38 -0
- data/lib/datadog_api_client/v1/models/funnel_widget_request.rb +251 -0
- data/lib/datadog_api_client/v1/models/metric_content_encoding.rb +38 -0
- data/lib/datadog_api_client/v1/models/metrics_query_metadata.rb +1 -0
- data/lib/datadog_api_client/v1/models/monitor.rb +2 -0
- data/lib/datadog_api_client/v1/models/monitor_options.rb +26 -2
- data/lib/datadog_api_client/v1/models/monitor_renotify_status_type.rb +40 -0
- data/lib/datadog_api_client/v1/models/notebook_author.rb +2 -0
- data/lib/datadog_api_client/v1/models/notebook_create_data_attributes.rb +10 -1
- data/lib/datadog_api_client/v1/models/notebook_metadata.rb +259 -0
- data/lib/datadog_api_client/v1/models/notebook_metadata_type.rb +42 -0
- data/lib/datadog_api_client/v1/models/notebook_response_data_attributes.rb +10 -1
- data/lib/datadog_api_client/v1/models/notebook_update_data_attributes.rb +10 -1
- data/lib/datadog_api_client/v1/models/notebooks_response_data_attributes.rb +10 -1
- data/lib/datadog_api_client/v1/models/notebooks_response_meta.rb +1 -1
- data/lib/datadog_api_client/v1/models/scatter_plot_widget_definition_requests.rb +10 -11
- data/lib/datadog_api_client/v1/models/scatterplot_dimension.rb +41 -0
- data/lib/datadog_api_client/v1/models/scatterplot_table_request.rb +256 -0
- data/lib/datadog_api_client/v1/models/scatterplot_widget_formula.rb +262 -0
- data/lib/datadog_api_client/v1/models/slo_correction.rb +2 -2
- data/lib/datadog_api_client/v1/models/slo_correction_create_data.rb +6 -1
- data/lib/datadog_api_client/v1/models/slo_correction_create_request.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_create_request_attributes.rb +5 -5
- data/lib/datadog_api_client/v1/models/slo_correction_list_response.rb +2 -2
- data/lib/datadog_api_client/v1/models/slo_correction_response.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_response_attributes.rb +5 -5
- data/lib/datadog_api_client/v1/models/slo_correction_update_data.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_update_request.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_update_request_attributes.rb +4 -4
- data/lib/datadog_api_client/v1/models/synthetics_batch_details.rb +232 -0
- data/lib/datadog_api_client/v1/models/synthetics_batch_details_data.rb +253 -0
- data/lib/datadog_api_client/v1/models/synthetics_batch_result.rb +319 -0
- data/lib/datadog_api_client/v1/models/{synthetics_ci_test_metadata.rb → synthetics_ci_batch_metadata.rb} +6 -6
- data/lib/datadog_api_client/v1/models/{synthetics_ci_test_metadata_ci.rb → synthetics_ci_batch_metadata_ci.rb} +4 -4
- data/lib/datadog_api_client/v1/models/{synthetics_ci_test_metadata_git.rb → synthetics_ci_batch_metadata_git.rb} +5 -5
- data/lib/datadog_api_client/v1/models/synthetics_ci_test.rb +1 -1
- data/lib/datadog_api_client/v1/models/synthetics_status.rb +40 -0
- data/lib/datadog_api_client/v1/models/synthetics_test_details.rb +10 -1
- data/lib/datadog_api_client/v1/models/synthetics_test_execution_rule.rb +40 -0
- data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_attribution_values.rb +13 -13
- data/lib/datadog_api_client/v1/models/usage_sds_hour.rb +253 -0
- data/lib/datadog_api_client/v1/models/usage_sds_response.rb +235 -0
- 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 +28 -8
- data/lib/datadog_api_client/v1/models/usage_summary_response.rb +29 -9
- data/lib/datadog_api_client/v1/models/usage_timeseries_hour.rb +1 -1
- data/lib/datadog_api_client/v1/models/webhooks_integration.rb +1 -1
- data/lib/datadog_api_client/v1/models/webhooks_integration_update_request.rb +1 -1
- data/lib/datadog_api_client/v1/models/widget_definition.rb +1 -0
- data/lib/datadog_api_client/v1.rb +29 -3
- data/lib/datadog_api_client/v2/api/incident_services_api.rb +5 -5
- data/lib/datadog_api_client/v2/api/incident_teams_api.rb +5 -5
- data/lib/datadog_api_client/v2/api/incidents_api.rb +5 -5
- data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +5 -5
- data/lib/datadog_api_client/v2/api_client.rb +14 -0
- data/lib/datadog_api_client/v2/configuration.rb +5 -0
- data/lib/datadog_api_client/v2/models/incident_field_attributes_multiple_value.rb +1 -0
- data/lib/datadog_api_client/v2/models/incident_field_attributes_single_value.rb +1 -0
- data/lib/datadog_api_client/v2/models/incident_response_attributes.rb +1 -0
- data/lib/datadog_api_client/v2/models/user_attributes.rb +2 -0
- data/lib/datadog_api_client/version.rb +1 -1
- data/spec/v1/models/formula_and_function_apm_dependency_stat_name_spec.rb +31 -0
- data/spec/v1/models/formula_and_function_apm_dependency_stats_data_source_spec.rb +31 -0
- data/spec/v1/models/formula_and_function_apm_dependency_stats_query_definition_spec.rb +91 -0
- data/spec/v1/models/formula_and_function_apm_resource_stat_name_spec.rb +31 -0
- data/spec/v1/models/formula_and_function_apm_resource_stats_data_source_spec.rb +31 -0
- data/spec/v1/models/formula_and_function_apm_resource_stats_query_definition_spec.rb +91 -0
- data/spec/v1/models/funnel_query_spec.rb +49 -0
- data/spec/v1/models/funnel_request_type_spec.rb +31 -0
- data/spec/v1/models/funnel_source_spec.rb +31 -0
- data/spec/v1/models/funnel_widget_definition_spec.rb +67 -0
- data/spec/v1/models/funnel_widget_definition_type_spec.rb +31 -0
- data/spec/v1/models/funnel_widget_request_spec.rb +43 -0
- data/spec/v1/models/metric_content_encoding_spec.rb +31 -0
- data/spec/v1/models/monitor_renotify_status_type_spec.rb +31 -0
- data/spec/v1/models/notebook_metadata_spec.rb +49 -0
- data/spec/v1/models/notebook_metadata_type_spec.rb +31 -0
- data/spec/v1/models/scatterplot_dimension_spec.rb +31 -0
- data/spec/v1/models/scatterplot_table_request_spec.rb +49 -0
- data/spec/v1/models/scatterplot_widget_formula_spec.rb +49 -0
- data/spec/v1/models/synthetics_batch_details_data_spec.rb +49 -0
- data/spec/v1/models/synthetics_batch_details_spec.rb +37 -0
- data/spec/v1/models/synthetics_batch_result_spec.rb +91 -0
- data/spec/v1/models/{synthetics_ci_test_metadata_ci_spec.rb → synthetics_ci_batch_metadata_ci_spec.rb} +6 -6
- data/spec/v1/models/{synthetics_ci_test_metadata_git_spec.rb → synthetics_ci_batch_metadata_git_spec.rb} +6 -6
- data/spec/v1/models/{synthetics_ci_test_metadata_spec.rb → synthetics_ci_batch_metadata_spec.rb} +6 -6
- data/spec/v1/models/synthetics_status_spec.rb +31 -0
- data/spec/v1/models/synthetics_test_execution_rule_spec.rb +31 -0
- data/spec/v1/models/usage_sds_hour_spec.rb +49 -0
- data/spec/v1/models/usage_sds_response_spec.rb +37 -0
- metadata +119 -14
- data/docs/v1/SyntheticsCITestMetadata.md +0 -20
- data/docs/v1/SyntheticsCITestMetadataGit.md +0 -20
|
@@ -22,6 +22,8 @@ module DatadogAPIClient::V1
|
|
|
22
22
|
# whether the object has unparsed attributes
|
|
23
23
|
attr_accessor :_unparsed
|
|
24
24
|
|
|
25
|
+
attr_accessor :table
|
|
26
|
+
|
|
25
27
|
attr_accessor :x
|
|
26
28
|
|
|
27
29
|
attr_accessor :y
|
|
@@ -29,6 +31,7 @@ module DatadogAPIClient::V1
|
|
|
29
31
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
30
32
|
def self.attribute_map
|
|
31
33
|
{
|
|
34
|
+
:'table' => :'table',
|
|
32
35
|
:'x' => :'x',
|
|
33
36
|
:'y' => :'y'
|
|
34
37
|
}
|
|
@@ -42,6 +45,7 @@ module DatadogAPIClient::V1
|
|
|
42
45
|
# Attribute type mapping.
|
|
43
46
|
def self.openapi_types
|
|
44
47
|
{
|
|
48
|
+
:'table' => :'ScatterplotTableRequest',
|
|
45
49
|
:'x' => :'ScatterPlotRequest',
|
|
46
50
|
:'y' => :'ScatterPlotRequest'
|
|
47
51
|
}
|
|
@@ -68,6 +72,10 @@ module DatadogAPIClient::V1
|
|
|
68
72
|
h[k.to_sym] = v
|
|
69
73
|
}
|
|
70
74
|
|
|
75
|
+
if attributes.key?(:'table')
|
|
76
|
+
self.table = attributes[:'table']
|
|
77
|
+
end
|
|
78
|
+
|
|
71
79
|
if attributes.key?(:'x')
|
|
72
80
|
self.x = attributes[:'x']
|
|
73
81
|
end
|
|
@@ -81,22 +89,12 @@ module DatadogAPIClient::V1
|
|
|
81
89
|
# @return Array for valid properties with the reasons
|
|
82
90
|
def list_invalid_properties
|
|
83
91
|
invalid_properties = Array.new
|
|
84
|
-
if @x.nil?
|
|
85
|
-
invalid_properties.push('invalid value for "x", x cannot be nil.')
|
|
86
|
-
end
|
|
87
|
-
|
|
88
|
-
if @y.nil?
|
|
89
|
-
invalid_properties.push('invalid value for "y", y cannot be nil.')
|
|
90
|
-
end
|
|
91
|
-
|
|
92
92
|
invalid_properties
|
|
93
93
|
end
|
|
94
94
|
|
|
95
95
|
# Check to see if the all the properties in the model are valid
|
|
96
96
|
# @return true if the model is valid
|
|
97
97
|
def valid?
|
|
98
|
-
return false if @x.nil?
|
|
99
|
-
return false if @y.nil?
|
|
100
98
|
true
|
|
101
99
|
end
|
|
102
100
|
|
|
@@ -105,6 +103,7 @@ module DatadogAPIClient::V1
|
|
|
105
103
|
def ==(o)
|
|
106
104
|
return true if self.equal?(o)
|
|
107
105
|
self.class == o.class &&
|
|
106
|
+
table == o.table &&
|
|
108
107
|
x == o.x &&
|
|
109
108
|
y == o.y
|
|
110
109
|
end
|
|
@@ -118,7 +117,7 @@ module DatadogAPIClient::V1
|
|
|
118
117
|
# Calculates hash code according to all attributes.
|
|
119
118
|
# @return [Integer] Hash code
|
|
120
119
|
def hash
|
|
121
|
-
[x, y].hash
|
|
120
|
+
[table, x, y].hash
|
|
122
121
|
end
|
|
123
122
|
|
|
124
123
|
# Builds the object from hash
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V1 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V1
|
|
20
|
+
class ScatterplotDimension
|
|
21
|
+
X = "x".freeze
|
|
22
|
+
Y = "y".freeze
|
|
23
|
+
RADIUS = "radius".freeze
|
|
24
|
+
COLOR = "color".freeze
|
|
25
|
+
|
|
26
|
+
# Builds the enum from string
|
|
27
|
+
# @param [String] The enum value in the form of the string
|
|
28
|
+
# @return [String] The enum value
|
|
29
|
+
def self.build_from_hash(value)
|
|
30
|
+
new.build_from_hash(value)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Builds the enum from string
|
|
34
|
+
# @param [String] The enum value in the form of the string
|
|
35
|
+
# @return [String] The enum value
|
|
36
|
+
def build_from_hash(value)
|
|
37
|
+
constantValues = ScatterplotDimension.constants.select { |c| ScatterplotDimension::const_get(c) == value }
|
|
38
|
+
constantValues.empty? ? DatadogAPIClient::V1::UnparsedObject.new(value) : value
|
|
39
|
+
end
|
|
40
|
+
end
|
|
41
|
+
end
|
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V1 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V1
|
|
20
|
+
# Scatterplot request containing formulas and functions.
|
|
21
|
+
class ScatterplotTableRequest
|
|
22
|
+
# whether the object has unparsed attributes
|
|
23
|
+
attr_accessor :_unparsed
|
|
24
|
+
|
|
25
|
+
# List of Scatterplot formulas that operate on queries. **This feature is currently in beta.**
|
|
26
|
+
attr_accessor :formulas
|
|
27
|
+
|
|
28
|
+
# List of queries that can be returned directly or used in formulas. **This feature is currently in beta.**
|
|
29
|
+
attr_accessor :queries
|
|
30
|
+
|
|
31
|
+
attr_accessor :response_format
|
|
32
|
+
|
|
33
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
34
|
+
def self.attribute_map
|
|
35
|
+
{
|
|
36
|
+
:'formulas' => :'formulas',
|
|
37
|
+
:'queries' => :'queries',
|
|
38
|
+
:'response_format' => :'response_format'
|
|
39
|
+
}
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
# Returns all the JSON keys this model knows about
|
|
43
|
+
def self.acceptable_attributes
|
|
44
|
+
attribute_map.values
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
# Attribute type mapping.
|
|
48
|
+
def self.openapi_types
|
|
49
|
+
{
|
|
50
|
+
:'formulas' => :'Array<ScatterplotWidgetFormula>',
|
|
51
|
+
:'queries' => :'Array<FormulaAndFunctionQueryDefinition>',
|
|
52
|
+
:'response_format' => :'FormulaAndFunctionResponseFormat'
|
|
53
|
+
}
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# List of attributes with nullable: true
|
|
57
|
+
def self.openapi_nullable
|
|
58
|
+
Set.new([
|
|
59
|
+
])
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# Initializes the object
|
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
64
|
+
def initialize(attributes = {})
|
|
65
|
+
if (!attributes.is_a?(Hash))
|
|
66
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::ScatterplotTableRequest` initialize method"
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
70
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
71
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
72
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::ScatterplotTableRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
73
|
+
end
|
|
74
|
+
h[k.to_sym] = v
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if attributes.key?(:'formulas')
|
|
78
|
+
if (value = attributes[:'formulas']).is_a?(Array)
|
|
79
|
+
self.formulas = value
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
if attributes.key?(:'queries')
|
|
84
|
+
if (value = attributes[:'queries']).is_a?(Array)
|
|
85
|
+
self.queries = value
|
|
86
|
+
end
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
if attributes.key?(:'response_format')
|
|
90
|
+
self.response_format = attributes[:'response_format']
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
95
|
+
# @return Array for valid properties with the reasons
|
|
96
|
+
def list_invalid_properties
|
|
97
|
+
invalid_properties = Array.new
|
|
98
|
+
invalid_properties
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
# Check to see if the all the properties in the model are valid
|
|
102
|
+
# @return true if the model is valid
|
|
103
|
+
def valid?
|
|
104
|
+
true
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# Checks equality by comparing each attribute.
|
|
108
|
+
# @param [Object] Object to be compared
|
|
109
|
+
def ==(o)
|
|
110
|
+
return true if self.equal?(o)
|
|
111
|
+
self.class == o.class &&
|
|
112
|
+
formulas == o.formulas &&
|
|
113
|
+
queries == o.queries &&
|
|
114
|
+
response_format == o.response_format
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
# @see the `==` method
|
|
118
|
+
# @param [Object] Object to be compared
|
|
119
|
+
def eql?(o)
|
|
120
|
+
self == o
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# Calculates hash code according to all attributes.
|
|
124
|
+
# @return [Integer] Hash code
|
|
125
|
+
def hash
|
|
126
|
+
[formulas, queries, response_format].hash
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Builds the object from hash
|
|
130
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
131
|
+
# @return [Object] Returns the model itself
|
|
132
|
+
def self.build_from_hash(attributes)
|
|
133
|
+
new.build_from_hash(attributes)
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# Builds the object from hash
|
|
137
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
138
|
+
# @return [Object] Returns the model itself
|
|
139
|
+
def build_from_hash(attributes)
|
|
140
|
+
return nil unless attributes.is_a?(Hash)
|
|
141
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
142
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
|
143
|
+
self.send("#{key}=", nil)
|
|
144
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
145
|
+
# check to ensure the input is an array given that the attribute
|
|
146
|
+
# is documented as an array but the input is not
|
|
147
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
148
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
149
|
+
end
|
|
150
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
151
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
152
|
+
end
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
self
|
|
156
|
+
end
|
|
157
|
+
|
|
158
|
+
# Deserializes the data based on type
|
|
159
|
+
# @param string type Data type
|
|
160
|
+
# @param string value Value to be deserialized
|
|
161
|
+
# @return [Object] Deserialized data
|
|
162
|
+
def _deserialize(type, value)
|
|
163
|
+
case type.to_sym
|
|
164
|
+
when :Time
|
|
165
|
+
Time.parse(value)
|
|
166
|
+
when :Date
|
|
167
|
+
Date.parse(value)
|
|
168
|
+
when :String
|
|
169
|
+
value.to_s
|
|
170
|
+
when :Integer
|
|
171
|
+
value.to_i
|
|
172
|
+
when :Float
|
|
173
|
+
value.to_f
|
|
174
|
+
when :Boolean
|
|
175
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
176
|
+
true
|
|
177
|
+
else
|
|
178
|
+
false
|
|
179
|
+
end
|
|
180
|
+
when :Object
|
|
181
|
+
# generic object (usually a Hash), return directly
|
|
182
|
+
value
|
|
183
|
+
when :Array
|
|
184
|
+
# generic array, return directly
|
|
185
|
+
value
|
|
186
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
187
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
188
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
189
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
190
|
+
k_type = Regexp.last_match[:k_type]
|
|
191
|
+
v_type = Regexp.last_match[:v_type]
|
|
192
|
+
{}.tap do |hash|
|
|
193
|
+
value.each do |k, v|
|
|
194
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
195
|
+
end
|
|
196
|
+
end
|
|
197
|
+
else # model
|
|
198
|
+
# models (e.g. Pet) or oneOf
|
|
199
|
+
klass = DatadogAPIClient::V1.const_get(type)
|
|
200
|
+
res = klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
201
|
+
if res.instance_of? DatadogAPIClient::V1::UnparsedObject
|
|
202
|
+
self._unparsed = true
|
|
203
|
+
end
|
|
204
|
+
res
|
|
205
|
+
end
|
|
206
|
+
end
|
|
207
|
+
|
|
208
|
+
# Returns the string representation of the object
|
|
209
|
+
# @return [String] String presentation of the object
|
|
210
|
+
def to_s
|
|
211
|
+
to_hash.to_s
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
215
|
+
# @return [Hash] Returns the object in the form of hash
|
|
216
|
+
def to_body
|
|
217
|
+
to_hash
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
# Returns the object in the form of hash
|
|
221
|
+
# @return [Hash] Returns the object in the form of hash
|
|
222
|
+
def to_hash
|
|
223
|
+
hash = {}
|
|
224
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
225
|
+
value = self.send(attr)
|
|
226
|
+
if value.nil?
|
|
227
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
228
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
hash[param] = _to_hash(value)
|
|
232
|
+
end
|
|
233
|
+
hash
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
# Outputs non-array value in the form of hash
|
|
237
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
238
|
+
# @param [Object] value Any valid value
|
|
239
|
+
# @return [Hash] Returns the value in the form of hash
|
|
240
|
+
def _to_hash(value)
|
|
241
|
+
if value.is_a?(Array)
|
|
242
|
+
value.compact.map { |v| _to_hash(v) }
|
|
243
|
+
elsif value.is_a?(Hash)
|
|
244
|
+
{}.tap do |hash|
|
|
245
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
246
|
+
end
|
|
247
|
+
elsif value.respond_to? :to_hash
|
|
248
|
+
value.to_hash
|
|
249
|
+
else
|
|
250
|
+
value
|
|
251
|
+
end
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
end
|
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Datadog API V1 Collection
|
|
3
|
+
|
|
4
|
+
#Collection of all Datadog Public endpoints.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0
|
|
7
|
+
Contact: support@datadoghq.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
|
|
10
|
+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
|
|
11
|
+
This product includes software developed at Datadog (https://www.datadoghq.com/).
|
|
12
|
+
Copyright 2020-Present Datadog, Inc.
|
|
13
|
+
|
|
14
|
+
=end
|
|
15
|
+
|
|
16
|
+
require 'date'
|
|
17
|
+
require 'time'
|
|
18
|
+
|
|
19
|
+
module DatadogAPIClient::V1
|
|
20
|
+
# Formula to be used in a Scatterplot widget query.
|
|
21
|
+
class ScatterplotWidgetFormula
|
|
22
|
+
# whether the object has unparsed attributes
|
|
23
|
+
attr_accessor :_unparsed
|
|
24
|
+
|
|
25
|
+
# Expression alias.
|
|
26
|
+
attr_accessor :_alias
|
|
27
|
+
|
|
28
|
+
attr_accessor :dimension
|
|
29
|
+
|
|
30
|
+
# String expression built from queries, formulas, and functions.
|
|
31
|
+
attr_accessor :formula
|
|
32
|
+
|
|
33
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
34
|
+
def self.attribute_map
|
|
35
|
+
{
|
|
36
|
+
:'_alias' => :'alias',
|
|
37
|
+
:'dimension' => :'dimension',
|
|
38
|
+
:'formula' => :'formula'
|
|
39
|
+
}
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
# Returns all the JSON keys this model knows about
|
|
43
|
+
def self.acceptable_attributes
|
|
44
|
+
attribute_map.values
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
# Attribute type mapping.
|
|
48
|
+
def self.openapi_types
|
|
49
|
+
{
|
|
50
|
+
:'_alias' => :'String',
|
|
51
|
+
:'dimension' => :'ScatterplotDimension',
|
|
52
|
+
:'formula' => :'String'
|
|
53
|
+
}
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# List of attributes with nullable: true
|
|
57
|
+
def self.openapi_nullable
|
|
58
|
+
Set.new([
|
|
59
|
+
])
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# Initializes the object
|
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
64
|
+
def initialize(attributes = {})
|
|
65
|
+
if (!attributes.is_a?(Hash))
|
|
66
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::ScatterplotWidgetFormula` initialize method"
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
70
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
71
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
72
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::ScatterplotWidgetFormula`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
73
|
+
end
|
|
74
|
+
h[k.to_sym] = v
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if attributes.key?(:'_alias')
|
|
78
|
+
self._alias = attributes[:'_alias']
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
if attributes.key?(:'dimension')
|
|
82
|
+
self.dimension = attributes[:'dimension']
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
if attributes.key?(:'formula')
|
|
86
|
+
self.formula = attributes[:'formula']
|
|
87
|
+
end
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
91
|
+
# @return Array for valid properties with the reasons
|
|
92
|
+
def list_invalid_properties
|
|
93
|
+
invalid_properties = Array.new
|
|
94
|
+
if @dimension.nil?
|
|
95
|
+
invalid_properties.push('invalid value for "dimension", dimension cannot be nil.')
|
|
96
|
+
end
|
|
97
|
+
|
|
98
|
+
if @formula.nil?
|
|
99
|
+
invalid_properties.push('invalid value for "formula", formula cannot be nil.')
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
invalid_properties
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
# Check to see if the all the properties in the model are valid
|
|
106
|
+
# @return true if the model is valid
|
|
107
|
+
def valid?
|
|
108
|
+
return false if @dimension.nil?
|
|
109
|
+
return false if @formula.nil?
|
|
110
|
+
true
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# Checks equality by comparing each attribute.
|
|
114
|
+
# @param [Object] Object to be compared
|
|
115
|
+
def ==(o)
|
|
116
|
+
return true if self.equal?(o)
|
|
117
|
+
self.class == o.class &&
|
|
118
|
+
_alias == o._alias &&
|
|
119
|
+
dimension == o.dimension &&
|
|
120
|
+
formula == o.formula
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# @see the `==` method
|
|
124
|
+
# @param [Object] Object to be compared
|
|
125
|
+
def eql?(o)
|
|
126
|
+
self == o
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Calculates hash code according to all attributes.
|
|
130
|
+
# @return [Integer] Hash code
|
|
131
|
+
def hash
|
|
132
|
+
[_alias, dimension, formula].hash
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Builds the object from hash
|
|
136
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
137
|
+
# @return [Object] Returns the model itself
|
|
138
|
+
def self.build_from_hash(attributes)
|
|
139
|
+
new.build_from_hash(attributes)
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
# Builds the object from hash
|
|
143
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
144
|
+
# @return [Object] Returns the model itself
|
|
145
|
+
def build_from_hash(attributes)
|
|
146
|
+
return nil unless attributes.is_a?(Hash)
|
|
147
|
+
self.class.openapi_types.each_pair do |key, type|
|
|
148
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
|
149
|
+
self.send("#{key}=", nil)
|
|
150
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
151
|
+
# check to ensure the input is an array given that the attribute
|
|
152
|
+
# is documented as an array but the input is not
|
|
153
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
154
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
155
|
+
end
|
|
156
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
157
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
158
|
+
end
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
self
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
# Deserializes the data based on type
|
|
165
|
+
# @param string type Data type
|
|
166
|
+
# @param string value Value to be deserialized
|
|
167
|
+
# @return [Object] Deserialized data
|
|
168
|
+
def _deserialize(type, value)
|
|
169
|
+
case type.to_sym
|
|
170
|
+
when :Time
|
|
171
|
+
Time.parse(value)
|
|
172
|
+
when :Date
|
|
173
|
+
Date.parse(value)
|
|
174
|
+
when :String
|
|
175
|
+
value.to_s
|
|
176
|
+
when :Integer
|
|
177
|
+
value.to_i
|
|
178
|
+
when :Float
|
|
179
|
+
value.to_f
|
|
180
|
+
when :Boolean
|
|
181
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
182
|
+
true
|
|
183
|
+
else
|
|
184
|
+
false
|
|
185
|
+
end
|
|
186
|
+
when :Object
|
|
187
|
+
# generic object (usually a Hash), return directly
|
|
188
|
+
value
|
|
189
|
+
when :Array
|
|
190
|
+
# generic array, return directly
|
|
191
|
+
value
|
|
192
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
193
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
194
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
195
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
196
|
+
k_type = Regexp.last_match[:k_type]
|
|
197
|
+
v_type = Regexp.last_match[:v_type]
|
|
198
|
+
{}.tap do |hash|
|
|
199
|
+
value.each do |k, v|
|
|
200
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
201
|
+
end
|
|
202
|
+
end
|
|
203
|
+
else # model
|
|
204
|
+
# models (e.g. Pet) or oneOf
|
|
205
|
+
klass = DatadogAPIClient::V1.const_get(type)
|
|
206
|
+
res = klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
207
|
+
if res.instance_of? DatadogAPIClient::V1::UnparsedObject
|
|
208
|
+
self._unparsed = true
|
|
209
|
+
end
|
|
210
|
+
res
|
|
211
|
+
end
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
# Returns the string representation of the object
|
|
215
|
+
# @return [String] String presentation of the object
|
|
216
|
+
def to_s
|
|
217
|
+
to_hash.to_s
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
221
|
+
# @return [Hash] Returns the object in the form of hash
|
|
222
|
+
def to_body
|
|
223
|
+
to_hash
|
|
224
|
+
end
|
|
225
|
+
|
|
226
|
+
# Returns the object in the form of hash
|
|
227
|
+
# @return [Hash] Returns the object in the form of hash
|
|
228
|
+
def to_hash
|
|
229
|
+
hash = {}
|
|
230
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
231
|
+
value = self.send(attr)
|
|
232
|
+
if value.nil?
|
|
233
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
234
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
hash[param] = _to_hash(value)
|
|
238
|
+
end
|
|
239
|
+
hash
|
|
240
|
+
end
|
|
241
|
+
|
|
242
|
+
# Outputs non-array value in the form of hash
|
|
243
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
244
|
+
# @param [Object] value Any valid value
|
|
245
|
+
# @return [Hash] Returns the value in the form of hash
|
|
246
|
+
def _to_hash(value)
|
|
247
|
+
if value.is_a?(Array)
|
|
248
|
+
value.compact.map { |v| _to_hash(v) }
|
|
249
|
+
elsif value.is_a?(Hash)
|
|
250
|
+
{}.tap do |hash|
|
|
251
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
252
|
+
end
|
|
253
|
+
elsif value.respond_to? :to_hash
|
|
254
|
+
value.to_hash
|
|
255
|
+
else
|
|
256
|
+
value
|
|
257
|
+
end
|
|
258
|
+
end
|
|
259
|
+
|
|
260
|
+
end
|
|
261
|
+
|
|
262
|
+
end
|
|
@@ -17,14 +17,14 @@ require 'date'
|
|
|
17
17
|
require 'time'
|
|
18
18
|
|
|
19
19
|
module DatadogAPIClient::V1
|
|
20
|
-
# The response object of a list of SLO corrections
|
|
20
|
+
# The response object of a list of SLO corrections.
|
|
21
21
|
class SLOCorrection
|
|
22
22
|
# whether the object has unparsed attributes
|
|
23
23
|
attr_accessor :_unparsed
|
|
24
24
|
|
|
25
25
|
attr_accessor :attributes
|
|
26
26
|
|
|
27
|
-
# The ID of the SLO correction
|
|
27
|
+
# The ID of the SLO correction.
|
|
28
28
|
attr_accessor :id
|
|
29
29
|
|
|
30
30
|
attr_accessor :type
|
|
@@ -17,7 +17,7 @@ require 'date'
|
|
|
17
17
|
require 'time'
|
|
18
18
|
|
|
19
19
|
module DatadogAPIClient::V1
|
|
20
|
-
# The data object associated with the SLO correction to be created
|
|
20
|
+
# The data object associated with the SLO correction to be created.
|
|
21
21
|
class SLOCorrectionCreateData
|
|
22
22
|
# whether the object has unparsed attributes
|
|
23
23
|
attr_accessor :_unparsed
|
|
@@ -83,12 +83,17 @@ module DatadogAPIClient::V1
|
|
|
83
83
|
# @return Array for valid properties with the reasons
|
|
84
84
|
def list_invalid_properties
|
|
85
85
|
invalid_properties = Array.new
|
|
86
|
+
if @type.nil?
|
|
87
|
+
invalid_properties.push('invalid value for "type", type cannot be nil.')
|
|
88
|
+
end
|
|
89
|
+
|
|
86
90
|
invalid_properties
|
|
87
91
|
end
|
|
88
92
|
|
|
89
93
|
# Check to see if the all the properties in the model are valid
|
|
90
94
|
# @return true if the model is valid
|
|
91
95
|
def valid?
|
|
96
|
+
return false if @type.nil?
|
|
92
97
|
true
|
|
93
98
|
end
|
|
94
99
|
|
|
@@ -17,7 +17,7 @@ require 'date'
|
|
|
17
17
|
require 'time'
|
|
18
18
|
|
|
19
19
|
module DatadogAPIClient::V1
|
|
20
|
-
# An object that defines a correction to be applied to an SLO
|
|
20
|
+
# An object that defines a correction to be applied to an SLO.
|
|
21
21
|
class SLOCorrectionCreateRequest
|
|
22
22
|
# whether the object has unparsed attributes
|
|
23
23
|
attr_accessor :_unparsed
|