onesignal 5.11.1 → 5.12.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 (297) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +4 -0
  3. data/Gemfile.lock +3 -3
  4. data/README.md +3 -3
  5. data/docs/CreateJourneyRequest.md +30 -0
  6. data/docs/DefaultApi.md +564 -1
  7. data/docs/Journey.md +48 -0
  8. data/docs/JourneyAudience.md +28 -0
  9. data/docs/JourneyBranch.md +24 -0
  10. data/docs/JourneyBranchStats.md +18 -0
  11. data/docs/JourneyCondition.md +34 -0
  12. data/docs/JourneyEarlyExit.md +20 -0
  13. data/docs/JourneyEarlyExitRules.md +24 -0
  14. data/docs/JourneyEarlyExitRulesOnEvent.md +18 -0
  15. data/docs/JourneyEarlyExitRulesOnSegment.md +18 -0
  16. data/docs/JourneyEventAttribute.md +22 -0
  17. data/docs/JourneyListAudience.md +18 -0
  18. data/docs/JourneyListItem.md +40 -0
  19. data/docs/JourneyListResponse.md +22 -0
  20. data/docs/JourneyMessageStats.md +18 -0
  21. data/docs/JourneyNode.md +50 -0
  22. data/docs/JourneyNodeStats.md +26 -0
  23. data/docs/JourneyReentryRules.md +18 -0
  24. data/docs/JourneySchedule.md +22 -0
  25. data/docs/JourneyStats.md +28 -0
  26. data/docs/JourneyTimePoint.md +20 -0
  27. data/docs/JourneyTimeWindow.md +22 -0
  28. data/docs/JourneyWaitUntilExpiration.md +20 -0
  29. data/docs/UpdateJourneyNodeRequest.md +48 -0
  30. data/docs/UpdateJourneyRequest.md +34 -0
  31. data/lib/onesignal/api/default_api.rb +525 -2
  32. data/lib/onesignal/api_client.rb +1 -2
  33. data/lib/onesignal/api_error.rb +0 -1
  34. data/lib/onesignal/configuration.rb +0 -1
  35. data/lib/onesignal/models/api_key_token.rb +0 -1
  36. data/lib/onesignal/models/api_key_tokens_list_response.rb +0 -1
  37. data/lib/onesignal/models/app.rb +0 -1
  38. data/lib/onesignal/models/audit_log_actor.rb +0 -1
  39. data/lib/onesignal/models/audit_log_context.rb +0 -1
  40. data/lib/onesignal/models/audit_log_event.rb +0 -1
  41. data/lib/onesignal/models/audit_log_target.rb +0 -1
  42. data/lib/onesignal/models/basic_notification.rb +0 -1
  43. data/lib/onesignal/models/basic_notification_all_of.rb +0 -1
  44. data/lib/onesignal/models/basic_notification_all_of_android_background_layout.rb +0 -1
  45. data/lib/onesignal/models/button.rb +0 -1
  46. data/lib/onesignal/models/copy_template_request.rb +0 -1
  47. data/lib/onesignal/models/create_api_key_request.rb +0 -1
  48. data/lib/onesignal/models/create_api_key_response.rb +0 -1
  49. data/lib/onesignal/models/create_journey_request.rb +287 -0
  50. data/lib/onesignal/models/create_notification_success_response.rb +0 -1
  51. data/lib/onesignal/models/create_segment_conflict_response.rb +0 -1
  52. data/lib/onesignal/models/create_segment_success_response.rb +0 -1
  53. data/lib/onesignal/models/create_template_request.rb +0 -1
  54. data/lib/onesignal/models/create_user_conflict_response.rb +0 -1
  55. data/lib/onesignal/models/create_user_conflict_response_errors_inner.rb +0 -1
  56. data/lib/onesignal/models/create_user_conflict_response_errors_items_meta.rb +0 -1
  57. data/lib/onesignal/models/custom_event.rb +0 -1
  58. data/lib/onesignal/models/custom_events_request.rb +0 -1
  59. data/lib/onesignal/models/delivery_data.rb +0 -1
  60. data/lib/onesignal/models/export_events_success_response.rb +0 -1
  61. data/lib/onesignal/models/export_subscriptions_request_body.rb +0 -1
  62. data/lib/onesignal/models/export_subscriptions_success_response.rb +0 -1
  63. data/lib/onesignal/models/filter.rb +0 -1
  64. data/lib/onesignal/models/filter_expression.rb +0 -1
  65. data/lib/onesignal/models/generic_error.rb +0 -1
  66. data/lib/onesignal/models/generic_success_bool_response.rb +0 -1
  67. data/lib/onesignal/models/get_notification_history_request_body.rb +0 -1
  68. data/lib/onesignal/models/get_segment_success_response.rb +0 -1
  69. data/lib/onesignal/models/get_segments_success_response.rb +0 -1
  70. data/lib/onesignal/models/journey.rb +409 -0
  71. data/lib/onesignal/models/journey_audience.rb +316 -0
  72. data/lib/onesignal/models/journey_branch.rb +250 -0
  73. data/lib/onesignal/models/journey_branch_stats.rb +220 -0
  74. data/lib/onesignal/models/journey_condition.rb +360 -0
  75. data/lib/onesignal/models/journey_early_exit.rb +231 -0
  76. data/lib/onesignal/models/journey_early_exit_rules.rb +251 -0
  77. data/lib/onesignal/models/journey_early_exit_rules_on_event.rb +224 -0
  78. data/lib/onesignal/models/journey_early_exit_rules_on_segment.rb +221 -0
  79. data/lib/onesignal/models/journey_event_attribute.rb +283 -0
  80. data/lib/onesignal/models/journey_list_audience.rb +254 -0
  81. data/lib/onesignal/models/journey_list_item.rb +366 -0
  82. data/lib/onesignal/models/journey_list_response.rb +241 -0
  83. data/lib/onesignal/models/journey_message_stats.rb +222 -0
  84. data/lib/onesignal/models/journey_node.rb +480 -0
  85. data/lib/onesignal/models/journey_node_stats.rb +293 -0
  86. data/lib/onesignal/models/journey_reentry_rules.rb +236 -0
  87. data/lib/onesignal/models/journey_schedule.rb +243 -0
  88. data/lib/onesignal/models/journey_stats.rb +274 -0
  89. data/lib/onesignal/models/journey_time_point.rb +277 -0
  90. data/lib/onesignal/models/journey_time_window.rb +266 -0
  91. data/lib/onesignal/models/journey_wait_until_expiration.rb +256 -0
  92. data/lib/onesignal/models/language_string_map.rb +0 -1
  93. data/lib/onesignal/models/list_audit_logs_success_response.rb +0 -1
  94. data/lib/onesignal/models/notification.rb +0 -1
  95. data/lib/onesignal/models/notification_all_of.rb +0 -1
  96. data/lib/onesignal/models/notification_history_success_response.rb +0 -1
  97. data/lib/onesignal/models/notification_slice.rb +0 -1
  98. data/lib/onesignal/models/notification_target.rb +0 -1
  99. data/lib/onesignal/models/notification_with_meta.rb +0 -1
  100. data/lib/onesignal/models/notification_with_meta_all_of.rb +0 -1
  101. data/lib/onesignal/models/operator.rb +0 -1
  102. data/lib/onesignal/models/outcome_data.rb +0 -1
  103. data/lib/onesignal/models/outcomes_data.rb +0 -1
  104. data/lib/onesignal/models/platform_delivery_data.rb +0 -1
  105. data/lib/onesignal/models/platform_delivery_data_email_all_of.rb +0 -1
  106. data/lib/onesignal/models/platform_delivery_data_sms_all_of.rb +0 -1
  107. data/lib/onesignal/models/properties_body.rb +0 -1
  108. data/lib/onesignal/models/properties_deltas.rb +0 -1
  109. data/lib/onesignal/models/properties_object.rb +0 -1
  110. data/lib/onesignal/models/purchase.rb +0 -1
  111. data/lib/onesignal/models/rate_limit_error.rb +0 -1
  112. data/lib/onesignal/models/segment.rb +0 -1
  113. data/lib/onesignal/models/segment_data.rb +0 -1
  114. data/lib/onesignal/models/segment_details.rb +0 -1
  115. data/lib/onesignal/models/segment_notification_target.rb +0 -1
  116. data/lib/onesignal/models/start_live_activity_request.rb +0 -1
  117. data/lib/onesignal/models/start_live_activity_success_response.rb +0 -1
  118. data/lib/onesignal/models/subscription.rb +0 -1
  119. data/lib/onesignal/models/subscription_body.rb +0 -1
  120. data/lib/onesignal/models/subscription_notification_target.rb +0 -1
  121. data/lib/onesignal/models/template_resource.rb +0 -1
  122. data/lib/onesignal/models/templates_list_response.rb +0 -1
  123. data/lib/onesignal/models/transfer_subscription_request_body.rb +0 -1
  124. data/lib/onesignal/models/update_api_key_request.rb +0 -1
  125. data/lib/onesignal/models/update_journey_node_request.rb +454 -0
  126. data/lib/onesignal/models/update_journey_request.rb +337 -0
  127. data/lib/onesignal/models/update_live_activity_request.rb +0 -1
  128. data/lib/onesignal/models/update_live_activity_success_response.rb +0 -1
  129. data/lib/onesignal/models/update_segment_request.rb +0 -1
  130. data/lib/onesignal/models/update_segment_success_response.rb +0 -1
  131. data/lib/onesignal/models/update_template_request.rb +0 -1
  132. data/lib/onesignal/models/update_user_request.rb +0 -1
  133. data/lib/onesignal/models/user.rb +0 -1
  134. data/lib/onesignal/models/user_identity_body.rb +0 -1
  135. data/lib/onesignal/models/web_button.rb +0 -1
  136. data/lib/onesignal/version.rb +1 -2
  137. data/lib/onesignal.rb +25 -1
  138. data/onesignal.gemspec +0 -1
  139. data/spec/api/default_api_spec.rb +95 -1
  140. data/spec/api_client_spec.rb +0 -1
  141. data/spec/configuration_spec.rb +0 -1
  142. data/spec/models/api_key_token_spec.rb +0 -1
  143. data/spec/models/api_key_tokens_list_response_spec.rb +0 -1
  144. data/spec/models/app_spec.rb +0 -1
  145. data/spec/models/audit_log_actor_spec.rb +0 -1
  146. data/spec/models/audit_log_context_spec.rb +0 -1
  147. data/spec/models/audit_log_event_spec.rb +0 -1
  148. data/spec/models/audit_log_target_spec.rb +0 -1
  149. data/spec/models/basic_notification_all_of_android_background_layout_spec.rb +0 -1
  150. data/spec/models/basic_notification_all_of_spec.rb +0 -1
  151. data/spec/models/basic_notification_spec.rb +0 -1
  152. data/spec/models/button_spec.rb +0 -1
  153. data/spec/models/copy_template_request_spec.rb +0 -1
  154. data/spec/models/create_api_key_request_spec.rb +0 -1
  155. data/spec/models/create_api_key_response_spec.rb +0 -1
  156. data/spec/models/create_journey_request_spec.rb +69 -0
  157. data/spec/models/create_notification_success_response_spec.rb +0 -1
  158. data/spec/models/create_segment_conflict_response_spec.rb +0 -1
  159. data/spec/models/create_segment_success_response_spec.rb +0 -1
  160. data/spec/models/create_template_request_spec.rb +0 -1
  161. data/spec/models/create_user_conflict_response_errors_inner_spec.rb +0 -1
  162. data/spec/models/create_user_conflict_response_errors_items_meta_spec.rb +0 -1
  163. data/spec/models/create_user_conflict_response_spec.rb +0 -1
  164. data/spec/models/custom_event_spec.rb +0 -1
  165. data/spec/models/custom_events_request_spec.rb +0 -1
  166. data/spec/models/delivery_data_spec.rb +0 -1
  167. data/spec/models/export_events_success_response_spec.rb +0 -1
  168. data/spec/models/export_subscriptions_request_body_spec.rb +0 -1
  169. data/spec/models/export_subscriptions_success_response_spec.rb +0 -1
  170. data/spec/models/filter_expression_spec.rb +0 -1
  171. data/spec/models/filter_spec.rb +0 -1
  172. data/spec/models/generic_error_spec.rb +0 -1
  173. data/spec/models/generic_success_bool_response_spec.rb +0 -1
  174. data/spec/models/get_notification_history_request_body_spec.rb +0 -1
  175. data/spec/models/get_segment_success_response_spec.rb +0 -1
  176. data/spec/models/get_segments_success_response_spec.rb +0 -1
  177. data/spec/models/journey_audience_spec.rb +67 -0
  178. data/spec/models/journey_branch_spec.rb +51 -0
  179. data/spec/models/journey_branch_stats_spec.rb +33 -0
  180. data/spec/models/journey_condition_spec.rb +89 -0
  181. data/spec/models/journey_early_exit_rules_on_event_spec.rb +33 -0
  182. data/spec/models/journey_early_exit_rules_on_segment_spec.rb +33 -0
  183. data/spec/models/journey_early_exit_rules_spec.rb +51 -0
  184. data/spec/models/journey_early_exit_spec.rb +39 -0
  185. data/spec/models/journey_event_attribute_spec.rb +49 -0
  186. data/spec/models/journey_list_audience_spec.rb +37 -0
  187. data/spec/models/journey_list_item_spec.rb +103 -0
  188. data/spec/models/journey_list_response_spec.rb +45 -0
  189. data/spec/models/journey_message_stats_spec.rb +33 -0
  190. data/spec/models/journey_node_spec.rb +137 -0
  191. data/spec/models/journey_node_stats_spec.rb +61 -0
  192. data/spec/models/journey_reentry_rules_spec.rb +33 -0
  193. data/spec/models/journey_schedule_spec.rb +45 -0
  194. data/spec/models/journey_spec.rb +127 -0
  195. data/spec/models/journey_stats_spec.rb +63 -0
  196. data/spec/models/journey_time_point_spec.rb +39 -0
  197. data/spec/models/journey_time_window_spec.rb +45 -0
  198. data/spec/models/journey_wait_until_expiration_spec.rb +39 -0
  199. data/spec/models/language_string_map_spec.rb +0 -1
  200. data/spec/models/list_audit_logs_success_response_spec.rb +0 -1
  201. data/spec/models/notification_all_of_spec.rb +0 -1
  202. data/spec/models/notification_history_success_response_spec.rb +0 -1
  203. data/spec/models/notification_slice_spec.rb +0 -1
  204. data/spec/models/notification_spec.rb +0 -1
  205. data/spec/models/notification_target_spec.rb +0 -1
  206. data/spec/models/notification_with_meta_all_of_spec.rb +0 -1
  207. data/spec/models/notification_with_meta_spec.rb +0 -1
  208. data/spec/models/operator_spec.rb +0 -1
  209. data/spec/models/outcome_data_spec.rb +0 -1
  210. data/spec/models/outcomes_data_spec.rb +0 -1
  211. data/spec/models/platform_delivery_data_email_all_of_spec.rb +0 -1
  212. data/spec/models/platform_delivery_data_sms_all_of_spec.rb +0 -1
  213. data/spec/models/platform_delivery_data_spec.rb +0 -1
  214. data/spec/models/properties_body_spec.rb +0 -1
  215. data/spec/models/properties_deltas_spec.rb +0 -1
  216. data/spec/models/properties_object_spec.rb +0 -1
  217. data/spec/models/purchase_spec.rb +0 -1
  218. data/spec/models/rate_limit_error_spec.rb +0 -1
  219. data/spec/models/segment_data_spec.rb +0 -1
  220. data/spec/models/segment_details_spec.rb +0 -1
  221. data/spec/models/segment_notification_target_spec.rb +0 -1
  222. data/spec/models/segment_spec.rb +0 -1
  223. data/spec/models/start_live_activity_request_spec.rb +0 -1
  224. data/spec/models/start_live_activity_success_response_spec.rb +0 -1
  225. data/spec/models/subscription_body_spec.rb +0 -1
  226. data/spec/models/subscription_notification_target_spec.rb +0 -1
  227. data/spec/models/subscription_spec.rb +0 -1
  228. data/spec/models/template_resource_spec.rb +0 -1
  229. data/spec/models/templates_list_response_spec.rb +0 -1
  230. data/spec/models/transfer_subscription_request_body_spec.rb +0 -1
  231. data/spec/models/update_api_key_request_spec.rb +0 -1
  232. data/spec/models/update_journey_node_request_spec.rb +127 -0
  233. data/spec/models/update_journey_request_spec.rb +85 -0
  234. data/spec/models/update_live_activity_request_spec.rb +0 -1
  235. data/spec/models/update_live_activity_success_response_spec.rb +0 -1
  236. data/spec/models/update_segment_request_spec.rb +0 -1
  237. data/spec/models/update_segment_success_response_spec.rb +0 -1
  238. data/spec/models/update_template_request_spec.rb +0 -1
  239. data/spec/models/update_user_request_spec.rb +0 -1
  240. data/spec/models/user_identity_body_spec.rb +0 -1
  241. data/spec/models/user_spec.rb +0 -1
  242. data/spec/models/web_button_spec.rb +0 -1
  243. data/spec/spec_helper.rb +0 -1
  244. data/vendor/bundle/ruby/3.2.0/cache/io-console-0.9.2.gem +0 -0
  245. data/vendor/bundle/ruby/3.2.0/cache/reline-0.7.0.gem +0 -0
  246. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/byebug-13.0.0/gem_make.out +5 -5
  247. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/date-3.5.1/gem_make.out +5 -5
  248. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/{io-console-0.8.2 → io-console-0.9.2}/gem_make.out +15 -14
  249. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/io-console-0.9.2/io/console.so +0 -0
  250. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/{io-console-0.8.2 → io-console-0.9.2}/mkmf.log +112 -109
  251. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/jaro_winkler-1.5.6/gem_make.out +5 -5
  252. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/psych-5.4.0/gem_make.out +5 -5
  253. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/racc-1.8.1/gem_make.out +5 -5
  254. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/stringio-3.2.0/gem_make.out +5 -5
  255. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/ext/io/console/Makefile +1 -1
  256. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/ext/io/console/console.c +521 -28
  257. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/ext/io/console/extconf.rb +13 -14
  258. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/ext/io/console/win32_vk.inc +313 -165
  259. data/vendor/bundle/ruby/3.2.0/gems/io-console-0.9.2/lib/io/console.so +0 -0
  260. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/io/ansi.rb +6 -4
  261. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/io/windows.rb +49 -23
  262. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/io.rb +8 -2
  263. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/line_editor.rb +49 -21
  264. data/vendor/bundle/ruby/3.2.0/gems/reline-0.7.0/lib/reline/version.rb +3 -0
  265. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline.rb +10 -9
  266. data/vendor/bundle/ruby/3.2.0/specifications/{io-console-0.8.2.gemspec → io-console-0.9.2.gemspec} +3 -3
  267. data/vendor/bundle/ruby/3.2.0/specifications/{reline-0.6.3.gemspec → reline-0.7.0.gemspec} +2 -2
  268. metadata +208 -108
  269. data/vendor/bundle/ruby/3.2.0/cache/io-console-0.8.2.gem +0 -0
  270. data/vendor/bundle/ruby/3.2.0/cache/reline-0.6.3.gem +0 -0
  271. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/io-console-0.8.2/io/console.so +0 -0
  272. data/vendor/bundle/ruby/3.2.0/gems/io-console-0.8.2/lib/io/console.so +0 -0
  273. data/vendor/bundle/ruby/3.2.0/gems/reline-0.6.3/lib/reline/version.rb +0 -3
  274. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/{io-console-0.8.2 → io-console-0.9.2}/gem.build_complete +0 -0
  275. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/.document +0 -0
  276. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/BSDL +0 -0
  277. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/COPYING +0 -0
  278. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/README.md +0 -0
  279. data/vendor/bundle/ruby/3.2.0/gems/{io-console-0.8.2 → io-console-0.9.2}/lib/io/console/size.rb +0 -0
  280. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/BSDL +0 -0
  281. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/COPYING +0 -0
  282. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/README.md +0 -0
  283. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/config.rb +0 -0
  284. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/face.rb +0 -0
  285. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/history.rb +0 -0
  286. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/io/dumb.rb +0 -0
  287. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor/base.rb +0 -0
  288. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor/composite.rb +0 -0
  289. data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor/emacs.rb +2 -2
  290. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor/vi_command.rb +0 -0
  291. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor/vi_insert.rb +0 -0
  292. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_actor.rb +0 -0
  293. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/key_stroke.rb +0 -0
  294. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/kill_ring.rb +0 -0
  295. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/unicode/east_asian_width.rb +0 -0
  296. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/lib/reline/unicode.rb +0 -0
  297. /data/vendor/bundle/ruby/3.2.0/gems/{reline-0.6.3 → reline-0.7.0}/license_of_rb-readline +0 -0
