datadog_api_client 2.1.0 → 2.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (130) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/poetry.lock +21 -14
  4. data/.generator/pyproject.toml +1 -1
  5. data/.generator/schemas/v1/openapi.yaml +558 -8
  6. data/.generator/schemas/v2/openapi.yaml +973 -253
  7. data/.generator/src/generator/templates/api_client.j2 +5 -1
  8. data/.generator/src/generator/templates/configuration.j2 +17 -0
  9. data/.github/workflows/test.yml +3 -0
  10. data/.pre-commit-config.yaml +1 -1
  11. data/CHANGELOG.md +26 -0
  12. data/README.md +11 -0
  13. data/examples/v1/dashboards/CreateDashboard_1423904722.rb +38 -0
  14. data/examples/v1/dashboards/CreateDashboard_2652180930.rb +43 -0
  15. data/examples/v1/dashboards/CreateDashboard_2850365602.rb +55 -0
  16. data/examples/v1/dashboards/CreateDashboard_3117424216.rb +33 -0
  17. data/examples/v1/dashboards/CreateDashboard_3669695268.rb +50 -0
  18. data/examples/v1/dashboards/CreateDashboard_858397694.rb +41 -0
  19. data/examples/v1/synthetics/CreateGlobalVariable_1068962881.rb +1 -1
  20. data/examples/v2/incidents/ListIncidentAttachments.rb +8 -0
  21. data/examples/v2/incidents/ListIncidentAttachments_2457735435.rb +11 -0
  22. data/examples/v2/incidents/UpdateIncidentAttachments.rb +38 -0
  23. data/examples/v2/incidents/UpdateIncidentAttachments_3881702075.rb +26 -0
  24. data/examples/v2/metrics/ListActiveMetricConfigurations.rb +5 -0
  25. data/examples/v2/metrics/ListTagConfigurations.rb +1 -1
  26. data/examples/v2/metrics/ListTagConfigurations_265033704.rb +8 -0
  27. data/examples/v2/metrics/{ListTagConfigurations_103226315.rb → ListTagConfigurations_2739018321.rb} +1 -1
  28. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule.rb +3 -2
  29. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_461183901.rb +2 -2
  30. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_498211763.rb +2 -2
  31. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_914562040.rb +50 -0
  32. data/examples/v2/security-monitoring/GetSecurityMonitoringSignal.rb +5 -0
  33. data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule.rb +2 -1
  34. data/examples/v2/usage-metering/GetEstimatedCostByOrg.rb +1 -4
  35. data/examples/v2/usage-metering/GetEstimatedCostByOrg_2734954020.rb +2 -4
  36. data/examples/v2/usage-metering/GetEstimatedCostByOrg_3186693804.rb +2 -4
  37. data/examples/v2/usage-metering/GetHistoricalCostByOrg.rb +8 -0
  38. data/generate.sh +30 -0
  39. data/lib/datadog_api_client/api_client.rb +5 -1
  40. data/lib/datadog_api_client/configuration.rb +20 -1
  41. data/lib/datadog_api_client/inflector.rb +51 -1
  42. data/lib/datadog_api_client/v1/api/service_level_objectives_api.rb +3 -1
  43. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +5 -5
  44. data/lib/datadog_api_client/v1/models/dashboard_template_variable.rb +14 -2
  45. data/lib/datadog_api_client/v1/models/dashboard_template_variable_preset_value.rb +28 -5
  46. data/lib/datadog_api_client/v1/models/formula_and_function_event_query_definition.rb +14 -4
  47. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +1 -0
  48. data/lib/datadog_api_client/v1/models/list_stream_query.rb +14 -4
  49. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +2 -0
  50. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +21 -1
  51. data/lib/datadog_api_client/v1/models/search_service_level_objective.rb +111 -0
  52. data/lib/datadog_api_client/v1/models/search_service_level_objective_attributes.rb +286 -0
  53. data/lib/datadog_api_client/v1/models/search_service_level_objective_data.rb +134 -0
  54. data/lib/datadog_api_client/v1/models/search_slo_query.rb +137 -0
  55. data/lib/datadog_api_client/v1/models/search_slo_response_data_attributes.rb +8 -8
  56. data/lib/datadog_api_client/v1/models/search_slo_response_links.rb +2 -0
  57. data/lib/datadog_api_client/v1/models/search_slo_threshold.rb +184 -0
  58. data/lib/datadog_api_client/v1/models/search_slo_timeframe.rb +28 -0
  59. data/lib/datadog_api_client/v1/models/slo_creator.rb +131 -0
  60. data/lib/datadog_api_client/v1/models/slo_list_widget_definition.rb +185 -0
  61. data/lib/datadog_api_client/v1/models/slo_list_widget_definition_type.rb +26 -0
  62. data/lib/datadog_api_client/v1/models/slo_list_widget_query.rb +149 -0
  63. data/lib/datadog_api_client/v1/models/slo_list_widget_request.rb +143 -0
  64. data/lib/datadog_api_client/v1/models/slo_list_widget_request_type.rb +26 -0
  65. data/lib/datadog_api_client/v1/models/slo_overall_statuses.rb +174 -0
  66. data/lib/datadog_api_client/v1/models/slo_raw_error_budget_remaining.rb +121 -0
  67. data/lib/datadog_api_client/v1/models/synthetics_assertion_operator.rb +1 -0
  68. data/lib/datadog_api_client/v1/models/topology_map_widget_definition.rb +193 -0
  69. data/lib/datadog_api_client/v1/models/topology_map_widget_definition_type.rb +26 -0
  70. data/lib/datadog_api_client/v1/models/topology_query.rb +144 -0
  71. data/lib/datadog_api_client/v1/models/topology_query_data_source.rb +27 -0
  72. data/lib/datadog_api_client/v1/models/topology_request.rb +121 -0
  73. data/lib/datadog_api_client/v1/models/topology_request_type.rb +26 -0
  74. data/lib/datadog_api_client/v1/models/usage_attribution_sort.rb +2 -0
  75. data/lib/datadog_api_client/v1/models/usage_attribution_supported_metrics.rb +2 -0
  76. data/lib/datadog_api_client/v1/models/usage_attribution_values.rb +21 -1
  77. data/lib/datadog_api_client/v1/models/usage_fargate_hour.rb +11 -1
  78. data/lib/datadog_api_client/v1/models/usage_summary_date.rb +11 -1
  79. data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +11 -1
  80. data/lib/datadog_api_client/v1/models/usage_summary_response.rb +11 -1
  81. data/lib/datadog_api_client/v1/models/widget_definition.rb +3 -1
  82. data/lib/datadog_api_client/v2/api/incident_services_api.rb +2 -2
  83. data/lib/datadog_api_client/v2/api/incident_teams_api.rb +2 -2
  84. data/lib/datadog_api_client/v2/api/incidents_api.rb +155 -0
  85. data/lib/datadog_api_client/v2/api/metrics_api.rb +76 -8
  86. data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +65 -0
  87. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +83 -17
  88. data/lib/datadog_api_client/v2/models/incident_attachment_attachment_type.rb +27 -0
  89. data/lib/datadog_api_client/v2/models/incident_attachment_attributes.rb +63 -0
  90. data/lib/datadog_api_client/v2/models/incident_attachment_data.rb +187 -0
  91. data/lib/datadog_api_client/v2/models/incident_attachment_link_attachment_type.rb +26 -0
  92. data/lib/datadog_api_client/v2/models/incident_attachment_link_attributes.rb +145 -0
  93. data/lib/datadog_api_client/v2/models/incident_attachment_link_attributes_attachment_object.rb +143 -0
  94. data/lib/datadog_api_client/v2/models/incident_attachment_postmortem_attachment_type.rb +26 -0
  95. data/lib/datadog_api_client/v2/models/incident_attachment_postmortem_attributes.rb +145 -0
  96. data/lib/datadog_api_client/v2/models/incident_attachment_related_object.rb +26 -0
  97. data/lib/datadog_api_client/v2/models/incident_attachment_relationships.rb +111 -0
  98. data/lib/datadog_api_client/v2/models/incident_attachment_type.rb +26 -0
  99. data/lib/datadog_api_client/v2/models/incident_attachment_update_attributes.rb +63 -0
  100. data/lib/datadog_api_client/v2/models/incident_attachment_update_data.rb +144 -0
  101. data/lib/datadog_api_client/v2/models/incident_attachment_update_request.rb +127 -0
  102. data/lib/datadog_api_client/v2/models/incident_attachment_update_response.rb +137 -0
  103. data/lib/datadog_api_client/v2/models/incident_attachments_postmortem_attributes_attachment_object.rb +143 -0
  104. data/lib/datadog_api_client/v2/models/incident_attachments_response.rb +136 -0
  105. data/lib/datadog_api_client/v2/models/incident_attachments_response_included_item.rb +62 -0
  106. data/lib/datadog_api_client/v2/models/incident_related_object.rb +1 -0
  107. data/lib/datadog_api_client/v2/models/incident_response_attributes.rb +1 -11
  108. data/lib/datadog_api_client/v2/models/incident_response_included_item.rb +2 -1
  109. data/lib/datadog_api_client/v2/models/incident_response_relationships.rb +14 -14
  110. data/lib/datadog_api_client/v2/models/metric_active_configuration_type.rb +26 -0
  111. data/lib/datadog_api_client/v2/models/metric_suggested_tags_and_aggregations.rb +133 -0
  112. data/lib/datadog_api_client/v2/models/metric_suggested_tags_and_aggregations_response.rb +111 -0
  113. data/lib/datadog_api_client/v2/models/metric_suggested_tags_attributes.rb +125 -0
  114. data/lib/datadog_api_client/v2/models/relationship_to_incident_attachment.rb +124 -0
  115. data/lib/datadog_api_client/v2/models/relationship_to_incident_attachment_data.rb +145 -0
  116. data/lib/datadog_api_client/v2/models/security_monitoring_rule_create_payload.rb +36 -248
  117. data/lib/datadog_api_client/v2/models/security_monitoring_rule_query.rb +36 -151
  118. data/lib/datadog_api_client/v2/models/security_monitoring_rule_query_aggregation.rb +1 -0
  119. data/lib/datadog_api_client/v2/models/security_monitoring_rule_response.rb +37 -253
  120. data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_create_payload.rb +275 -0
  121. data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_query.rb +187 -0
  122. data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_response.rb +279 -0
  123. data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_type.rb +26 -0
  124. data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_create_payload.rb +275 -0
  125. data/lib/datadog_api_client/v2/models/{security_monitoring_rule_query_create.rb → security_monitoring_standard_rule_query.rb} +3 -3
  126. data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_response.rb +279 -0
  127. data/lib/datadog_api_client/version.rb +1 -1
  128. metadata +70 -6
  129. data/Makefile +0 -7
  130. data/examples/v2/metrics/ListTagConfigurations_1799362914.rb +0 -8
