datadog_api_client 2.27.1 → 2.28.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (233) hide show
  1. checksums.yaml +4 -4
  2. data/.apigentools-info +4 -4
  3. data/.generator/conftest.py +0 -3
  4. data/.generator/schemas/v1/openapi.yaml +385 -616
  5. data/.generator/schemas/v2/openapi.yaml +1498 -386
  6. data/.generator/src/generator/formatter.py +2 -43
  7. data/.generator/src/generator/keywords.json +43 -0
  8. data/.generator/src/generator/templates/api.j2 +4 -0
  9. data/.generator/src/generator/templates/api_client.j2 +1 -0
  10. data/CHANGELOG.md +39 -0
  11. data/examples/v1/dashboards/CreateDashboard_1413226400.rb +66 -0
  12. data/examples/v1/dashboards/CreateDashboard_3298564989.rb +65 -0
  13. data/examples/v1/gcp-integration/CreateGCPIntegration.rb +1 -0
  14. data/examples/v1/gcp-integration/UpdateGCPIntegration.rb +1 -0
  15. data/examples/v1/gcp-integration/UpdateGCPIntegration_3544259255.rb +1 -0
  16. data/examples/v1/monitors/ValidateExistingMonitor.rb +0 -1
  17. data/examples/v1/monitors/ValidateMonitor.rb +0 -1
  18. data/examples/v1/monitors/ValidateMonitor_4247196452.rb +0 -1
  19. data/examples/v1/synthetics/CreateSyntheticsAPITest.rb +3 -1
  20. data/examples/v1/synthetics/CreateSyntheticsMobileTest.rb +1 -1
  21. data/examples/v1/synthetics/UpdateBrowserTest.rb +3 -1
  22. data/examples/v1/synthetics/UpdateMobileTest.rb +1 -1
  23. data/examples/v2/domain-allowlist/GetDomainAllowlist.rb +5 -0
  24. data/examples/v2/domain-allowlist/PatchDomainAllowlist.rb +17 -0
  25. data/examples/v2/gcp-integration/CreateGCPSTSAccount_2597004741.rb +1 -0
  26. data/examples/v2/incidents/CreateIncidentType.rb +19 -0
  27. data/examples/v2/incidents/DeleteIncidentType.rb +11 -0
  28. data/examples/v2/incidents/GetIncidentType.rb +8 -0
  29. data/examples/v2/incidents/ListIncidentTypes.rb +8 -0
  30. data/examples/v2/incidents/UpdateIncidentType.rb +22 -0
  31. data/examples/v2/metrics/QueryScalarData.rb +0 -3
  32. data/examples/v2/metrics/QueryScalarData_3112571352.rb +0 -3
  33. data/examples/v2/metrics/QueryTimeseriesData.rb +0 -3
  34. data/examples/v2/metrics/QueryTimeseriesData_301142940.rb +0 -3
  35. data/examples/v2/microsoft-teams-integration/CreateTenantBasedHandle.rb +17 -0
  36. data/examples/v2/microsoft-teams-integration/{CreateApiHandle_1540689753.rb → CreateTenantBasedHandle_1540689753.rb} +5 -5
  37. data/examples/v2/microsoft-teams-integration/DeleteTenantBasedHandle.rb +5 -0
  38. data/examples/v2/microsoft-teams-integration/DeleteTenantBasedHandle_377884154.rb +8 -0
  39. data/examples/v2/microsoft-teams-integration/GetTenantBasedHandle.rb +5 -0
  40. data/examples/v2/microsoft-teams-integration/GetTenantBasedHandle_2883785101.rb +8 -0
  41. data/examples/v2/microsoft-teams-integration/{ListApiHandles.rb → ListTenantBasedHandles.rb} +2 -2
  42. data/examples/v2/microsoft-teams-integration/{ListApiHandles_769592979.rb → ListTenantBasedHandles_769592979.rb} +1 -1
  43. data/examples/v2/microsoft-teams-integration/UpdateTenantBasedHandle.rb +17 -0
  44. data/examples/v2/microsoft-teams-integration/UpdateTenantBasedHandle_419892746.rb +18 -0
  45. data/examples/v2/rum-metrics/CreateRumMetric.rb +32 -0
  46. data/examples/v2/rum-metrics/DeleteRumMetric.rb +8 -0
  47. data/examples/v2/rum-metrics/GetRumMetric.rb +8 -0
  48. data/examples/v2/rum-metrics/ListRumMetrics.rb +5 -0
  49. data/examples/v2/rum-metrics/UpdateRumMetric.rb +29 -0
  50. data/examples/v2/security-monitoring/ListFindings_1668290866.rb +14 -0
  51. data/examples/v2/usage-metering/GetBillingDimensionMapping.rb +8 -0
  52. data/examples/v2/usage-metering/GetMonthlyCostAttribution.rb +4 -1
  53. data/lib/datadog_api_client/api_client.rb +1 -0
  54. data/lib/datadog_api_client/configuration.rb +6 -2
  55. data/lib/datadog_api_client/inflector.rb +81 -28
  56. data/lib/datadog_api_client/v1/api/monitors_api.rb +6 -3
  57. data/lib/datadog_api_client/v1/api/synthetics_api.rb +2 -0
  58. data/lib/datadog_api_client/v1/api/usage_metering_api.rb +5 -3
  59. data/lib/datadog_api_client/v1/models/gcp_account.rb +11 -1
  60. data/lib/datadog_api_client/v1/models/hourly_usage_attribution_usage_type.rb +1 -3
  61. data/lib/datadog_api_client/v1/models/list_stream_source.rb +1 -0
  62. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_supported_metrics.rb +2 -6
  63. data/lib/datadog_api_client/v1/models/monthly_usage_attribution_values.rb +11 -61
  64. data/lib/datadog_api_client/v1/models/slo_history_monitor.rb +1 -1
  65. data/lib/datadog_api_client/v1/models/synthetics_batch_details_data.rb +2 -2
  66. data/lib/datadog_api_client/v1/models/synthetics_batch_result.rb +2 -2
  67. data/lib/datadog_api_client/v1/models/{synthetics_status.rb → synthetics_batch_status.rb} +4 -4
  68. data/lib/datadog_api_client/v1/models/synthetics_mobile_step.rb +32 -6
  69. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params.rb +249 -0
  70. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_direction.rb +29 -0
  71. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element.rb +175 -0
  72. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element_context_type.rb +27 -0
  73. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element_relative_position.rb +115 -0
  74. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element_user_locator.rb +117 -0
  75. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element_user_locator_values_items.rb +115 -0
  76. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_element_user_locator_values_items_type.rb +30 -0
  77. data/lib/datadog_api_client/v1/models/{synthetics_mobile_test_initial_application_arguments.rb → synthetics_mobile_step_params_positions_items.rb} +21 -11
  78. data/lib/datadog_api_client/v1/models/synthetics_mobile_step_params_value.rb +63 -0
  79. data/lib/datadog_api_client/v1/models/{synthetics_mobile_test_ci_options.rb → synthetics_mobile_step_params_variable.rb} +38 -17
  80. data/lib/datadog_api_client/v1/models/synthetics_mobile_test.rb +2 -2
  81. data/lib/datadog_api_client/v1/models/synthetics_mobile_test_config.rb +1 -1
  82. data/lib/datadog_api_client/v1/models/synthetics_mobile_test_options.rb +42 -16
  83. data/lib/datadog_api_client/v1/models/synthetics_mobile_tests_mobile_application.rb +24 -5
  84. data/lib/datadog_api_client/v1/models/synthetics_step.rb +22 -2
  85. data/lib/datadog_api_client/v1/models/synthetics_step_detail.rb +21 -1
  86. data/lib/datadog_api_client/v1/models/synthetics_test_ci_options.rb +19 -1
  87. data/lib/datadog_api_client/v1/models/synthetics_test_details_type.rb +1 -0
  88. data/lib/datadog_api_client/v1/models/synthetics_test_options_monitor_options.rb +34 -4
  89. data/lib/datadog_api_client/v1/models/{synthetics_mobile_test_options_monitor_options_notification_preset_name.rb → synthetics_test_options_monitor_options_notification_preset_name.rb} +2 -2
  90. data/lib/datadog_api_client/v1/models/synthetics_test_options_scheduling.rb +31 -2
  91. data/lib/datadog_api_client/v1/models/synthetics_test_options_scheduling_timeframe.rb +32 -6
  92. data/lib/datadog_api_client/v1/models/{synthetics_mobile_test_binding_items.rb → synthetics_test_restriction_policy_binding.rb} +11 -11
  93. data/lib/datadog_api_client/v1/models/{synthetics_mobile_test_binding_items_role.rb → synthetics_test_restriction_policy_binding_relation.rb} +2 -2
  94. data/lib/datadog_api_client/v1/models/toplist_widget_stacked.rb +1 -12
  95. data/lib/datadog_api_client/v1/models/usage_summary_date.rb +21 -1
  96. data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +21 -1
  97. data/lib/datadog_api_client/v1/models/usage_summary_response.rb +21 -1
  98. data/lib/datadog_api_client/v2/api/cloud_cost_management_api.rb +3 -69
  99. data/lib/datadog_api_client/v2/api/domain_allowlist_api.rb +153 -0
  100. data/lib/datadog_api_client/v2/api/incidents_api.rb +361 -0
  101. data/lib/datadog_api_client/v2/api/metrics_api.rb +1 -13
  102. data/lib/datadog_api_client/v2/api/microsoft_teams_integration_api.rb +98 -161
  103. data/lib/datadog_api_client/v2/api/rum_metrics_api.rb +357 -0
  104. data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +3 -0
  105. data/lib/datadog_api_client/v2/api/software_catalog_api.rb +19 -19
  106. data/lib/datadog_api_client/v2/api/teams_api.rb +1 -0
  107. data/lib/datadog_api_client/v2/api/usage_metering_api.rb +79 -10
  108. data/lib/datadog_api_client/v2/models/billing_dimensions_mapping_body_item.rb +125 -0
  109. data/lib/datadog_api_client/v2/models/billing_dimensions_mapping_body_item_attributes.rb +127 -0
  110. data/lib/datadog_api_client/v2/models/billing_dimensions_mapping_body_item_attributes_endpoints_items.rb +127 -0
  111. data/lib/datadog_api_client/v2/models/billing_dimensions_mapping_body_item_attributes_endpoints_items_status.rb +27 -0
  112. data/lib/datadog_api_client/v2/models/billing_dimensions_mapping_response.rb +107 -0
  113. data/lib/datadog_api_client/v2/models/cloudflare_account_create_request_attributes.rb +1 -1
  114. data/lib/datadog_api_client/v2/models/cloudflare_account_response_attributes.rb +1 -1
  115. data/lib/datadog_api_client/v2/models/cloudflare_account_update_request_attributes.rb +1 -1
  116. data/lib/datadog_api_client/v2/models/domain_allowlist.rb +151 -0
  117. data/lib/datadog_api_client/v2/models/{aws_related_account_attributes.rb → domain_allowlist_attributes.rb} +20 -18
  118. data/lib/datadog_api_client/v2/models/domain_allowlist_request.rb +123 -0
  119. data/lib/datadog_api_client/{v1/models/synthetics_mobile_test_binding.rb → v2/models/domain_allowlist_response.rb} +13 -13
  120. data/lib/datadog_api_client/v2/models/domain_allowlist_response_data.rb +151 -0
  121. data/lib/datadog_api_client/v2/models/domain_allowlist_response_data_attributes.rb +117 -0
  122. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_type.rb → domain_allowlist_type.rb} +3 -3
  123. data/lib/datadog_api_client/v2/models/entity_attributes.rb +1 -1
  124. data/lib/datadog_api_client/v2/models/entity_data.rb +1 -1
  125. data/lib/datadog_api_client/v2/models/entity_response_included_incident.rb +1 -1
  126. data/lib/datadog_api_client/v2/models/entity_response_included_raw_schema.rb +1 -1
  127. data/lib/datadog_api_client/v2/models/entity_response_included_related_oncall_attributes.rb +1 -1
  128. data/lib/datadog_api_client/v2/models/entity_response_included_related_oncall_escalation_item.rb +1 -1
  129. data/lib/datadog_api_client/v2/models/entity_response_included_schema.rb +1 -1
  130. data/lib/datadog_api_client/v2/models/entity_v3_api_version.rb +1 -1
  131. data/lib/datadog_api_client/v2/models/entity_v3_datadog_code_location_item.rb +3 -3
  132. data/lib/datadog_api_client/v2/models/entity_v3_datadog_event_item.rb +2 -2
  133. data/lib/datadog_api_client/v2/models/entity_v3_datadog_integration_opsgenie.rb +2 -2
  134. data/lib/datadog_api_client/v2/models/entity_v3_datadog_integration_pagerduty.rb +2 -2
  135. data/lib/datadog_api_client/v2/models/entity_v3_datadog_log_item.rb +3 -3
  136. data/lib/datadog_api_client/v2/models/entity_v3_datadog_performance.rb +2 -2
  137. data/lib/datadog_api_client/v2/models/entity_v3_datadog_pipelines.rb +2 -2
  138. data/lib/datadog_api_client/v2/models/entity_v3_datastore.rb +4 -4
  139. data/lib/datadog_api_client/v2/models/entity_v3_datastore_datadog.rb +4 -4
  140. data/lib/datadog_api_client/v2/models/entity_v3_datastore_spec.rb +2 -2
  141. data/lib/datadog_api_client/v2/models/entity_v3_integrations.rb +3 -3
  142. data/lib/datadog_api_client/v2/models/entity_v3_metadata.rb +9 -9
  143. data/lib/datadog_api_client/v2/models/entity_v3_metadata_additional_owners_items.rb +2 -2
  144. data/lib/datadog_api_client/v2/models/entity_v3_metadata_contacts_items.rb +2 -2
  145. data/lib/datadog_api_client/v2/models/entity_v3_metadata_links_items.rb +2 -2
  146. data/lib/datadog_api_client/v2/models/entity_v3_metadata_owner.rb +2 -2
  147. data/lib/datadog_api_client/v2/models/entity_v3_queue.rb +5 -5
  148. data/lib/datadog_api_client/v2/models/entity_v3_queue_datadog.rb +4 -4
  149. data/lib/datadog_api_client/v2/models/entity_v3_queue_spec.rb +2 -2
  150. data/lib/datadog_api_client/v2/models/entity_v3_service.rb +5 -5
  151. data/lib/datadog_api_client/v2/models/entity_v3_service_datadog.rb +6 -6
  152. data/lib/datadog_api_client/v2/models/entity_v3_service_spec.rb +3 -3
  153. data/lib/datadog_api_client/v2/models/entity_v3_system.rb +5 -5
  154. data/lib/datadog_api_client/v2/models/entity_v3_system_datadog.rb +5 -5
  155. data/lib/datadog_api_client/v2/models/finding_attributes.rb +14 -4
  156. data/lib/datadog_api_client/v2/models/finding_vulnerability_type.rb +29 -0
  157. data/lib/datadog_api_client/v2/models/gcp_metric_namespace_config.rb +115 -0
  158. data/lib/datadog_api_client/v2/models/gcpsts_service_account_attributes.rb +23 -1
  159. data/lib/datadog_api_client/v2/models/incident_create_attributes.rb +11 -1
  160. data/lib/datadog_api_client/v2/models/incident_integration_metadata_metadata.rb +2 -1
  161. data/lib/datadog_api_client/v2/models/incident_response_attributes.rb +11 -1
  162. data/lib/datadog_api_client/v2/models/incident_response_included_item.rb +1 -1
  163. data/lib/datadog_api_client/v2/models/incident_type_attributes.rb +193 -0
  164. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_request_data.rb → incident_type_create_data.rb} +7 -7
  165. data/lib/datadog_api_client/v2/models/{microsoft_teams_create_api_handle_request.rb → incident_type_create_request.rb} +5 -5
  166. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handles_response.rb → incident_type_list_response.rb} +5 -5
  167. data/lib/datadog_api_client/v2/models/{aws_related_account.rb → incident_type_object.rb} +8 -8
  168. data/lib/datadog_api_client/v2/models/incident_type_patch_data.rb +165 -0
  169. data/lib/datadog_api_client/v2/models/{microsoft_teams_create_api_handle_response.rb → incident_type_patch_request.rb} +5 -5
  170. data/lib/datadog_api_client/v2/models/{microsoft_teams_update_api_handle_request.rb → incident_type_response.rb} +5 -5
  171. data/lib/datadog_api_client/v2/models/{aws_related_account_type.rb → incident_type_type.rb} +3 -3
  172. data/lib/datadog_api_client/v2/models/incident_type_update_attributes.rb +175 -0
  173. data/lib/datadog_api_client/v2/models/incident_user_attributes.rb +153 -0
  174. data/lib/datadog_api_client/v2/models/incident_user_data.rb +125 -0
  175. data/lib/datadog_api_client/v2/models/include_type.rb +1 -1
  176. data/lib/datadog_api_client/v2/models/list_entity_catalog_response_links.rb +3 -3
  177. data/lib/datadog_api_client/v2/models/microsoft_teams_create_tenant_based_handle_request.rb +123 -0
  178. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_attributes.rb → microsoft_teams_tenant_based_handle_attributes.rb} +4 -4
  179. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_info_response_attributes.rb → microsoft_teams_tenant_based_handle_info_response_attributes.rb} +4 -4
  180. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_response_data.rb → microsoft_teams_tenant_based_handle_info_response_data.rb} +8 -8
  181. data/lib/datadog_api_client/v2/models/microsoft_teams_tenant_based_handle_info_type.rb +26 -0
  182. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_request_attributes.rb → microsoft_teams_tenant_based_handle_request_attributes.rb} +4 -4
  183. data/lib/datadog_api_client/v2/models/{microsoft_teams_update_api_handle_request_data.rb → microsoft_teams_tenant_based_handle_request_data.rb} +7 -7
  184. data/lib/datadog_api_client/v2/models/microsoft_teams_tenant_based_handle_response.rb +123 -0
  185. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_info_response_data.rb → microsoft_teams_tenant_based_handle_response_data.rb} +8 -8
  186. data/lib/datadog_api_client/v2/models/microsoft_teams_tenant_based_handle_type.rb +26 -0
  187. data/lib/datadog_api_client/v2/models/microsoft_teams_tenant_based_handles_response.rb +125 -0
  188. data/lib/datadog_api_client/v2/models/microsoft_teams_update_tenant_based_handle_request.rb +123 -0
  189. data/lib/datadog_api_client/v2/models/microsoft_teams_update_tenant_based_handle_request_data.rb +144 -0
  190. data/lib/datadog_api_client/v2/models/ms_teams_integration_metadata.rb +125 -0
  191. data/lib/datadog_api_client/v2/models/ms_teams_integration_metadata_teams_item.rb +186 -0
  192. data/lib/datadog_api_client/v2/models/relation_type.rb +1 -1
  193. data/lib/datadog_api_client/v2/models/relationship_item.rb +1 -1
  194. data/lib/datadog_api_client/v2/models/rum_metric_compute.rb +145 -0
  195. data/lib/datadog_api_client/v2/models/rum_metric_compute_aggregation_type.rb +27 -0
  196. data/lib/datadog_api_client/v2/models/rum_metric_create_attributes.rb +176 -0
  197. data/lib/datadog_api_client/v2/models/rum_metric_create_data.rb +165 -0
  198. data/lib/datadog_api_client/v2/models/rum_metric_create_request.rb +123 -0
  199. data/lib/datadog_api_client/v2/models/rum_metric_event_type.rb +32 -0
  200. data/lib/datadog_api_client/v2/models/rum_metric_filter.rb +123 -0
  201. data/lib/datadog_api_client/v2/models/rum_metric_group_by.rb +133 -0
  202. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_info_response.rb → rum_metric_response.rb} +5 -5
  203. data/lib/datadog_api_client/v2/models/rum_metric_response_attributes.rb +147 -0
  204. data/lib/datadog_api_client/v2/models/rum_metric_response_compute.rb +127 -0
  205. data/lib/datadog_api_client/v2/models/rum_metric_response_data.rb +125 -0
  206. data/lib/datadog_api_client/{v1/models/synthetics_mobile_test_initial_application_arguments_property_names.rb → v2/models/rum_metric_response_filter.rb} +13 -13
  207. data/lib/datadog_api_client/v2/models/rum_metric_response_group_by.rb +115 -0
  208. data/lib/datadog_api_client/v2/models/rum_metric_response_uniqueness.rb +105 -0
  209. data/lib/datadog_api_client/v2/models/{microsoft_teams_api_handle_info_type.rb → rum_metric_type.rb} +3 -3
  210. data/lib/datadog_api_client/v2/models/rum_metric_uniqueness.rb +123 -0
  211. data/lib/datadog_api_client/v2/models/rum_metric_uniqueness_when.rb +27 -0
  212. data/lib/datadog_api_client/v2/models/rum_metric_update_attributes.rb +127 -0
  213. data/lib/datadog_api_client/v2/models/rum_metric_update_compute.rb +106 -0
  214. data/lib/datadog_api_client/v2/models/rum_metric_update_data.rb +154 -0
  215. data/lib/datadog_api_client/v2/models/rum_metric_update_request.rb +123 -0
  216. data/lib/datadog_api_client/v2/models/{aws_related_accounts_response.rb → rum_metrics_response.rb} +5 -5
  217. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_included_keyword_configuration.rb +15 -4
  218. data/lib/datadog_api_client/v2/models/sensitive_data_scanner_meta.rb +2 -2
  219. data/lib/datadog_api_client/v2/models/upsert_catalog_entity_request.rb +1 -1
  220. data/lib/datadog_api_client/version.rb +1 -1
  221. metadata +110 -43
  222. data/examples/v2/cloud-cost-management/ListAWSRelatedAccounts.rb +0 -5
  223. data/examples/v2/microsoft-teams-integration/CreateApiHandle.rb +0 -17
  224. data/examples/v2/microsoft-teams-integration/DeleteApiHandle.rb +0 -5
  225. data/examples/v2/microsoft-teams-integration/DeleteApiHandle_377884154.rb +0 -8
  226. data/examples/v2/microsoft-teams-integration/GetApiHandle.rb +0 -5
  227. data/examples/v2/microsoft-teams-integration/GetApiHandleByName.rb +0 -5
  228. data/examples/v2/microsoft-teams-integration/GetApiHandleByName_1103107145.rb +0 -8
  229. data/examples/v2/microsoft-teams-integration/GetApiHandle_2883785101.rb +0 -8
  230. data/examples/v2/microsoft-teams-integration/UpdateApiHandle.rb +0 -17
  231. data/examples/v2/microsoft-teams-integration/UpdateApiHandle_419892746.rb +0 -18
  232. data/lib/datadog_api_client/v1/models/synthetics_mobile_device_id.rb +0 -251
  233. data/lib/datadog_api_client/v1/models/synthetics_mobile_test_options_monitor_options.rb +0 -155
