datadog_api_client 1.11.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (277) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/schemas/v1/openapi.yaml +291 -114
  4. data/.generator/schemas/v2/openapi.yaml +1156 -41
  5. data/.generator/src/generator/cli.py +57 -40
  6. data/.generator/src/generator/openapi.py +12 -6
  7. data/.generator/src/generator/templates/api.j2 +14 -13
  8. data/.generator/src/generator/templates/api_client.j2 +63 -11
  9. data/.generator/src/generator/templates/configuration.j2 +12 -8
  10. data/.generator/src/generator/templates/example.j2 +1 -1
  11. data/.generator/src/generator/templates/inflector.j2 +28 -0
  12. data/.generator/src/generator/templates/model_base.j2 +2 -2
  13. data/.generator/src/generator/templates/model_oneof.j2 +1 -1
  14. data/.generator/src/generator/templates/package.j2 +7 -12
  15. data/.github/workflows/approved_status.yml +0 -2
  16. data/.github/workflows/codeql-analysis.yml +49 -0
  17. data/.github/workflows/docs.yml +1 -1
  18. data/.github/workflows/prepare_release.yml +1 -1
  19. data/.github/workflows/publish.yml +1 -1
  20. data/.github/workflows/release.yml +1 -1
  21. data/.github/workflows/test.yml +4 -6
  22. data/.github/workflows/test_integration.yml +1 -1
  23. data/.pre-commit-config.yaml +3 -12
  24. data/CHANGELOG.md +25 -0
  25. data/Gemfile +1 -0
  26. data/Makefile +1 -2
  27. data/datadog_api_client.gemspec +2 -0
  28. data/examples/v1/downtimes/CreateDowntime_1393233946.rb +3 -0
  29. data/examples/v1/downtimes/CreateDowntime_2908359488.rb +3 -0
  30. data/examples/v1/downtimes/CreateDowntime_3059354445.rb +3 -0
  31. data/examples/v1/events/ListEvents.rb +1 -1
  32. data/examples/v1/service-level-objectives/GetSLOHistory.rb +1 -1
  33. data/examples/v1/service-level-objectives/SearchSLO.rb +1 -1
  34. data/examples/v1/synthetics/CreateSyntheticsBrowserTest_2932742688.rb +1 -1
  35. data/examples/v1/synthetics/GetAPITestLatestResults.rb +1 -1
  36. data/examples/v1/synthetics/GetAPITestResult.rb +1 -1
  37. data/examples/v1/synthetics/GetBrowserTestLatestResults.rb +1 -1
  38. data/examples/v1/synthetics/GetBrowserTestResult.rb +1 -1
  39. data/examples/v1/usage-metering/GetDailyCustomReports.rb +1 -1
  40. data/examples/v1/usage-metering/GetHourlyUsageAttribution.rb +0 -3
  41. data/examples/v1/usage-metering/GetMonthlyCustomReports.rb +1 -1
  42. data/examples/v1/usage-metering/GetMonthlyUsageAttribution.rb +0 -3
  43. data/examples/v1/usage-metering/GetSpecifiedDailyCustomReports.rb +1 -1
  44. data/examples/v1/usage-metering/GetSpecifiedMonthlyCustomReports.rb +1 -1
  45. data/examples/v1/usage-metering/GetUsageAttribution.rb +1 -1
  46. data/examples/v1/usage-metering/GetUsageCIApp.rb +2 -5
  47. data/examples/v1/usage-metering/GetUsageCIApp_1064440884.rb +8 -0
  48. data/examples/v1/usage-metering/GetUsageCWS.rb +2 -5
  49. data/examples/v1/usage-metering/GetUsageCWS_736958514.rb +8 -0
  50. data/examples/v1/usage-metering/GetUsageDBM.rb +2 -5
  51. data/examples/v1/usage-metering/GetUsageDBM_3446806203.rb +8 -0
  52. data/examples/v1/usage-metering/GetUsageLambda.rb +2 -5
  53. data/examples/v1/usage-metering/GetUsageLambda_3132428705.rb +8 -0
  54. data/examples/v1/usage-metering/GetUsageLogs.rb +2 -5
  55. data/examples/v1/usage-metering/GetUsageLogsByIndex.rb +2 -5
  56. data/examples/v1/usage-metering/GetUsageLogsByIndex_1025184776.rb +8 -0
  57. data/examples/v1/usage-metering/GetUsageLogs_2562396405.rb +8 -0
  58. data/examples/v1/usage-metering/GetUsageNetworkFlows.rb +2 -5
  59. data/examples/v1/usage-metering/GetUsageNetworkFlows_1239422069.rb +8 -0
  60. data/examples/v1/usage-metering/GetUsageNetworkHosts.rb +2 -5
  61. data/examples/v1/usage-metering/GetUsageNetworkHosts_1249907835.rb +8 -0
  62. data/examples/v1/usage-metering/GetUsageOnlineArchive.rb +2 -5
  63. data/examples/v1/usage-metering/GetUsageOnlineArchive_1501172903.rb +8 -0
  64. data/examples/v1/usage-metering/GetUsageRumSessions.rb +2 -5
  65. data/examples/v1/usage-metering/GetUsageRumSessions_714937291.rb +8 -0
  66. data/examples/v1/usage-metering/GetUsageRumUnits.rb +2 -5
  67. data/examples/v1/usage-metering/GetUsageRumUnits_3959755399.rb +8 -0
  68. data/examples/v1/usage-metering/GetUsageSDS.rb +2 -5
  69. data/examples/v1/usage-metering/GetUsageSDS_271128478.rb +8 -0
  70. data/examples/v1/usage-metering/GetUsageSynthetics.rb +1 -1
  71. data/examples/v1/usage-metering/GetUsageSyntheticsAPI.rb +2 -5
  72. data/examples/v1/usage-metering/GetUsageSyntheticsAPI_4048033529.rb +8 -0
  73. data/examples/v1/usage-metering/GetUsageSyntheticsBrowser.rb +2 -5
  74. data/examples/v1/usage-metering/GetUsageSyntheticsBrowser_1704663299.rb +8 -0
  75. data/examples/v2/events/ListEvents.rb +8 -0
  76. data/examples/v2/events/ListEvents_2663715109.rb +14 -0
  77. data/examples/v2/events/SearchEvents.rb +23 -0
  78. data/examples/v2/incident-services/CreateIncidentService.rb +1 -1
  79. data/examples/v2/incident-services/DeleteIncidentService.rb +1 -1
  80. data/examples/v2/incident-services/GetIncidentService.rb +1 -1
  81. data/examples/v2/incident-services/ListIncidentServices.rb +1 -1
  82. data/examples/v2/incident-services/UpdateIncidentService.rb +1 -1
  83. data/examples/v2/incident-teams/CreateIncidentTeam.rb +1 -1
  84. data/examples/v2/incident-teams/DeleteIncidentTeam.rb +1 -1
  85. data/examples/v2/incident-teams/GetIncidentTeam.rb +1 -1
  86. data/examples/v2/incident-teams/ListIncidentTeams.rb +1 -1
  87. data/examples/v2/incident-teams/UpdateIncidentTeam.rb +1 -1
  88. data/examples/v2/incidents/CreateIncident.rb +1 -1
  89. data/examples/v2/incidents/DeleteIncident.rb +1 -1
  90. data/examples/v2/incidents/GetIncident.rb +1 -1
  91. data/examples/v2/incidents/ListIncidents.rb +1 -1
  92. data/examples/v2/incidents/UpdateIncident.rb +1 -1
  93. data/examples/v2/incidents/UpdateIncident_1009194038.rb +1 -1
  94. data/examples/v2/incidents/UpdateIncident_3369341440.rb +1 -1
  95. data/examples/v2/metrics/SubmitMetrics.rb +6 -0
  96. data/examples/v2/security-monitoring/EditSecurityMonitoringSignalAssignee.rb +15 -0
  97. data/examples/v2/security-monitoring/EditSecurityMonitoringSignalIncidents.rb +15 -0
  98. data/examples/v2/security-monitoring/EditSecurityMonitoringSignalState.rb +14 -0
  99. data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule.rb +1 -0
  100. data/examples/v2/usage-metering/GetEstimatedCostByOrg.rb +5 -2
  101. data/examples/v2/usage-metering/GetEstimatedCostByOrg_2734954020.rb +11 -0
  102. data/examples/v2/usage-metering/GetEstimatedCostByOrg_3186693804.rb +11 -0
  103. data/examples/v2/usage-metering/GetUsageApplicationSecurityMonitoring.rb +2 -5
  104. data/examples/v2/usage-metering/GetUsageApplicationSecurityMonitoring_3959166796.rb +8 -0
  105. data/examples/v2/usage-metering/GetUsageLambdaTracedInvocations.rb +2 -5
  106. data/examples/v2/usage-metering/GetUsageLambdaTracedInvocations_1436752065.rb +8 -0
  107. data/examples/v2/usage-metering/GetUsageObservabilityPipelines.rb +2 -5
  108. data/examples/v2/usage-metering/GetUsageObservabilityPipelines_970725512.rb +8 -0
  109. data/lib/datadog_api_client/{v2/api_client.rb → api_client.rb} +63 -11
  110. data/lib/datadog_api_client/api_key_configuration.rb +1 -18
  111. data/lib/datadog_api_client/{v1/configuration.rb → configuration.rb} +84 -31
  112. data/lib/datadog_api_client/inflector.rb +1293 -0
  113. data/lib/datadog_api_client/models.rb +66 -0
  114. data/lib/datadog_api_client/v1/api/authentication_api.rb +3 -11
  115. data/lib/datadog_api_client/v1/api/aws_integration_api.rb +19 -91
  116. data/lib/datadog_api_client/v1/api/aws_logs_integration_api.rb +15 -71
  117. data/lib/datadog_api_client/v1/api/azure_integration_api.rb +11 -51
  118. data/lib/datadog_api_client/v1/api/dashboard_lists_api.rb +11 -51
  119. data/lib/datadog_api_client/v1/api/dashboards_api.rb +15 -71
  120. data/lib/datadog_api_client/v1/api/downtimes_api.rb +15 -71
  121. data/lib/datadog_api_client/v1/api/events_api.rb +9 -33
  122. data/lib/datadog_api_client/v1/api/gcp_integration_api.rb +9 -41
  123. data/lib/datadog_api_client/v1/api/hosts_api.rb +9 -41
  124. data/lib/datadog_api_client/v1/api/ip_ranges_api.rb +3 -11
  125. data/lib/datadog_api_client/v1/api/key_management_api.rb +21 -101
  126. data/lib/datadog_api_client/v1/api/logs_api.rb +5 -21
  127. data/lib/datadog_api_client/v1/api/logs_indexes_api.rb +13 -61
  128. data/lib/datadog_api_client/v1/api/logs_pipelines_api.rb +15 -71
  129. data/lib/datadog_api_client/v1/api/metrics_api.rb +15 -71
  130. data/lib/datadog_api_client/v1/api/monitors_api.rb +21 -101
  131. data/lib/datadog_api_client/v1/api/notebooks_api.rb +11 -51
  132. data/lib/datadog_api_client/v1/api/organizations_api.rb +13 -61
  133. data/lib/datadog_api_client/v1/api/pager_duty_integration_api.rb +9 -41
  134. data/lib/datadog_api_client/v1/api/security_monitoring_api.rb +8 -32
  135. data/lib/datadog_api_client/v1/api/service_checks_api.rb +3 -11
  136. data/lib/datadog_api_client/v1/api/service_level_objective_corrections_api.rb +11 -51
  137. data/lib/datadog_api_client/v1/api/service_level_objectives_api.rb +31 -99
  138. data/lib/datadog_api_client/v1/api/slack_integration_api.rb +11 -51
  139. data/lib/datadog_api_client/v1/api/snapshots_api.rb +3 -11
  140. data/lib/datadog_api_client/v1/api/synthetics_api.rb +55 -271
  141. data/lib/datadog_api_client/v1/api/tags_api.rb +11 -51
  142. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +171 -418
  143. data/lib/datadog_api_client/v1/api/users_api.rb +11 -51
  144. data/lib/datadog_api_client/v1/api/webhooks_integration_api.rb +17 -81
  145. data/lib/datadog_api_client/v1/model_base.rb +2 -2
  146. data/lib/datadog_api_client/v1/models/distribution_point_item.rb +1 -1
  147. data/lib/datadog_api_client/v1/models/distribution_widget_histogram_request_query.rb +1 -1
  148. data/lib/datadog_api_client/v1/models/formula_and_function_query_definition.rb +1 -1
  149. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_body.rb +5 -1
  150. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +7 -0
  151. data/lib/datadog_api_client/v1/models/logs_processor.rb +1 -1
  152. data/lib/datadog_api_client/v1/models/monitor_formula_and_function_query_definition.rb +1 -1
  153. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_body.rb +6 -2
  154. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +14 -0
  155. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +21 -1
  156. data/lib/datadog_api_client/v1/models/notebook_cell_create_request_attributes.rb +1 -1
  157. data/lib/datadog_api_client/v1/models/notebook_cell_response_attributes.rb +1 -1
  158. data/lib/datadog_api_client/v1/models/notebook_cell_time.rb +1 -1
  159. data/lib/datadog_api_client/v1/models/notebook_cell_update_request_attributes.rb +1 -1
  160. data/lib/datadog_api_client/v1/models/notebook_global_time.rb +1 -1
  161. data/lib/datadog_api_client/v1/models/notebook_update_cell.rb +1 -1
  162. data/lib/datadog_api_client/v1/models/sunburst_widget_legend.rb +1 -1
  163. data/lib/datadog_api_client/v1/models/synthetics_assertion.rb +1 -1
  164. data/lib/datadog_api_client/v1/models/synthetics_basic_auth.rb +1 -1
  165. data/lib/datadog_api_client/v1/models/tree_map_color_by.rb +1 -1
  166. data/lib/datadog_api_client/v1/models/tree_map_group_by.rb +1 -1
  167. data/lib/datadog_api_client/v1/models/tree_map_size_by.rb +1 -1
  168. data/lib/datadog_api_client/v1/models/tree_map_widget_definition.rb +28 -6
  169. data/lib/datadog_api_client/v1/models/usage_attribution_body.rb +6 -2
  170. data/lib/datadog_api_client/v1/models/usage_attribution_sort.rb +2 -0
  171. data/lib/datadog_api_client/v1/models/usage_attribution_supported_metrics.rb +2 -0
  172. data/lib/datadog_api_client/v1/models/usage_attribution_values.rb +22 -2
  173. data/lib/datadog_api_client/v1/models/widget_definition.rb +1 -1
  174. data/lib/datadog_api_client/v2/api/audit_api.rb +11 -25
  175. data/lib/datadog_api_client/v2/api/authn_mappings_api.rb +11 -51
  176. data/lib/datadog_api_client/v2/api/cloud_workload_security_api.rb +13 -61
  177. data/lib/datadog_api_client/v2/api/dashboard_lists_api.rb +9 -41
  178. data/lib/datadog_api_client/v2/api/events_api.rb +228 -0
  179. data/lib/datadog_api_client/v2/api/incident_services_api.rb +36 -46
  180. data/lib/datadog_api_client/v2/api/incident_teams_api.rb +36 -46
  181. data/lib/datadog_api_client/v2/api/incidents_api.rb +39 -48
  182. data/lib/datadog_api_client/v2/api/key_management_api.rb +29 -141
  183. data/lib/datadog_api_client/v2/api/logs_api.rb +15 -45
  184. data/lib/datadog_api_client/v2/api/logs_archives_api.rb +21 -101
  185. data/lib/datadog_api_client/v2/api/logs_metrics_api.rb +11 -51
  186. data/lib/datadog_api_client/v2/api/metrics_api.rb +26 -112
  187. data/lib/datadog_api_client/v2/api/opsgenie_integration_api.rb +11 -51
  188. data/lib/datadog_api_client/v2/api/organizations_api.rb +3 -11
  189. data/lib/datadog_api_client/v2/api/processes_api.rb +6 -13
  190. data/lib/datadog_api_client/v2/api/roles_api.rb +27 -131
  191. data/lib/datadog_api_client/v2/api/rum_api.rb +13 -35
  192. data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +247 -125
  193. data/lib/datadog_api_client/v2/api/service_accounts_api.rb +11 -51
  194. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +132 -68
  195. data/lib/datadog_api_client/v2/api/users_api.rb +21 -101
  196. data/lib/datadog_api_client/v2/model_base.rb +2 -2
  197. data/lib/datadog_api_client/v2/models/api_key_response_included_item.rb +1 -1
  198. data/lib/datadog_api_client/v2/models/application_key_response_included_item.rb +1 -1
  199. data/lib/datadog_api_client/v2/models/authn_mapping_included.rb +1 -1
  200. data/lib/datadog_api_client/v2/models/event.rb +141 -0
  201. data/lib/datadog_api_client/v2/models/event_attributes.rb +305 -0
  202. data/lib/datadog_api_client/v2/models/event_priority.rb +27 -0
  203. data/lib/datadog_api_client/v2/models/event_response.rb +133 -0
  204. data/lib/datadog_api_client/v2/models/event_response_attributes.rb +133 -0
  205. data/lib/datadog_api_client/v2/models/event_status_type.rb +35 -0
  206. data/lib/datadog_api_client/v2/models/event_type.rb +26 -0
  207. data/lib/datadog_api_client/v2/models/events_list_request.rb +142 -0
  208. data/lib/datadog_api_client/v2/models/events_list_response.rb +133 -0
  209. data/lib/datadog_api_client/v2/models/events_list_response_links.rb +112 -0
  210. data/lib/datadog_api_client/v2/models/events_query_filter.rb +137 -0
  211. data/lib/datadog_api_client/v2/models/events_query_options.rb +124 -0
  212. data/lib/datadog_api_client/v2/models/events_request_page.rb +134 -0
  213. data/lib/datadog_api_client/v2/models/events_response_metadata.rb +144 -0
  214. data/lib/datadog_api_client/v2/models/events_response_metadata_page.rb +112 -0
  215. data/lib/datadog_api_client/v2/models/events_sort.rb +27 -0
  216. data/lib/datadog_api_client/v2/models/events_warning.rb +131 -0
  217. data/lib/datadog_api_client/v2/models/hourly_usage.rb +133 -0
  218. data/lib/datadog_api_client/v2/models/hourly_usage_attributes.rb +163 -0
  219. data/lib/datadog_api_client/v2/models/hourly_usage_measurement.rb +122 -0
  220. data/lib/datadog_api_client/v2/models/hourly_usage_metadata.rb +111 -0
  221. data/lib/datadog_api_client/v2/models/hourly_usage_pagination.rb +112 -0
  222. data/lib/datadog_api_client/v2/models/hourly_usage_response.rb +123 -0
  223. data/lib/datadog_api_client/v2/models/incident_field_attributes.rb +1 -1
  224. data/lib/datadog_api_client/v2/models/incident_response_included_item.rb +1 -1
  225. data/lib/datadog_api_client/v2/models/incident_service_included_items.rb +1 -1
  226. data/lib/datadog_api_client/v2/models/incident_team_included_items.rb +1 -1
  227. data/lib/datadog_api_client/v2/models/incident_timeline_cell_create_attributes.rb +1 -1
  228. data/lib/datadog_api_client/v2/models/logs_aggregate_bucket_value.rb +1 -1
  229. data/lib/datadog_api_client/v2/models/logs_archive_create_request_destination.rb +1 -1
  230. data/lib/datadog_api_client/v2/models/logs_archive_destination.rb +1 -1
  231. data/lib/datadog_api_client/v2/models/logs_group_by_missing.rb +1 -1
  232. data/lib/datadog_api_client/v2/models/logs_group_by_total.rb +1 -1
  233. data/lib/datadog_api_client/v2/models/metric_intake_type.rb +1 -2
  234. data/lib/datadog_api_client/v2/models/metric_resource.rb +2 -2
  235. data/lib/datadog_api_client/v2/models/metric_series.rb +1 -1
  236. data/lib/datadog_api_client/v2/models/metric_volumes.rb +1 -1
  237. data/lib/datadog_api_client/v2/models/metrics_and_metric_tag_configurations.rb +1 -1
  238. data/lib/datadog_api_client/v2/models/monitor_type.rb +215 -0
  239. data/lib/datadog_api_client/v2/models/rum_aggregate_bucket_value.rb +1 -1
  240. data/lib/datadog_api_client/v2/models/rum_group_by_missing.rb +1 -1
  241. data/lib/datadog_api_client/v2/models/rum_group_by_total.rb +1 -1
  242. data/lib/datadog_api_client/v2/models/security_monitoring_rule_query.rb +13 -1
  243. data/lib/datadog_api_client/v2/models/security_monitoring_rule_query_create.rb +13 -1
  244. data/lib/datadog_api_client/v2/models/security_monitoring_signal_archive_reason.rb +29 -0
  245. data/lib/datadog_api_client/v2/models/security_monitoring_signal_assignee_update_attributes.rb +132 -0
  246. data/lib/datadog_api_client/v2/models/security_monitoring_signal_assignee_update_data.rb +122 -0
  247. data/lib/datadog_api_client/v2/models/security_monitoring_signal_assignee_update_request.rb +122 -0
  248. data/lib/datadog_api_client/v2/models/security_monitoring_signal_incidents_update_attributes.rb +134 -0
  249. data/lib/datadog_api_client/v2/models/security_monitoring_signal_incidents_update_data.rb +122 -0
  250. data/lib/datadog_api_client/v2/models/security_monitoring_signal_incidents_update_request.rb +122 -0
  251. data/lib/datadog_api_client/v2/models/security_monitoring_signal_state.rb +28 -0
  252. data/lib/datadog_api_client/v2/models/security_monitoring_signal_state_update_attributes.rb +152 -0
  253. data/lib/datadog_api_client/v2/models/security_monitoring_signal_state_update_data.rb +122 -0
  254. data/lib/datadog_api_client/v2/models/security_monitoring_signal_state_update_request.rb +122 -0
  255. data/lib/datadog_api_client/v2/models/security_monitoring_signal_triage_attributes.rb +248 -0
  256. data/lib/datadog_api_client/v2/models/security_monitoring_signal_triage_update_data.rb +111 -0
  257. data/lib/datadog_api_client/v2/models/security_monitoring_signal_triage_update_response.rb +122 -0
  258. data/lib/datadog_api_client/v2/models/security_monitoring_triage_user.rb +152 -0
  259. data/lib/datadog_api_client/v2/models/user_response_included_item.rb +1 -1
  260. data/lib/datadog_api_client/v2.rb +40 -0
  261. data/lib/datadog_api_client/version.rb +1 -1
  262. data/lib/datadog_api_client.rb +11 -5
  263. data/spec/{v1/api_client_spec.rb → api_client_spec.rb} +29 -29
  264. data/spec/{v1/configuration_spec.rb → configuration_spec.rb} +3 -3
  265. data/spec/spec_helper.rb +1 -3
  266. metadata +97 -21
  267. data/.dockerignore +0 -1
  268. data/.generator/src/generator/templates/api_error.j2 +0 -49
  269. data/examples/v2/usage-metering/GetEstimatedCostByOrg_1171921972.rb +0 -9
  270. data/examples/v2/usage-metering/GetEstimatedCostByOrg_627383212.rb +0 -9
  271. data/lib/datadog_api_client/v1/api_client.rb +0 -453
  272. data/lib/datadog_api_client/v1/api_error.rb +0 -60
  273. data/lib/datadog_api_client/v1.rb +0 -813
  274. data/lib/datadog_api_client/v2/api_error.rb +0 -60
  275. data/lib/datadog_api_client/v2/configuration.rb +0 -420
  276. data/spec/v2/api_client_spec.rb +0 -210
  277. data/spec/v2/configuration_spec.rb +0 -45
