datadog_api_client 2.8.0 → 2.10.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 (535) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/conftest.py +5 -24
  4. data/.generator/poetry.lock +164 -189
  5. data/.generator/schemas/v1/openapi.yaml +966 -34
  6. data/.generator/schemas/v2/openapi.yaml +7697 -4475
  7. data/.generator/src/generator/formatter.py +2 -1
  8. data/.generator/src/generator/openapi.py +2 -1
  9. data/.generator/src/generator/templates/api_client.j2 +2 -2
  10. data/.generator/src/generator/templates/example.j2 +1 -1
  11. data/.generator/src/generator/templates/model_base.j2 +8 -4
  12. data/.generator/src/generator/templates/model_oneof.j2 +1 -1
  13. data/.github/workflows/test.yml +1 -1
  14. data/.github/workflows/test_integration.yml +3 -3
  15. data/CHANGELOG.md +60 -0
  16. data/README.md +1 -1
  17. data/examples/v1/dashboard-lists/CreateDashboardList.rb +1 -1
  18. data/examples/v1/dashboard-lists/UpdateDashboardList.rb +1 -1
  19. data/examples/v1/dashboards/CreateDashboard.rb +1 -1
  20. data/examples/v1/dashboards/CreateDashboard_1024858348.rb +1 -1
  21. data/examples/v1/dashboards/CreateDashboard_1039800684.rb +1 -1
  22. data/examples/v1/dashboards/CreateDashboard_109450134.rb +1 -1
  23. data/examples/v1/dashboards/CreateDashboard_1094917386.rb +1 -1
  24. data/examples/v1/dashboards/CreateDashboard_1177423752.rb +1 -1
  25. data/examples/v1/dashboards/CreateDashboard_1200099236.rb +1 -1
  26. data/examples/v1/dashboards/CreateDashboard_1213075383.rb +1 -1
  27. data/examples/v1/dashboards/CreateDashboard_1307120899.rb +1 -1
  28. data/examples/v1/dashboards/CreateDashboard_1423904722.rb +1 -1
  29. data/examples/v1/dashboards/CreateDashboard_1442588603.rb +1 -1
  30. data/examples/v1/dashboards/CreateDashboard_145494973.rb +1 -1
  31. data/examples/v1/dashboards/CreateDashboard_173805046.rb +1 -1
  32. data/examples/v1/dashboards/CreateDashboard_1738608750.rb +1 -1
  33. data/examples/v1/dashboards/CreateDashboard_2029850837.rb +1 -1
  34. data/examples/v1/dashboards/CreateDashboard_2034634967.rb +1 -1
  35. data/examples/v1/dashboards/CreateDashboard_2064651578.rb +64 -0
  36. data/examples/v1/dashboards/CreateDashboard_2104498738.rb +1 -1
  37. data/examples/v1/dashboards/CreateDashboard_2308247857.rb +1 -1
  38. data/examples/v1/dashboards/CreateDashboard_2316374332.rb +1 -1
  39. data/examples/v1/dashboards/CreateDashboard_2336428357.rb +1 -1
  40. data/examples/v1/dashboards/CreateDashboard_2338918735.rb +1 -1
  41. data/examples/v1/dashboards/CreateDashboard_2342457693.rb +1 -1
  42. data/examples/v1/dashboards/CreateDashboard_2349863258.rb +1 -1
  43. data/examples/v1/dashboards/CreateDashboard_2432046716.rb +1 -1
  44. data/examples/v1/dashboards/CreateDashboard_2490110261.rb +1 -1
  45. data/examples/v1/dashboards/CreateDashboard_252716965.rb +1 -1
  46. data/examples/v1/dashboards/CreateDashboard_2607944105.rb +1 -1
  47. data/examples/v1/dashboards/CreateDashboard_2610827685.rb +1 -1
  48. data/examples/v1/dashboards/CreateDashboard_2634813877.rb +1 -1
  49. data/examples/v1/dashboards/CreateDashboard_2644712913.rb +1 -1
  50. data/examples/v1/dashboards/CreateDashboard_2652180930.rb +1 -1
  51. data/examples/v1/dashboards/CreateDashboard_2705593938.rb +1 -1
  52. data/examples/v1/dashboards/CreateDashboard_2800096921.rb +62 -0
  53. data/examples/v1/dashboards/CreateDashboard_2843286292.rb +1 -1
  54. data/examples/v1/dashboards/CreateDashboard_2917274132.rb +1 -1
  55. data/examples/v1/dashboards/CreateDashboard_2921337351.rb +1 -1
  56. data/examples/v1/dashboards/CreateDashboard_3117424216.rb +1 -1
  57. data/examples/v1/dashboards/CreateDashboard_3195475781.rb +32 -0
  58. data/examples/v1/dashboards/CreateDashboard_3250131584.rb +1 -1
  59. data/examples/v1/dashboards/CreateDashboard_3669695268.rb +1 -1
  60. data/examples/v1/dashboards/CreateDashboard_3882428227.rb +2 -2
  61. data/examples/v1/dashboards/CreateDashboard_3982498788.rb +1 -1
  62. data/examples/v1/dashboards/CreateDashboard_4026341408.rb +1 -1
  63. data/examples/v1/dashboards/CreateDashboard_4076476470.rb +1 -1
  64. data/examples/v1/dashboards/CreateDashboard_41622531.rb +1 -1
  65. data/examples/v1/dashboards/CreateDashboard_417992286.rb +1 -1
  66. data/examples/v1/dashboards/CreateDashboard_578885732.rb +1 -1
  67. data/examples/v1/dashboards/CreateDashboard_651038379.rb +1 -1
  68. data/examples/v1/dashboards/CreateDashboard_765140092.rb +1 -1
  69. data/examples/v1/dashboards/CreateDashboard_798168180.rb +1 -1
  70. data/examples/v1/dashboards/CreateDashboard_803346562.rb +1 -1
  71. data/examples/v1/dashboards/CreateDashboard_913313564.rb +1 -1
  72. data/examples/v1/dashboards/CreateDashboard_915214113.rb +1 -1
  73. data/examples/v1/dashboards/CreateDashboard_927141680.rb +1 -1
  74. data/examples/v1/dashboards/CreatePublicDashboard.rb +17 -0
  75. data/examples/v1/dashboards/DeletePublicDashboard.rb +5 -0
  76. data/examples/v1/dashboards/DeletePublicDashboardInvitation.rb +16 -0
  77. data/examples/v1/dashboards/GetPublicDashboard.rb +8 -0
  78. data/examples/v1/dashboards/GetPublicDashboardInvitations.rb +8 -0
  79. data/examples/v1/dashboards/SendPublicDashboardInvitation.rb +17 -0
  80. data/examples/v1/dashboards/UpdateDashboard.rb +1 -1
  81. data/examples/v1/dashboards/UpdateDashboard_3454865944.rb +40 -0
  82. data/examples/v1/dashboards/UpdatePublicDashboard.rb +16 -0
  83. data/examples/v1/downtimes/CreateDowntime.rb +2 -2
  84. data/examples/v1/downtimes/CreateDowntime_1393233946.rb +1 -1
  85. data/examples/v1/downtimes/CreateDowntime_2908359488.rb +1 -1
  86. data/examples/v1/downtimes/CreateDowntime_3059354445.rb +1 -1
  87. data/examples/v1/downtimes/CreateDowntime_3355644446.rb +2 -2
  88. data/examples/v1/downtimes/ListDowntimes.rb +4 -1
  89. data/examples/v1/downtimes/UpdateDowntime.rb +1 -1
  90. data/examples/v1/events/CreateEvent.rb +2 -2
  91. data/examples/v1/events/CreateEvent_19927815.rb +2 -2
  92. data/examples/v1/logs/SubmitLog.rb +2 -2
  93. data/examples/v1/logs/SubmitLog_1920474053.rb +2 -2
  94. data/examples/v1/logs/SubmitLog_3418823904.rb +2 -2
  95. data/examples/v1/metrics/SubmitMetrics.rb +1 -1
  96. data/examples/v1/metrics/SubmitMetrics_2203981258.rb +1 -1
  97. data/examples/v1/monitors/CreateMonitor.rb +2 -2
  98. data/examples/v1/monitors/CreateMonitor_1969035628.rb +2 -2
  99. data/examples/v1/monitors/CreateMonitor_2012680290.rb +1 -1
  100. data/examples/v1/monitors/CreateMonitor_2520912138.rb +2 -2
  101. data/examples/v1/monitors/CreateMonitor_3790803616.rb +2 -2
  102. data/examples/v1/monitors/CreateMonitor_3824294658.rb +2 -2
  103. data/examples/v1/monitors/CreateMonitor_3883669300.rb +2 -2
  104. data/examples/v1/monitors/CreateMonitor_440013737.rb +2 -2
  105. data/examples/v1/monitors/ListMonitors_3448441939.rb +1 -1
  106. data/examples/v1/monitors/ValidateExistingMonitor.rb +2 -2
  107. data/examples/v1/monitors/ValidateMonitor.rb +2 -2
  108. data/examples/v1/monitors/ValidateMonitor_4247196452.rb +2 -2
  109. data/examples/v1/notebooks/CreateNotebook.rb +1 -1
  110. data/examples/v1/notebooks/UpdateNotebook.rb +1 -1
  111. data/examples/v1/service-checks/SubmitServiceCheck.rb +1 -1
  112. data/examples/v1/service-level-objective-corrections/CreateSLOCorrection.rb +1 -1
  113. data/examples/v1/service-level-objective-corrections/CreateSLOCorrection_1326388368.rb +1 -1
  114. data/examples/v1/service-level-objective-corrections/UpdateSLOCorrection.rb +1 -1
  115. data/examples/v1/service-level-objectives/CreateSLO.rb +1 -1
  116. data/examples/v1/synthetics/CreateGlobalVariable_1068962881.rb +1 -1
  117. data/examples/v1/synthetics/CreatePrivateLocation.rb +3 -3
  118. data/examples/v1/synthetics/CreateSyntheticsAPITest_1072503741.rb +1 -1
  119. data/examples/v1/synthetics/CreateSyntheticsAPITest_1279271422.rb +2 -2
  120. data/examples/v1/synthetics/CreateSyntheticsAPITest_1402674167.rb +2 -2
  121. data/examples/v1/synthetics/CreateSyntheticsAPITest_1487281163.rb +3 -3
  122. data/examples/v1/synthetics/CreateSyntheticsAPITest_2472747642.rb +2 -2
  123. data/examples/v1/synthetics/CreateSyntheticsAPITest_3829801148.rb +2 -2
  124. data/examples/v1/synthetics/CreateSyntheticsAPITest_960766374.rb +3 -3
  125. data/examples/v1/synthetics/CreateSyntheticsBrowserTest.rb +1 -1
  126. data/examples/v1/synthetics/CreateSyntheticsBrowserTest_2932742688.rb +1 -1
  127. data/examples/v1/synthetics/CreateSyntheticsBrowserTest_397420811.rb +1 -1
  128. data/examples/v1/synthetics/UpdateAPITest.rb +2 -2
  129. data/examples/v1/webhooks-integration/CreateWebhooksIntegration.rb +1 -1
  130. data/examples/v1/webhooks-integration/CreateWebhooksIntegrationCustomVariable.rb +1 -1
  131. data/examples/v2/authn-mappings/CreateAuthNMapping.rb +2 -2
  132. data/examples/v2/cloud-workload-security/CreateCloudWorkloadSecurityAgentRule.rb +1 -1
  133. data/examples/v2/cloudflare-integration/CreateCloudflareAccount.rb +2 -2
  134. data/examples/v2/cloudflare-integration/UpdateCloudflareAccount.rb +1 -1
  135. data/examples/v2/confluent-cloud/CreateConfluentResource.rb +1 -1
  136. data/examples/v2/events/ListEvents.rb +1 -1
  137. data/examples/v2/events/ListEvents_1527584014.rb +1 -1
  138. data/examples/v2/events/ListEvents_2663715109.rb +1 -1
  139. data/examples/v2/events/SearchEvents.rb +1 -1
  140. data/examples/v2/events/SearchEvents_3856995058.rb +1 -1
  141. data/examples/v2/fastly-integration/CreateFastlyAccount.rb +2 -2
  142. data/examples/v2/incident-services/CreateIncidentService.rb +2 -2
  143. data/examples/v2/incident-services/DeleteIncidentService.rb +1 -1
  144. data/examples/v2/incident-services/GetIncidentService.rb +1 -1
  145. data/examples/v2/incident-services/ListIncidentServices.rb +1 -1
  146. data/examples/v2/incident-services/UpdateIncidentService.rb +1 -1
  147. data/examples/v2/incident-teams/CreateIncidentTeam.rb +2 -2
  148. data/examples/v2/incident-teams/DeleteIncidentTeam.rb +1 -1
  149. data/examples/v2/incident-teams/GetIncidentTeam.rb +1 -1
  150. data/examples/v2/incident-teams/ListIncidentTeams.rb +1 -1
  151. data/examples/v2/incident-teams/UpdateIncidentTeam.rb +1 -1
  152. data/examples/v2/incidents/CreateIncident.rb +2 -2
  153. data/examples/v2/incidents/CreateIncidentIntegration.rb +31 -0
  154. data/examples/v2/incidents/CreateIncidentTodo.rb +23 -0
  155. data/examples/v2/incidents/DeleteIncident.rb +1 -1
  156. data/examples/v2/incidents/DeleteIncidentIntegration.rb +14 -0
  157. data/examples/v2/incidents/DeleteIncidentTodo.rb +14 -0
  158. data/examples/v2/incidents/GetIncident.rb +1 -1
  159. data/examples/v2/incidents/GetIncidentIntegration.rb +14 -0
  160. data/examples/v2/incidents/GetIncidentTodo.rb +14 -0
  161. data/examples/v2/incidents/ListIncidentAttachments.rb +1 -1
  162. data/examples/v2/incidents/ListIncidentAttachments_2457735435.rb +1 -1
  163. data/examples/v2/incidents/ListIncidentIntegrations.rb +11 -0
  164. data/examples/v2/incidents/ListIncidentTodos.rb +11 -0
  165. data/examples/v2/incidents/ListIncidents.rb +1 -1
  166. data/examples/v2/incidents/ListIncidents_2665616954.rb +1 -1
  167. data/examples/v2/incidents/SearchIncidents.rb +1 -1
  168. data/examples/v2/incidents/SearchIncidents_1931679109.rb +11 -0
  169. data/examples/v2/incidents/UpdateIncident.rb +1 -1
  170. data/examples/v2/incidents/UpdateIncidentAttachments.rb +1 -1
  171. data/examples/v2/incidents/UpdateIncidentAttachments_3881702075.rb +2 -2
  172. data/examples/v2/incidents/UpdateIncidentIntegration.rb +34 -0
  173. data/examples/v2/incidents/UpdateIncidentTodo.rb +28 -0
  174. data/examples/v2/incidents/UpdateIncident_1009194038.rb +1 -1
  175. data/examples/v2/incidents/UpdateIncident_3369341440.rb +1 -1
  176. data/examples/v2/ip-allowlist/GetIPAllowlist.rb +5 -0
  177. data/examples/v2/ip-allowlist/UpdateIPAllowlist.rb +25 -0
  178. data/examples/v2/key-management/CreateAPIKey.rb +1 -1
  179. data/examples/v2/key-management/CreateCurrentUserApplicationKey_1999509896.rb +1 -1
  180. data/examples/v2/key-management/CreateCurrentUserApplicationKey_3383369233.rb +1 -1
  181. data/examples/v2/key-management/UpdateAPIKey.rb +1 -1
  182. data/examples/v2/logs/SubmitLog.rb +1 -1
  183. data/examples/v2/logs-metrics/CreateLogsMetric.rb +1 -1
  184. data/examples/v2/logs-metrics/DeleteLogsMetric.rb +1 -1
  185. data/examples/v2/metrics/CreateBulkTagsMetricsConfiguration.rb +1 -1
  186. data/examples/v2/metrics/CreateTagConfiguration.rb +2 -2
  187. data/examples/v2/metrics/DeleteTagConfiguration.rb +1 -1
  188. data/examples/v2/metrics/ListActiveMetricConfigurations.rb +1 -1
  189. data/examples/v2/metrics/ListTagConfigurations_265033704.rb +1 -1
  190. data/examples/v2/metrics/ListVolumesByMetricName.rb +1 -1
  191. data/examples/v2/metrics/QueryScalarData.rb +1 -1
  192. data/examples/v2/metrics/QueryScalarData_3112571352.rb +1 -1
  193. data/examples/v2/metrics/QueryTimeseriesData.rb +1 -1
  194. data/examples/v2/metrics/QueryTimeseriesData_301142940.rb +1 -1
  195. data/examples/v2/opsgenie-integration/CreateOpsgenieService.rb +1 -1
  196. data/examples/v2/restriction-policies/DeleteRestrictionPolicy.rb +5 -0
  197. data/examples/v2/restriction-policies/GetRestrictionPolicy.rb +5 -0
  198. data/examples/v2/restriction-policies/UpdateRestrictionPolicy.rb +25 -0
  199. data/examples/v2/roles/CloneRole.rb +1 -1
  200. data/examples/v2/roles/CreateRole.rb +1 -1
  201. data/examples/v2/security-monitoring/CreateSecurityFilter.rb +2 -2
  202. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule.rb +1 -1
  203. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_1092490364.rb +1 -1
  204. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_461183901.rb +1 -1
  205. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_498211763.rb +1 -1
  206. data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_914562040.rb +1 -1
  207. data/examples/v2/security-monitoring/UpdateSecurityFilter.rb +2 -2
  208. data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule.rb +1 -1
  209. data/examples/v2/security-monitoring/UpdateSecurityMonitoringRule_428087276.rb +1 -1
  210. data/examples/v2/sensitive-data-scanner/CreateScanningGroup.rb +1 -1
  211. data/examples/v2/sensitive-data-scanner/CreateScanningRule.rb +1 -1
  212. data/examples/v2/sensitive-data-scanner/UpdateScanningGroup.rb +1 -1
  213. data/examples/v2/sensitive-data-scanner/UpdateScanningRule.rb +1 -1
  214. data/examples/v2/service-accounts/CreateServiceAccount.rb +1 -1
  215. data/examples/v2/service-accounts/CreateServiceAccountApplicationKey_1761876297.rb +1 -1
  216. data/examples/v2/service-accounts/CreateServiceAccountApplicationKey_3480494373.rb +1 -1
  217. data/examples/v2/service-definition/CreateOrUpdateServiceDefinitions.rb +19 -27
  218. data/examples/v2/service-definition/CreateOrUpdateServiceDefinitions_1808735248.rb +54 -0
  219. data/examples/v2/service-definition/CreateOrUpdateServiceDefinitions_2619874414.rb +53 -0
  220. data/examples/v2/service-definition/ListServiceDefinitions_336468013.rb +8 -0
  221. data/examples/v2/spans-metrics/CreateSpansMetric.rb +28 -0
  222. data/examples/v2/spans-metrics/DeleteSpansMetric.rb +8 -0
  223. data/examples/v2/spans-metrics/GetSpansMetric.rb +8 -0
  224. data/examples/v2/spans-metrics/ListSpansMetrics.rb +5 -0
  225. data/examples/v2/spans-metrics/UpdateSpansMetric.rb +29 -0
  226. data/examples/v2/synthetics/GetOnDemandConcurrencyCap.rb +5 -0
  227. data/examples/v2/synthetics/GetOnDemandConcurrencyCap_2633566918.rb +5 -0
  228. data/examples/v2/synthetics/SetOnDemandConcurrencyCap.rb +7 -0
  229. data/examples/v2/synthetics/SetOnDemandConcurrencyCap_2850884405.rb +9 -0
  230. data/examples/v2/teams/CreateTeam.rb +20 -0
  231. data/examples/v2/teams/CreateTeamLink.rb +19 -0
  232. data/examples/v2/teams/CreateTeamMembership.rb +22 -0
  233. data/examples/v2/teams/DeleteTeam.rb +8 -0
  234. data/examples/v2/teams/DeleteTeamLink.rb +11 -0
  235. data/examples/v2/teams/DeleteTeamMembership.rb +8 -0
  236. data/examples/v2/teams/GetTeam.rb +8 -0
  237. data/examples/v2/teams/GetTeamLink.rb +11 -0
  238. data/examples/v2/teams/GetTeamLinks.rb +8 -0
  239. data/examples/v2/teams/GetTeamMemberships.rb +8 -0
  240. data/examples/v2/teams/GetTeamPermissionSettings.rb +8 -0
  241. data/examples/v2/teams/ListTeams.rb +5 -0
  242. data/examples/v2/teams/UpdateTeam.rb +20 -0
  243. data/examples/v2/teams/UpdateTeamLink.rb +21 -0
  244. data/examples/v2/teams/UpdateTeamMembership.rb +14 -0
  245. data/examples/v2/teams/UpdateTeamPermissionSetting.rb +17 -0
  246. data/examples/v2/users/CreateUser.rb +1 -1
  247. data/lib/datadog_api_client/api_client.rb +2 -2
  248. data/lib/datadog_api_client/configuration.rb +15 -0
  249. data/lib/datadog_api_client/inflector.rb +161 -0
  250. data/lib/datadog_api_client/v1/api/dashboards_api.rb +482 -0
  251. data/lib/datadog_api_client/v1/api/downtimes_api.rb +2 -0
  252. data/lib/datadog_api_client/v1/api/monitors_api.rb +3 -3
  253. data/lib/datadog_api_client/v1/api/snapshots_api.rb +2 -2
  254. data/lib/datadog_api_client/v1/api/synthetics_api.rb +2 -2
  255. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +9 -6
  256. data/lib/datadog_api_client/v1/model_base.rb +7 -3
  257. data/lib/datadog_api_client/v1/models/application_key.rb +16 -16
  258. data/lib/datadog_api_client/v1/models/cancel_downtimes_by_scope_request.rb +1 -1
  259. data/lib/datadog_api_client/v1/models/check_can_delete_monitor_response.rb +8 -0
  260. data/lib/datadog_api_client/v1/models/dashboard.rb +25 -1
  261. data/lib/datadog_api_client/v1/models/dashboard_global_time.rb +91 -0
  262. data/lib/datadog_api_client/v1/models/dashboard_global_time_live_span.rb +33 -0
  263. data/lib/datadog_api_client/v1/models/dashboard_invite_type.rb +26 -0
  264. data/lib/datadog_api_client/v1/models/dashboard_share_type.rb +27 -0
  265. data/lib/datadog_api_client/v1/models/dashboard_type.rb +27 -0
  266. data/lib/datadog_api_client/v1/models/delete_shared_dashboard_response.rb +91 -0
  267. data/lib/datadog_api_client/v1/models/distribution_point_item.rb +1 -1
  268. data/lib/datadog_api_client/v1/models/distribution_widget_histogram_request_query.rb +1 -1
  269. data/lib/datadog_api_client/v1/models/downtime.rb +2 -1
  270. data/lib/datadog_api_client/v1/models/downtime_child.rb +2 -1
  271. data/lib/datadog_api_client/v1/models/formula_and_function_events_data_source.rb +1 -0
  272. data/lib/datadog_api_client/v1/models/formula_and_function_query_definition.rb +1 -1
  273. data/lib/datadog_api_client/v1/models/host.rb +8 -0
  274. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_body.rb +19 -1
  275. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +3 -0
  276. data/lib/datadog_api_client/v1/models/list_stream_source.rb +3 -0
  277. data/lib/datadog_api_client/v1/models/logs_list_response.rb +8 -0
  278. data/lib/datadog_api_client/v1/models/logs_processor.rb +1 -1
  279. data/lib/datadog_api_client/v1/models/metrics_query_metadata.rb +2 -2
  280. data/lib/datadog_api_client/v1/models/monitor_formula_and_function_query_definition.rb +1 -1
  281. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_body.rb +19 -1
  282. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +6 -0
  283. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +66 -6
  284. data/lib/datadog_api_client/v1/models/notebook_cell_create_request_attributes.rb +1 -1
  285. data/lib/datadog_api_client/v1/models/notebook_cell_response_attributes.rb +1 -1
  286. data/lib/datadog_api_client/v1/models/notebook_cell_time.rb +1 -1
  287. data/lib/datadog_api_client/v1/models/notebook_cell_update_request_attributes.rb +1 -1
  288. data/lib/datadog_api_client/v1/models/notebook_global_time.rb +1 -1
  289. data/lib/datadog_api_client/v1/models/notebook_update_cell.rb +1 -1
  290. data/lib/datadog_api_client/v1/models/selectable_template_variable_items.rb +131 -0
  291. data/lib/datadog_api_client/v1/models/shared_dashboard.rb +228 -0
  292. data/lib/datadog_api_client/v1/models/shared_dashboard_author.rb +109 -0
  293. data/lib/datadog_api_client/v1/models/shared_dashboard_invites.rb +112 -0
  294. data/lib/datadog_api_client/v1/models/shared_dashboard_invites_data.rb +63 -0
  295. data/lib/datadog_api_client/v1/models/shared_dashboard_invites_data_object.rb +123 -0
  296. data/lib/datadog_api_client/v1/models/shared_dashboard_invites_data_object_attributes.rb +149 -0
  297. data/lib/datadog_api_client/v1/models/shared_dashboard_invites_meta.rb +91 -0
  298. data/lib/datadog_api_client/v1/models/shared_dashboard_invites_meta_page.rb +91 -0
  299. data/lib/datadog_api_client/v1/models/shared_dashboard_update_request.rb +147 -0
  300. data/lib/datadog_api_client/v1/models/shared_dashboard_update_request_global_time.rb +91 -0
  301. data/lib/datadog_api_client/v1/models/slo_correction_response_attributes.rb +3 -0
  302. data/lib/datadog_api_client/v1/models/slo_creator.rb +8 -0
  303. data/lib/datadog_api_client/v1/models/slo_history_monitor.rb +8 -0
  304. data/lib/datadog_api_client/v1/models/slo_history_response.rb +8 -0
  305. data/lib/datadog_api_client/v1/models/slo_history_sli_data.rb +9 -0
  306. data/lib/datadog_api_client/v1/models/sunburst_widget_legend.rb +1 -1
  307. data/lib/datadog_api_client/v1/models/synthetics_assertion.rb +1 -1
  308. data/lib/datadog_api_client/v1/models/synthetics_basic_auth.rb +1 -1
  309. data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +11 -1
  310. data/lib/datadog_api_client/v1/models/usage_attribution_body.rb +8 -0
  311. data/lib/datadog_api_client/v1/models/usage_billable_summary_keys.rb +7 -7
  312. data/lib/datadog_api_client/v1/models/usage_ci_visibility_hour.rb +11 -0
  313. data/lib/datadog_api_client/v1/models/usage_cws_hour.rb +9 -0
  314. data/lib/datadog_api_client/v1/models/usage_dbm_hour.rb +9 -0
  315. data/lib/datadog_api_client/v1/models/usage_fargate_hour.rb +11 -0
  316. data/lib/datadog_api_client/v1/models/usage_host_hour.rb +22 -0
  317. data/lib/datadog_api_client/v1/models/usage_incident_management_hour.rb +8 -0
  318. data/lib/datadog_api_client/v1/models/usage_lambda_hour.rb +9 -0
  319. data/lib/datadog_api_client/v1/models/usage_logs_hour.rb +26 -1
  320. data/lib/datadog_api_client/v1/models/usage_online_archive_hour.rb +8 -0
  321. data/lib/datadog_api_client/v1/models/usage_profiling_hour.rb +9 -0
  322. data/lib/datadog_api_client/v1/models/usage_rum_sessions_hour.rb +12 -1
  323. data/lib/datadog_api_client/v1/models/usage_rum_units_hour.rb +2 -0
  324. data/lib/datadog_api_client/v1/models/usage_snmp_hour.rb +8 -0
  325. data/lib/datadog_api_client/v1/models/usage_summary_date.rb +41 -1
  326. data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +41 -1
  327. data/lib/datadog_api_client/v1/models/usage_summary_response.rb +41 -1
  328. data/lib/datadog_api_client/v1/models/usage_synthetics_api_hour.rb +8 -0
  329. data/lib/datadog_api_client/v1/models/usage_synthetics_browser_hour.rb +8 -0
  330. data/lib/datadog_api_client/v1/models/usage_top_avg_metrics_pagination.rb +1 -0
  331. data/lib/datadog_api_client/v1/models/widget_definition.rb +1 -1
  332. data/lib/datadog_api_client/v2/api/incidents_api.rb +836 -43
  333. data/lib/datadog_api_client/v2/api/ip_allowlist_api.rb +153 -0
  334. data/lib/datadog_api_client/v2/api/logs_api.rb +1 -0
  335. data/lib/datadog_api_client/v2/api/restriction_policies_api.rb +245 -0
  336. data/lib/datadog_api_client/v2/api/service_definition_api.rb +25 -0
  337. data/lib/datadog_api_client/v2/api/spans_metrics_api.rb +357 -0
  338. data/lib/datadog_api_client/v2/api/synthetics_api.rb +153 -0
  339. data/lib/datadog_api_client/v2/api/teams_api.rb +1166 -0
  340. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +1 -1
  341. data/lib/datadog_api_client/v2/model_base.rb +7 -3
  342. data/lib/datadog_api_client/v2/models/api_key_response_included_item.rb +1 -1
  343. data/lib/datadog_api_client/v2/models/application_key_response_included_item.rb +1 -1
  344. data/lib/datadog_api_client/v2/models/authn_mapping_included.rb +1 -1
  345. data/lib/datadog_api_client/v2/models/ci_app_aggregate_bucket_value.rb +1 -1
  346. data/lib/datadog_api_client/v2/models/ci_app_group_by_missing.rb +1 -1
  347. data/lib/datadog_api_client/v2/models/ci_app_group_by_total.rb +1 -1
  348. data/lib/datadog_api_client/v2/models/cloud_configuration_rule_compliance_signal_options.rb +9 -0
  349. data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_creator_attributes.rb +8 -0
  350. data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_updater_attributes.rb +8 -0
  351. data/lib/datadog_api_client/v2/models/confluent_account_resource_attributes.rb +12 -1
  352. data/lib/datadog_api_client/v2/models/confluent_resource_request_attributes.rb +12 -1
  353. data/lib/datadog_api_client/v2/models/creator.rb +8 -0
  354. data/lib/datadog_api_client/v2/models/dashboard_list_item.rb +8 -0
  355. data/lib/datadog_api_client/v2/models/events_data_source.rb +1 -0
  356. data/lib/datadog_api_client/v2/models/get_team_memberships_sort.rb +33 -0
  357. data/lib/datadog_api_client/v2/models/incident_attachment_attributes.rb +1 -1
  358. data/lib/datadog_api_client/v2/models/incident_attachment_update_attributes.rb +1 -1
  359. data/lib/datadog_api_client/v2/models/incident_attachments_response_included_item.rb +1 -1
  360. data/lib/datadog_api_client/v2/models/incident_field_attributes.rb +1 -1
  361. data/lib/datadog_api_client/v2/models/incident_integration_metadata_attributes.rb +161 -0
  362. data/lib/datadog_api_client/v2/models/incident_integration_metadata_create_data.rb +123 -0
  363. data/lib/datadog_api_client/v2/models/incident_integration_metadata_create_request.rb +102 -0
  364. data/lib/datadog_api_client/v2/models/incident_integration_metadata_list_response.rb +126 -0
  365. data/lib/datadog_api_client/v2/models/incident_integration_metadata_metadata.rb +63 -0
  366. data/lib/datadog_api_client/v2/models/incident_integration_metadata_patch_data.rb +123 -0
  367. data/lib/datadog_api_client/v2/models/incident_integration_metadata_patch_request.rb +102 -0
  368. data/lib/datadog_api_client/v2/models/incident_integration_metadata_response.rb +114 -0
  369. data/lib/datadog_api_client/v2/models/incident_integration_metadata_response_data.rb +133 -0
  370. data/lib/datadog_api_client/v2/models/incident_integration_metadata_response_included_item.rb +62 -0
  371. data/lib/datadog_api_client/v2/models/incident_response_included_item.rb +1 -1
  372. data/lib/datadog_api_client/v2/models/incident_search_response.rb +14 -4
  373. data/lib/datadog_api_client/v2/models/incident_search_response_meta.rb +91 -0
  374. data/lib/datadog_api_client/v2/models/incident_service_included_items.rb +1 -1
  375. data/lib/datadog_api_client/v2/models/incident_team_included_items.rb +1 -1
  376. data/lib/datadog_api_client/v2/models/incident_timeline_cell_create_attributes.rb +1 -1
  377. data/lib/datadog_api_client/v2/models/incident_todo_anonymous_assignee.rb +165 -0
  378. data/lib/datadog_api_client/v2/models/incident_todo_anonymous_assignee_source.rb +27 -0
  379. data/lib/datadog_api_client/v2/models/incident_todo_assignee.rb +63 -0
  380. data/lib/datadog_api_client/v2/models/incident_todo_attributes.rb +164 -0
  381. data/lib/datadog_api_client/v2/models/incident_todo_create_data.rb +123 -0
  382. data/lib/datadog_api_client/v2/models/incident_todo_create_request.rb +102 -0
  383. data/lib/datadog_api_client/v2/models/incident_todo_list_response.rb +126 -0
  384. data/lib/datadog_api_client/v2/models/incident_todo_patch_data.rb +123 -0
  385. data/lib/datadog_api_client/v2/models/incident_todo_patch_request.rb +102 -0
  386. data/lib/datadog_api_client/v2/models/incident_todo_response.rb +114 -0
  387. data/lib/datadog_api_client/v2/models/incident_todo_response_data.rb +133 -0
  388. data/lib/datadog_api_client/v2/models/incident_todo_response_included_item.rb +62 -0
  389. data/lib/datadog_api_client/v2/models/incident_todo_type.rb +26 -0
  390. data/lib/datadog_api_client/v2/models/incident_update_data.rb +1 -1
  391. data/lib/datadog_api_client/v2/models/ip_allowlist_attributes.rb +103 -0
  392. data/lib/datadog_api_client/v2/models/ip_allowlist_data.rb +122 -0
  393. data/lib/datadog_api_client/v2/models/ip_allowlist_entry.rb +102 -0
  394. data/lib/datadog_api_client/v2/models/ip_allowlist_entry_attributes.rb +121 -0
  395. data/lib/datadog_api_client/v2/models/ip_allowlist_entry_data.rb +122 -0
  396. data/lib/datadog_api_client/v2/models/ip_allowlist_entry_type.rb +26 -0
  397. data/lib/datadog_api_client/v2/models/ip_allowlist_response.rb +91 -0
  398. data/lib/datadog_api_client/v2/models/ip_allowlist_type.rb +26 -0
  399. data/lib/datadog_api_client/v2/models/ip_allowlist_update_request.rb +102 -0
  400. data/lib/datadog_api_client/v2/models/jira_integration_metadata.rb +104 -0
  401. data/lib/datadog_api_client/v2/models/jira_integration_metadata_issues_item.rb +153 -0
  402. data/lib/datadog_api_client/v2/models/list_teams_include.rb +27 -0
  403. data/lib/datadog_api_client/v2/models/list_teams_sort.rb +29 -0
  404. data/lib/datadog_api_client/v2/models/logs_aggregate_bucket_value.rb +1 -1
  405. data/lib/datadog_api_client/v2/models/logs_archive_create_request_destination.rb +1 -1
  406. data/lib/datadog_api_client/v2/models/logs_archive_destination.rb +1 -1
  407. data/lib/datadog_api_client/v2/models/logs_group_by_missing.rb +1 -1
  408. data/lib/datadog_api_client/v2/models/logs_group_by_total.rb +1 -1
  409. data/lib/datadog_api_client/v2/models/metric_volumes.rb +1 -1
  410. data/lib/datadog_api_client/v2/models/metrics_aggregator.rb +4 -0
  411. data/lib/datadog_api_client/v2/models/metrics_and_metric_tag_configurations.rb +1 -1
  412. data/lib/datadog_api_client/v2/models/monitor_config_policy_policy.rb +1 -1
  413. data/lib/datadog_api_client/v2/models/monitor_config_policy_policy_create_request.rb +1 -1
  414. data/lib/datadog_api_client/v2/models/on_demand_concurrency_cap.rb +91 -0
  415. data/lib/datadog_api_client/v2/models/on_demand_concurrency_cap_attributes.rb +91 -0
  416. data/lib/datadog_api_client/v2/models/on_demand_concurrency_cap_response.rb +91 -0
  417. data/lib/datadog_api_client/v2/models/relationship_to_incident_integration_metadatas.rb +1 -1
  418. data/lib/datadog_api_client/v2/models/relationship_to_team_link_data.rb +123 -0
  419. data/lib/datadog_api_client/v2/models/relationship_to_team_links.rb +93 -0
  420. data/lib/datadog_api_client/v2/models/relationship_to_user_team_permission.rb +91 -0
  421. data/lib/datadog_api_client/v2/models/relationship_to_user_team_permission_data.rb +123 -0
  422. data/lib/datadog_api_client/v2/models/relationship_to_user_team_user.rb +102 -0
  423. data/lib/datadog_api_client/v2/models/relationship_to_user_team_user_data.rb +123 -0
  424. data/lib/datadog_api_client/v2/models/restriction_policy.rb +144 -0
  425. data/lib/datadog_api_client/v2/models/restriction_policy_attributes.rb +104 -0
  426. data/lib/datadog_api_client/v2/models/restriction_policy_binding.rb +127 -0
  427. data/lib/datadog_api_client/v2/models/restriction_policy_response.rb +102 -0
  428. data/lib/datadog_api_client/v2/models/restriction_policy_type.rb +26 -0
  429. data/lib/datadog_api_client/v2/models/restriction_policy_update_request.rb +102 -0
  430. data/lib/datadog_api_client/v2/models/rum_aggregate_bucket_value.rb +1 -1
  431. data/lib/datadog_api_client/v2/models/rum_application_attributes.rb +7 -7
  432. data/lib/datadog_api_client/v2/models/rum_application_list_attributes.rb +7 -7
  433. data/lib/datadog_api_client/v2/models/rum_group_by_missing.rb +1 -1
  434. data/lib/datadog_api_client/v2/models/rum_group_by_total.rb +1 -1
  435. data/lib/datadog_api_client/v2/models/scalar_column.rb +1 -1
  436. data/lib/datadog_api_client/v2/models/scalar_query.rb +1 -1
  437. data/lib/datadog_api_client/v2/models/security_monitoring_rule_create_payload.rb +1 -1
  438. data/lib/datadog_api_client/v2/models/security_monitoring_rule_query.rb +1 -1
  439. data/lib/datadog_api_client/v2/models/security_monitoring_rule_response.rb +1 -1
  440. data/lib/datadog_api_client/v2/models/security_monitoring_rule_type_read.rb +1 -0
  441. data/lib/datadog_api_client/v2/models/security_monitoring_triage_user.rb +8 -0
  442. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_get_config_included_item.rb +1 -1
  443. data/lib/datadog_api_client/v2/models/service_definition_schema.rb +3 -2
  444. data/lib/datadog_api_client/v2/models/service_definition_v2_contact.rb +3 -2
  445. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1.rb +229 -0
  446. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_contact.rb +64 -0
  447. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_email.rb +133 -0
  448. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_email_type.rb +26 -0
  449. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_integrations.rb +101 -0
  450. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_link.rb +154 -0
  451. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_link_type.rb +30 -0
  452. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_ms_teams.rb +133 -0
  453. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_ms_teams_type.rb +26 -0
  454. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_opsgenie.rb +112 -0
  455. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_opsgenie_region.rb +27 -0
  456. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_pagerduty.rb +91 -0
  457. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_slack.rb +133 -0
  458. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_slack_type.rb +26 -0
  459. data/lib/datadog_api_client/v2/models/service_definition_v2_dot1_version.rb +26 -0
  460. data/lib/datadog_api_client/v2/models/service_definition_v2_ms_teams.rb +133 -0
  461. data/lib/datadog_api_client/v2/models/service_definition_v2_ms_teams_type.rb +26 -0
  462. data/lib/datadog_api_client/v2/models/service_definitions_create_request.rb +2 -1
  463. data/lib/datadog_api_client/v2/models/slack_integration_metadata.rb +104 -0
  464. data/lib/datadog_api_client/v2/models/slack_integration_metadata_channel_item.rb +154 -0
  465. data/lib/datadog_api_client/v2/models/spans_metric_compute.rb +123 -0
  466. data/lib/datadog_api_client/v2/models/spans_metric_compute_aggregation_type.rb +27 -0
  467. data/lib/datadog_api_client/v2/models/spans_metric_create_attributes.rb +124 -0
  468. data/lib/datadog_api_client/v2/models/spans_metric_create_data.rb +144 -0
  469. data/lib/datadog_api_client/v2/models/spans_metric_create_request.rb +102 -0
  470. data/lib/datadog_api_client/v2/models/spans_metric_filter.rb +91 -0
  471. data/lib/datadog_api_client/v2/models/spans_metric_group_by.rb +112 -0
  472. data/lib/datadog_api_client/v2/models/spans_metric_response.rb +91 -0
  473. data/lib/datadog_api_client/v2/models/spans_metric_response_attributes.rb +113 -0
  474. data/lib/datadog_api_client/v2/models/spans_metric_response_compute.rb +112 -0
  475. data/lib/datadog_api_client/v2/models/spans_metric_response_data.rb +111 -0
  476. data/lib/datadog_api_client/v2/models/spans_metric_response_filter.rb +91 -0
  477. data/lib/datadog_api_client/v2/models/spans_metric_response_group_by.rb +101 -0
  478. data/lib/datadog_api_client/v2/models/spans_metric_type.rb +26 -0
  479. data/lib/datadog_api_client/v2/models/spans_metric_update_attributes.rb +113 -0
  480. data/lib/datadog_api_client/v2/models/spans_metric_update_compute.rb +92 -0
  481. data/lib/datadog_api_client/v2/models/spans_metric_update_data.rb +123 -0
  482. data/lib/datadog_api_client/v2/models/spans_metric_update_request.rb +102 -0
  483. data/lib/datadog_api_client/v2/models/spans_metrics_response.rb +93 -0
  484. data/lib/datadog_api_client/v2/models/team.rb +154 -0
  485. data/lib/datadog_api_client/v2/models/team_attributes.rb +233 -0
  486. data/lib/datadog_api_client/v2/models/team_create.rb +133 -0
  487. data/lib/datadog_api_client/v2/models/team_create_attributes.rb +162 -0
  488. data/lib/datadog_api_client/v2/models/team_create_relationships.rb +91 -0
  489. data/lib/datadog_api_client/v2/models/team_create_request.rb +102 -0
  490. data/lib/datadog_api_client/v2/models/team_data.rb +144 -0
  491. data/lib/datadog_api_client/v2/models/team_included.rb +64 -0
  492. data/lib/datadog_api_client/v2/models/team_link.rb +144 -0
  493. data/lib/datadog_api_client/v2/models/team_link_attributes.rb +158 -0
  494. data/lib/datadog_api_client/v2/models/team_link_create.rb +123 -0
  495. data/lib/datadog_api_client/v2/models/team_link_create_request.rb +102 -0
  496. data/lib/datadog_api_client/v2/models/team_link_response.rb +91 -0
  497. data/lib/datadog_api_client/v2/models/team_link_type.rb +26 -0
  498. data/lib/datadog_api_client/v2/models/team_links_response.rb +93 -0
  499. data/lib/datadog_api_client/v2/models/team_permission_setting.rb +133 -0
  500. data/lib/datadog_api_client/v2/models/team_permission_setting_attributes.rb +133 -0
  501. data/lib/datadog_api_client/v2/models/team_permission_setting_response.rb +91 -0
  502. data/lib/datadog_api_client/v2/models/team_permission_setting_serializer_action.rb +27 -0
  503. data/lib/datadog_api_client/v2/models/team_permission_setting_type.rb +26 -0
  504. data/lib/datadog_api_client/v2/models/team_permission_setting_update.rb +112 -0
  505. data/lib/datadog_api_client/v2/models/team_permission_setting_update_attributes.rb +91 -0
  506. data/lib/datadog_api_client/v2/models/team_permission_setting_update_request.rb +102 -0
  507. data/lib/datadog_api_client/v2/models/team_permission_setting_value.rb +30 -0
  508. data/lib/datadog_api_client/v2/models/team_permission_settings_response.rb +93 -0
  509. data/lib/datadog_api_client/v2/models/team_relationships.rb +101 -0
  510. data/lib/datadog_api_client/v2/models/team_response.rb +91 -0
  511. data/lib/datadog_api_client/v2/models/team_type.rb +26 -0
  512. data/lib/datadog_api_client/v2/models/team_update.rb +133 -0
  513. data/lib/datadog_api_client/v2/models/team_update_attributes.rb +187 -0
  514. data/lib/datadog_api_client/v2/models/team_update_relationships.rb +91 -0
  515. data/lib/datadog_api_client/v2/models/team_update_request.rb +102 -0
  516. data/lib/datadog_api_client/v2/models/teams_response.rb +105 -0
  517. data/lib/datadog_api_client/v2/models/timeseries_query.rb +1 -1
  518. data/lib/datadog_api_client/v2/models/user_response_included_item.rb +1 -1
  519. data/lib/datadog_api_client/v2/models/user_team.rb +143 -0
  520. data/lib/datadog_api_client/v2/models/user_team_attributes.rb +99 -0
  521. data/lib/datadog_api_client/v2/models/user_team_create.rb +122 -0
  522. data/lib/datadog_api_client/v2/models/user_team_permission.rb +133 -0
  523. data/lib/datadog_api_client/v2/models/user_team_permission_attributes.rb +91 -0
  524. data/lib/datadog_api_client/v2/models/user_team_permission_type.rb +26 -0
  525. data/lib/datadog_api_client/v2/models/user_team_relationships.rb +91 -0
  526. data/lib/datadog_api_client/v2/models/user_team_request.rb +102 -0
  527. data/lib/datadog_api_client/v2/models/user_team_response.rb +91 -0
  528. data/lib/datadog_api_client/v2/models/user_team_role.rb +26 -0
  529. data/lib/datadog_api_client/v2/models/user_team_type.rb +26 -0
  530. data/lib/datadog_api_client/v2/models/user_team_update.rb +112 -0
  531. data/lib/datadog_api_client/v2/models/user_team_update_request.rb +102 -0
  532. data/lib/datadog_api_client/v2/models/user_team_user_type.rb +26 -0
  533. data/lib/datadog_api_client/v2/models/user_teams_response.rb +93 -0
  534. data/lib/datadog_api_client/version.rb +1 -1
  535. metadata +218 -2
