datadog_api_client 2.18.0 → 2.20.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.
Files changed (193) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/conftest.py +1 -1
  4. data/.generator/poetry.lock +69 -69
  5. data/.generator/schemas/v1/openapi.yaml +286 -55
  6. data/.generator/schemas/v2/openapi.yaml +2021 -226
  7. data/.generator/src/generator/templates/api.j2 +5 -5
  8. data/.generator/src/generator/templates/model_generic.j2 +2 -2
  9. data/CHANGELOG.md +38 -0
  10. data/examples/v1/azure-integration/CreateAzureIntegration.rb +4 -4
  11. data/examples/v1/azure-integration/DeleteAzureIntegration.rb +2 -15
  12. data/examples/v1/azure-integration/UpdateAzureIntegration.rb +4 -4
  13. data/examples/v1/gcp-integration/CreateGCPIntegration.rb +4 -5
  14. data/examples/v1/gcp-integration/DeleteGCPIntegration.rb +2 -14
  15. data/examples/v1/gcp-integration/UpdateGCPIntegration.rb +4 -5
  16. data/examples/v1/logs-indexes/CreateLogsIndex.rb +5 -0
  17. data/examples/v1/logs-indexes/UpdateLogsIndex.rb +5 -0
  18. data/examples/v1/service-level-objectives/CreateSLO_3765703239.rb +46 -0
  19. data/examples/v1/synthetics/CreateSyntheticsAPITest.rb +1 -1
  20. data/examples/v1/synthetics/CreateSyntheticsBrowserTest.rb +1 -1
  21. data/examples/v1/synthetics/TriggerCITests.rb +1 -1
  22. data/examples/v1/synthetics/UpdateBrowserTest.rb +1 -1
  23. data/examples/v1/usage-metering/GetUsageLambda.rb +5 -2
  24. data/examples/v2/api-management/CreateOpenAPI.rb +11 -0
  25. data/examples/v2/api-management/DeleteOpenAPI.rb +11 -0
  26. data/examples/v2/api-management/GetOpenAPI.rb +11 -0
  27. data/examples/v2/api-management/UpdateOpenAPI.rb +14 -0
  28. data/examples/v2/ci-visibility-pipelines/CreateCIAppPipelineEvent.rb +0 -3
  29. data/examples/v2/ci-visibility-pipelines/CreateCIAppPipelineEvent_129899466.rb +0 -3
  30. data/examples/v2/cloud-cost-management/CreateCostAWSCURConfig.rb +18 -0
  31. data/examples/v2/cloud-cost-management/CreateCostAzureUCConfigs.rb +29 -0
  32. data/examples/v2/cloud-cost-management/DeleteCostAWSCURConfig.rb +5 -0
  33. data/examples/v2/cloud-cost-management/DeleteCostAzureUCConfig.rb +5 -0
  34. data/examples/v2/cloud-cost-management/GetCloudCostActivity.rb +5 -0
  35. data/examples/v2/cloud-cost-management/ListAWSRelatedAccounts.rb +5 -0
  36. data/examples/v2/cloud-cost-management/ListCostAWSCURConfigs.rb +5 -0
  37. data/examples/v2/cloud-cost-management/ListCostAzureUCConfigs.rb +5 -0
  38. data/examples/v2/cloud-cost-management/UpdateCostAWSCURConfig.rb +14 -0
  39. data/examples/v2/cloud-cost-management/UpdateCostAzureUCConfigs.rb +14 -0
  40. data/examples/v2/cloudflare-integration/CreateCloudflareAccount.rb +1 -1
  41. data/examples/v2/cloudflare-integration/UpdateCloudflareAccount.rb +4 -1
  42. data/examples/v2/downtimes/ListMonitorDowntimes_3316718253.rb +5 -0
  43. data/examples/v2/gcp-integration/CreateGCPSTSAccount_130557025.rb +16 -0
  44. data/examples/v2/gcp-integration/CreateGCPSTSAccount_2597004741.rb +16 -0
  45. data/examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.rb +17 -0
  46. data/examples/v2/gcp-integration/UpdateGCPSTSAccount_3205636354.rb +19 -0
  47. data/examples/v2/okta-integration/CreateOktaAccount.rb +1 -1
  48. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_3367706049.rb +46 -0
  49. data/examples/v2/security-monitoring/CreateSecurityMonitoringSuppression.rb +19 -0
  50. data/examples/v2/security-monitoring/DeleteSecurityMonitoringSuppression.rb +8 -0
  51. data/examples/v2/security-monitoring/GetSecurityMonitoringSuppression.rb +8 -0
  52. data/examples/v2/security-monitoring/ListSecurityMonitoringSuppressions.rb +5 -0
  53. data/examples/v2/security-monitoring/UpdateSecurityMonitoringSuppression.rb +17 -0
  54. data/examples/v2/sensitive-data-scanner/CreateScanningRule.rb +7 -0
  55. data/examples/v2/sensitive-data-scanner/UpdateScanningRule.rb +7 -10
  56. data/examples/v2/teams/CreateTeamMembership.rb +6 -0
  57. data/examples/v2/teams/GetTeamMemberships_3799131168.rb +8 -0
  58. data/examples/v2/usage-metering/GetUsageLambdaTracedInvocations.rb +1 -1
  59. data/lib/datadog_api_client/configuration.rb +4 -1
  60. data/lib/datadog_api_client/inflector.rb +74 -0
  61. data/lib/datadog_api_client/v1/api/downtimes_api.rb +28 -7
  62. data/lib/datadog_api_client/v1/api/monitors_api.rb +1 -1
  63. data/lib/datadog_api_client/v1/api/organizations_api.rb +1 -1
  64. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +3 -3
  65. data/lib/datadog_api_client/v1/models/dashboard.rb +5 -1
  66. data/lib/datadog_api_client/v1/models/dashboard_summary_definition.rb +2 -0
  67. data/lib/datadog_api_client/v1/models/gcp_account.rb +22 -2
  68. data/lib/datadog_api_client/v1/models/log.rb +1 -1
  69. data/lib/datadog_api_client/v1/models/logs_daily_limit_reset.rb +90 -0
  70. data/lib/datadog_api_client/v1/models/logs_index.rb +36 -1
  71. data/lib/datadog_api_client/v1/models/logs_index_update_request.rb +36 -1
  72. data/lib/datadog_api_client/v1/models/metrics_payload.rb +1 -1
  73. data/lib/datadog_api_client/v1/models/metrics_query_metadata.rb +1 -1
  74. data/lib/datadog_api_client/v1/models/organization.rb +1 -1
  75. data/lib/datadog_api_client/v1/models/service_level_objective.rb +11 -1
  76. data/lib/datadog_api_client/v1/models/service_level_objective_request.rb +11 -1
  77. data/lib/datadog_api_client/v1/models/slo_correction_create_request_attributes.rb +1 -1
  78. data/lib/datadog_api_client/v1/models/slo_correction_response_attributes.rb +1 -1
  79. data/lib/datadog_api_client/v1/models/slo_correction_update_request_attributes.rb +1 -1
  80. data/lib/datadog_api_client/v1/models/slo_data_source_query_definition.rb +62 -0
  81. data/lib/datadog_api_client/v1/models/slo_formula.rb +98 -0
  82. data/lib/datadog_api_client/v1/models/slo_history_metrics.rb +2 -2
  83. data/lib/datadog_api_client/v1/models/slo_history_metrics_series.rb +1 -1
  84. data/lib/datadog_api_client/v1/models/slo_history_monitor.rb +1 -1
  85. data/lib/datadog_api_client/v1/models/slo_history_sli_data.rb +1 -1
  86. data/lib/datadog_api_client/v1/models/slo_response_data.rb +11 -1
  87. data/lib/datadog_api_client/v1/models/slo_sli_spec.rb +62 -0
  88. data/lib/datadog_api_client/v1/models/slo_time_slice_comparator.rb +29 -0
  89. data/lib/datadog_api_client/v1/models/slo_time_slice_condition.rb +141 -0
  90. data/lib/datadog_api_client/v1/models/slo_time_slice_query.rb +131 -0
  91. data/lib/datadog_api_client/v1/models/slo_time_slice_spec.rb +99 -0
  92. data/lib/datadog_api_client/v1/models/slo_type.rb +1 -0
  93. data/lib/datadog_api_client/v1/models/slo_type_numeric.rb +1 -0
  94. data/lib/datadog_api_client/v1/models/split_config.rb +6 -6
  95. data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +11 -1
  96. data/lib/datadog_api_client/v1/models/usage_lambda_hour.rb +1 -1
  97. data/lib/datadog_api_client/v1/models/usage_lambda_response.rb +1 -1
  98. data/lib/datadog_api_client/v1/models/usage_summary_date.rb +11 -1
  99. data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +11 -1
  100. data/lib/datadog_api_client/v1/models/usage_summary_response.rb +11 -1
  101. data/lib/datadog_api_client/v2/api/api_management_api.rb +319 -0
  102. data/lib/datadog_api_client/v2/api/ci_visibility_pipelines_api.rb +0 -6
  103. data/lib/datadog_api_client/v2/api/cloud_cost_management_api.rb +680 -0
  104. data/lib/datadog_api_client/v2/api/downtimes_api.rb +25 -0
  105. data/lib/datadog_api_client/v2/api/metrics_api.rb +3 -2
  106. data/lib/datadog_api_client/v2/api/organizations_api.rb +1 -1
  107. data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +329 -0
  108. data/lib/datadog_api_client/v2/api/teams_api.rb +22 -0
  109. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +3 -3
  110. data/lib/datadog_api_client/v2/models/aws_cur_config.rb +129 -0
  111. data/lib/datadog_api_client/v2/models/aws_cur_config_attributes.rb +305 -0
  112. data/lib/datadog_api_client/v2/models/aws_cur_config_patch_data.rb +119 -0
  113. data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request.rb +98 -0
  114. data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request_attributes.rb +98 -0
  115. data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request_type.rb +26 -0
  116. data/lib/datadog_api_client/v2/models/aws_cur_config_post_data.rb +119 -0
  117. data/lib/datadog_api_client/v2/models/aws_cur_config_post_request.rb +98 -0
  118. data/lib/datadog_api_client/v2/models/aws_cur_config_post_request_attributes.rb +202 -0
  119. data/lib/datadog_api_client/v2/models/aws_cur_config_post_request_type.rb +26 -0
  120. data/lib/datadog_api_client/v2/models/aws_cur_config_response.rb +80 -0
  121. data/lib/datadog_api_client/v2/models/aws_cur_config_type.rb +26 -0
  122. data/lib/datadog_api_client/v2/models/aws_cur_configs_response.rb +82 -0
  123. data/lib/datadog_api_client/v2/models/aws_related_account.rb +129 -0
  124. data/lib/datadog_api_client/v2/models/aws_related_account_attributes.rb +90 -0
  125. data/lib/datadog_api_client/v2/models/aws_related_account_type.rb +26 -0
  126. data/lib/datadog_api_client/v2/models/aws_related_accounts_response.rb +82 -0
  127. data/lib/datadog_api_client/v2/models/azure_uc_config.rb +378 -0
  128. data/lib/datadog_api_client/v2/models/azure_uc_config_pair.rb +129 -0
  129. data/lib/datadog_api_client/v2/models/azure_uc_config_pair_attributes.rb +110 -0
  130. data/lib/datadog_api_client/v2/models/azure_uc_config_pair_type.rb +26 -0
  131. data/lib/datadog_api_client/v2/models/azure_uc_config_pairs_response.rb +80 -0
  132. data/lib/datadog_api_client/v2/models/azure_uc_config_patch_data.rb +119 -0
  133. data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request.rb +98 -0
  134. data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request_attributes.rb +98 -0
  135. data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request_type.rb +26 -0
  136. data/lib/datadog_api_client/v2/models/azure_uc_config_post_data.rb +119 -0
  137. data/lib/datadog_api_client/v2/models/azure_uc_config_post_request.rb +98 -0
  138. data/lib/datadog_api_client/v2/models/azure_uc_config_post_request_attributes.rb +192 -0
  139. data/lib/datadog_api_client/v2/models/azure_uc_config_post_request_type.rb +26 -0
  140. data/lib/datadog_api_client/v2/models/azure_uc_configs_response.rb +82 -0
  141. data/lib/datadog_api_client/v2/models/bill_config.rb +161 -0
  142. data/lib/datadog_api_client/v2/models/ci_app_git_info.rb +2 -2
  143. data/lib/datadog_api_client/v2/models/cloud_cost_activity.rb +119 -0
  144. data/lib/datadog_api_client/v2/models/cloud_cost_activity_attributes.rb +98 -0
  145. data/lib/datadog_api_client/v2/models/cloud_cost_activity_response.rb +80 -0
  146. data/lib/datadog_api_client/v2/models/cloud_cost_activity_type.rb +26 -0
  147. data/lib/datadog_api_client/v2/models/cloudflare_account_create_request_attributes.rb +28 -4
  148. data/lib/datadog_api_client/v2/models/cloudflare_account_response_attributes.rb +28 -4
  149. data/lib/datadog_api_client/v2/models/cloudflare_account_update_request_attributes.rb +28 -4
  150. data/lib/datadog_api_client/v2/models/create_open_api_response.rb +80 -0
  151. data/lib/datadog_api_client/v2/models/create_open_api_response_attributes.rb +82 -0
  152. data/lib/datadog_api_client/v2/models/create_open_api_response_data.rb +90 -0
  153. data/lib/datadog_api_client/v2/models/dora_deployment_request_attributes.rb +11 -1
  154. data/lib/datadog_api_client/v2/models/dora_git_info.rb +2 -2
  155. data/lib/datadog_api_client/v2/models/dora_incident_request_attributes.rb +11 -1
  156. data/lib/datadog_api_client/v2/models/gcpsts_service_account_attributes.rb +25 -5
  157. data/lib/datadog_api_client/v2/models/metric_payload.rb +1 -1
  158. data/lib/datadog_api_client/v2/models/open_api_endpoint.rb +90 -0
  159. data/lib/datadog_api_client/v2/models/open_api_file.rb +80 -0
  160. data/lib/datadog_api_client/v2/models/relationship_to_user_team_team.rb +98 -0
  161. data/lib/datadog_api_client/v2/models/relationship_to_user_team_team_data.rb +119 -0
  162. data/lib/datadog_api_client/v2/models/security_monitoring_rule_options.rb +14 -4
  163. data/lib/datadog_api_client/v2/models/security_monitoring_rule_third_party_options.rb +114 -0
  164. data/lib/datadog_api_client/v2/models/security_monitoring_rule_update_payload.rb +13 -1
  165. data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_create_payload.rb +13 -1
  166. data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_response.rb +13 -1
  167. data/lib/datadog_api_client/v2/models/security_monitoring_suppression.rb +100 -0
  168. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_attributes.rb +198 -0
  169. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_attributes.rb +181 -0
  170. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_data.rb +119 -0
  171. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_request.rb +98 -0
  172. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_response.rb +80 -0
  173. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_type.rb +26 -0
  174. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_attributes.rb +166 -0
  175. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_data.rb +119 -0
  176. data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_request.rb +98 -0
  177. data/lib/datadog_api_client/v2/models/security_monitoring_suppressions_response.rb +82 -0
  178. data/lib/datadog_api_client/v2/models/security_monitoring_third_party_root_query.rb +92 -0
  179. data/lib/datadog_api_client/v2/models/security_monitoring_third_party_rule_case.rb +112 -0
  180. data/lib/datadog_api_client/v2/models/security_monitoring_third_party_rule_case_create.rb +130 -0
  181. data/lib/datadog_api_client/v2/models/security_monitoring_user.rb +98 -0
  182. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_included_keyword_configuration.rb +134 -0
  183. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_rule_attributes.rb +46 -1
  184. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_standard_pattern_attributes.rb +33 -1
  185. data/lib/datadog_api_client/v2/models/update_open_api_response.rb +80 -0
  186. data/lib/datadog_api_client/v2/models/update_open_api_response_attributes.rb +82 -0
  187. data/lib/datadog_api_client/v2/models/update_open_api_response_data.rb +90 -0
  188. data/lib/datadog_api_client/v2/models/user_team_attributes.rb +24 -1
  189. data/lib/datadog_api_client/v2/models/user_team_relationships.rb +11 -1
  190. data/lib/datadog_api_client/v2/models/user_team_team_type.rb +26 -0
  191. data/lib/datadog_api_client/version.rb +1 -1
  192. metadata +103 -3
  193. data/examples/v1/usage-metering/GetUsageLambda_3132428705.rb +0 -8