@@ -21,7 +21,7 @@ module DatadogAPIClient::V1
21
21
  class SyntheticsMobileTestOptions
22
22
  include BaseGenericModel
23
23
 
24
- # The `SyntheticsMobileTestOptions` `allowApplicationCrash`.
24
+ # A boolean to set if an application crash would mark the test as failed.
25
25
  attr_accessor :allow_application_crash
26
26
 
27
27
  # Array of bindings used for the mobile test.
@@ -30,32 +30,32 @@ module DatadogAPIClient::V1
30
30
  # CI/CD options for a Synthetic test.
31
31
  attr_accessor :ci
32
32
 
33
- # The `SyntheticsMobileTestOptions` `defaultStepTimeout`.
33
+ # The default timeout for steps in the test (in seconds).
34
34
  attr_reader :default_step_timeout
35
35
 
36
36
  # For mobile test, array with the different device IDs used to run the test.
37
- attr_accessor :device_ids
37
+ attr_reader :device_ids
38
38
 
39
- # The `SyntheticsMobileTestOptions` `disableAutoAcceptAlert`.
39
+ # A boolean to disable auto accepting alerts.
40
40
  attr_accessor :disable_auto_accept_alert
41
41
 
42
42
  # Minimum amount of time in failure required to trigger an alert.