@@ -96,6 +96,162 @@ module DatadogAPIClient::V2
96
96
  return data, status_code, headers
97
97
  end
98
98
 
99
+ # Create an incident integration metadata.
100
+ #
101
+ # @see #create_incident_integration_with_http_info
102
+ def create_incident_integration(incident_id, body, opts = {})
103
+ data, _status_code, _headers = create_incident_integration_with_http_info(incident_id, body, opts)
104
+ data
105
+ end
106
+
107
+ # Create an incident integration metadata.
108
+ #
109
+ # Create an incident integration metadata.
110
+ #
111
+ # @param incident_id [String] The UUID of the incident.
112
+ # @param body [IncidentIntegrationMetadataCreateRequest] Incident integration metadata payload.
113
+ # @param opts [Hash] the optional parameters
114
+ # @return [Array<(IncidentIntegrationMetadataResponse, Integer, Hash)>] IncidentIntegrationMetadataResponse data, response status code and response headers
115
+ def create_incident_integration_with_http_info(incident_id, body, opts = {})
116
+ unstable_enabled = @api_client.config.unstable_operations["v2.create_incident_integration".to_sym]
117
+ if unstable_enabled
118
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_incident_integration")
119
+ else
120
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_incident_integration"))
121
+ end
122
+
123
+ if @api_client.config.debugging
124
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.create_incident_integration ...'
125
+ end
126
+ # verify the required parameter 'incident_id' is set
127
+ if @api_client.config.client_side_validation && incident_id.nil?
128
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.create_incident_integration"
129
+ end
130
+ # verify the required parameter 'body' is set
131
+ if @api_client.config.client_side_validation && body.nil?
132
+ fail ArgumentError, "Missing the required parameter 'body' when calling IncidentsAPI.create_incident_integration"
133
+ end
134
+ # resource path
135
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/integrations'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
136
+
137
+ # query parameters
138
+ query_params = opts[:query_params] || {}
139
+
140
+ # header parameters
141
+ header_params = opts[:header_params] || {}
142
+ # HTTP header 'Accept' (if needed)
143
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
144
+ # HTTP header 'Content-Type'
145
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
146
+
147
+ # form parameters
148
+ form_params = opts[:form_params] || {}
149
+
150
+ # http body (model)
151
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
152
+
153
+ # return_type
154
+ return_type = opts[:debug_return_type] || 'IncidentIntegrationMetadataResponse'
155
+
156
+ # auth_names
157
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
158
+
159
+ new_options = opts.merge(
160
+ :operation => :create_incident_integration,
161
+ :header_params => header_params,
162
+ :query_params => query_params,
163
+ :form_params => form_params,
164
+ :body => post_body,
165
+ :auth_names => auth_names,
166
+ :return_type => return_type,
167
+ :api_version => "V2"
168
+ )
169
+
170
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options)
171
+ if @api_client.config.debugging
172
+ @api_client.config.logger.debug "API called: IncidentsAPI#create_incident_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
173
+ end
174
+ return data, status_code, headers
175
+ end
176
+
177
+ # Create an incident todo.
178
+ #
179
+ # @see #create_incident_todo_with_http_info
180
+ def create_incident_todo(incident_id, body, opts = {})
181
+ data, _status_code, _headers = create_incident_todo_with_http_info(incident_id, body, opts)
182
+ data
183
+ end
184
+
185
+ # Create an incident todo.
186
+ #
187
+ # Create an incident todo.
188
+ #
189
+ # @param incident_id [String] The UUID of the incident.
190
+ # @param body [IncidentTodoCreateRequest] Incident todo payload.
191
+ # @param opts [Hash] the optional parameters
192
+ # @return [Array<(IncidentTodoResponse, Integer, Hash)>] IncidentTodoResponse data, response status code and response headers
193
+ def create_incident_todo_with_http_info(incident_id, body, opts = {})
194
+ unstable_enabled = @api_client.config.unstable_operations["v2.create_incident_todo".to_sym]
195
+ if unstable_enabled
196
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_incident_todo")
197
+ else
198
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_incident_todo"))
199
+ end
200
+
201
+ if @api_client.config.debugging
202
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.create_incident_todo ...'
203
+ end
204
+ # verify the required parameter 'incident_id' is set
205
+ if @api_client.config.client_side_validation && incident_id.nil?
206
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.create_incident_todo"
207
+ end
208
+ # verify the required parameter 'body' is set
209
+ if @api_client.config.client_side_validation && body.nil?
210
+ fail ArgumentError, "Missing the required parameter 'body' when calling IncidentsAPI.create_incident_todo"
211
+ end
212
+ # resource path
213
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/todos'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
214
+
215
+ # query parameters
216
+ query_params = opts[:query_params] || {}
217
+
218
+ # header parameters
219
+ header_params = opts[:header_params] || {}
220
+ # HTTP header 'Accept' (if needed)
221
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
222
+ # HTTP header 'Content-Type'
223
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
224
+
225
+ # form parameters
226
+ form_params = opts[:form_params] || {}
227
+
228
+ # http body (model)
229
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
230
+
231
+ # return_type
232
+ return_type = opts[:debug_return_type] || 'IncidentTodoResponse'
233
+
234
+ # auth_names
235
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
236
+
237
+ new_options = opts.merge(
238
+ :operation => :create_incident_todo,
239
+ :header_params => header_params,
240
+ :query_params => query_params,
241
+ :form_params => form_params,
242
+ :body => post_body,
243
+ :auth_names => auth_names,
244
+ :return_type => return_type,
245
+ :api_version => "V2"
246
+ )
247
+
248
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options)
249
+ if @api_client.config.debugging
250
+ @api_client.config.logger.debug "API called: IncidentsAPI#create_incident_todo\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
251
+ end
252
+ return data, status_code, headers
253
+ end
254
+
99
255
  # Delete an existing incident.