@@ -0,0 +1,90 @@
1
+ =begin
2
+ #Datadog API V2 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::V2
20
+ # Data envelope for `CreateOpenAPIResponse`.
21
+ class CreateOpenAPIResponseData
22
+ include BaseGenericModel
23
+
24
+ # Attributes for `CreateOpenAPI`.
25
+ attr_accessor :attributes
26
+
27
+ # API identifier.
28
+ attr_accessor :id
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ # @!visibility private
32
+ def self.attribute_map
33
+ {
34
+ :'attributes' => :'attributes',
35
+ :'id' => :'id'
36
+ }
37
+ end
38
+
39
+ # Attribute type mapping.
40
+ # @!visibility private
41
+ def self.openapi_types
42
+ {
43
+ :'attributes' => :'CreateOpenAPIResponseAttributes',
44
+ :'id' => :'UUID'
45
+ }
46
+ end
47
+
48
+ # Initializes the object
49
+ # @param attributes [Hash] Model attributes in the form of hash
50
+ # @!visibility private
51
+ def initialize(attributes = {})
52
+ if (!attributes.is_a?(Hash))
53
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::CreateOpenAPIResponseData` initialize method"
54
+ end
55
+
56
+ # check to see if the attribute exists and convert string to symbol for hash key
57
+ attributes = attributes.each_with_object({}) { |(k, v), h|
58
+ if (!self.class.attribute_map.key?(k.to_sym))
59
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::CreateOpenAPIResponseData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
60
+ end
61
+ h[k.to_sym] = v
62
+ }
63
+
64
+ if attributes.key?(:'attributes')
65
+ self.attributes = attributes[:'attributes']
66
+ end
67
+
68
+ if attributes.key?(:'id')
69
+ self.id = attributes[:'id']
70
+ end
71
+ end
72
+
73
+ # Checks equality by comparing each attribute.
74
+ # @param o [Object] Object to be compared
75
+ # @!visibility private
76
+ def ==(o)
77
+ return true if self.equal?(o)
78
+ self.class == o.class &&
79
+ attributes == o.attributes &&
80
+ id == o.id
81
+ end
82
+
83
+ # Calculates hash code according to all attributes.
84
+ # @return [Integer] Hash code
85
+ # @!visibility private
86
+ def hash
87
+ [attributes, id].hash
88
+ end
89
+ end
90
+ end
@@ -21,6 +21,9 @@ module DatadogAPIClient::V2
21
21
  class DORADeploymentRequestAttributes
22
22
  include BaseGenericModel
23
23
 
24
+ # Environment name to where the service was deployed.
25
+ attr_accessor :env
26
+
24
27
  # Unix timestamp in nanoseconds when the deployment finished. It should not be older than 3 hours.
25
28
  attr_reader :finished_at
26
29
 
@@ -43,6 +46,7 @@ module DatadogAPIClient::V2
43
46
  # @!visibility private
44
47
  def self.attribute_map
45
48
  {
49
+ :'env' => :'env',
46
50
  :'finished_at' => :'finished_at',
47
51
  :'git' => :'git',
48
52
  :'id' => :'id',
@@ -56,6 +60,7 @@ module DatadogAPIClient::V2
56
60
  # @!visibility private
57
61
  def self.openapi_types
58
62
  {
63
+ :'env' => :'String',
59
64
  :'finished_at' => :'Integer',
60
65
  :'git' => :'DORAGitInfo',
61
66
  :'id' => :'String',
@@ -81,6 +86,10 @@ module DatadogAPIClient::V2
81
86
  h[k.to_sym] = v
82
87
  }
83
88
 
89
+ if attributes.key?(:'env')
90
+ self.env = attributes[:'env']
91
+ end
92
+
84
93
  if attributes.key?(:'finished_at')
85
94
  self.finished_at = attributes[:'finished_at']
86
95
  end
@@ -152,6 +161,7 @@ module DatadogAPIClient::V2
152
161
  def ==(o)
153
162
  return true if self.equal?(o)
154
163
  self.class == o.class &&
164
+ env == o.env &&
155
165
  finished_at == o.finished_at &&
156
166
  git == o.git &&
157
167
  id == o.id &&
@@ -164,7 +174,7 @@ module DatadogAPIClient::V2
164
174
  # @return [Integer] Hash code
165
175
  # @!visibility private
166
176
  def hash
167
- [finished_at, git, id, service, started_at, version].hash
177
+ [env, finished_at, git, id, service, started_at, version].hash
168
178
  end
169
179
  end
170
180
  end
@@ -75,7 +75,7 @@ module DatadogAPIClient::V2
75
75
  # @!visibility private
76
76
  def valid?
77
77
  return false if @commit_sha.nil?
78
- pattern = Regexp.new("^[a-fA-F0-9]{40,}$")
78
+ pattern = Regexp.new(/^[a-fA-F0-9]{40,}$/)
79
79
  return false if @commit_sha !~ pattern
80
80
  return false if @repository_url.nil?
81
81
  true
@@ -88,7 +88,7 @@ module DatadogAPIClient::V2
88
88
  if commit_sha.nil?
89
89
  fail ArgumentError, 'invalid value for "commit_sha", commit_sha cannot be nil.'
90
90
  end
91
- pattern = Regexp.new("^[a-fA-F0-9]{40,}$")
91
+ pattern = Regexp.new(/^[a-fA-F0-9]{40,}$/)
92
92
  if commit_sha !~ pattern
93
93
  fail ArgumentError, "invalid value for \"commit_sha\", must conform to the pattern #{pattern}."
94
94
  end
@@ -21,6 +21,9 @@ module DatadogAPIClient::V2
21
21
  class DORAIncidentRequestAttributes
22
22
  include BaseGenericModel
23
23
 
24
+ # Environment name that was impacted by the incident.
25
+ attr_accessor :env
26
+
24
27
  # Unix timestamp in nanoseconds when the incident finished. It should not be older than 3 hours.
25
28
  attr_accessor :finished_at
26
29
 
@@ -49,6 +52,7 @@ module DatadogAPIClient::V2
49
52
  # @!visibility private
50
53
  def self.attribute_map
51
54
  {
55
+ :'env' => :'env',
52
56
  :'finished_at' => :'finished_at',
53
57
  :'git' => :'git',
54
58
  :'id' => :'id',
@@ -64,6 +68,7 @@ module DatadogAPIClient::V2
64
68
  # @!visibility private
65
69
  def self.openapi_types
66
70
  {
71
+ :'env' => :'String',
67
72
  :'finished_at' => :'Integer',
68
73
  :'git' => :'DORAGitInfo',
69
74
  :'id' => :'String',
@@ -91,6 +96,10 @@ module DatadogAPIClient::V2
91
96
  h[k.to_sym] = v
92
97
  }
93
98
 
99
+ if attributes.key?(:'env')
100
+ self.env = attributes[:'env']
101
+ end
102
+
94
103
  if attributes.key?(:'finished_at')
95
104
  self.finished_at = attributes[:'finished_at']
96
105
  end
@@ -159,6 +168,7 @@ module DatadogAPIClient::V2
159
168
  def ==(o)
160
169
  return true if self.equal?(o)
161
170
  self.class == o.class &&
171
+ env == o.env &&
162
172
  finished_at == o.finished_at &&
163
173
  git == o.git &&
164
174
  id == o.id &&
@@ -173,7 +183,7 @@ module DatadogAPIClient::V2
173
183
  # @return [Integer] Hash code
174
184
  # @!visibility private
175
185
  def hash
176
- [finished_at, git, id, name, service, severity, started_at, version].hash
186
+ [env, finished_at, git, id, name, service, severity, started_at, version].hash
177
187
  end
178
188
  end
179
189
  end
@@ -33,9 +33,15 @@ module DatadogAPIClient::V2
33
33
  # Your Host Filters.
34
34
  attr_accessor :host_filters
35
35
 
36
- # When enabled, Datadog performs configuration checks across your Google Cloud environment by continuously scanning every resource.
36
+ # When enabled, Datadog will activate the Cloud Security Monitoring product for this service account. Note: This requires resource_collection_enabled to be set to true.
37
37
  attr_accessor :is_cspm_enabled
38
38
 
39
+ # When enabled, Datadog will attempt to collect Security Command Center Findings. Note: This requires additional permissions on the service account.
40
+ attr_accessor :is_security_command_center_enabled
41
+
42
+ # When enabled, Datadog scans for all resources in your GCP environment.
43
+ attr_accessor :resource_collection_enabled
44
+
39
45
  # Attribute mapping from ruby-style variable name to JSON key.
40
46
  # @!visibility private
41
47
  def self.attribute_map
@@ -44,7 +50,9 @@ module DatadogAPIClient::V2
44
50
  :'automute' => :'automute',
45
51
  :'client_email' => :'client_email',
46
52
  :'host_filters' => :'host_filters',
47
- :'is_cspm_enabled' => :'is_cspm_enabled'
53
+ :'is_cspm_enabled' => :'is_cspm_enabled',
54
+ :'is_security_command_center_enabled' => :'is_security_command_center_enabled',
55
+ :'resource_collection_enabled' => :'resource_collection_enabled'
48
56
  }
49
57
  end
50
58
 
@@ -56,7 +64,9 @@ module DatadogAPIClient::V2
56
64
  :'automute' => :'Boolean',
57
65
  :'client_email' => :'String',
58
66
  :'host_filters' => :'Array<String>',
59
- :'is_cspm_enabled' => :'Boolean'
67
+ :'is_cspm_enabled' => :'Boolean',
68
+ :'is_security_command_center_enabled' => :'Boolean',
69
+ :'resource_collection_enabled' => :'Boolean'
60
70
  }
61
71
  end
62
72
 
@@ -99,6 +109,14 @@ module DatadogAPIClient::V2
99
109
  if attributes.key?(:'is_cspm_enabled')
100
110
  self.is_cspm_enabled = attributes[:'is_cspm_enabled']
101
111
  end
112
+
113
+ if attributes.key?(:'is_security_command_center_enabled')
114
+ self.is_security_command_center_enabled = attributes[:'is_security_command_center_enabled']
115
+ end
116
+
117
+ if attributes.key?(:'resource_collection_enabled')
118
+ self.resource_collection_enabled = attributes[:'resource_collection_enabled']
119
+ end
102
120
  end
103
121
 
104
122
  # Checks equality by comparing each attribute.
@@ -111,14 +129,16 @@ module DatadogAPIClient::V2
111
129
  automute == o.automute &&
112
130
  client_email == o.client_email &&
113
131
  host_filters == o.host_filters &&
114
- is_cspm_enabled == o.is_cspm_enabled
132
+ is_cspm_enabled == o.is_cspm_enabled &&
133
+ is_security_command_center_enabled == o.is_security_command_center_enabled &&
134
+ resource_collection_enabled == o.resource_collection_enabled
115
135
  end
116
136
 
117
137
  # Calculates hash code according to all attributes.
118
138
  # @return [Integer] Hash code
119
139
  # @!visibility private
120
140
  def hash
121
- [account_tags, automute, client_email, host_filters, is_cspm_enabled].hash
141
+ [account_tags, automute, client_email, host_filters, is_cspm_enabled, is_security_command_center_enabled, resource_collection_enabled].hash
122
142
  end
123
143
  end
124
144
  end
@@ -21,7 +21,7 @@ module DatadogAPIClient::V2
21
21
  class MetricPayload
22
22
  include BaseGenericModel
23
23
 
24
- # A list of time series to submit to Datadog.
24
+ # A list of timeseries to submit to Datadog.
25
25
  attr_reader :series
26
26
 
27
27
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -0,0 +1,90 @@
1
+ =begin
2
+ #Datadog API V2 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::V2
20
+ # Endpoint info extracted from an `OpenAPI` specification.
21
+ class OpenAPIEndpoint
22
+ include BaseGenericModel
23
+
24
+ # The endpoint method.
25
+ attr_accessor :method
26
+
27
+ # The endpoint path.
28
+ attr_accessor :path
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ # @!visibility private
32
+ def self.attribute_map
33
+ {
34
+ :'method' => :'method',
35
+ :'path' => :'path'
36
+ }
37
+ end
38
+
39
+ # Attribute type mapping.
40
+ # @!visibility private
41
+ def self.openapi_types
42
+ {
43
+ :'method' => :'String',
44
+ :'path' => :'String'
45
+ }
46
+ end
47
+
48
+ # Initializes the object
49
+ # @param attributes [Hash] Model attributes in the form of hash
50
+ # @!visibility private
51
+ def initialize(attributes = {})
52
+ if (!attributes.is_a?(Hash))
53
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::OpenAPIEndpoint` initialize method"
54
+ end
55
+
56
+ # check to see if the attribute exists and convert string to symbol for hash key
57
+ attributes = attributes.each_with_object({}) { |(k, v), h|
58
+ if (!self.class.attribute_map.key?(k.to_sym))
59
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::OpenAPIEndpoint`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
60
+ end
61
+ h[k.to_sym] = v
62
+ }
63
+
64
+ if attributes.key?(:'method')
65
+ self.method = attributes[:'method']
66
+ end
67
+
68
+ if attributes.key?(:'path')
69
+ self.path = attributes[:'path']
70
+ end
71
+ end
72
+
73
+ # Checks equality by comparing each attribute.
74
+ # @param o [Object] Object to be compared
75
+ # @!visibility private
76
+ def ==(o)
77
+ return true if self.equal?(o)
78
+ self.class == o.class &&
79
+ method == o.method &&
80
+ path == o.path
81
+ end
82
+
83
+ # Calculates hash code according to all attributes.
84
+ # @return [Integer] Hash code
85
+ # @!visibility private
86
+ def hash
87
+ [method, path].hash
88
+ end
89
+ end
90
+ end
@@ -0,0 +1,80 @@
1
+ =begin
2
+ #Datadog API V2 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::V2
20
+ # Object for API data in an `OpenAPI` format as a file.
21
+ class OpenAPIFile
22
+ include BaseGenericModel
23
+
24
+ # Binary `OpenAPI` spec file
25
+ attr_accessor :openapi_spec_file
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ # @!visibility private
29
+ def self.attribute_map
30
+ {
31
+ :'openapi_spec_file' => :'openapi_spec_file'
32
+ }
33
+ end
34
+
35
+ # Attribute type mapping.
36
+ # @!visibility private
37
+ def self.openapi_types
38
+ {
39
+ :'openapi_spec_file' => :'File'
40
+ }
41
+ end
42
+
43
+ # Initializes the object
44
+ # @param attributes [Hash] Model attributes in the form of hash
45
+ # @!visibility private
46
+ def initialize(attributes = {})
47
+ if (!attributes.is_a?(Hash))
48
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::OpenAPIFile` initialize method"
49
+ end
50
+
51
+ # check to see if the attribute exists and convert string to symbol for hash key
52
+ attributes = attributes.each_with_object({}) { |(k, v), h|
53
+ if (!self.class.attribute_map.key?(k.to_sym))
54
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::OpenAPIFile`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
55
+ end
56
+ h[k.to_sym] = v
57
+ }
58
+
59
+ if attributes.key?(:'openapi_spec_file')
60
+ self.openapi_spec_file = attributes[:'openapi_spec_file']
61
+ end
62
+ end
63
+
64
+ # Checks equality by comparing each attribute.
65
+ # @param o [Object] Object to be compared
66
+ # @!visibility private
67
+ def ==(o)
68
+ return true if self.equal?(o)
69
+ self.class == o.class &&
70
+ openapi_spec_file == o.openapi_spec_file
71
+ end
72
+
73
+ # Calculates hash code according to all attributes.
74
+ # @return [Integer] Hash code
75
+ # @!visibility private
76
+ def hash
77
+ [openapi_spec_file].hash
78
+ end
79
+ end
80
+ end
@@ -0,0 +1,98 @@
1
+ =begin
2
+ #Datadog API V2 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::V2
20
+ # Relationship between team membership and team
21
+ class RelationshipToUserTeamTeam
22
+ include BaseGenericModel
23
+
24
+ # The team associated with the membership
25
+ attr_reader :data
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ # @!visibility private
29
+ def self.attribute_map
30
+ {
31
+ :'data' => :'data'
32
+ }
33
+ end
34
+
35
+ # Attribute type mapping.
36
+ # @!visibility private
37
+ def self.openapi_types
38
+ {
39
+ :'data' => :'RelationshipToUserTeamTeamData'
40
+ }
41
+ end
42
+
43
+ # Initializes the object
44
+ # @param attributes [Hash] Model attributes in the form of hash
45
+ # @!visibility private
46
+ def initialize(attributes = {})
47
+ if (!attributes.is_a?(Hash))
48
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::RelationshipToUserTeamTeam` initialize method"
49
+ end
50
+
51
+ # check to see if the attribute exists and convert string to symbol for hash key
52
+ attributes = attributes.each_with_object({}) { |(k, v), h|
53
+ if (!self.class.attribute_map.key?(k.to_sym))
54
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::RelationshipToUserTeamTeam`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
55
+ end
56
+ h[k.to_sym] = v
57
+ }
58
+
59
+ if attributes.key?(:'data')
60
+ self.data = attributes[:'data']
61
+ end
62
+ end
63
+
64
+ # Check to see if the all the properties in the model are valid
65
+ # @return true if the model is valid
66
+ # @!visibility private
67
+ def valid?
68
+ return false if @data.nil?
69
+ true
70
+ end
71
+
72
+ # Custom attribute writer method with validation
73
+ # @param data [Object] Object to be assigned
74
+ # @!visibility private
75
+ def data=(data)
76
+ if data.nil?
77
+ fail ArgumentError, 'invalid value for "data", data cannot be nil.'
78
+ end
79
+ @data = data
80
+ end
81
+
82
+ # Checks equality by comparing each attribute.
83
+ # @param o [Object] Object to be compared
84
+ # @!visibility private
85
+ def ==(o)
86
+ return true if self.equal?(o)
87
+ self.class == o.class &&
88
+ data == o.data
89
+ end
90
+
91
+ # Calculates hash code according to all attributes.
92
+ # @return [Integer] Hash code
93
+ # @!visibility private
94
+ def hash
95
+ [data].hash
96
+ end
97
+ end
98
+ end
@@ -0,0 +1,119 @@
1
+ =begin
2
+ #Datadog API V2 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::V2
20
+ # The team associated with the membership
21
+ class RelationshipToUserTeamTeamData
22
+ include BaseGenericModel
23
+
24
+ # The ID of the team associated with the membership
25
+ attr_reader :id
26
+
27
+ # User team team type
28
+ attr_reader :type
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ # @!visibility private
32
+ def self.attribute_map
33
+ {
34
+ :'id' => :'id',
35
+ :'type' => :'type'
36
+ }
37
+ end
38
+
39
+ # Attribute type mapping.
40
+ # @!visibility private
41
+ def self.openapi_types
42
+ {
43
+ :'id' => :'String',
44
+ :'type' => :'UserTeamTeamType'
45
+ }
46
+ end
47
+
48
+ # Initializes the object
49
+ # @param attributes [Hash] Model attributes in the form of hash
50
+ # @!visibility private
51
+ def initialize(attributes = {})
52
+ if (!attributes.is_a?(Hash))
53
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::RelationshipToUserTeamTeamData` initialize method"
54
+ end
55
+
56
+ # check to see if the attribute exists and convert string to symbol for hash key
57
+ attributes = attributes.each_with_object({}) { |(k, v), h|
58
+ if (!self.class.attribute_map.key?(k.to_sym))
59
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::RelationshipToUserTeamTeamData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
60
+ end
61
+ h[k.to_sym] = v
62
+ }
63
+
64
+ if attributes.key?(:'id')
65
+ self.id = attributes[:'id']
66
+ end
67
+
68
+ if attributes.key?(:'type')
69
+ self.type = attributes[:'type']
70
+ end
71
+ end
72
+
73
+ # Check to see if the all the properties in the model are valid
74
+ # @return true if the model is valid
75
+ # @!visibility private
76
+ def valid?
77
+ return false if @id.nil?
78
+ return false if @type.nil?
79
+ true
80
+ end
81
+
82
+ # Custom attribute writer method with validation
83
+ # @param id [Object] Object to be assigned
84
+ # @!visibility private
85
+ def id=(id)
86
+ if id.nil?
87
+ fail ArgumentError, 'invalid value for "id", id cannot be nil.'
88
+ end
89
+ @id = id
90
+ end
91
+
92
+ # Custom attribute writer method with validation
93
+ # @param type [Object] Object to be assigned
94
+ # @!visibility private
95
+ def type=(type)
96
+ if type.nil?
97
+ fail ArgumentError, 'invalid value for "type", type cannot be nil.'
98
+ end
99
+ @type = type
100
+ end
101
+
102
+ # Checks equality by comparing each attribute.
103
+ # @param o [Object] Object to be compared
104
+ # @!visibility private
105
+ def ==(o)
106
+ return true if self.equal?(o)
107
+ self.class == o.class &&
108
+ id == o.id &&
109
+ type == o.type
110
+ end
111
+
112
+ # Calculates hash code according to all attributes.
113
+ # @return [Integer] Hash code
114
+ # @!visibility private
115
+ def hash
116
+ [id, type].hash
117
+ end
118
+ end
119
+ end