43
43
  attr_reader :min_failure_duration
44
44
 
45
45
  # Mobile application for mobile synthetics test.
46
- attr_accessor :mobile_application
46
+ attr_reader :mobile_application
47
47
 
48
48
  # The monitor name is used for the alert title as well as for all monitor dashboard widgets and SLOs.
49
49
  attr_accessor :monitor_name
50
50
 
51
- # Object containing the options for a mobile Synthetic test as a monitor
51
+ # Object containing the options for a Synthetic test as a monitor
52
52
  # (for example, renotification).
53
53
  attr_accessor :monitor_options
54
54
 
55
55
  # Integer from 1 (high) to 5 (low) indicating alert severity.
56
56
  attr_reader :monitor_priority
57
57
 
58
- # The `SyntheticsMobileTestOptions` `noScreenshot`.
58
+ # A boolean set to not take a screenshot for the step.
59
59
  attr_accessor :no_screenshot
60
60
 
61
61
  # A list of role identifiers that can be pulled from the Roles API, for restricting read and write access.
@@ -70,7 +70,7 @@ module DatadogAPIClient::V1
70
70
  # The frequency at which to run the Synthetic test (in seconds).
71
71
  attr_reader :tick_every
72
72
 
73
- # The `SyntheticsMobileTestOptions` `verbosity`.
73
+ # The level of verbosity for the mobile test.
74
74
  attr_reader :verbosity