@@ -0,0 +1,121 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Error budget remaining for an SLO.
21
+ class SLORawErrorBudgetRemaining
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # Error budget remaining unit.
29
+ attr_accessor :unit
30
+
31
+ # Error budget remaining value.
32
+ attr_accessor :value
33
+
34
+ # Attribute mapping from ruby-style variable name to JSON key.
35
+ # @!visibility private
36
+ def self.attribute_map
37
+ {
38
+ :'unit' => :'unit',
39
+ :'value' => :'value'
40
+ }
41
+ end
42
+
43
+ # Returns all the JSON keys this model knows about
44
+ # @!visibility private
45
+ def self.acceptable_attributes
46
+ attribute_map.values
47
+ end
48
+
49
+ # Attribute type mapping.
50
+ # @!visibility private
51
+ def self.openapi_types
52
+ {
53
+ :'unit' => :'String',
54
+ :'value' => :'Float'
55
+ }
56
+ end
57
+
58
+ # List of attributes with nullable: true
59
+ # @!visibility private
60
+ def self.openapi_nullable
61
+ Set.new([
62
+ ])
63
+ end
64
+
65
+ # Initializes the object
66
+ # @param attributes [Hash] Model attributes in the form of hash
67
+ # @!visibility private
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::SLORawErrorBudgetRemaining` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ attributes = attributes.each_with_object({}) { |(k, v), h|
75
+ if (!self.class.attribute_map.key?(k.to_sym))
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::SLORawErrorBudgetRemaining`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
+ end
78
+ h[k.to_sym] = v
79
+ }
80
+
81
+ if attributes.key?(:'unit')
82
+ self.unit = attributes[:'unit']
83
+ end
84
+
85
+ if attributes.key?(:'value')
86
+ self.value = attributes[:'value']
87
+ end
88
+ end
89
+
90
+ # Check to see if the all the properties in the model are valid
91
+ # @return true if the model is valid
92
+ # @!visibility private
93
+ def valid?
94
+ true
95
+ end
96
+
97
+ # Checks equality by comparing each attribute.
98
+ # @param o [Object] Object to be compared
99
+ # @!visibility private
100
+ def ==(o)
101
+ return true if self.equal?(o)
102
+ self.class == o.class &&
103
+ unit == o.unit &&
104
+ value == o.value
105
+ end
106
+
107
+ # @see the `==` method
108
+ # @param o [Object] Object to be compared
109
+ # @!visibility private
110
+ def eql?(o)
111
+ self == o
112
+ end
113
+
114
+ # Calculates hash code according to all attributes.
115
+ # @return [Integer] Hash code
116
+ # @!visibility private
117
+ def hash
118
+ [unit, value].hash
119
+ end
120
+ end
121
+ end
@@ -34,5 +34,6 @@ module DatadogAPIClient::V1
34
34
  VALIDATES = "validates".freeze