100
256
  #
101
257
  # @see #delete_incident_with_http_info
@@ -144,13 +300,390 @@ module DatadogAPIClient::V2
144
300
  post_body = opts[:debug_body]
145
301
 
146
302
  # return_type
147
- return_type = opts[:debug_return_type]
303
+ return_type = opts[:debug_return_type]
304
+
305
+ # auth_names
306
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
307
+
308
+ new_options = opts.merge(
309
+ :operation => :delete_incident,
310
+ :header_params => header_params,
311
+ :query_params => query_params,
312
+ :form_params => form_params,
313
+ :body => post_body,
314
+ :auth_names => auth_names,
315
+ :return_type => return_type,
316
+ :api_version => "V2"
317
+ )
318
+
319
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
320
+ if @api_client.config.debugging
321
+ @api_client.config.logger.debug "API called: IncidentsAPI#delete_incident\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
322
+ end
323
+ return data, status_code, headers
324
+ end
325
+
326
+ # Delete an incident integration metadata.
327
+ #
328
+ # @see #delete_incident_integration_with_http_info
329
+ def delete_incident_integration(incident_id, integration_metadata_id, opts = {})
330
+ delete_incident_integration_with_http_info(incident_id, integration_metadata_id, opts)
331
+ nil
332
+ end
333
+
334
+ # Delete an incident integration metadata.
335
+ #
336
+ # Delete an incident integration metadata.
337
+ #
338
+ # @param incident_id [String] The UUID of the incident.
339
+ # @param integration_metadata_id [String] The UUID of the incident integration metadata.
340
+ # @param opts [Hash] the optional parameters
341
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
342
+ def delete_incident_integration_with_http_info(incident_id, integration_metadata_id, opts = {})
343
+ unstable_enabled = @api_client.config.unstable_operations["v2.delete_incident_integration".to_sym]
344
+ if unstable_enabled
345
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.delete_incident_integration")
346
+ else
347
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.delete_incident_integration"))
348
+ end
349
+
350
+ if @api_client.config.debugging
351
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.delete_incident_integration ...'
352
+ end
353
+ # verify the required parameter 'incident_id' is set
354
+ if @api_client.config.client_side_validation && incident_id.nil?
355
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.delete_incident_integration"
356
+ end
357
+ # verify the required parameter 'integration_metadata_id' is set
358
+ if @api_client.config.client_side_validation && integration_metadata_id.nil?
359
+ fail ArgumentError, "Missing the required parameter 'integration_metadata_id' when calling IncidentsAPI.delete_incident_integration"
360
+ end
361
+ # resource path
362
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/integrations/{integration_metadata_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{integration_metadata_id}', CGI.escape(integration_metadata_id.to_s).gsub('%2F', '/'))
363
+
364
+ # query parameters
365
+ query_params = opts[:query_params] || {}
366
+
367
+ # header parameters
368
+ header_params = opts[:header_params] || {}
369
+ # HTTP header 'Accept' (if needed)
370
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
371
+
372
+ # form parameters
373
+ form_params = opts[:form_params] || {}
374
+
375
+ # http body (model)
376
+ post_body = opts[:debug_body]
377
+
378
+ # return_type
379
+ return_type = opts[:debug_return_type]
380
+
381
+ # auth_names
382
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
383
+
384
+ new_options = opts.merge(
385
+ :operation => :delete_incident_integration,
386
+ :header_params => header_params,
387
+ :query_params => query_params,
388
+ :form_params => form_params,
389
+ :body => post_body,
390
+ :auth_names => auth_names,
391
+ :return_type => return_type,
392
+ :api_version => "V2"
393
+ )
394
+
395
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
396
+ if @api_client.config.debugging
397
+ @api_client.config.logger.debug "API called: IncidentsAPI#delete_incident_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
398
+ end
399
+ return data, status_code, headers
400
+ end
401
+
402
+ # Delete an incident todo.
403
+ #
404
+ # @see #delete_incident_todo_with_http_info
405
+ def delete_incident_todo(incident_id, todo_id, opts = {})
406
+ delete_incident_todo_with_http_info(incident_id, todo_id, opts)
407
+ nil
408
+ end
409
+
410
+ # Delete an incident todo.
411
+ #
412
+ # Delete an incident todo.
413
+ #
414
+ # @param incident_id [String] The UUID of the incident.
415
+ # @param todo_id [String] The UUID of the incident todo.
416
+ # @param opts [Hash] the optional parameters
417
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
418
+ def delete_incident_todo_with_http_info(incident_id, todo_id, opts = {})
419
+ unstable_enabled = @api_client.config.unstable_operations["v2.delete_incident_todo".to_sym]
420
+ if unstable_enabled
421
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.delete_incident_todo")
422
+ else
423
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.delete_incident_todo"))
424
+ end
425
+
426
+ if @api_client.config.debugging
427
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.delete_incident_todo ...'
428
+ end
429
+ # verify the required parameter 'incident_id' is set
430
+ if @api_client.config.client_side_validation && incident_id.nil?
431
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.delete_incident_todo"
432
+ end
433
+ # verify the required parameter 'todo_id' is set
434
+ if @api_client.config.client_side_validation && todo_id.nil?
435
+ fail ArgumentError, "Missing the required parameter 'todo_id' when calling IncidentsAPI.delete_incident_todo"
436
+ end
437
+ # resource path
438
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/todos/{todo_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{todo_id}', CGI.escape(todo_id.to_s).gsub('%2F', '/'))
439
+
440
+ # query parameters
441
+ query_params = opts[:query_params] || {}
442
+
443
+ # header parameters
444
+ header_params = opts[:header_params] || {}
445
+ # HTTP header 'Accept' (if needed)
446
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
447
+
448
+ # form parameters
449
+ form_params = opts[:form_params] || {}
450
+
451
+ # http body (model)
452
+ post_body = opts[:debug_body]
453
+
454
+ # return_type
455
+ return_type = opts[:debug_return_type]
456
+
457
+ # auth_names
458
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
459
+
460
+ new_options = opts.merge(
461
+ :operation => :delete_incident_todo,
462
+ :header_params => header_params,
463
+ :query_params => query_params,
464
+ :form_params => form_params,
465
+ :body => post_body,
466
+ :auth_names => auth_names,
467
+ :return_type => return_type,
468
+ :api_version => "V2"
469
+ )
470
+
471
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
472
+ if @api_client.config.debugging
473
+ @api_client.config.logger.debug "API called: IncidentsAPI#delete_incident_todo\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
474
+ end
475
+ return data, status_code, headers
476
+ end
477
+
478
+ # Get the details of an incident.
479
+ #
480
+ # @see #get_incident_with_http_info
481
+ def get_incident(incident_id, opts = {})
482
+ data, _status_code, _headers = get_incident_with_http_info(incident_id, opts)
483
+ data
484
+ end
485
+
486
+ # Get the details of an incident.
487
+ #
488
+ # Get the details of an incident by `incident_id`.
489
+ #
490
+ # @param incident_id [String] The UUID of the incident.
491
+ # @param opts [Hash] the optional parameters
492
+ # @option opts [Array<IncidentRelatedObject>] :include Specifies which types of related objects should be included in the response.
493
+ # @return [Array<(IncidentResponse, Integer, Hash)>] IncidentResponse data, response status code and response headers
494
+ def get_incident_with_http_info(incident_id, opts = {})
495
+ unstable_enabled = @api_client.config.unstable_operations["v2.get_incident".to_sym]
496
+ if unstable_enabled
497
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_incident")
498
+ else
499
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_incident"))
500
+ end
501
+
502
+ if @api_client.config.debugging
503
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.get_incident ...'
504
+ end
505
+ # verify the required parameter 'incident_id' is set
506
+ if @api_client.config.client_side_validation && incident_id.nil?
507
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.get_incident"
508
+ end
509
+ # resource path
510
+ local_var_path = '/api/v2/incidents/{incident_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
511
+
512
+ # query parameters
513
+ query_params = opts[:query_params] || {}
514
+ query_params[:'include'] = @api_client.build_collection_param(opts[:'include'], :csv) if !opts[:'include'].nil?
515
+
516
+ # header parameters
517
+ header_params = opts[:header_params] || {}
518
+ # HTTP header 'Accept' (if needed)
519
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
520
+
521
+ # form parameters
522
+ form_params = opts[:form_params] || {}
523
+
524
+ # http body (model)
525
+ post_body = opts[:debug_body]
526
+
527
+ # return_type
528
+ return_type = opts[:debug_return_type] || 'IncidentResponse'
529
+
530
+ # auth_names
531
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
532
+
533
+ new_options = opts.merge(
534
+ :operation => :get_incident,
535
+ :header_params => header_params,
536
+ :query_params => query_params,
537
+ :form_params => form_params,
538
+ :body => post_body,
539
+ :auth_names => auth_names,
540
+ :return_type => return_type,
541
+ :api_version => "V2"
542
+ )
543
+
544
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
545
+ if @api_client.config.debugging
546
+ @api_client.config.logger.debug "API called: IncidentsAPI#get_incident\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
547
+ end
548
+ return data, status_code, headers
549
+ end
550
+
551
+ # Get incident integration metadata details.
552
+ #
553
+ # @see #get_incident_integration_with_http_info
554
+ def get_incident_integration(incident_id, integration_metadata_id, opts = {})
555
+ data, _status_code, _headers = get_incident_integration_with_http_info(incident_id, integration_metadata_id, opts)
556
+ data
557
+ end
558
+
559
+ # Get incident integration metadata details.
560
+ #
561
+ # Get incident integration metadata details.
562
+ #
563
+ # @param incident_id [String] The UUID of the incident.
564
+ # @param integration_metadata_id [String] The UUID of the incident integration metadata.
565
+ # @param opts [Hash] the optional parameters
566
+ # @return [Array<(IncidentIntegrationMetadataResponse, Integer, Hash)>] IncidentIntegrationMetadataResponse data, response status code and response headers
567
+ def get_incident_integration_with_http_info(incident_id, integration_metadata_id, opts = {})
568
+ unstable_enabled = @api_client.config.unstable_operations["v2.get_incident_integration".to_sym]
569
+ if unstable_enabled
570
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_incident_integration")
571
+ else
572
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_incident_integration"))
573
+ end
574
+
575
+ if @api_client.config.debugging
576
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.get_incident_integration ...'
577
+ end
578
+ # verify the required parameter 'incident_id' is set
579
+ if @api_client.config.client_side_validation && incident_id.nil?
580
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.get_incident_integration"
581
+ end
582
+ # verify the required parameter 'integration_metadata_id' is set
583
+ if @api_client.config.client_side_validation && integration_metadata_id.nil?
584
+ fail ArgumentError, "Missing the required parameter 'integration_metadata_id' when calling IncidentsAPI.get_incident_integration"
585
+ end
586
+ # resource path
587
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/integrations/{integration_metadata_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{integration_metadata_id}', CGI.escape(integration_metadata_id.to_s).gsub('%2F', '/'))
588
+
589
+ # query parameters
590
+ query_params = opts[:query_params] || {}
591
+
592
+ # header parameters
593
+ header_params = opts[:header_params] || {}
594
+ # HTTP header 'Accept' (if needed)
595
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
596
+
597
+ # form parameters
598
+ form_params = opts[:form_params] || {}
599
+
600
+ # http body (model)
601
+ post_body = opts[:debug_body]
602
+
603
+ # return_type
604
+ return_type = opts[:debug_return_type] || 'IncidentIntegrationMetadataResponse'
605
+
606
+ # auth_names
607
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
608
+
609
+ new_options = opts.merge(
610
+ :operation => :get_incident_integration,
611
+ :header_params => header_params,
612
+ :query_params => query_params,
613
+ :form_params => form_params,
614
+ :body => post_body,
615
+ :auth_names => auth_names,
616
+ :return_type => return_type,
617
+ :api_version => "V2"
618
+ )
619
+
620
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
621
+ if @api_client.config.debugging
622
+ @api_client.config.logger.debug "API called: IncidentsAPI#get_incident_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
623
+ end
624
+ return data, status_code, headers
625
+ end
626
+
627
+ # Get incident todo details.
628
+ #
629
+ # @see #get_incident_todo_with_http_info
630
+ def get_incident_todo(incident_id, todo_id, opts = {})
631
+ data, _status_code, _headers = get_incident_todo_with_http_info(incident_id, todo_id, opts)
632
+ data
633
+ end
634
+
635
+ # Get incident todo details.
636
+ #
637
+ # Get incident todo details.
638
+ #
639
+ # @param incident_id [String] The UUID of the incident.
640
+ # @param todo_id [String] The UUID of the incident todo.
641
+ # @param opts [Hash] the optional parameters
642
+ # @return [Array<(IncidentTodoResponse, Integer, Hash)>] IncidentTodoResponse data, response status code and response headers
643
+ def get_incident_todo_with_http_info(incident_id, todo_id, opts = {})
644
+ unstable_enabled = @api_client.config.unstable_operations["v2.get_incident_todo".to_sym]
645
+ if unstable_enabled
646
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_incident_todo")
647
+ else
648
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_incident_todo"))
649
+ end
650
+
651
+ if @api_client.config.debugging
652
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.get_incident_todo ...'
653
+ end
654
+ # verify the required parameter 'incident_id' is set
655
+ if @api_client.config.client_side_validation && incident_id.nil?
656
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.get_incident_todo"
657
+ end
658
+ # verify the required parameter 'todo_id' is set
659
+ if @api_client.config.client_side_validation && todo_id.nil?
660
+ fail ArgumentError, "Missing the required parameter 'todo_id' when calling IncidentsAPI.get_incident_todo"
661
+ end
662
+ # resource path
663
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/todos/{todo_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{todo_id}', CGI.escape(todo_id.to_s).gsub('%2F', '/'))
664
+
665
+ # query parameters
666
+ query_params = opts[:query_params] || {}
667
+
668
+ # header parameters
669
+ header_params = opts[:header_params] || {}
670
+ # HTTP header 'Accept' (if needed)
671
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
672
+
673
+ # form parameters
674
+ form_params = opts[:form_params] || {}
675
+
676
+ # http body (model)
677
+ post_body = opts[:debug_body]
678
+
679
+ # return_type
680
+ return_type = opts[:debug_return_type] || 'IncidentTodoResponse'
148
681
 
149
682
  # auth_names
150
683
  auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
151
684
 
152
685
  new_options = opts.merge(
153
- :operation => :delete_incident,
686
+ :operation => :get_incident_todo,
154
687
  :header_params => header_params,
155
688
  :query_params => query_params,
156
689
  :form_params => form_params,
@@ -160,50 +693,52 @@ module DatadogAPIClient::V2
160
693
  :api_version => "V2"
161
694
  )
162
695
 
163
- data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
696
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
164
697
  if @api_client.config.debugging
165
- @api_client.config.logger.debug "API called: IncidentsAPI#delete_incident\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
698
+ @api_client.config.logger.debug "API called: IncidentsAPI#get_incident_todo\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
166
699
  end
167
700
  return data, status_code, headers
168
701
  end
169
702
 
170
- # Get the details of an incident.
703
+ # Get a list of attachments.
171
704
  #
172
- # @see #get_incident_with_http_info
173
- def get_incident(incident_id, opts = {})
174
- data, _status_code, _headers = get_incident_with_http_info(incident_id, opts)
705
+ # @see #list_incident_attachments_with_http_info
706
+ def list_incident_attachments(incident_id, opts = {})
707
+ data, _status_code, _headers = list_incident_attachments_with_http_info(incident_id, opts)
175
708
  data
176
709
  end
177
710
 
178
- # Get the details of an incident.
711
+ # Get a list of attachments.
179
712
  #
180
- # Get the details of an incident by `incident_id`.
713
+ # Get all attachments for a given incident.
181
714
  #
182
715
  # @param incident_id [String] The UUID of the incident.
183
716
  # @param opts [Hash] the optional parameters
184
- # @option opts [Array<IncidentRelatedObject>] :include Specifies which types of related objects should be included in the response.
185
- # @return [Array<(IncidentResponse, Integer, Hash)>] IncidentResponse data, response status code and response headers
186
- def get_incident_with_http_info(incident_id, opts = {})
187
- unstable_enabled = @api_client.config.unstable_operations["v2.get_incident".to_sym]
717
+ # @option opts [Array<IncidentAttachmentRelatedObject>] :include Specifies which types of related objects are included in the response.
718
+ # @option opts [Array<IncidentAttachmentAttachmentType>] :filter_attachment_type Specifies which types of attachments are included in the response.
719
+ # @return [Array<(IncidentAttachmentsResponse, Integer, Hash)>] IncidentAttachmentsResponse data, response status code and response headers
720
+ def list_incident_attachments_with_http_info(incident_id, opts = {})
721
+ unstable_enabled = @api_client.config.unstable_operations["v2.list_incident_attachments".to_sym]
188
722
  if unstable_enabled
189
- @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_incident")
723
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_incident_attachments")
190
724
  else
191
- raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_incident"))
725
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_incident_attachments"))
192
726
  end
193
727
 
194
728
  if @api_client.config.debugging
195
- @api_client.config.logger.debug 'Calling API: IncidentsAPI.get_incident ...'
729
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.list_incident_attachments ...'
196
730
  end
197
731
  # verify the required parameter 'incident_id' is set
198
732
  if @api_client.config.client_side_validation && incident_id.nil?
199
- fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.get_incident"
733
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.list_incident_attachments"
200
734
  end
201
735
  # resource path
202
- local_var_path = '/api/v2/incidents/{incident_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
736
+ local_var_path = '/api/v2/incidents/{incident_id}/attachments'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
203
737
 
204
738
  # query parameters
205
739
  query_params = opts[:query_params] || {}
206
740
  query_params[:'include'] = @api_client.build_collection_param(opts[:'include'], :csv) if !opts[:'include'].nil?
741
+ query_params[:'filter[attachment_type]'] = @api_client.build_collection_param(opts[:'filter_attachment_type'], :csv) if !opts[:'filter_attachment_type'].nil?
207
742
 
208
743
  # header parameters
209
744
  header_params = opts[:header_params] || {}
@@ -217,13 +752,13 @@ module DatadogAPIClient::V2
217
752
  post_body = opts[:debug_body]
218
753
 
219
754
  # return_type
220
- return_type = opts[:debug_return_type] || 'IncidentResponse'
755
+ return_type = opts[:debug_return_type] || 'IncidentAttachmentsResponse'
221
756
 
222
757
  # auth_names
223
758
  auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
224
759
 
225
760
  new_options = opts.merge(
226
- :operation => :get_incident,
761
+ :operation => :list_incident_attachments,
227
762
  :header_params => header_params,
228
763
  :query_params => query_params,
229
764
  :form_params => form_params,
@@ -235,50 +770,46 @@ module DatadogAPIClient::V2
235
770
 
236
771
  data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
237
772
  if @api_client.config.debugging
238
- @api_client.config.logger.debug "API called: IncidentsAPI#get_incident\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
773
+ @api_client.config.logger.debug "API called: IncidentsAPI#list_incident_attachments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
239
774
  end
240
775
  return data, status_code, headers
241
776
  end
242
777
 
243
- # Get a list of attachments.
778
+ # Get a list of an incident's integration metadata.
244
779
  #
245
- # @see #list_incident_attachments_with_http_info
246
- def list_incident_attachments(incident_id, opts = {})
247
- data, _status_code, _headers = list_incident_attachments_with_http_info(incident_id, opts)
780
+ # @see #list_incident_integrations_with_http_info
781
+ def list_incident_integrations(incident_id, opts = {})
782
+ data, _status_code, _headers = list_incident_integrations_with_http_info(incident_id, opts)
248
783
  data
249
784
  end
250
785
 
251
- # Get a list of attachments.
786
+ # Get a list of an incident's integration metadata.
252
787
  #
253
- # Get all attachments for a given incident.
788
+ # Get all integration metadata for an incident.
254
789
  #
255
790
  # @param incident_id [String] The UUID of the incident.
256
791
  # @param opts [Hash] the optional parameters
257
- # @option opts [Array<IncidentAttachmentRelatedObject>] :include Specifies which types of related objects are included in the response.
258
- # @option opts [Array<IncidentAttachmentAttachmentType>] :filter_attachment_type Specifies which types of attachments are included in the response.
259
- # @return [Array<(IncidentAttachmentsResponse, Integer, Hash)>] IncidentAttachmentsResponse data, response status code and response headers
260
- def list_incident_attachments_with_http_info(incident_id, opts = {})
261
- unstable_enabled = @api_client.config.unstable_operations["v2.list_incident_attachments".to_sym]
792
+ # @return [Array<(IncidentIntegrationMetadataListResponse, Integer, Hash)>] IncidentIntegrationMetadataListResponse data, response status code and response headers
793
+ def list_incident_integrations_with_http_info(incident_id, opts = {})
794
+ unstable_enabled = @api_client.config.unstable_operations["v2.list_incident_integrations".to_sym]
262
795
  if unstable_enabled
263
- @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_incident_attachments")
796
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_incident_integrations")
264
797
  else
265
- raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_incident_attachments"))
798
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_incident_integrations"))
266
799
  end
267
800
 
268
801
  if @api_client.config.debugging
269
- @api_client.config.logger.debug 'Calling API: IncidentsAPI.list_incident_attachments ...'
802
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.list_incident_integrations ...'
270
803
  end
271
804
  # verify the required parameter 'incident_id' is set
272
805
  if @api_client.config.client_side_validation && incident_id.nil?
273
- fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.list_incident_attachments"
806
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.list_incident_integrations"
274
807
  end
275
808
  # resource path
276
- local_var_path = '/api/v2/incidents/{incident_id}/attachments'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
809
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/integrations'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
277
810
 
278
811
  # query parameters
279
812
  query_params = opts[:query_params] || {}
280
- query_params[:'include'] = @api_client.build_collection_param(opts[:'include'], :csv) if !opts[:'include'].nil?
281
- query_params[:'filter[attachment_type]'] = @api_client.build_collection_param(opts[:'filter_attachment_type'], :csv) if !opts[:'filter_attachment_type'].nil?
282
813
 
283
814
  # header parameters
284
815
  header_params = opts[:header_params] || {}
@@ -292,13 +823,13 @@ module DatadogAPIClient::V2
292
823
  post_body = opts[:debug_body]
293
824
 
294
825
  # return_type
295
- return_type = opts[:debug_return_type] || 'IncidentAttachmentsResponse'
826
+ return_type = opts[:debug_return_type] || 'IncidentIntegrationMetadataListResponse'
296
827
 
297
828
  # auth_names
298
829
  auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
299
830
 
300
831
  new_options = opts.merge(
301
- :operation => :list_incident_attachments,
832
+ :operation => :list_incident_integrations,
302
833
  :header_params => header_params,
303
834
  :query_params => query_params,
304
835
  :form_params => form_params,
@@ -310,7 +841,7 @@ module DatadogAPIClient::V2
310
841
 
311
842
  data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
312
843
  if @api_client.config.debugging
313
- @api_client.config.logger.debug "API called: IncidentsAPI#list_incident_attachments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
844
+ @api_client.config.logger.debug "API called: IncidentsAPI#list_incident_integrations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
314
845
  end
315
846
  return data, status_code, headers
316
847
  end
@@ -408,6 +939,77 @@ module DatadogAPIClient::V2
408
939
  end
409
940
  end
410
941
 
942
+ # Get a list of an incident's todos.
943
+ #
944
+ # @see #list_incident_todos_with_http_info
945
+ def list_incident_todos(incident_id, opts = {})
946
+ data, _status_code, _headers = list_incident_todos_with_http_info(incident_id, opts)
947
+ data
948
+ end
949
+
950
+ # Get a list of an incident's todos.
951
+ #
952
+ # Get all todos for an incident.
953
+ #
954
+ # @param incident_id [String] The UUID of the incident.
955
+ # @param opts [Hash] the optional parameters
956
+ # @return [Array<(IncidentTodoListResponse, Integer, Hash)>] IncidentTodoListResponse data, response status code and response headers
957
+ def list_incident_todos_with_http_info(incident_id, opts = {})
958
+ unstable_enabled = @api_client.config.unstable_operations["v2.list_incident_todos".to_sym]
959
+ if unstable_enabled
960
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_incident_todos")
961
+ else
962
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_incident_todos"))
963
+ end
964
+
965
+ if @api_client.config.debugging
966
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.list_incident_todos ...'
967
+ end
968
+ # verify the required parameter 'incident_id' is set
969
+ if @api_client.config.client_side_validation && incident_id.nil?
970
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.list_incident_todos"
971
+ end
972
+ # resource path
973
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/todos'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/'))
974
+
975
+ # query parameters
976
+ query_params = opts[:query_params] || {}
977
+
978
+ # header parameters
979
+ header_params = opts[:header_params] || {}
980
+ # HTTP header 'Accept' (if needed)
981
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
982
+
983
+ # form parameters
984
+ form_params = opts[:form_params] || {}
985
+
986
+ # http body (model)
987
+ post_body = opts[:debug_body]
988
+
989
+ # return_type
990
+ return_type = opts[:debug_return_type] || 'IncidentTodoListResponse'
991
+
992
+ # auth_names
993
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
994
+
995
+ new_options = opts.merge(
996
+ :operation => :list_incident_todos,
997
+ :header_params => header_params,
998
+ :query_params => query_params,
999
+ :form_params => form_params,
1000
+ :body => post_body,
1001
+ :auth_names => auth_names,
1002
+ :return_type => return_type,
1003
+ :api_version => "V2"
1004
+ )
1005
+
1006
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
1007
+ if @api_client.config.debugging
1008
+ @api_client.config.logger.debug "API called: IncidentsAPI#list_incident_todos\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1009
+ end
1010
+ return data, status_code, headers
1011
+ end
1012
+
411
1013
  # Search for incidents.
412
1014
  #
413
1015
  # @see #search_incidents_with_http_info
@@ -424,6 +1026,8 @@ module DatadogAPIClient::V2
424
1026
  # @param opts [Hash] the optional parameters
425
1027
  # @option opts [IncidentRelatedObject] :include Specifies which types of related objects should be included in the response.
426
1028
  # @option opts [IncidentSearchSortOrder] :sort Specifies the order of returned incidents.
1029
+ # @option opts [Integer] :page_size Size for a given page. The maximum allowed value is 5000.
1030
+ # @option opts [Integer] :page_offset Specific offset to use as the beginning of the returned page.
427
1031
  # @return [Array<(IncidentSearchResponse, Integer, Hash)>] IncidentSearchResponse data, response status code and response headers
428
1032
  def search_incidents_with_http_info(query, opts = {})
429
1033
  unstable_enabled = @api_client.config.unstable_operations["v2.search_incidents".to_sym]
@@ -456,6 +1060,8 @@ module DatadogAPIClient::V2
456
1060
  query_params[:'query'] = query
457
1061
  query_params[:'include'] = opts[:'include'] if !opts[:'include'].nil?
458
1062
  query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
1063
+ query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil?
1064
+ query_params[:'page[offset]'] = opts[:'page_offset'] if !opts[:'page_offset'].nil?
459
1065
 
460
1066
  # header parameters
461
1067
  header_params = opts[:header_params] || {}
@@ -492,6 +1098,27 @@ module DatadogAPIClient::V2
492
1098
  return data, status_code, headers
493
1099
  end
494
1100
 
1101
+ # Search for incidents.
1102
+ #
1103
+ # Provide a paginated version of {#search_incidents}, returning all items.
1104
+ #
1105
+ # To use it you need to use a block: search_incidents_with_pagination { |item| p item }
1106
+ #
1107
+ # @yield [IncidentSearchResponseIncidentsData] Paginated items
1108
+ def search_incidents_with_pagination(query, opts = {})
1109
+ api_version = "V2"
1110
+ page_size = @api_client.get_attribute_from_path(opts, "page_size", 10)
1111
+ @api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
1112
+ while true do
1113
+ response = search_incidents(query, opts)
1114
+ @api_client.get_attribute_from_path(response, "data.attributes.incidents").each { |item| yield(item) }
1115
+ if @api_client.get_attribute_from_path(response, "data.attributes.incidents").length < page_size
1116
+ break
1117
+ end
1118
+ @api_client.set_attribute_from_path(api_version, opts, "page_offset", Integer, @api_client.get_attribute_from_path(opts, "page_offset", 0) + page_size)
1119
+ end
1120
+ end
1121
+
495
1122
  # Update an existing incident.
496
1123
  #
497
1124
  # @see #update_incident_with_http_info
@@ -651,5 +1278,171 @@ module DatadogAPIClient::V2
651
1278
  end
652
1279
  return data, status_code, headers
653
1280
  end
1281
+
1282
+ # Update an existing incident integration metadata.
1283
+ #
1284
+ # @see #update_incident_integration_with_http_info
1285
+ def update_incident_integration(incident_id, integration_metadata_id, body, opts = {})
1286
+ data, _status_code, _headers = update_incident_integration_with_http_info(incident_id, integration_metadata_id, body, opts)
1287
+ data
1288
+ end
1289
+
1290
+ # Update an existing incident integration metadata.
1291
+ #
1292
+ # Update an existing incident integration metadata.
1293
+ #
1294
+ # @param incident_id [String] The UUID of the incident.
1295
+ # @param integration_metadata_id [String] The UUID of the incident integration metadata.
1296
+ # @param body [IncidentIntegrationMetadataPatchRequest] Incident integration metadata payload.
1297
+ # @param opts [Hash] the optional parameters
1298
+ # @return [Array<(IncidentIntegrationMetadataResponse, Integer, Hash)>] IncidentIntegrationMetadataResponse data, response status code and response headers
1299
+ def update_incident_integration_with_http_info(incident_id, integration_metadata_id, body, opts = {})
1300
+ unstable_enabled = @api_client.config.unstable_operations["v2.update_incident_integration".to_sym]
1301
+ if unstable_enabled
1302
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.update_incident_integration")
1303
+ else
1304
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.update_incident_integration"))
1305
+ end
1306
+
1307
+ if @api_client.config.debugging
1308
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.update_incident_integration ...'
1309
+ end
1310
+ # verify the required parameter 'incident_id' is set
1311
+ if @api_client.config.client_side_validation && incident_id.nil?
1312
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.update_incident_integration"
1313
+ end
1314
+ # verify the required parameter 'integration_metadata_id' is set
1315
+ if @api_client.config.client_side_validation && integration_metadata_id.nil?
1316
+ fail ArgumentError, "Missing the required parameter 'integration_metadata_id' when calling IncidentsAPI.update_incident_integration"
1317
+ end
1318
+ # verify the required parameter 'body' is set
1319
+ if @api_client.config.client_side_validation && body.nil?
1320
+ fail ArgumentError, "Missing the required parameter 'body' when calling IncidentsAPI.update_incident_integration"
1321
+ end
1322
+ # resource path
1323
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/integrations/{integration_metadata_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{integration_metadata_id}', CGI.escape(integration_metadata_id.to_s).gsub('%2F', '/'))
1324
+
1325
+ # query parameters
1326
+ query_params = opts[:query_params] || {}
1327
+
1328
+ # header parameters
1329
+ header_params = opts[:header_params] || {}
1330
+ # HTTP header 'Accept' (if needed)
1331
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1332
+ # HTTP header 'Content-Type'
1333
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1334
+
1335
+ # form parameters
1336
+ form_params = opts[:form_params] || {}
1337
+
1338
+ # http body (model)
1339
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
1340
+
1341
+ # return_type
1342
+ return_type = opts[:debug_return_type] || 'IncidentIntegrationMetadataResponse'
1343
+
1344
+ # auth_names
1345
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
1346
+
1347
+ new_options = opts.merge(
1348
+ :operation => :update_incident_integration,
1349
+ :header_params => header_params,
1350
+ :query_params => query_params,
1351
+ :form_params => form_params,
1352
+ :body => post_body,
1353
+ :auth_names => auth_names,
1354
+ :return_type => return_type,
1355
+ :api_version => "V2"
1356
+ )
1357
+
1358
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Patch, local_var_path, new_options)
1359
+ if @api_client.config.debugging
1360
+ @api_client.config.logger.debug "API called: IncidentsAPI#update_incident_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1361
+ end
1362
+ return data, status_code, headers
1363
+ end
1364
+
1365
+ # Update an incident todo.
1366
+ #
1367
+ # @see #update_incident_todo_with_http_info
1368
+ def update_incident_todo(incident_id, todo_id, body, opts = {})
1369
+ data, _status_code, _headers = update_incident_todo_with_http_info(incident_id, todo_id, body, opts)
1370
+ data
1371
+ end
1372
+
1373
+ # Update an incident todo.
1374
+ #
1375
+ # Update an incident todo.
1376
+ #
1377
+ # @param incident_id [String] The UUID of the incident.
1378
+ # @param todo_id [String] The UUID of the incident todo.
1379
+ # @param body [IncidentTodoPatchRequest] Incident todo payload.
1380
+ # @param opts [Hash] the optional parameters
1381
+ # @return [Array<(IncidentTodoResponse, Integer, Hash)>] IncidentTodoResponse data, response status code and response headers
1382
+ def update_incident_todo_with_http_info(incident_id, todo_id, body, opts = {})
1383
+ unstable_enabled = @api_client.config.unstable_operations["v2.update_incident_todo".to_sym]
1384
+ if unstable_enabled
1385
+ @api_client.config.logger.warn format("Using unstable operation '%s'", "v2.update_incident_todo")
1386
+ else
1387
+ raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.update_incident_todo"))
1388
+ end
1389
+
1390
+ if @api_client.config.debugging
1391
+ @api_client.config.logger.debug 'Calling API: IncidentsAPI.update_incident_todo ...'
1392
+ end
1393
+ # verify the required parameter 'incident_id' is set
1394
+ if @api_client.config.client_side_validation && incident_id.nil?
1395
+ fail ArgumentError, "Missing the required parameter 'incident_id' when calling IncidentsAPI.update_incident_todo"
1396
+ end
1397
+ # verify the required parameter 'todo_id' is set
1398
+ if @api_client.config.client_side_validation && todo_id.nil?
1399
+ fail ArgumentError, "Missing the required parameter 'todo_id' when calling IncidentsAPI.update_incident_todo"
1400
+ end
1401
+ # verify the required parameter 'body' is set
1402
+ if @api_client.config.client_side_validation && body.nil?
1403
+ fail ArgumentError, "Missing the required parameter 'body' when calling IncidentsAPI.update_incident_todo"
1404
+ end
1405
+ # resource path
1406
+ local_var_path = '/api/v2/incidents/{incident_id}/relationships/todos/{todo_id}'.sub('{incident_id}', CGI.escape(incident_id.to_s).gsub('%2F', '/')).sub('{todo_id}', CGI.escape(todo_id.to_s).gsub('%2F', '/'))
1407
+
1408
+ # query parameters
1409
+ query_params = opts[:query_params] || {}
1410
+
1411
+ # header parameters
1412
+ header_params = opts[:header_params] || {}
1413
+ # HTTP header 'Accept' (if needed)
1414
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1415
+ # HTTP header 'Content-Type'
1416
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1417
+
1418
+ # form parameters
1419
+ form_params = opts[:form_params] || {}
1420
+
1421
+ # http body (model)
1422
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
1423
+
1424
+ # return_type
1425
+ return_type = opts[:debug_return_type] || 'IncidentTodoResponse'
1426
+
1427
+ # auth_names
1428
+ auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
1429
+
1430
+ new_options = opts.merge(
1431
+ :operation => :update_incident_todo,
1432
+ :header_params => header_params,
1433
+ :query_params => query_params,
1434
+ :form_params => form_params,
1435
+ :body => post_body,
1436
+ :auth_names => auth_names,
1437
+ :return_type => return_type,
1438
+ :api_version => "V2"
1439
+ )
1440
+
1441
+ data, status_code, headers = @api_client.call_api(Net::HTTP::Patch, local_var_path, new_options)
1442
+ if @api_client.config.debugging
1443
+ @api_client.config.logger.debug "API called: IncidentsAPI#update_incident_todo\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1444
+ end
1445
+ return data, status_code, headers
1446
+ end
654
1447
  end
655
1448
  end