75
75
 
76
76
  attr_accessor :additional_properties
@@ -104,15 +104,15 @@ module DatadogAPIClient::V1
104
104
  def self.openapi_types
105
105
  {
106
106
  :'allow_application_crash' => :'Boolean',
107
- :'bindings' => :'Array<SyntheticsMobileTestBinding>',
108
- :'ci' => :'SyntheticsMobileTestCiOptions',
107
+ :'bindings' => :'Array<SyntheticsTestRestrictionPolicyBinding>',
108
+ :'ci' => :'SyntheticsTestCiOptions',
109
109
  :'default_step_timeout' => :'Integer',
110
- :'device_ids' => :'Array<SyntheticsMobileDeviceID>',
110
+ :'device_ids' => :'Array<String>',
111
111
  :'disable_auto_accept_alert' => :'Boolean',
112
112
  :'min_failure_duration' => :'Integer',
113
113
  :'mobile_application' => :'SyntheticsMobileTestsMobileApplication',
114
114
  :'monitor_name' => :'String',
115
- :'monitor_options' => :'SyntheticsMobileTestOptionsMonitorOptions',
115
+ :'monitor_options' => :'SyntheticsTestOptionsMonitorOptions',
116
116
  :'monitor_priority' => :'Integer',
117
117
  :'no_screenshot' => :'Boolean',
118
118
  :'restricted_roles' => :'Array<String>',
@@ -222,12 +222,15 @@ module DatadogAPIClient::V1
222
222
  def valid?
223
223
  return false if !@default_step_timeout.nil? && @default_step_timeout > 300
224
224
  return false if !@default_step_timeout.nil? && @default_step_timeout < 1
225
+ return false if @device_ids.nil?
225
226
  return false if !@min_failure_duration.nil? && @min_failure_duration > 7200
226
227
  return false if !@min_failure_duration.nil? && @min_failure_duration < 0
228
+ return false if @mobile_application.nil?
227
229
  return false if !@monitor_priority.nil? && @monitor_priority > 5
228
230
  return false if !@monitor_priority.nil? && @monitor_priority < 1
229
- return false if !@tick_every.nil? && @tick_every > 604800
230
- return false if !@tick_every.nil? && @tick_every < 300
231
+ return false if @tick_every.nil?
232
+ return false if @tick_every > 604800
233
+ return false if @tick_every < 300
231
234
  return false if !@verbosity.nil? && @verbosity > 5
232
235
  return false if !@verbosity.nil? && @verbosity < 0
233
236
  true
@@ -246,6 +249,16 @@ module DatadogAPIClient::V1
246
249
  @default_step_timeout = default_step_timeout
247
250
  end
248
251
 
252
+ # Custom attribute writer method with validation
253
+ # @param device_ids [Object] Object to be assigned
254
+ # @!visibility private
255
+ def device_ids=(device_ids)
256
+ if device_ids.nil?
257
+ fail ArgumentError, 'invalid value for "device_ids", device_ids cannot be nil.'
258
+ end
259
+ @device_ids = device_ids
260
+ end
261
+
249
262
  # Custom attribute writer method with validation
250
263
  # @param min_failure_duration [Object] Object to be assigned
251
264
  # @!visibility private
@@ -259,6 +272,16 @@ module DatadogAPIClient::V1
259
272
  @min_failure_duration = min_failure_duration
260
273
  end
261
274
 
275
+ # Custom attribute writer method with validation
276
+ # @param mobile_application [Object] Object to be assigned
277
+ # @!visibility private
278
+ def mobile_application=(mobile_application)
279
+ if mobile_application.nil?
280
+ fail ArgumentError, 'invalid value for "mobile_application", mobile_application cannot be nil.'
281
+ end
282
+ @mobile_application = mobile_application
283
+ end
284
+
262
285
  # Custom attribute writer method with validation
263
286
  # @param monitor_priority [Object] Object to be assigned
264
287
  # @!visibility private
@@ -276,10 +299,13 @@ module DatadogAPIClient::V1
276
299
  # @param tick_every [Object] Object to be assigned
277
300
  # @!visibility private
278
301
  def tick_every=(tick_every)
279
- if !tick_every.nil? && tick_every > 604800
302
+ if tick_every.nil?
303
+ fail ArgumentError, 'invalid value for "tick_every", tick_every cannot be nil.'
304
+ end
305
+ if tick_every > 604800
280
306
  fail ArgumentError, 'invalid value for "tick_every", must be smaller than or equal to 604800.'
281
307
  end
282
- if !tick_every.nil? && tick_every < 300
308
+ if tick_every < 300
283
309
  fail ArgumentError, 'invalid value for "tick_every", must be greater than or equal to 300.'
284
310
  end
285
311
  @tick_every = tick_every
@@ -28,7 +28,7 @@ module DatadogAPIClient::V1
28
28
  attr_reader :reference_id
29
29
 
30
30
  # Reference type for the mobile application for a mobile synthetics test.
31
- attr_accessor :reference_type
31
+ attr_reader :reference_type
32
32
 
33
33
  attr_accessor :additional_properties
34
34
 
@@ -87,8 +87,11 @@ module DatadogAPIClient::V1
87
87
  # @return true if the model is valid
88
88
  # @!visibility private
89
89
  def valid?
90
- return false if !@application_id.nil? && @application_id.to_s.length > 1500
91
- return false if !@reference_id.nil? && @reference_id.to_s.length > 1500
90
+ return false if @application_id.nil?
91
+ return false if @application_id.to_s.length > 1500
92
+ return false if @reference_id.nil?
93
+ return false if @reference_id.to_s.length > 1500
94
+ return false if @reference_type.nil?
92
95
  true
93
96
  end
94
97
 
@@ -96,7 +99,10 @@ module DatadogAPIClient::V1
96
99
  # @param application_id [Object] Object to be assigned
97
100
  # @!visibility private
98
101
  def application_id=(application_id)
99
- if !application_id.nil? && application_id.to_s.length > 1500
102
+ if application_id.nil?
103
+ fail ArgumentError, 'invalid value for "application_id", application_id cannot be nil.'
104
+ end
105
+ if application_id.to_s.length > 1500
100
106
  fail ArgumentError, 'invalid value for "application_id", the character length must be smaller than or equal to 1500.'
101
107
  end
102
108
  @application_id = application_id
@@ -106,12 +112,25 @@ module DatadogAPIClient::V1
106
112
  # @param reference_id [Object] Object to be assigned
107
113
  # @!visibility private
108
114
  def reference_id=(reference_id)
109
- if !reference_id.nil? && reference_id.to_s.length > 1500
115
+ if reference_id.nil?
116
+ fail ArgumentError, 'invalid value for "reference_id", reference_id cannot be nil.'
117
+ end
118
+ if reference_id.to_s.length > 1500
110
119
  fail ArgumentError, 'invalid value for "reference_id", the character length must be smaller than or equal to 1500.'
111
120
  end
112
121
  @reference_id = reference_id
113
122
  end
114
123
 
124
+ # Custom attribute writer method with validation
125
+ # @param reference_type [Object] Object to be assigned
126
+ # @!visibility private
127
+ def reference_type=(reference_type)
128
+ if reference_type.nil?
129
+ fail ArgumentError, 'invalid value for "reference_type", reference_type cannot be nil.'
130
+ end
131
+ @reference_type = reference_type
132
+ end
133
+
115
134
  # Returns the object in the form of hash, with additionalProperties support.
116
135
  # @return [Hash] Returns the object in the form of hash
117
136
  # @!visibility private
@@ -24,13 +24,19 @@ module DatadogAPIClient::V1
24
24
  # A boolean set to allow this step to fail.
25
25
  attr_accessor :allow_failure
26
26
 
27
+ # A boolean set to always execute this step even if the previous step failed or was skipped.
28
+ attr_accessor :always_execute
29
+
30
+ # A boolean set to exit the test if the step succeeds.
31
+ attr_accessor :exit_if_succeed
32
+
27
33
  # A boolean to use in addition to `allowFailure` to determine if the test should be marked as failed when the step fails.
28
34
  attr_accessor :is_critical
29
35
 
30
36
  # The name of the step.
31
37
  attr_accessor :name
32
38
 
33
- # A boolean set to not take a screenshot for the step.
39
+ # A boolean set to skip taking a screenshot for the step.
34
40
  attr_accessor :no_screenshot
35
41
 
36
42
  # The parameters of the step.
@@ -49,6 +55,8 @@ module DatadogAPIClient::V1
49
55
  def self.attribute_map
50
56
  {
51
57
  :'allow_failure' => :'allowFailure',
58
+ :'always_execute' => :'alwaysExecute',
59
+ :'exit_if_succeed' => :'exitIfSucceed',
52
60
  :'is_critical' => :'isCritical',
53
61
  :'name' => :'name',
54
62
  :'no_screenshot' => :'noScreenshot',
@@ -63,6 +71,8 @@ module DatadogAPIClient::V1
63
71
  def self.openapi_types
64
72
  {
65
73
  :'allow_failure' => :'Boolean',
74
+ :'always_execute' => :'Boolean',
75
+ :'exit_if_succeed' => :'Boolean',
66
76
  :'is_critical' => :'Boolean',
67
77
  :'name' => :'String',
68
78
  :'no_screenshot' => :'Boolean',
@@ -94,6 +104,14 @@ module DatadogAPIClient::V1
94
104
  self.allow_failure = attributes[:'allow_failure']
95
105
  end
96
106
 
107
+ if attributes.key?(:'always_execute')
108
+ self.always_execute = attributes[:'always_execute']
109
+ end
110
+
111
+ if attributes.key?(:'exit_if_succeed')
112
+ self.exit_if_succeed = attributes[:'exit_if_succeed']
113
+ end
114
+
97
115
  if attributes.key?(:'is_critical')
98
116
  self.is_critical = attributes[:'is_critical']
99
117
  end
@@ -146,6 +164,8 @@ module DatadogAPIClient::V1
146
164
  return true if self.equal?(o)
147
165
  self.class == o.class &&
148
166
  allow_failure == o.allow_failure &&
167
+ always_execute == o.always_execute &&
168
+ exit_if_succeed == o.exit_if_succeed &&
149
169
  is_critical == o.is_critical &&
150
170
  name == o.name &&
151
171
  no_screenshot == o.no_screenshot &&
@@ -159,7 +179,7 @@ module DatadogAPIClient::V1
159
179
  # @return [Integer] Hash code
160
180
  # @!visibility private
161
181
  def hash
162
- [allow_failure, is_critical, name, no_screenshot, params, timeout, type].hash
182
+ [allow_failure, always_execute, exit_if_succeed, is_critical, name, no_screenshot, params, timeout, type].hash
163
183
  end
164
184
  end
165
185
  end
@@ -21,6 +21,9 @@ module DatadogAPIClient::V1
21
21
  class SyntheticsStepDetail
22
22
  include BaseGenericModel
23
23
 
24
+ # Whether or not the step was allowed to fail.
25
+ attr_accessor :allow_failure
26
+
24
27
  # Array of errors collected for a browser test.
25
28
  attr_accessor :browser_errors
26
29
 
@@ -36,6 +39,9 @@ module DatadogAPIClient::V1
36
39
  # Error returned by the test.
37
40
  attr_accessor :error
38
41
 
42
+ # The browser test failure details.
43
+ attr_accessor :failure
44
+
39
45
  # Navigate between different tabs for your browser test.
40
46
  attr_accessor :playing_tab
41
47
 
@@ -79,11 +85,13 @@ module DatadogAPIClient::V1
79
85
  # @!visibility private
80
86
  def self.attribute_map
81
87
  {
88
+ :'allow_failure' => :'allowFailure',
82
89
  :'browser_errors' => :'browserErrors',
83
90
  :'check_type' => :'checkType',
84
91
  :'description' => :'description',
85
92
  :'duration' => :'duration',
86
93
  :'error' => :'error',
94
+ :'failure' => :'failure',
87
95
  :'playing_tab' => :'playingTab',
88
96
  :'screenshot_bucket_key' => :'screenshotBucketKey',
89
97
  :'skipped' => :'skipped',
@@ -103,11 +111,13 @@ module DatadogAPIClient::V1
103
111
  # @!visibility private
104
112
  def self.openapi_types
105
113
  {
114
+ :'allow_failure' => :'Boolean',
106
115
  :'browser_errors' => :'Array<SyntheticsBrowserError>',
107
116
  :'check_type' => :'SyntheticsCheckType',
108
117
  :'description' => :'String',
109
118
  :'duration' => :'Float',
110
119
  :'error' => :'String',
120
+ :'failure' => :'SyntheticsBrowserTestResultFailure',
111
121
  :'playing_tab' => :'SyntheticsPlayingTab',
112
122
  :'screenshot_bucket_key' => :'Boolean',
113
123
  :'skipped' => :'Boolean',
@@ -141,6 +151,10 @@ module DatadogAPIClient::V1
141
151
  end
142
152
  }
143
153
 
154
+ if attributes.key?(:'allow_failure')
155
+ self.allow_failure = attributes[:'allow_failure']
156
+ end
157
+
144
158
  if attributes.key?(:'browser_errors')
145
159
  if (value = attributes[:'browser_errors']).is_a?(Array)
146
160
  self.browser_errors = value
@@ -163,6 +177,10 @@ module DatadogAPIClient::V1
163
177
  self.error = attributes[:'error']
164
178
  end
165
179
 
180
+ if attributes.key?(:'failure')
181
+ self.failure = attributes[:'failure']
182
+ end
183
+
166
184
  if attributes.key?(:'playing_tab')
167
185
  self.playing_tab = attributes[:'playing_tab']
168
186
  end
@@ -244,11 +262,13 @@ module DatadogAPIClient::V1
244
262
  def ==(o)
245
263
  return true if self.equal?(o)
246
264
  self.class == o.class &&
265
+ allow_failure == o.allow_failure &&
247
266
  browser_errors == o.browser_errors &&
248
267
  check_type == o.check_type &&
249
268
  description == o.description &&
250
269
  duration == o.duration &&
251
270
  error == o.error &&
271
+ failure == o.failure &&
252
272
  playing_tab == o.playing_tab &&
253
273
  screenshot_bucket_key == o.screenshot_bucket_key &&
254
274
  skipped == o.skipped &&
@@ -268,7 +288,7 @@ module DatadogAPIClient::V1
268
288
  # @return [Integer] Hash code
269
289
  # @!visibility private
270
290
  def hash
271
- [browser_errors, check_type, description, duration, error, playing_tab, screenshot_bucket_key, skipped, snapshot_bucket_key, step_id, sub_test_step_details, time_to_interactive, type, url, value, vitals_metrics, warnings].hash
291
+ [allow_failure, browser_errors, check_type, description, duration, error, failure, playing_tab, screenshot_bucket_key, skipped, snapshot_bucket_key, step_id, sub_test_step_details, time_to_interactive, type, url, value, vitals_metrics, warnings].hash
272
292
  end
273
293
  end
274
294
  end
@@ -22,7 +22,7 @@ module DatadogAPIClient::V1
22
22
  include BaseGenericModel
23
23
 
24
24
  # Execution rule for a Synthetic test.
25
- attr_accessor :execution_rule
25
+ attr_reader :execution_rule
26
26
 
27
27
  attr_accessor :additional_properties
28
28
 
@@ -65,6 +65,24 @@ module DatadogAPIClient::V1
65
65
  end
66
66
  end
67
67
 
68
+ # Check to see if the all the properties in the model are valid
69
+ # @return true if the model is valid
70
+ # @!visibility private
71
+ def valid?
72
+ return false if @execution_rule.nil?
73
+ true
74
+ end
75
+
76
+ # Custom attribute writer method with validation
77
+ # @param execution_rule [Object] Object to be assigned
78
+ # @!visibility private
79
+ def execution_rule=(execution_rule)
80
+ if execution_rule.nil?
81
+ fail ArgumentError, 'invalid value for "execution_rule", execution_rule cannot be nil.'
82
+ end
83
+ @execution_rule = execution_rule
84
+ end
85
+
68
86
  # Returns the object in the form of hash, with additionalProperties support.
69
87
  # @return [Hash] Returns the object in the form of hash
70
88
  # @!visibility private
@@ -23,5 +23,6 @@ module DatadogAPIClient::V1
23
23
 
24
24
  API = "api".freeze
25
25
  BROWSER = "browser".freeze
26
+ MOBILE = "mobile".freeze
26
27
  end
27
28
  end
@@ -22,17 +22,29 @@ module DatadogAPIClient::V1
22
22
  class SyntheticsTestOptionsMonitorOptions
23
23
  include BaseGenericModel
24
24
 
25
+ # Message to include in the escalation notification.
26
+ attr_accessor :escalation_message
27
+
28
+ # The name of the preset for the notification for the monitor.
29
+ attr_accessor :notification_preset_name
30
+
25
31
  # Time interval before renotifying if the test is still failing
26
32
  # (in minutes).
27
33
  attr_reader :renotify_interval
28
34
 
35
+ # The number of times to renotify if the test is still failing.
36
+ attr_accessor :renotify_occurrences
37
+
29
38
  attr_accessor :additional_properties
30
39
 
31
40
  # Attribute mapping from ruby-style variable name to JSON key.
32
41
  # @!visibility private
33
42
  def self.attribute_map
34
43
  {
35
- :'renotify_interval' => :'renotify_interval'
44
+ :'escalation_message' => :'escalation_message',
45
+ :'notification_preset_name' => :'notification_preset_name',
46
+ :'renotify_interval' => :'renotify_interval',
47
+ :'renotify_occurrences' => :'renotify_occurrences'
36
48
  }
37
49
  end
38
50
 
@@ -40,7 +52,10 @@ module DatadogAPIClient::V1
40
52
  # @!visibility private
41
53
  def self.openapi_types
42
54
  {
43
- :'renotify_interval' => :'Integer'
55
+ :'escalation_message' => :'String',
56
+ :'notification_preset_name' => :'SyntheticsTestOptionsMonitorOptionsNotificationPresetName',
57
+ :'renotify_interval' => :'Integer',
58
+ :'renotify_occurrences' => :'Integer'
44
59
  }
45
60
  end
46
61
 
@@ -62,9 +77,21 @@ module DatadogAPIClient::V1
62
77
  end
63
78
  }
64
79
 
80
+ if attributes.key?(:'escalation_message')
81
+ self.escalation_message = attributes[:'escalation_message']
82
+ end
83
+
84
+ if attributes.key?(:'notification_preset_name')
85
+ self.notification_preset_name = attributes[:'notification_preset_name']
86
+ end
87
+
65
88
  if attributes.key?(:'renotify_interval')
66
89
  self.renotify_interval = attributes[:'renotify_interval']
67
90
  end
91
+
92
+ if attributes.key?(:'renotify_occurrences')
93
+ self.renotify_occurrences = attributes[:'renotify_occurrences']
94
+ end
68
95
  end
69
96
 
70
97
  # Check to see if the all the properties in the model are valid
@@ -111,7 +138,10 @@ module DatadogAPIClient::V1
111
138
  def ==(o)
112
139
  return true if self.equal?(o)
113
140
  self.class == o.class &&
114
- renotify_interval == o.renotify_interval
141
+ escalation_message == o.escalation_message &&
142
+ notification_preset_name == o.notification_preset_name &&
143
+ renotify_interval == o.renotify_interval &&
144
+ renotify_occurrences == o.renotify_occurrences
115
145
  additional_properties == o.additional_properties
116
146
  end
117
147
 
@@ -119,7 +149,7 @@ module DatadogAPIClient::V1
119
149
  # @return [Integer] Hash code
120
150
  # @!visibility private
121
151
  def hash
122
- [renotify_interval].hash
152
+ [escalation_message, notification_preset_name, renotify_interval, renotify_occurrences].hash
123
153
  end
124
154
  end
125
155
  end
@@ -17,8 +17,8 @@ require 'date'
17
17
  require 'time'
18
18
 
19
19
  module DatadogAPIClient::V1
20
- # The definition of `SyntheticsMobileTestOptionsMonitorOptionsNotificationPresetName` object.
21
- class SyntheticsMobileTestOptionsMonitorOptionsNotificationPresetName
20
+ # The name of the preset for the notification for the monitor.
21
+ class SyntheticsTestOptionsMonitorOptionsNotificationPresetName
22
22
  include BaseEnumModel
23
23
 
24
24
  SHOW_ALL = "show_all".freeze
@@ -22,10 +22,10 @@ module DatadogAPIClient::V1
22
22
  include BaseGenericModel
23
23
 
24
24
  # Array containing objects describing the scheduling pattern to apply to each day.
25
- attr_accessor :timeframes
25
+ attr_reader :timeframes
26
26
 
27
27
  # Timezone in which the timeframe is based.
28
- attr_accessor :timezone
28
+ attr_reader :timezone
29
29
 
30
30
  attr_accessor :additional_properties
31
31
 
@@ -76,6 +76,35 @@ module DatadogAPIClient::V1
76
76
  end
77
77
  end
78
78
 
79
+ # Check to see if the all the properties in the model are valid
80
+ # @return true if the model is valid
81
+ # @!visibility private
82
+ def valid?
83
+ return false if @timeframes.nil?
84
+ return false if @timezone.nil?
85
+ true
86
+ end
87
+
88
+ # Custom attribute writer method with validation
89
+ # @param timeframes [Object] Object to be assigned
90
+ # @!visibility private
91
+ def timeframes=(timeframes)
92
+ if timeframes.nil?
93
+ fail ArgumentError, 'invalid value for "timeframes", timeframes cannot be nil.'
94
+ end
95
+ @timeframes = timeframes
96
+ end
97
+
98
+ # Custom attribute writer method with validation
99
+ # @param timezone [Object] Object to be assigned
100
+ # @!visibility private
101
+ def timezone=(timezone)
102
+ if timezone.nil?
103
+ fail ArgumentError, 'invalid value for "timezone", timezone cannot be nil.'
104
+ end
105
+ @timezone = timezone
106
+ end
107
+
79
108
  # Returns the object in the form of hash, with additionalProperties support.
80
109
  # @return [Hash] Returns the object in the form of hash
81
110
  # @!visibility private
@@ -25,10 +25,10 @@ module DatadogAPIClient::V1
25
25
  attr_reader :day
26
26
 
27
27
  # The hour of the day on which scheduling starts.
28
- attr_accessor :from
28
+ attr_reader :from
29
29
 
30
30
  # The hour of the day on which scheduling ends.
31
- attr_accessor :to
31
+ attr_reader :to
32
32
 
33
33
  attr_accessor :additional_properties
34
34
 
@@ -87,8 +87,11 @@ module DatadogAPIClient::V1
87
87
  # @return true if the model is valid
88
88
  # @!visibility private
89
89
  def valid?
90
- return false if !@day.nil? && @day > 7
91
- return false if !@day.nil? && @day < 1
90
+ return false if @day.nil?
91
+ return false if @day > 7
92
+ return false if @day < 1
93
+ return false if @from.nil?
94
+ return false if @to.nil?
92
95
  true
93
96
  end
94
97
 
@@ -96,15 +99,38 @@ module DatadogAPIClient::V1
96
99
  # @param day [Object] Object to be assigned
97
100
  # @!visibility private
98
101
  def day=(day)
99
- if !day.nil? && day > 7
102
+ if day.nil?
103
+ fail ArgumentError, 'invalid value for "day", day cannot be nil.'
104
+ end
105
+ if day > 7
100
106
  fail ArgumentError, 'invalid value for "day", must be smaller than or equal to 7.'
101
107
  end
102
- if !day.nil? && day < 1
108
+ if day < 1
103
109
  fail ArgumentError, 'invalid value for "day", must be greater than or equal to 1.'
104
110
  end
105
111
  @day = day
106
112
  end
107
113
 
114
+ # Custom attribute writer method with validation
115
+ # @param from [Object] Object to be assigned
116
+ # @!visibility private
117
+ def from=(from)
118
+ if from.nil?
119
+ fail ArgumentError, 'invalid value for "from", from cannot be nil.'
120
+ end
121
+ @from = from
122
+ end
123
+
124
+ # Custom attribute writer method with validation
125
+ # @param to [Object] Object to be assigned
126
+ # @!visibility private
127
+ def to=(to)
128
+ if to.nil?
129
+ fail ArgumentError, 'invalid value for "to", to cannot be nil.'
130
+ end
131
+ @to = to
132
+ end
133
+
108
134
  # Returns the object in the form of hash, with additionalProperties support.
109
135
  # @return [Hash] Returns the object in the form of hash
110
136
  # @!visibility private