@@ -0,0 +1,305 @@
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 description of attributes from your event.
21
+ class EventAttributes
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # Aggregation key of the event.
29
+ attr_accessor :aggregation_key
30
+
31
+ # POSIX timestamp of the event. Must be sent as an integer (no quotation marks).
32
+ # Limited to events no older than 18 hours.
33
+ attr_accessor :date_happened
34
+
35
+ # A device name.
36
+ attr_accessor :device_name
37
+
38
+ # The duration between the triggering of the event and its recovery in nanoseconds.
39
+ attr_accessor :duration
40
+
41
+ # The event title.
42
+ attr_accessor :event_object
43
+
44
+ # The metadata associated with a request.
45
+ attr_accessor :evt
46
+
47
+ # Host name to associate with the event.
48
+ # Any tags associated with the host are also applied to this event.
49
+ attr_accessor :hostname
50
+
51
+ # Attributes from the monitor that triggered the event.
52
+ attr_accessor :monitor
53
+
54
+ # List of groups referred to in the event.
55
+ attr_accessor :monitor_groups
56
+
57
+ # ID of the monitor that triggered the event. When an event isn't related to a monitor, this field is empty.
58
+ attr_accessor :monitor_id
59
+
60
+ # The priority of the event's monitor. For example, `normal` or `low`.
61
+ attr_accessor :priority
62
+
63
+ # Related event ID.
64
+ attr_accessor :related_event_id
65
+
66
+ # Service that triggered the event.
67
+ attr_accessor :service
68
+
69
+ # The type of event being posted.
70
+ # For example, `nagios`, `hudson`, `jenkins`, `my_apps`, `chef`, `puppet`, `git` or `bitbucket`.
71
+ # The list of standard source attribute values is [available here](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value).
72
+ attr_accessor :source_type_name
73
+
74
+ # Identifier for the source of the event, such as a monitor alert, an externally-submitted event, or an integration.
75
+ attr_accessor :sourcecategory
76
+
77
+ # If an alert event is enabled, its status is one of the following:
78
+ # `failure`, `error`, `warning`, `info`, `success`, `user_update`,
79
+ # `recommendation`, or `snapshot`.
80
+ attr_accessor :status
81
+
82
+ # A list of tags to apply to the event.
83
+ attr_accessor :tags
84
+
85
+ # POSIX timestamp of your event in milliseconds.
86
+ attr_accessor :timestamp
87
+
88
+ # The event title.
89
+ attr_accessor :title
90
+
91
+ # Attribute mapping from ruby-style variable name to JSON key.
92
+ # @!visibility private
93
+ def self.attribute_map
94
+ {
95
+ :'aggregation_key' => :'aggregation_key',
96
+ :'date_happened' => :'date_happened',
97
+ :'device_name' => :'device_name',
98
+ :'duration' => :'duration',
99
+ :'event_object' => :'event_object',
100
+ :'evt' => :'evt',
101
+ :'hostname' => :'hostname',
102
+ :'monitor' => :'monitor',
103
+ :'monitor_groups' => :'monitor_groups',
104
+ :'monitor_id' => :'monitor_id',
105
+ :'priority' => :'priority',
106
+ :'related_event_id' => :'related_event_id',
107
+ :'service' => :'service',
108
+ :'source_type_name' => :'source_type_name',
109
+ :'sourcecategory' => :'sourcecategory',
110
+ :'status' => :'status',
111
+ :'tags' => :'tags',
112
+ :'timestamp' => :'timestamp',
113
+ :'title' => :'title'
114
+ }
115
+ end
116
+
117
+ # Returns all the JSON keys this model knows about
118
+ # @!visibility private
119
+ def self.acceptable_attributes
120
+ attribute_map.values
121
+ end
122
+
123
+ # Attribute type mapping.
124
+ # @!visibility private
125
+ def self.openapi_types
126
+ {
127
+ :'aggregation_key' => :'String',
128
+ :'date_happened' => :'Integer',
129
+ :'device_name' => :'String',
130
+ :'duration' => :'Integer',
131
+ :'event_object' => :'String',
132
+ :'evt' => :'Event',
133
+ :'hostname' => :'String',
134
+ :'monitor' => :'MonitorType',
135
+ :'monitor_groups' => :'Array<String>',
136
+ :'monitor_id' => :'Integer',
137
+ :'priority' => :'EventPriority',
138
+ :'related_event_id' => :'Integer',
139
+ :'service' => :'String',
140
+ :'source_type_name' => :'String',
141
+ :'sourcecategory' => :'String',
142
+ :'status' => :'EventStatusType',
143
+ :'tags' => :'Array<String>',
144
+ :'timestamp' => :'Integer',
145
+ :'title' => :'String'
146
+ }
147
+ end
148
+
149
+ # List of attributes with nullable: true
150
+ # @!visibility private
151
+ def self.openapi_nullable
152
+ Set.new([
153
+ :'monitor',
154
+ :'monitor_groups',
155
+ :'monitor_id',
156
+ :'priority',
157
+ ])
158
+ end
159
+
160
+ # Initializes the object
161
+ # @param attributes [Hash] Model attributes in the form of hash
162
+ # @!visibility private
163
+ def initialize(attributes = {})
164
+ if (!attributes.is_a?(Hash))
165
+ fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::EventAttributes` initialize method"
166
+ end
167
+
168
+ # check to see if the attribute exists and convert string to symbol for hash key
169
+ attributes = attributes.each_with_object({}) { |(k, v), h|
170
+ if (!self.class.attribute_map.key?(k.to_sym))
171
+ fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::EventAttributes`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
172
+ end
173
+ h[k.to_sym] = v
174
+ }
175
+
176
+ if attributes.key?(:'aggregation_key')
177
+ self.aggregation_key = attributes[:'aggregation_key']
178
+ end
179
+
180
+ if attributes.key?(:'date_happened')
181
+ self.date_happened = attributes[:'date_happened']
182
+ end
183
+
184
+ if attributes.key?(:'device_name')
185
+ self.device_name = attributes[:'device_name']
186
+ end
187
+
188
+ if attributes.key?(:'duration')
189
+ self.duration = attributes[:'duration']
190
+ end
191
+
192
+ if attributes.key?(:'event_object')
193
+ self.event_object = attributes[:'event_object']
194
+ end
195
+
196
+ if attributes.key?(:'evt')
197
+ self.evt = attributes[:'evt']
198
+ end
199
+
200
+ if attributes.key?(:'hostname')
201
+ self.hostname = attributes[:'hostname']
202
+ end
203
+
204
+ if attributes.key?(:'monitor')
205
+ self.monitor = attributes[:'monitor']
206
+ end
207
+
208
+ if attributes.key?(:'monitor_groups')
209
+ if (value = attributes[:'monitor_groups']).is_a?(Array)
210
+ self.monitor_groups = value
211
+ end
212
+ end
213
+
214
+ if attributes.key?(:'monitor_id')
215
+ self.monitor_id = attributes[:'monitor_id']
216
+ end
217
+
218
+ if attributes.key?(:'priority')
219
+ self.priority = attributes[:'priority']
220
+ end
221
+
222
+ if attributes.key?(:'related_event_id')
223
+ self.related_event_id = attributes[:'related_event_id']
224
+ end
225
+
226
+ if attributes.key?(:'service')
227
+ self.service = attributes[:'service']
228
+ end
229
+
230
+ if attributes.key?(:'source_type_name')
231
+ self.source_type_name = attributes[:'source_type_name']
232
+ end
233
+
234
+ if attributes.key?(:'sourcecategory')
235
+ self.sourcecategory = attributes[:'sourcecategory']
236
+ end
237
+
238
+ if attributes.key?(:'status')
239
+ self.status = attributes[:'status']
240
+ end
241
+
242
+ if attributes.key?(:'tags')
243
+ if (value = attributes[:'tags']).is_a?(Array)
244
+ self.tags = value
245
+ end
246
+ end
247
+
248
+ if attributes.key?(:'timestamp')
249
+ self.timestamp = attributes[:'timestamp']
250
+ end
251
+
252
+ if attributes.key?(:'title')
253
+ self.title = attributes[:'title']
254
+ end
255
+ end
256
+
257
+ # Check to see if the all the properties in the model are valid
258
+ # @return true if the model is valid
259
+ # @!visibility private
260
+ def valid?
261
+ true
262
+ end
263
+
264
+ # Checks equality by comparing each attribute.
265
+ # @param o [Object] Object to be compared
266
+ # @!visibility private
267
+ def ==(o)
268
+ return true if self.equal?(o)
269
+ self.class == o.class &&
270
+ aggregation_key == o.aggregation_key &&
271
+ date_happened == o.date_happened &&
272
+ device_name == o.device_name &&
273
+ duration == o.duration &&
274
+ event_object == o.event_object &&
275
+ evt == o.evt &&
276
+ hostname == o.hostname &&
277
+ monitor == o.monitor &&
278
+ monitor_groups == o.monitor_groups &&
279
+ monitor_id == o.monitor_id &&
280
+ priority == o.priority &&
281
+ related_event_id == o.related_event_id &&
282
+ service == o.service &&
283
+ source_type_name == o.source_type_name &&
284
+ sourcecategory == o.sourcecategory &&
285
+ status == o.status &&
286
+ tags == o.tags &&
287
+ timestamp == o.timestamp &&
288
+ title == o.title
289
+ end
290
+
291
+ # @see the `==` method
292
+ # @param o [Object] Object to be compared
293
+ # @!visibility private
294
+ def eql?(o)
295
+ self == o
296
+ end
297
+
298
+ # Calculates hash code according to all attributes.
299
+ # @return [Integer] Hash code
300
+ # @!visibility private
301
+ def hash
302
+ [aggregation_key, date_happened, device_name, duration, event_object, evt, hostname, monitor, monitor_groups, monitor_id, priority, related_event_id, service, source_type_name, sourcecategory, status, tags, timestamp, title].hash
303
+ end
304
+ end
305
+ end
@@ -0,0 +1,27 @@
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 priority of the event's monitor. For example, `normal` or `low`.
21
+ class EventPriority
22
+ include BaseEnumModel
23
+
24
+ NORMAL = "normal".freeze
25
+ LOW = "low".freeze
26
+ end
27
+ end
@@ -0,0 +1,133 @@
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 object description of an event after being processed and stored by Datadog.
21
+ class EventResponse
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # The object description of an event response attribute.
29
+ attr_accessor :attributes
30
+
31
+ # the unique ID of the event.
32
+ attr_accessor :id
33
+
34
+ # Type of the event.
35
+ attr_accessor :type
36
+
37
+ # Attribute mapping from ruby-style variable name to JSON key.
38
+ # @!visibility private
39
+ def self.attribute_map
40
+ {
41
+ :'attributes' => :'attributes',
42
+ :'id' => :'id',
43
+ :'type' => :'type'
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
+ :'attributes' => :'EventResponseAttributes',
58
+ :'id' => :'String',
59
+ :'type' => :'EventType'
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::V2::EventResponse` 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::V2::EventResponse`. 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?(:'attributes')
87
+ self.attributes = attributes[:'attributes']
88
+ end
89
+
90
+ if attributes.key?(:'id')
91
+ self.id = attributes[:'id']
92
+ end
93
+
94
+ if attributes.key?(:'type')
95
+ self.type = attributes[:'type']
96
+ else
97
+ self.type = 'event'
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
+ true
106
+ end
107
+
108
+ # Checks equality by comparing each attribute.
109
+ # @param o [Object] Object to be compared
110
+ # @!visibility private
111
+ def ==(o)
112
+ return true if self.equal?(o)
113
+ self.class == o.class &&
114
+ attributes == o.attributes &&
115
+ id == o.id &&
116
+ type == o.type
117
+ end
118
+
119
+ # @see the `==` method
120
+ # @param o [Object] Object to be compared
121
+ # @!visibility private
122
+ def eql?(o)
123
+ self == o
124
+ end
125
+
126
+ # Calculates hash code according to all attributes.
127
+ # @return [Integer] Hash code
128
+ # @!visibility private
129
+ def hash
130
+ [attributes, id, type].hash
131
+ end
132
+ end
133
+ end
@@ -0,0 +1,133 @@
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 object description of an event response attribute.
21
+ class EventResponseAttributes
22
+ include BaseGenericModel
23
+
24
+ # Whether the object has unparsed attributes
25
+ # @!visibility private
26
+ attr_accessor :_unparsed
27
+
28
+ # Object description of attributes from your event.
29
+ attr_accessor :attributes
30
+
31
+ # An array of tags associated with the event.
32
+ attr_accessor :tags
33
+
34
+ # The timestamp of the event.
35
+ attr_accessor :timestamp
36
+
37
+ # Attribute mapping from ruby-style variable name to JSON key.
38
+ # @!visibility private
39
+ def self.attribute_map
40
+ {
41
+ :'attributes' => :'attributes',
42
+ :'tags' => :'tags',
43
+ :'timestamp' => :'timestamp'
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
+ :'attributes' => :'EventAttributes',
58
+ :'tags' => :'Array<String>',
59
+ :'timestamp' => :'Time'
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::V2::EventResponseAttributes` 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::V2::EventResponseAttributes`. 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?(:'attributes')
87
+ self.attributes = attributes[:'attributes']
88
+ end
89
+
90
+ if attributes.key?(:'tags')
91
+ if (value = attributes[:'tags']).is_a?(Array)
92
+ self.tags = value
93
+ end
94
+ end
95
+
96
+ if attributes.key?(:'timestamp')
97
+ self.timestamp = attributes[:'timestamp']
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
+ true
106
+ end
107
+
108
+ # Checks equality by comparing each attribute.
109
+ # @param o [Object] Object to be compared
110
+ # @!visibility private
111
+ def ==(o)
112
+ return true if self.equal?(o)
113
+ self.class == o.class &&
114
+ attributes == o.attributes &&
115
+ tags == o.tags &&
116
+ timestamp == o.timestamp
117
+ end
118
+
119
+ # @see the `==` method
120
+ # @param o [Object] Object to be compared
121
+ # @!visibility private
122
+ def eql?(o)
123
+ self == o
124
+ end
125
+
126
+ # Calculates hash code according to all attributes.
127
+ # @return [Integer] Hash code
128
+ # @!visibility private
129
+ def hash
130
+ [attributes, tags, timestamp].hash
131
+ end
132
+ end
133
+ end
@@ -0,0 +1,35 @@
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
+ # If an alert event is enabled, its status is one of the following:
21
+ # `failure`, `error`, `warning`, `info`, `success`, `user_update`,
22
+ # `recommendation`, or `snapshot`.
23
+ class EventStatusType
24
+ include BaseEnumModel
25
+
26
+ FAILURE = "failure".freeze
27
+ ERROR = "error".freeze
28
+ WARNING = "warning".freeze
29
+ INFO = "info".freeze
30
+ SUCCESS = "success".freeze
31
+ USER_UPDATE = "user_update".freeze
32
+ RECOMMENDATION = "recommendation".freeze
33
+ SNAPSHOT = "snapshot".freeze
34
+ end
35
+ end
@@ -0,0 +1,26 @@
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
+ # Type of the event.
21
+ class EventType
22
+ include BaseEnumModel
23
+
24
+ EVENT = "event".freeze
25
+ end
26
+ end