@@ -0,0 +1,409 @@
1
+ =begin
2
+ #OneSignal
3
+
4
+ #A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com
5
+
6
+ Contact: devrel@onesignal.com
7
+ Generated by: https://openapi-generator.tech
8
+ OpenAPI Generator version: 6.0.0-SNAPSHOT
9
+
10
+ =end
11
+
12
+ require 'date'
13
+ require 'time'
14
+
15
+ module OneSignal
16
+ # Full journey representation returned by the detail, create, and update endpoints.
17
+ class Journey
18
+ # Journey UUID. Read-only.
19
+ attr_accessor :id
20
+
21
+ # UUID of the app the journey belongs to. Read-only.
22
+ attr_accessor :app_id
23
+
24
+ # Journey name, up to 300 characters.
25
+ attr_accessor :name
26
+
27
+ # Journey description, up to 1024 characters. Defaults to an empty string.
28
+ attr_accessor :description
29
+
30
+ # Journey state. New journeys are created as draft. processing is transient while activation is in progress. archived is a journey that has been stopped. Change it through the state field on Update journey.
31
+ attr_accessor :state
32
+
33
+ # ISO 8601 creation time. Read-only.
34
+ attr_accessor :created_at
35
+
36
+ # ISO 8601 last-update time. Read-only.
37
+ attr_accessor :updated_at
38
+
39
+ # ISO 8601 time the journey was activated, or null. Read-only. May stay null briefly after you set state to active: activation is enqueued, and started_at populates once the journey finishes processing.
40
+ attr_accessor :started_at
41
+
42
+ # ISO 8601 time the journey was archived, or null. Read-only.
43
+ attr_accessor :archived_at
44
+
45
+ # Origin of the journey, for example public_api or dashboard. Read-only.
46
+ attr_accessor :created_source
47
+
48
+ attr_accessor :audience
49
+
50
+ attr_accessor :early_exit
51
+
52
+ attr_accessor :reentry_rules
53
+
54
+ attr_accessor :schedule
55
+
56
+ # Ordered list of journey nodes.
57
+ attr_accessor :nodes
58
+
59
+ # Opaque optimistic-concurrency token. Read-only. Pass it back on update to guard against overwriting a concurrent change (409). Send it back exactly as read; do not construct or parse it.
60
+ attr_accessor :concurrency_key
61
+
62
+ class EnumAttributeValidator
63
+ attr_reader :datatype
64
+ attr_reader :allowable_values
65
+
66
+ def initialize(datatype, allowable_values)
67
+ @allowable_values = allowable_values.map do |value|
68
+ case datatype.to_s
69
+ when /Integer/i
70
+ value.to_i
71
+ when /Float/i
72
+ value.to_f
73
+ else
74
+ value
75
+ end
76
+ end
77
+ end
78
+
79
+ def valid?(value)
80
+ !value || allowable_values.include?(value)
81
+ end
82
+ end
83
+
84
+ # Attribute mapping from ruby-style variable name to JSON key.
85
+ def self.attribute_map
86
+ {
87
+ :'id' => :'id',
88
+ :'app_id' => :'app_id',
89
+ :'name' => :'name',
90
+ :'description' => :'description',
91
+ :'state' => :'state',
92
+ :'created_at' => :'created_at',
93
+ :'updated_at' => :'updated_at',
94
+ :'started_at' => :'started_at',
95
+ :'archived_at' => :'archived_at',
96
+ :'created_source' => :'created_source',
97
+ :'audience' => :'audience',
98
+ :'early_exit' => :'early_exit',
99
+ :'reentry_rules' => :'reentry_rules',
100
+ :'schedule' => :'schedule',
101
+ :'nodes' => :'nodes',
102
+ :'concurrency_key' => :'concurrency_key'
103
+ }
104
+ end
105
+
106
+ # Returns all the JSON keys this model knows about
107
+ def self.acceptable_attributes
108
+ attribute_map.values
109
+ end
110
+
111
+ # Attribute type mapping.
112
+ def self.openapi_types
113
+ {
114
+ :'id' => :'String',
115
+ :'app_id' => :'String',
116
+ :'name' => :'String',
117
+ :'description' => :'String',
118
+ :'state' => :'String',
119
+ :'created_at' => :'String',
120
+ :'updated_at' => :'String',
121
+ :'started_at' => :'String',
122
+ :'archived_at' => :'String',
123
+ :'created_source' => :'String',
124
+ :'audience' => :'JourneyAudience',
125
+ :'early_exit' => :'JourneyEarlyExit',
126
+ :'reentry_rules' => :'JourneyReentryRules',
127
+ :'schedule' => :'JourneySchedule',
128
+ :'nodes' => :'Array<JourneyNode>',
129
+ :'concurrency_key' => :'String'
130
+ }
131
+ end
132
+
133
+ # List of attributes with nullable: true
134
+ def self.openapi_nullable
135
+ Set.new([
136
+ :'description',
137
+ :'started_at',
138
+ :'archived_at',
139
+ :'created_source',
140
+ :'early_exit',
141
+ :'reentry_rules',
142
+ :'schedule',
143
+ ])
144
+ end
145
+
146
+ # Initializes the object
147
+ # @param [Hash] attributes Model attributes in the form of hash
148
+ def initialize(attributes = {})
149
+ if (!attributes.is_a?(Hash))
150
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OneSignal::Journey` initialize method"
151
+ end
152
+
153
+ # check to see if the attribute exists and convert string to symbol for hash key
154
+ attributes = attributes.each_with_object({}) { |(k, v), h|
155
+ if (!self.class.attribute_map.key?(k.to_sym))
156
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OneSignal::Journey`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
157
+ end
158
+ h[k.to_sym] = v
159
+ }
160
+
161
+ if attributes.key?(:'id')
162
+ self.id = attributes[:'id']
163
+ end
164
+
165
+ if attributes.key?(:'app_id')
166
+ self.app_id = attributes[:'app_id']
167
+ end
168
+
169
+ if attributes.key?(:'name')
170
+ self.name = attributes[:'name']
171
+ end
172
+
173
+ if attributes.key?(:'description')
174
+ self.description = attributes[:'description']
175
+ end
176
+
177
+ if attributes.key?(:'state')
178
+ self.state = attributes[:'state']
179
+ end
180
+
181
+ if attributes.key?(:'created_at')
182
+ self.created_at = attributes[:'created_at']
183
+ end
184
+
185
+ if attributes.key?(:'updated_at')
186
+ self.updated_at = attributes[:'updated_at']
187
+ end
188
+
189
+ if attributes.key?(:'started_at')
190
+ self.started_at = attributes[:'started_at']
191
+ end
192
+
193
+ if attributes.key?(:'archived_at')
194
+ self.archived_at = attributes[:'archived_at']
195
+ end
196
+
197
+ if attributes.key?(:'created_source')
198
+ self.created_source = attributes[:'created_source']
199
+ end
200
+
201
+ if attributes.key?(:'audience')
202
+ self.audience = attributes[:'audience']
203
+ end
204
+
205
+ if attributes.key?(:'early_exit')
206
+ self.early_exit = attributes[:'early_exit']
207
+ end
208
+
209
+ if attributes.key?(:'reentry_rules')
210
+ self.reentry_rules = attributes[:'reentry_rules']
211
+ end
212
+
213
+ if attributes.key?(:'schedule')
214
+ self.schedule = attributes[:'schedule']
215
+ end
216
+
217
+ if attributes.key?(:'nodes')
218
+ if (value = attributes[:'nodes']).is_a?(Array)
219
+ self.nodes = value
220
+ end
221
+ end
222
+
223
+ if attributes.key?(:'concurrency_key')
224
+ self.concurrency_key = attributes[:'concurrency_key']
225
+ end
226
+ end
227
+
228
+ # Show invalid properties with the reasons. Usually used together with valid?
229
+ # @return Array for valid properties with the reasons
230
+ def list_invalid_properties
231
+ invalid_properties = Array.new
232
+ invalid_properties
233
+ end
234
+
235
+ # Check to see if the all the properties in the model are valid
236
+ # @return true if the model is valid
237
+ def valid?
238
+ state_validator = EnumAttributeValidator.new('String', ["draft", "scheduled", "processing", "active", "archived"])
239
+ return false unless state_validator.valid?(@state)
240
+ true
241
+ end
242
+
243
+ # Custom attribute writer method checking allowed values (enum).
244
+ # @param [Object] state Object to be assigned
245
+ def state=(state)
246
+ validator = EnumAttributeValidator.new('String', ["draft", "scheduled", "processing", "active", "archived"])
247
+ unless validator.valid?(state)
248
+ fail ArgumentError, "invalid value for \"state\", must be one of #{validator.allowable_values}."
249
+ end
250
+ @state = state
251
+ end
252
+
253
+ # Checks equality by comparing each attribute.
254
+ # @param [Object] Object to be compared
255
+ def ==(o)
256
+ return true if self.equal?(o)
257
+ self.class == o.class &&
258
+ id == o.id &&
259
+ app_id == o.app_id &&
260
+ name == o.name &&
261
+ description == o.description &&
262
+ state == o.state &&
263
+ created_at == o.created_at &&
264
+ updated_at == o.updated_at &&
265
+ started_at == o.started_at &&
266
+ archived_at == o.archived_at &&
267
+ created_source == o.created_source &&
268
+ audience == o.audience &&
269
+ early_exit == o.early_exit &&
270
+ reentry_rules == o.reentry_rules &&
271
+ schedule == o.schedule &&
272
+ nodes == o.nodes &&
273
+ concurrency_key == o.concurrency_key
274
+ end
275
+
276
+ # @see the `==` method
277
+ # @param [Object] Object to be compared
278
+ def eql?(o)
279
+ self == o
280
+ end
281
+
282
+ # Calculates hash code according to all attributes.
283
+ # @return [Integer] Hash code
284
+ def hash
285
+ [id, app_id, name, description, state, created_at, updated_at, started_at, archived_at, created_source, audience, early_exit, reentry_rules, schedule, nodes, concurrency_key].hash
286
+ end
287
+
288
+ # Builds the object from hash
289
+ # @param [Hash] attributes Model attributes in the form of hash
290
+ # @return [Object] Returns the model itself
291
+ def self.build_from_hash(attributes)
292
+ new.build_from_hash(attributes)
293
+ end
294
+
295
+ # Builds the object from hash
296
+ # @param [Hash] attributes Model attributes in the form of hash
297
+ # @return [Object] Returns the model itself
298
+ def build_from_hash(attributes)
299
+ return nil unless attributes.is_a?(Hash)
300
+ attributes = attributes.transform_keys(&:to_sym)
301
+ self.class.openapi_types.each_pair do |key, type|
302
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
303
+ self.send("#{key}=", nil)
304
+ elsif type =~ /\AArray<(.*)>/i
305
+ # check to ensure the input is an array given that the attribute
306
+ # is documented as an array but the input is not
307
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
308
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
309
+ end
310
+ elsif !attributes[self.class.attribute_map[key]].nil?
311
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
312
+ end
313
+ end
314
+
315
+ self
316
+ end
317
+
318
+ # Deserializes the data based on type
319
+ # @param string type Data type
320
+ # @param string value Value to be deserialized
321
+ # @return [Object] Deserialized data
322
+ def _deserialize(type, value)
323
+ case type.to_sym
324
+ when :Time
325
+ Time.parse(value)
326
+ when :Date
327
+ Date.parse(value)
328
+ when :String
329
+ value.to_s
330
+ when :Integer
331
+ value.to_i
332
+ when :Float
333
+ value.to_f
334
+ when :Boolean
335
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
336
+ true
337
+ else
338
+ false
339
+ end
340
+ when :Object
341
+ # generic object (usually a Hash), return directly
342
+ value
343
+ when /\AArray<(?<inner_type>.+)>\z/
344
+ inner_type = Regexp.last_match[:inner_type]
345
+ value.map { |v| _deserialize(inner_type, v) }
346
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
347
+ k_type = Regexp.last_match[:k_type]
348
+ v_type = Regexp.last_match[:v_type]
349
+ {}.tap do |hash|
350
+ value.each do |k, v|
351
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
352
+ end
353
+ end
354
+ else # model
355
+ # models (e.g. Pet) or oneOf
356
+ klass = OneSignal.const_get(type)
357
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
358
+ end
359
+ end
360
+
361
+ # Returns the string representation of the object
362
+ # @return [String] String presentation of the object
363
+ def to_s
364
+ to_hash.to_s
365
+ end
366
+
367
+ # to_body is an alias to to_hash (backward compatibility)
368
+ # @return [Hash] Returns the object in the form of hash
369
+ def to_body
370
+ to_hash
371
+ end
372
+
373
+ # Returns the object in the form of hash
374
+ # @return [Hash] Returns the object in the form of hash
375
+ def to_hash
376
+ hash = {}
377
+ self.class.attribute_map.each_pair do |attr, param|
378
+ value = self.send(attr)
379
+ if value.nil?
380
+ is_nullable = self.class.openapi_nullable.include?(attr)
381
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
382
+ end
383
+
384
+ hash[param] = _to_hash(value)
385
+ end
386
+ hash
387
+ end
388
+
389
+ # Outputs non-array value in the form of hash
390
+ # For object, use to_hash. Otherwise, just return the value
391
+ # @param [Object] value Any valid value
392
+ # @return [Hash] Returns the value in the form of hash
393
+ def _to_hash(value)
394
+ if value.is_a?(Array)
395
+ value.compact.map { |v| _to_hash(v) }
396
+ elsif value.is_a?(Hash)
397
+ {}.tap do |hash|
398
+ value.each { |k, v| hash[k] = _to_hash(v) }
399
+ end
400
+ elsif value.respond_to? :to_hash
401
+ value.to_hash
402
+ else
403
+ value
404
+ end
405
+ end
406
+
407
+ end
408
+
409
+ end