35
35
  IS_IN_MORE_DAYS_THAN = "isInMoreThan".freeze
36
36
  IS_IN_LESS_DAYS_THAN = "isInLessThan".freeze
37
+ DOES_NOT_EXIST = "doesNotExist".freeze
37
38
  end
38
39
  end
@@ -0,0 +1,193 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # This widget displays a topology of nodes and edges for different data sources. It replaces the service map widget.
21
+ class TopologyMapWidgetDefinition
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # List of custom links.
29
+ attr_accessor :custom_links
30
+
31
+ # One or more Topology requests.
32
+ attr_accessor :requests
33
+
34
+ # Title of your widget.
35
+ attr_accessor :title
36
+
37
+ # How to align the text on the widget.
38
+ attr_accessor :title_align
39
+
40
+ # Size of the title.
41
+ attr_accessor :title_size
42
+
43
+ # Type of the topology map widget.
44
+ attr_accessor :type
45
+
46
+ # Attribute mapping from ruby-style variable name to JSON key.
47
+ # @!visibility private
48
+ def self.attribute_map
49
+ {
50
+ :'custom_links' => :'custom_links',
51
+ :'requests' => :'requests',
52
+ :'title' => :'title',
53
+ :'title_align' => :'title_align',
54
+ :'title_size' => :'title_size',
55
+ :'type' => :'type'
56
+ }
57
+ end
58
+
59
+ # Returns all the JSON keys this model knows about
60
+ # @!visibility private
61
+ def self.acceptable_attributes
62
+ attribute_map.values
63
+ end
64
+
65
+ # Attribute type mapping.
66
+ # @!visibility private
67
+ def self.openapi_types
68
+ {
69
+ :'custom_links' => :'Array<WidgetCustomLink>',
70
+ :'requests' => :'Array<TopologyRequest>',
71
+ :'title' => :'String',
72
+ :'title_align' => :'WidgetTextAlign',
73
+ :'title_size' => :'String',
74
+ :'type' => :'TopologyMapWidgetDefinitionType'
75
+ }
76
+ end
77
+
78
+ # List of attributes with nullable: true
79
+ # @!visibility private
80
+ def self.openapi_nullable
81
+ Set.new([
82
+ ])
83
+ end
84
+
85
+ # Initializes the object
86
+ # @param attributes [Hash] Model attributes in the form of hash
87
+ # @!visibility private
88
+ def initialize(attributes = {})
89
+ if (!attributes.is_a?(Hash))
90
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::TopologyMapWidgetDefinition` initialize method"
91
+ end
92
+
93
+ # check to see if the attribute exists and convert string to symbol for hash key
94
+ attributes = attributes.each_with_object({}) { |(k, v), h|
95
+ if (!self.class.attribute_map.key?(k.to_sym))
96
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::TopologyMapWidgetDefinition`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
97
+ end
98
+ h[k.to_sym] = v
99
+ }
100
+
101
+ if attributes.key?(:'custom_links')
102
+ if (value = attributes[:'custom_links']).is_a?(Array)
103
+ self.custom_links = value
104
+ end
105
+ end
106
+
107
+ if attributes.key?(:'requests')
108
+ if (value = attributes[:'requests']).is_a?(Array)
109
+ self.requests = value
110
+ end
111
+ end
112
+
113
+ if attributes.key?(:'title')
114
+ self.title = attributes[:'title']
115
+ end
116
+
117
+ if attributes.key?(:'title_align')
118
+ self.title_align = attributes[:'title_align']
119
+ end
120
+
121
+ if attributes.key?(:'title_size')
122
+ self.title_size = attributes[:'title_size']
123
+ end
124
+
125
+ if attributes.key?(:'type')
126
+ self.type = attributes[:'type']
127
+ else
128
+ self.type = 'topology_map'
129
+ end
130
+ end
131
+
132
+ # Check to see if the all the properties in the model are valid
133
+ # @return true if the model is valid
134
+ # @!visibility private
135
+ def valid?
136
+ return false if @requests.nil?
137
+ return false if @requests.length < 1
138
+ return false if @type.nil?
139
+ true
140
+ end
141
+
142
+ # Custom attribute writer method with validation
143
+ # @param requests [Object] Object to be assigned
144
+ # @!visibility private
145
+ def requests=(requests)
146
+ if requests.nil?
147
+ fail ArgumentError, 'invalid value for "requests", requests cannot be nil.'
148
+ end
149
+ if requests.length < 1
150
+ fail ArgumentError, 'invalid value for "requests", number of items must be greater than or equal to 1.'
151
+ end
152
+ @requests = requests
153
+ end
154
+
155
+ # Custom attribute writer method with validation
156
+ # @param type [Object] Object to be assigned
157
+ # @!visibility private
158
+ def type=(type)
159
+ if type.nil?
160
+ fail ArgumentError, 'invalid value for "type", type cannot be nil.'
161
+ end
162
+ @type = type
163
+ end
164
+
165
+ # Checks equality by comparing each attribute.
166
+ # @param o [Object] Object to be compared
167
+ # @!visibility private
168
+ def ==(o)
169
+ return true if self.equal?(o)
170
+ self.class == o.class &&
171
+ custom_links == o.custom_links &&
172
+ requests == o.requests &&
173
+ title == o.title &&
174
+ title_align == o.title_align &&
175
+ title_size == o.title_size &&
176
+ type == o.type
177
+ end
178
+
179
+ # @see the `==` method
180
+ # @param o [Object] Object to be compared
181
+ # @!visibility private
182
+ def eql?(o)
183
+ self == o
184
+ end
185
+
186
+ # Calculates hash code according to all attributes.
187
+ # @return [Integer] Hash code
188
+ # @!visibility private
189
+ def hash
190
+ [custom_links, requests, title, title_align, title_size, type].hash
191
+ end
192
+ end
193
+ end
@@ -0,0 +1,26 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Type of the topology map widget.
21
+ class TopologyMapWidgetDefinitionType
22
+ include BaseEnumModel
23
+
24
+ TOPOLOGY_MAP = "topology_map".freeze
25
+ end
26
+ end
@@ -0,0 +1,144 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Query to service-based topology data sources like the service map or data streams.
21
+ class TopologyQuery
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # Name of the data source
29
+ attr_accessor :data_source
30
+
31
+ # Your environment and primary tag (or * if enabled for your account).
32
+ attr_accessor :filters
33
+
34
+ # Name of the service
35
+ attr_accessor :service
36
+
37
+ # Attribute mapping from ruby-style variable name to JSON key.
38
+ # @!visibility private
39
+ def self.attribute_map
40
+ {
41
+ :'data_source' => :'data_source',
42
+ :'filters' => :'filters',
43
+ :'service' => :'service'
44
+ }
45
+ end
46
+
47
+ # Returns all the JSON keys this model knows about
48
+ # @!visibility private
49
+ def self.acceptable_attributes
50
+ attribute_map.values
51
+ end
52
+
53
+ # Attribute type mapping.
54
+ # @!visibility private
55
+ def self.openapi_types
56
+ {
57
+ :'data_source' => :'TopologyQueryDataSource',
58
+ :'filters' => :'Array<String>',
59
+ :'service' => :'String'
60
+ }
61
+ end
62
+
63
+ # List of attributes with nullable: true
64
+ # @!visibility private
65
+ def self.openapi_nullable
66
+ Set.new([
67
+ ])
68
+ end
69
+
70
+ # Initializes the object
71
+ # @param attributes [Hash] Model attributes in the form of hash
72
+ # @!visibility private
73
+ def initialize(attributes = {})
74
+ if (!attributes.is_a?(Hash))
75
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::TopologyQuery` initialize method"
76
+ end
77
+
78
+ # check to see if the attribute exists and convert string to symbol for hash key
79
+ attributes = attributes.each_with_object({}) { |(k, v), h|
80
+ if (!self.class.attribute_map.key?(k.to_sym))
81
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::TopologyQuery`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
82
+ end
83
+ h[k.to_sym] = v
84
+ }
85
+
86
+ if attributes.key?(:'data_source')
87
+ self.data_source = attributes[:'data_source']
88
+ end
89
+
90
+ if attributes.key?(:'filters')
91
+ if (value = attributes[:'filters']).is_a?(Array)
92
+ self.filters = value
93
+ end
94
+ end
95
+
96
+ if attributes.key?(:'service')
97
+ self.service = attributes[:'service']
98
+ end
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
+ # @!visibility private
104
+ def valid?
105
+ return false if !@filters.nil? && @filters.length < 1
106
+ true
107
+ end
108
+
109
+ # Custom attribute writer method with validation
110
+ # @param filters [Object] Object to be assigned
111
+ # @!visibility private
112
+ def filters=(filters)
113
+ if !filters.nil? && filters.length < 1
114
+ fail ArgumentError, 'invalid value for "filters", number of items must be greater than or equal to 1.'
115
+ end
116
+ @filters = filters
117
+ end
118
+
119
+ # Checks equality by comparing each attribute.
120
+ # @param o [Object] Object to be compared
121
+ # @!visibility private
122
+ def ==(o)
123
+ return true if self.equal?(o)
124
+ self.class == o.class &&
125
+ data_source == o.data_source &&
126
+ filters == o.filters &&
127
+ service == o.service
128
+ end
129
+
130
+ # @see the `==` method
131
+ # @param o [Object] Object to be compared
132
+ # @!visibility private
133
+ def eql?(o)
134
+ self == o
135
+ end
136
+
137
+ # Calculates hash code according to all attributes.
138
+ # @return [Integer] Hash code
139
+ # @!visibility private
140
+ def hash
141
+ [data_source, filters, service].hash
142
+ end
143
+ end
144
+ end
@@ -0,0 +1,27 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Name of the data source
21
+ class TopologyQueryDataSource
22
+ include BaseEnumModel
23
+
24
+ DATA_STREAMS = "data_streams".freeze
25
+ SERVICE_MAP = "service_map".freeze
26
+ end
27
+ end
@@ -0,0 +1,121 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Request that will return nodes and edges to be used by topology map.
21
+ class TopologyRequest
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # Query to service-based topology data sources like the service map or data streams.
29
+ attr_accessor :query
30
+
31
+ # Widget request type.
32
+ attr_accessor :request_type
33
+
34
+ # Attribute mapping from ruby-style variable name to JSON key.
35
+ # @!visibility private
36
+ def self.attribute_map
37
+ {
38
+ :'query' => :'query',
39
+ :'request_type' => :'request_type'
40
+ }
41
+ end
42
+
43
+ # Returns all the JSON keys this model knows about
44
+ # @!visibility private
45
+ def self.acceptable_attributes
46
+ attribute_map.values
47
+ end
48
+
49
+ # Attribute type mapping.
50
+ # @!visibility private
51
+ def self.openapi_types
52
+ {
53
+ :'query' => :'TopologyQuery',
54
+ :'request_type' => :'TopologyRequestType'
55
+ }
56
+ end
57
+
58
+ # List of attributes with nullable: true
59
+ # @!visibility private
60
+ def self.openapi_nullable
61
+ Set.new([
62
+ ])
63
+ end
64
+
65
+ # Initializes the object
66
+ # @param attributes [Hash] Model attributes in the form of hash
67
+ # @!visibility private
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::TopologyRequest` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ attributes = attributes.each_with_object({}) { |(k, v), h|
75
+ if (!self.class.attribute_map.key?(k.to_sym))
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::TopologyRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
+ end
78
+ h[k.to_sym] = v
79
+ }
80
+
81
+ if attributes.key?(:'query')
82
+ self.query = attributes[:'query']
83
+ end
84
+
85
+ if attributes.key?(:'request_type')
86
+ self.request_type = attributes[:'request_type']
87
+ end
88
+ end
89
+
90
+ # Check to see if the all the properties in the model are valid
91
+ # @return true if the model is valid
92
+ # @!visibility private
93
+ def valid?
94
+ true
95
+ end
96
+
97
+ # Checks equality by comparing each attribute.
98
+ # @param o [Object] Object to be compared
99
+ # @!visibility private
100
+ def ==(o)
101
+ return true if self.equal?(o)
102
+ self.class == o.class &&
103
+ query == o.query &&
104
+ request_type == o.request_type
105
+ end
106
+
107
+ # @see the `==` method
108
+ # @param o [Object] Object to be compared
109
+ # @!visibility private
110
+ def eql?(o)
111
+ self == o
112
+ end
113
+
114
+ # Calculates hash code according to all attributes.
115
+ # @return [Integer] Hash code
116
+ # @!visibility private
117
+ def hash
118
+ [query, request_type].hash
119
+ end
120
+ end
121
+ end
@@ -0,0 +1,26 @@
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://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
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
+ # Widget request type.
21
+ class TopologyRequestType
22
+ include BaseEnumModel
23
+
24
+ TOPOLOGY = "topology".freeze
25
+ end
26
+ end
@@ -51,5 +51,7 @@ module DatadogAPIClient::V1
51
51
  ESTIMATED_INDEXED_SPANS_PERCENTAGE = "estimated_indexed_spans_percentage".freeze
52
52
  ESTIMATED_INGESTED_SPANS_USAGE = "estimated_ingested_spans_usage".freeze
53
53
  ESTIMATED_INGESTED_SPANS_PERCENTAGE = "estimated_ingested_spans_percentage".freeze
54
+ APM_FARGATE_USAGE = "apm_fargate_usage".freeze
55
+ APM_FARGATE_PERCENTAGE = "apm_fargate_percentage".freeze
54
56
  end
55
57
  end
@@ -61,6 +61,8 @@ module DatadogAPIClient::V1
61
61
  ESTIMATED_INDEXED_SPANS_PERCENTAGE = "estimated_indexed_spans_percentage".freeze
62
62
  ESTIMATED_INGESTED_SPANS_USAGE = "estimated_ingested_spans_usage".freeze
63
63
  ESTIMATED_INGESTED_SPANS_PERCENTAGE = "estimated_ingested_spans_percentage".freeze
64
+ APM_FARGATE_USAGE = "apm_fargate_usage".freeze
65
+ APM_FARGATE_PERCENTAGE = "apm_fargate_percentage".freeze
64
66
  ALL = "*".freeze
65
67
  end
66
68
  end