notifo-io 1.0.1 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (369) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1242 -42
  3. data/Rakefile +0 -2
  4. data/docs/AddAllowedTopicDto.md +3 -14
  5. data/docs/AddContributorDto.md +4 -16
  6. data/docs/AppContributorDto.md +5 -18
  7. data/docs/AppDetailsDto.md +12 -44
  8. data/docs/AppDto.md +10 -24
  9. data/docs/AppIdMediaBody.md +7 -0
  10. data/docs/AppsApi.md +161 -343
  11. data/docs/ChannelCondition.md +6 -0
  12. data/docs/ChannelSend.md +6 -0
  13. data/docs/ChannelSendInfoDto.md +9 -0
  14. data/docs/ChannelSettingDto.md +11 -0
  15. data/docs/ChannelTemplateDetailsDtoOfEmailTemplateDto.md +12 -0
  16. data/docs/ChannelTemplateDetailsDtoOfMessagingTemplateDto.md +12 -0
  17. data/docs/ChannelTemplateDetailsDtoOfSmsTemplateDto.md +12 -0
  18. data/docs/ChannelTemplateDto.md +11 -0
  19. data/docs/ConfigsApi.md +21 -61
  20. data/docs/ConfiguredIntegrationDto.md +13 -0
  21. data/docs/ConfiguredIntegrationsDto.md +8 -0
  22. data/docs/ConfirmMode.md +2 -11
  23. data/docs/CreateChannelTemplateDto.md +7 -0
  24. data/docs/CreateChannelTemplateLanguageDto.md +7 -0
  25. data/docs/CreateIntegrationDto.md +11 -0
  26. data/docs/CreateSystemUserDto.md +9 -0
  27. data/docs/EmailFormattingError.md +10 -0
  28. data/docs/EmailPreviewDto.md +8 -0
  29. data/docs/EmailPreviewRequestDto.md +9 -0
  30. data/docs/EmailPreviewType.md +6 -0
  31. data/docs/EmailTemplateDto.md +8 -18
  32. data/docs/EmailTemplateType.md +6 -0
  33. data/docs/EmailTemplatesApi.md +488 -0
  34. data/docs/ErrorDto.md +8 -22
  35. data/docs/EventDto.md +17 -36
  36. data/docs/EventsApi.md +74 -65
  37. data/docs/HandledInfoDto.md +8 -0
  38. data/docs/IntegrationCreatedDto.md +8 -0
  39. data/docs/IntegrationDefinitionDto.md +11 -0
  40. data/docs/IntegrationPropertyDto.md +19 -0
  41. data/docs/IntegrationPropertyType.md +6 -0
  42. data/docs/IntegrationStatus.md +6 -0
  43. data/docs/IsoDayOfWeek.md +2 -11
  44. data/docs/ListResponseDtoOfChannelTemplateDto.md +8 -0
  45. data/docs/ListResponseDtoOfEventDto.md +4 -16
  46. data/docs/ListResponseDtoOfLogEntryDto.md +4 -16
  47. data/docs/ListResponseDtoOfMediaDto.md +4 -16
  48. data/docs/ListResponseDtoOfMobilePushTokenDto.md +8 -0
  49. data/docs/ListResponseDtoOfSubscriptionDto.md +4 -16
  50. data/docs/ListResponseDtoOfSystemUserDto.md +8 -0
  51. data/docs/ListResponseDtoOfTemplateDto.md +4 -16
  52. data/docs/ListResponseDtoOfTopicDto.md +4 -16
  53. data/docs/ListResponseDtoOfUserDto.md +4 -16
  54. data/docs/ListResponseDtoOfUserNotificationDetailsDto.md +8 -0
  55. data/docs/ListResponseDtoOfUserNotificationDto.md +8 -0
  56. data/docs/LocalizedText.md +6 -0
  57. data/docs/LogEntryDto.md +6 -20
  58. data/docs/LogsApi.md +21 -40
  59. data/docs/MediaApi.md +102 -196
  60. data/docs/MediaDto.md +11 -26
  61. data/docs/MediaMetadata.md +6 -0
  62. data/docs/MediaType.md +2 -11
  63. data/docs/MessagingTemplateDto.md +7 -0
  64. data/docs/MessagingTemplatesApi.md +394 -0
  65. data/docs/MobileDeviceType.md +6 -0
  66. data/docs/MobilePushApi.md +135 -0
  67. data/docs/MobilePushTokenDto.md +9 -0
  68. data/docs/MobilePushTokenDto2.md +8 -0
  69. data/docs/NotificationFormattingDto.md +10 -28
  70. data/docs/NotificationProperties.md +6 -0
  71. data/docs/NotificationsApi.md +199 -0
  72. data/docs/PingApi.md +48 -0
  73. data/docs/ProcessStatus.md +6 -0
  74. data/docs/ProfileDto.md +11 -28
  75. data/docs/PublishDto.md +14 -32
  76. data/docs/PublishManyDto.md +3 -14
  77. data/docs/RegisterMobileTokenDto.md +8 -0
  78. data/docs/ResizeMode.md +2 -11
  79. data/docs/SchedulingDto.md +6 -20
  80. data/docs/SchedulingType.md +2 -11
  81. data/docs/SmsTemplateDto.md +7 -0
  82. data/docs/SmsTemplatesApi.md +394 -0
  83. data/docs/SubscribeDto.md +8 -0
  84. data/docs/SubscribeManyDto.md +8 -0
  85. data/docs/SubscriptionDto.md +4 -16
  86. data/docs/SystemUserDto.md +11 -0
  87. data/docs/SystemUsersApi.md +327 -0
  88. data/docs/TemplateDto.md +7 -18
  89. data/docs/TemplatesApi.md +52 -108
  90. data/docs/TopicChannel.md +6 -0
  91. data/docs/TopicDto.md +11 -18
  92. data/docs/TopicQueryScope.md +6 -0
  93. data/docs/TopicsApi.md +106 -30
  94. data/docs/TrackNotificationDto.md +10 -0
  95. data/docs/UpdateChannelTemplateDtoOfEmailTemplateDto.md +9 -0
  96. data/docs/UpdateChannelTemplateDtoOfMessagingTemplateDto.md +9 -0
  97. data/docs/UpdateChannelTemplateDtoOfSmsTemplateDto.md +9 -0
  98. data/docs/UpdateIntegrationDto.md +11 -0
  99. data/docs/UpdateProfileDto.md +8 -24
  100. data/docs/UpdateSystemUserDto.md +9 -0
  101. data/docs/UpsertAppDto.md +12 -32
  102. data/docs/UpsertTemplateDto.md +5 -18
  103. data/docs/UpsertTemplatesDto.md +3 -14
  104. data/docs/UpsertTopicDto.md +11 -0
  105. data/docs/UpsertTopicsDto.md +7 -0
  106. data/docs/UpsertUserDto.md +11 -28
  107. data/docs/UpsertUsersDto.md +3 -14
  108. data/docs/UserApi.md +156 -150
  109. data/docs/UserDto.md +20 -32
  110. data/docs/UserNotificationBaseDto.md +23 -0
  111. data/docs/UserNotificationChannelDto.md +11 -0
  112. data/docs/UserNotificationDetailsDto.md +27 -0
  113. data/docs/UserNotificationDto.md +25 -0
  114. data/docs/UserPropertyDto.md +9 -0
  115. data/docs/UserTopicDto.md +11 -0
  116. data/docs/UsersApi.md +161 -320
  117. data/git_push.sh +7 -10
  118. data/lib/notifo/api/apps_api.rb +164 -236
  119. data/lib/notifo/api/configs_api.rb +14 -30
  120. data/lib/notifo/api/email_templates_api.rb +663 -0
  121. data/lib/notifo/api/events_api.rb +88 -45
  122. data/lib/notifo/api/logs_api.rb +12 -21
  123. data/lib/notifo/api/media_api.rb +60 -97
  124. data/lib/notifo/api/messaging_templates_api.rb +541 -0
  125. data/lib/notifo/api/mobile_push_api.rb +178 -0
  126. data/lib/notifo/api/notifications_api.rb +256 -0
  127. data/lib/notifo/api/ping_api.rb +70 -0
  128. data/lib/notifo/api/sms_templates_api.rb +541 -0
  129. data/lib/notifo/api/system_users_api.rb +411 -0
  130. data/lib/notifo/api/templates_api.rb +43 -66
  131. data/lib/notifo/api/topics_api.rb +137 -21
  132. data/lib/notifo/api/user_api.rb +178 -104
  133. data/lib/notifo/api/users_api.rb +140 -199
  134. data/lib/notifo/api_client.rb +54 -56
  135. data/lib/notifo/api_error.rb +5 -5
  136. data/lib/notifo/configuration.rb +12 -84
  137. data/lib/notifo/models/add_allowed_topic_dto.rb +13 -44
  138. data/lib/notifo/models/add_contributor_dto.rb +14 -64
  139. data/lib/notifo/models/app_contributor_dto.rb +15 -84
  140. data/lib/notifo/models/app_details_dto.rb +51 -189
  141. data/lib/notifo/models/app_dto.rb +47 -86
  142. data/lib/notifo/models/{inline_object.rb → app_id_media_body.rb} +16 -28
  143. data/lib/notifo/models/channel_condition.rb +30 -0
  144. data/lib/notifo/models/channel_send.rb +30 -0
  145. data/lib/notifo/models/channel_send_info_dto.rb +227 -0
  146. data/lib/notifo/models/channel_setting_dto.rb +256 -0
  147. data/lib/notifo/models/channel_template_details_dto_of_email_template_dto.rb +285 -0
  148. data/lib/notifo/models/channel_template_details_dto_of_messaging_template_dto.rb +285 -0
  149. data/lib/notifo/models/channel_template_details_dto_of_sms_template_dto.rb +285 -0
  150. data/lib/notifo/models/channel_template_dto.rb +264 -0
  151. data/lib/notifo/models/configured_integration_dto.rb +285 -0
  152. data/lib/notifo/models/configured_integrations_dto.rb +231 -0
  153. data/lib/notifo/models/confirm_mode.rb +6 -16
  154. data/lib/notifo/models/create_channel_template_dto.rb +208 -0
  155. data/lib/notifo/models/{create_email_template_dto.rb → create_channel_template_language_dto.rb} +16 -47
  156. data/lib/notifo/models/create_integration_dto.rb +262 -0
  157. data/lib/notifo/models/create_system_user_dto.rb +240 -0
  158. data/lib/notifo/models/email_formatting_error.rb +233 -0
  159. data/lib/notifo/models/email_preview_dto.rb +221 -0
  160. data/lib/notifo/models/{notification_setting_dto.rb → email_preview_request_dto.rb} +43 -45
  161. data/lib/notifo/models/email_preview_type.rb +28 -0
  162. data/lib/notifo/models/email_template_dto.rb +52 -69
  163. data/lib/notifo/models/email_template_type.rb +30 -0
  164. data/lib/notifo/models/error_dto.rb +29 -30
  165. data/lib/notifo/models/event_dto.rb +60 -115
  166. data/lib/notifo/models/handled_info_dto.rb +218 -0
  167. data/lib/notifo/models/integration_created_dto.rb +226 -0
  168. data/lib/notifo/models/integration_definition_dto.rb +272 -0
  169. data/lib/notifo/models/integration_property_dto.rb +347 -0
  170. data/lib/notifo/models/integration_property_type.rb +31 -0
  171. data/lib/notifo/models/integration_status.rb +29 -0
  172. data/lib/notifo/models/iso_day_of_week.rb +12 -21
  173. data/lib/notifo/models/list_response_dto_of_channel_template_dto.rb +229 -0
  174. data/lib/notifo/models/list_response_dto_of_event_dto.rb +14 -26
  175. data/lib/notifo/models/list_response_dto_of_log_entry_dto.rb +14 -26
  176. data/lib/notifo/models/list_response_dto_of_media_dto.rb +14 -26
  177. data/lib/notifo/models/list_response_dto_of_mobile_push_token_dto.rb +229 -0
  178. data/lib/notifo/models/list_response_dto_of_subscription_dto.rb +14 -26
  179. data/lib/notifo/models/list_response_dto_of_system_user_dto.rb +229 -0
  180. data/lib/notifo/models/list_response_dto_of_template_dto.rb +14 -26
  181. data/lib/notifo/models/list_response_dto_of_topic_dto.rb +14 -26
  182. data/lib/notifo/models/list_response_dto_of_user_dto.rb +14 -26
  183. data/lib/notifo/models/list_response_dto_of_user_notification_details_dto.rb +229 -0
  184. data/lib/notifo/models/list_response_dto_of_user_notification_dto.rb +229 -0
  185. data/lib/notifo/models/localized_text.rb +201 -0
  186. data/lib/notifo/models/log_entry_dto.rb +16 -85
  187. data/lib/notifo/models/media_dto.rb +56 -116
  188. data/lib/notifo/models/media_metadata.rb +201 -0
  189. data/lib/notifo/models/media_type.rb +8 -17
  190. data/lib/notifo/models/messaging_template_dto.rb +212 -0
  191. data/lib/notifo/models/mobile_device_type.rb +29 -0
  192. data/lib/notifo/models/mobile_push_token_dto.rb +237 -0
  193. data/lib/notifo/models/mobile_push_token_dto2.rb +221 -0
  194. data/lib/notifo/models/notification_formatting_dto.rb +27 -58
  195. data/lib/notifo/models/notification_properties.rb +201 -0
  196. data/lib/notifo/models/process_status.rb +31 -0
  197. data/lib/notifo/models/profile_dto.rb +33 -71
  198. data/lib/notifo/models/publish_dto.rb +47 -59
  199. data/lib/notifo/models/publish_many_dto.rb +13 -25
  200. data/lib/notifo/models/register_mobile_token_dto.rb +221 -0
  201. data/lib/notifo/models/resize_mode.rb +11 -20
  202. data/lib/notifo/models/scheduling_dto.rb +16 -28
  203. data/lib/notifo/models/scheduling_type.rb +6 -15
  204. data/lib/notifo/models/sms_template_dto.rb +212 -0
  205. data/lib/notifo/models/subscribe_dto.rb +225 -0
  206. data/lib/notifo/models/subscribe_many_dto.rb +223 -0
  207. data/lib/notifo/models/subscription_dto.rb +17 -44
  208. data/lib/notifo/models/system_user_dto.rb +269 -0
  209. data/lib/notifo/models/template_dto.rb +44 -45
  210. data/lib/notifo/models/topic_channel.rb +28 -0
  211. data/lib/notifo/models/topic_dto.rb +81 -65
  212. data/lib/notifo/models/topic_query_scope.rb +29 -0
  213. data/lib/notifo/models/track_notification_dto.rb +243 -0
  214. data/lib/notifo/models/update_channel_template_dto_of_email_template_dto.rb +232 -0
  215. data/lib/notifo/models/update_channel_template_dto_of_messaging_template_dto.rb +232 -0
  216. data/lib/notifo/models/update_channel_template_dto_of_sms_template_dto.rb +232 -0
  217. data/lib/notifo/models/update_integration_dto.rb +258 -0
  218. data/lib/notifo/models/update_profile_dto.rb +18 -30
  219. data/lib/notifo/models/update_system_user_dto.rb +240 -0
  220. data/lib/notifo/models/upsert_app_dto.rb +22 -34
  221. data/lib/notifo/models/upsert_template_dto.rb +15 -46
  222. data/lib/notifo/models/upsert_templates_dto.rb +13 -25
  223. data/lib/notifo/models/upsert_topic_dto.rb +249 -0
  224. data/lib/notifo/models/upsert_topics_dto.rb +214 -0
  225. data/lib/notifo/models/upsert_user_dto.rb +34 -33
  226. data/lib/notifo/models/upsert_users_dto.rb +13 -25
  227. data/lib/notifo/models/user_dto.rb +137 -73
  228. data/lib/notifo/models/user_notification_base_dto.rb +402 -0
  229. data/lib/notifo/models/user_notification_channel_dto.rb +261 -0
  230. data/lib/notifo/models/user_notification_details_dto.rb +450 -0
  231. data/lib/notifo/models/user_notification_dto.rb +436 -0
  232. data/lib/notifo/models/user_property_dto.rb +234 -0
  233. data/lib/notifo/models/user_topic_dto.rb +265 -0
  234. data/lib/notifo/version.rb +4 -5
  235. data/lib/notifo.rb +71 -9
  236. data/notifo.gemspec +8 -8
  237. data/spec/api/apps_api_spec.rb +31 -32
  238. data/spec/api/configs_api_spec.rb +7 -8
  239. data/spec/api/email_templates_api_spec.rb +161 -0
  240. data/spec/api/events_api_spec.rb +20 -9
  241. data/spec/api/logs_api_spec.rb +7 -8
  242. data/spec/api/media_api_spec.rb +32 -11
  243. data/spec/api/messaging_templates_api_spec.rb +137 -0
  244. data/spec/api/mobile_push_api_spec.rb +66 -0
  245. data/spec/api/notifications_api_spec.rb +85 -0
  246. data/spec/api/ping_api_spec.rb +45 -0
  247. data/spec/api/sms_templates_api_spec.rb +137 -0
  248. data/spec/api/system_users_api_spec.rb +114 -0
  249. data/spec/api/templates_api_spec.rb +9 -10
  250. data/spec/api/topics_api_spec.rb +32 -8
  251. data/spec/api/user_api_spec.rb +41 -17
  252. data/spec/api/users_api_spec.rb +24 -23
  253. data/spec/api_client_spec.rb +5 -6
  254. data/spec/base_object_spec.rb +109 -0
  255. data/spec/configuration_spec.rb +7 -8
  256. data/spec/models/add_allowed_topic_dto_spec.rb +15 -9
  257. data/spec/models/add_contributor_dto_spec.rb +15 -9
  258. data/spec/models/app_contributor_dto_spec.rb +15 -9
  259. data/spec/models/app_details_dto_spec.rb +18 -48
  260. data/spec/models/app_dto_spec.rb +27 -9
  261. data/spec/models/app_id_media_body_spec.rb +40 -0
  262. data/spec/models/channel_condition_spec.rb +34 -0
  263. data/spec/models/channel_send_info_dto_spec.rb +52 -0
  264. data/spec/models/channel_send_spec.rb +34 -0
  265. data/spec/models/channel_setting_dto_spec.rb +64 -0
  266. data/spec/models/channel_template_details_dto_of_email_template_dto_spec.rb +70 -0
  267. data/spec/models/channel_template_details_dto_of_messaging_template_dto_spec.rb +70 -0
  268. data/spec/models/channel_template_details_dto_of_sms_template_dto_spec.rb +70 -0
  269. data/spec/models/channel_template_dto_spec.rb +64 -0
  270. data/spec/models/configured_integration_dto_spec.rb +76 -0
  271. data/spec/models/configured_integrations_dto_spec.rb +46 -0
  272. data/spec/models/confirm_mode_spec.rb +15 -9
  273. data/spec/models/create_channel_template_dto_spec.rb +40 -0
  274. data/spec/models/create_channel_template_language_dto_spec.rb +40 -0
  275. data/spec/models/create_integration_dto_spec.rb +64 -0
  276. data/spec/models/create_system_user_dto_spec.rb +52 -0
  277. data/spec/models/email_formatting_error_spec.rb +58 -0
  278. data/spec/models/email_preview_dto_spec.rb +46 -0
  279. data/spec/models/email_preview_request_dto_spec.rb +52 -0
  280. data/spec/models/email_preview_type_spec.rb +34 -0
  281. data/spec/models/email_template_dto_spec.rb +33 -9
  282. data/spec/models/email_template_type_spec.rb +34 -0
  283. data/spec/models/error_dto_spec.rb +21 -9
  284. data/spec/models/event_dto_spec.rb +33 -9
  285. data/spec/models/handled_info_dto_spec.rb +46 -0
  286. data/spec/models/integration_created_dto_spec.rb +46 -0
  287. data/spec/models/integration_definition_dto_spec.rb +64 -0
  288. data/spec/models/integration_property_dto_spec.rb +112 -0
  289. data/spec/models/integration_property_type_spec.rb +34 -0
  290. data/spec/models/integration_status_spec.rb +34 -0
  291. data/spec/models/iso_day_of_week_spec.rb +15 -9
  292. data/spec/models/list_response_dto_of_channel_template_dto_spec.rb +46 -0
  293. data/spec/models/list_response_dto_of_event_dto_spec.rb +15 -9
  294. data/spec/models/list_response_dto_of_log_entry_dto_spec.rb +15 -9
  295. data/spec/models/list_response_dto_of_media_dto_spec.rb +15 -9
  296. data/spec/models/list_response_dto_of_mobile_push_token_dto_spec.rb +46 -0
  297. data/spec/models/list_response_dto_of_subscription_dto_spec.rb +15 -9
  298. data/spec/models/list_response_dto_of_system_user_dto_spec.rb +46 -0
  299. data/spec/models/list_response_dto_of_template_dto_spec.rb +15 -9
  300. data/spec/models/list_response_dto_of_topic_dto_spec.rb +15 -9
  301. data/spec/models/list_response_dto_of_user_dto_spec.rb +15 -9
  302. data/spec/models/list_response_dto_of_user_notification_details_dto_spec.rb +46 -0
  303. data/spec/models/list_response_dto_of_user_notification_dto_spec.rb +46 -0
  304. data/spec/models/localized_text_spec.rb +34 -0
  305. data/spec/models/log_entry_dto_spec.rb +15 -9
  306. data/spec/models/media_dto_spec.rb +33 -9
  307. data/spec/models/media_metadata_spec.rb +34 -0
  308. data/spec/models/media_type_spec.rb +15 -9
  309. data/spec/models/messaging_template_dto_spec.rb +40 -0
  310. data/spec/models/mobile_device_type_spec.rb +34 -0
  311. data/spec/models/mobile_push_token_dto2_spec.rb +46 -0
  312. data/spec/models/mobile_push_token_dto_spec.rb +52 -0
  313. data/spec/models/notification_formatting_dto_spec.rb +15 -9
  314. data/spec/models/notification_properties_spec.rb +34 -0
  315. data/spec/models/process_status_spec.rb +34 -0
  316. data/spec/models/profile_dto_spec.rb +21 -9
  317. data/spec/models/publish_dto_spec.rb +27 -9
  318. data/spec/models/publish_many_dto_spec.rb +15 -9
  319. data/spec/models/register_mobile_token_dto_spec.rb +46 -0
  320. data/spec/models/resize_mode_spec.rb +15 -9
  321. data/spec/models/scheduling_dto_spec.rb +15 -9
  322. data/spec/models/scheduling_type_spec.rb +15 -9
  323. data/spec/models/sms_template_dto_spec.rb +40 -0
  324. data/spec/models/subscribe_dto_spec.rb +46 -0
  325. data/spec/models/subscribe_many_dto_spec.rb +46 -0
  326. data/spec/models/subscription_dto_spec.rb +15 -9
  327. data/spec/models/system_user_dto_spec.rb +64 -0
  328. data/spec/models/template_dto_spec.rb +27 -9
  329. data/spec/models/topic_channel_spec.rb +34 -0
  330. data/spec/models/topic_dto_spec.rb +51 -9
  331. data/spec/models/topic_query_scope_spec.rb +34 -0
  332. data/spec/models/track_notification_dto_spec.rb +58 -0
  333. data/spec/models/update_channel_template_dto_of_email_template_dto_spec.rb +52 -0
  334. data/spec/models/update_channel_template_dto_of_messaging_template_dto_spec.rb +52 -0
  335. data/spec/models/update_channel_template_dto_of_sms_template_dto_spec.rb +52 -0
  336. data/spec/models/update_integration_dto_spec.rb +64 -0
  337. data/spec/models/update_profile_dto_spec.rb +15 -9
  338. data/spec/models/update_system_user_dto_spec.rb +52 -0
  339. data/spec/models/upsert_app_dto_spec.rb +15 -9
  340. data/spec/models/upsert_template_dto_spec.rb +15 -9
  341. data/spec/models/upsert_templates_dto_spec.rb +15 -9
  342. data/spec/models/upsert_topic_dto_spec.rb +64 -0
  343. data/spec/models/upsert_topics_dto_spec.rb +40 -0
  344. data/spec/models/upsert_user_dto_spec.rb +21 -9
  345. data/spec/models/upsert_users_dto_spec.rb +15 -9
  346. data/spec/models/user_dto_spec.rb +63 -9
  347. data/spec/models/user_notification_base_dto_spec.rb +136 -0
  348. data/spec/models/user_notification_channel_dto_spec.rb +64 -0
  349. data/spec/models/user_notification_details_dto_spec.rb +160 -0
  350. data/spec/models/user_notification_dto_spec.rb +148 -0
  351. data/spec/models/user_property_dto_spec.rb +52 -0
  352. data/spec/models/user_topic_dto_spec.rb +64 -0
  353. data/spec/spec_helper.rb +4 -5
  354. metadata +299 -32
  355. data/docs/CreateEmailTemplateDto.md +0 -18
  356. data/docs/EmailVerificationStatus.md +0 -15
  357. data/docs/InlineObject.md +0 -18
  358. data/docs/NotificationSend.md +0 -15
  359. data/docs/NotificationSettingDto.md +0 -20
  360. data/lib/notifo/models/email_verification_status.rb +0 -39
  361. data/lib/notifo/models/notification_send.rb +0 -39
  362. data/notifo-1.0.0.gem +0 -0
  363. data/notifo-io-1.0.0.2.gem +0 -0
  364. data/notifo-io-1.0.0.gem +0 -0
  365. data/spec/models/create_email_template_dto_spec.rb +0 -34
  366. data/spec/models/email_verification_status_spec.rb +0 -28
  367. data/spec/models/inline_object_spec.rb +0 -34
  368. data/spec/models/notification_send_spec.rb +0 -28
  369. data/spec/models/notification_setting_dto_spec.rb +0 -40
@@ -1,17 +1,14 @@
1
1
  =begin
2
2
  #Notifo API
3
3
 
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
5
 
6
- The version of the OpenAPI document: 1.0.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 5.1.0-SNAPSHOT
6
+ OpenAPI spec version: 1.0.0
10
7
 
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 3.0.29
11
10
  =end
12
11
 
13
- require 'cgi'
14
-
15
12
  module Notifo
16
13
  class UsersApi
17
14
  attr_accessor :api_client
@@ -20,9 +17,9 @@ module Notifo
20
17
  @api_client = api_client
21
18
  end
22
19
  # Remove an allowed topic.
23
- # @param app_id [String] The app where the users belong to.
24
- # @param id [String] The user id.
25
- # @param prefix [String] The topic prefix.
20
+ # @param app_id The app where the users belong to.
21
+ # @param id The user ID.
22
+ # @param prefix The topic prefix.
26
23
  # @param [Hash] opts the optional parameters
27
24
  # @return [nil]
28
25
  def users_delete_allowed_topic(app_id, id, prefix, opts = {})
@@ -31,9 +28,9 @@ module Notifo
31
28
  end
32
29
 
33
30
  # Remove an allowed topic.
34
- # @param app_id [String] The app where the users belong to.
35
- # @param id [String] The user id.
36
- # @param prefix [String] The topic prefix.
31
+ # @param app_id The app where the users belong to.
32
+ # @param id The user ID.
33
+ # @param prefix The topic prefix.
37
34
  # @param [Hash] opts the optional parameters
38
35
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
39
36
  def users_delete_allowed_topic_with_http_info(app_id, id, prefix, opts = {})
@@ -53,7 +50,7 @@ module Notifo
53
50
  fail ArgumentError, "Missing the required parameter 'prefix' when calling UsersApi.users_delete_allowed_topic"
54
51
  end
55
52
  # resource path
56
- local_var_path = '/api/apps/{appId}/users/{id}/allowed-topics/{prefix}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s)).sub('{' + 'prefix' + '}', CGI.escape(prefix.to_s))
53
+ local_var_path = '/api/apps/{appId}/users/{id}/allowed-topics/{prefix}'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s).sub('{' + 'prefix' + '}', prefix.to_s)
57
54
 
58
55
  # query parameters
59
56
  query_params = opts[:query_params] || {}
@@ -67,35 +64,28 @@ module Notifo
67
64
  form_params = opts[:form_params] || {}
68
65
 
69
66
  # http body (model)
70
- post_body = opts[:debug_body]
67
+ post_body = opts[:body]
71
68
 
72
- # return_type
73
- return_type = opts[:debug_return_type]
69
+ return_type = opts[:return_type]
74
70
 
75
- # auth_names
76
- auth_names = opts[:debug_auth_names] || []
77
-
78
- new_options = opts.merge(
79
- :operation => :"UsersApi.users_delete_allowed_topic",
71
+ auth_names = opts[:auth_names] || []
72
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
80
73
  :header_params => header_params,
81
74
  :query_params => query_params,
82
75
  :form_params => form_params,
83
76
  :body => post_body,
84
77
  :auth_names => auth_names,
85
- :return_type => return_type
86
- )
78
+ :return_type => return_type)
87
79
 
88
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
89
80
  if @api_client.config.debugging
90
81
  @api_client.config.logger.debug "API called: UsersApi#users_delete_allowed_topic\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
91
82
  end
92
83
  return data, status_code, headers
93
84
  end
94
-
95
- # Remove a user subscriptions.
96
- # @param app_id [String] The app where the user belongs to.
97
- # @param id [String] The user id.
98
- # @param prefix [String] The topic prefix.
85
+ # Unsubscribes a user from a subscription.
86
+ # @param app_id The app where the user belongs to.
87
+ # @param id The user ID.
88
+ # @param prefix The topic prefix.
99
89
  # @param [Hash] opts the optional parameters
100
90
  # @return [nil]
101
91
  def users_delete_subscription(app_id, id, prefix, opts = {})
@@ -103,10 +93,10 @@ module Notifo
103
93
  nil
104
94
  end
105
95
 
106
- # Remove a user subscriptions.
107
- # @param app_id [String] The app where the user belongs to.
108
- # @param id [String] The user id.
109
- # @param prefix [String] The topic prefix.
96
+ # Unsubscribes a user from a subscription.
97
+ # @param app_id The app where the user belongs to.
98
+ # @param id The user ID.
99
+ # @param prefix The topic prefix.
110
100
  # @param [Hash] opts the optional parameters
111
101
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
112
102
  def users_delete_subscription_with_http_info(app_id, id, prefix, opts = {})
@@ -126,7 +116,7 @@ module Notifo
126
116
  fail ArgumentError, "Missing the required parameter 'prefix' when calling UsersApi.users_delete_subscription"
127
117
  end
128
118
  # resource path
129
- local_var_path = '/api/apps/{appId}/users/{id}/subscriptions/{prefix}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s)).sub('{' + 'prefix' + '}', CGI.escape(prefix.to_s))
119
+ local_var_path = '/api/apps/{appId}/users/{id}/subscriptions/{prefix}'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s).sub('{' + 'prefix' + '}', prefix.to_s)
130
120
 
131
121
  # query parameters
132
122
  query_params = opts[:query_params] || {}
@@ -140,46 +130,39 @@ module Notifo
140
130
  form_params = opts[:form_params] || {}
141
131
 
142
132
  # http body (model)
143
- post_body = opts[:debug_body]
133
+ post_body = opts[:body]
144
134
 
145
- # return_type
146
- return_type = opts[:debug_return_type]
135
+ return_type = opts[:return_type]
147
136
 
148
- # auth_names
149
- auth_names = opts[:debug_auth_names] || []
150
-
151
- new_options = opts.merge(
152
- :operation => :"UsersApi.users_delete_subscription",
137
+ auth_names = opts[:auth_names] || []
138
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
153
139
  :header_params => header_params,
154
140
  :query_params => query_params,
155
141
  :form_params => form_params,
156
142
  :body => post_body,
157
143
  :auth_names => auth_names,
158
- :return_type => return_type
159
- )
144
+ :return_type => return_type)
160
145
 
161
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
162
146
  if @api_client.config.debugging
163
147
  @api_client.config.logger.debug "API called: UsersApi#users_delete_subscription\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
164
148
  end
165
149
  return data, status_code, headers
166
150
  end
167
-
168
151
  # Delete a user.
169
- # @param app_id [String] The app where the users belongs to.
170
- # @param id [String] The user id to delete.
152
+ # @param app_id The app where the users belongs to.
153
+ # @param id The user id to delete.
171
154
  # @param [Hash] opts the optional parameters
172
- # @return [ListResponseDtoOfUserDto]
155
+ # @return [String]
173
156
  def users_delete_user(app_id, id, opts = {})
174
157
  data, _status_code, _headers = users_delete_user_with_http_info(app_id, id, opts)
175
158
  data
176
159
  end
177
160
 
178
161
  # Delete a user.
179
- # @param app_id [String] The app where the users belongs to.
180
- # @param id [String] The user id to delete.
162
+ # @param app_id The app where the users belongs to.
163
+ # @param id The user id to delete.
181
164
  # @param [Hash] opts the optional parameters
182
- # @return [Array<(ListResponseDtoOfUserDto, Integer, Hash)>] ListResponseDtoOfUserDto data, response status code and response headers
165
+ # @return [Array<(String, Integer, Hash)>] String data, response status code and response headers
183
166
  def users_delete_user_with_http_info(app_id, id, opts = {})
184
167
  if @api_client.config.debugging
185
168
  @api_client.config.logger.debug 'Calling API: UsersApi.users_delete_user ...'
@@ -193,7 +176,7 @@ module Notifo
193
176
  fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_delete_user"
194
177
  end
195
178
  # resource path
196
- local_var_path = '/api/apps/{appId}/users/{id}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s))
179
+ local_var_path = '/api/apps/{appId}/users/{id}'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s)
197
180
 
198
181
  # query parameters
199
182
  query_params = opts[:query_params] || {}
@@ -201,40 +184,33 @@ module Notifo
201
184
  # header parameters
202
185
  header_params = opts[:header_params] || {}
203
186
  # HTTP header 'Accept' (if needed)
204
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
187
+ header_params['Accept'] = @api_client.select_header_accept(['application/octet-stream', 'application/json'])
205
188
 
206
189
  # form parameters
207
190
  form_params = opts[:form_params] || {}
208
191
 
209
192
  # http body (model)
210
- post_body = opts[:debug_body]
211
-
212
- # return_type
213
- return_type = opts[:debug_return_type] || 'ListResponseDtoOfUserDto'
193
+ post_body = opts[:body]
214
194
 
215
- # auth_names
216
- auth_names = opts[:debug_auth_names] || []
195
+ return_type = opts[:return_type] || 'String'
217
196
 
218
- new_options = opts.merge(
219
- :operation => :"UsersApi.users_delete_user",
197
+ auth_names = opts[:auth_names] || []
198
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
220
199
  :header_params => header_params,
221
200
  :query_params => query_params,
222
201
  :form_params => form_params,
223
202
  :body => post_body,
224
203
  :auth_names => auth_names,
225
- :return_type => return_type
226
- )
204
+ :return_type => return_type)
227
205
 
228
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
229
206
  if @api_client.config.debugging
230
207
  @api_client.config.logger.debug "API called: UsersApi#users_delete_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
231
208
  end
232
209
  return data, status_code, headers
233
210
  end
234
-
235
211
  # Query user subscriptions.
236
- # @param app_id [String] The app where the user belongs to.
237
- # @param id [String] The user id.
212
+ # @param app_id The app where the user belongs to.
213
+ # @param id The user ID.
238
214
  # @param [Hash] opts the optional parameters
239
215
  # @option opts [String] :query The optional query to search for items.
240
216
  # @option opts [Integer] :take The number of items to return.
@@ -246,8 +222,8 @@ module Notifo
246
222
  end
247
223
 
248
224
  # Query user subscriptions.
249
- # @param app_id [String] The app where the user belongs to.
250
- # @param id [String] The user id.
225
+ # @param app_id The app where the user belongs to.
226
+ # @param id The user ID.
251
227
  # @param [Hash] opts the optional parameters
252
228
  # @option opts [String] :query The optional query to search for items.
253
229
  # @option opts [Integer] :take The number of items to return.
@@ -266,7 +242,7 @@ module Notifo
266
242
  fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_get_subscriptions"
267
243
  end
268
244
  # resource path
269
- local_var_path = '/api/apps/{appId}/users/{id}/subscriptions'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s))
245
+ local_var_path = '/api/apps/{appId}/users/{id}/subscriptions'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s)
270
246
 
271
247
  # query parameters
272
248
  query_params = opts[:query_params] || {}
@@ -283,46 +259,41 @@ module Notifo
283
259
  form_params = opts[:form_params] || {}
284
260
 
285
261
  # http body (model)
286
- post_body = opts[:debug_body]
287
-
288
- # return_type
289
- return_type = opts[:debug_return_type] || 'ListResponseDtoOfSubscriptionDto'
262
+ post_body = opts[:body]
290
263
 
291
- # auth_names
292
- auth_names = opts[:debug_auth_names] || []
264
+ return_type = opts[:return_type] || 'ListResponseDtoOfSubscriptionDto'
293
265
 
294
- new_options = opts.merge(
295
- :operation => :"UsersApi.users_get_subscriptions",
266
+ auth_names = opts[:auth_names] || []
267
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
296
268
  :header_params => header_params,
297
269
  :query_params => query_params,
298
270
  :form_params => form_params,
299
271
  :body => post_body,
300
272
  :auth_names => auth_names,
301
- :return_type => return_type
302
- )
273
+ :return_type => return_type)
303
274
 
304
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
305
275
  if @api_client.config.debugging
306
276
  @api_client.config.logger.debug "API called: UsersApi#users_get_subscriptions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
307
277
  end
308
278
  return data, status_code, headers
309
279
  end
310
-
311
280
  # Get a user.
312
- # @param app_id [String] The app where the user belongs to.
313
- # @param id [String] The user id.
281
+ # @param app_id The app where the user belongs to.
282
+ # @param id The user ID.
314
283
  # @param [Hash] opts the optional parameters
315
- # @return [ListResponseDtoOfUserDto]
284
+ # @option opts [BOOLEAN] :with_details Provide extra details, might be expensive. (default to false)
285
+ # @return [UserDto]
316
286
  def users_get_user(app_id, id, opts = {})
317
287
  data, _status_code, _headers = users_get_user_with_http_info(app_id, id, opts)
318
288
  data
319
289
  end
320
290
 
321
291
  # Get a user.
322
- # @param app_id [String] The app where the user belongs to.
323
- # @param id [String] The user id.
292
+ # @param app_id The app where the user belongs to.
293
+ # @param id The user ID.
324
294
  # @param [Hash] opts the optional parameters
325
- # @return [Array<(ListResponseDtoOfUserDto, Integer, Hash)>] ListResponseDtoOfUserDto data, response status code and response headers
295
+ # @option opts [BOOLEAN] :with_details Provide extra details, might be expensive.
296
+ # @return [Array<(UserDto, Integer, Hash)>] UserDto data, response status code and response headers
326
297
  def users_get_user_with_http_info(app_id, id, opts = {})
327
298
  if @api_client.config.debugging
328
299
  @api_client.config.logger.debug 'Calling API: UsersApi.users_get_user ...'
@@ -336,10 +307,11 @@ module Notifo
336
307
  fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_get_user"
337
308
  end
338
309
  # resource path
339
- local_var_path = '/api/apps/{appId}/users/{id}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s))
310
+ local_var_path = '/api/apps/{appId}/users/{id}'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s)
340
311
 
341
312
  # query parameters
342
313
  query_params = opts[:query_params] || {}
314
+ query_params[:'withDetails'] = opts[:'with_details'] if !opts[:'with_details'].nil?
343
315
 
344
316
  # header parameters
345
317
  header_params = opts[:header_params] || {}
@@ -350,37 +322,31 @@ module Notifo
350
322
  form_params = opts[:form_params] || {}
351
323
 
352
324
  # http body (model)
353
- post_body = opts[:debug_body]
325
+ post_body = opts[:body]
354
326
 
355
- # return_type
356
- return_type = opts[:debug_return_type] || 'ListResponseDtoOfUserDto'
327
+ return_type = opts[:return_type] || 'UserDto'
357
328
 
358
- # auth_names
359
- auth_names = opts[:debug_auth_names] || []
360
-
361
- new_options = opts.merge(
362
- :operation => :"UsersApi.users_get_user",
329
+ auth_names = opts[:auth_names] || []
330
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
363
331
  :header_params => header_params,
364
332
  :query_params => query_params,
365
333
  :form_params => form_params,
366
334
  :body => post_body,
367
335
  :auth_names => auth_names,
368
- :return_type => return_type
369
- )
336
+ :return_type => return_type)
370
337
 
371
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
372
338
  if @api_client.config.debugging
373
339
  @api_client.config.logger.debug "API called: UsersApi#users_get_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
374
340
  end
375
341
  return data, status_code, headers
376
342
  end
377
-
378
343
  # Query users.
379
- # @param app_id [String] The app where the users belongs to.
344
+ # @param app_id The app where the users belongs to.
380
345
  # @param [Hash] opts the optional parameters
381
346
  # @option opts [String] :query The optional query to search for items.
382
347
  # @option opts [Integer] :take The number of items to return.
383
348
  # @option opts [Integer] :skip The number of items to skip.
349
+ # @option opts [BOOLEAN] :with_details Provide extra details, might be expensive. (default to false)
384
350
  # @return [ListResponseDtoOfUserDto]
385
351
  def users_get_users(app_id, opts = {})
386
352
  data, _status_code, _headers = users_get_users_with_http_info(app_id, opts)
@@ -388,11 +354,12 @@ module Notifo
388
354
  end
389
355
 
390
356
  # Query users.
391
- # @param app_id [String] The app where the users belongs to.
357
+ # @param app_id The app where the users belongs to.
392
358
  # @param [Hash] opts the optional parameters
393
359
  # @option opts [String] :query The optional query to search for items.
394
360
  # @option opts [Integer] :take The number of items to return.
395
361
  # @option opts [Integer] :skip The number of items to skip.
362
+ # @option opts [BOOLEAN] :with_details Provide extra details, might be expensive.
396
363
  # @return [Array<(ListResponseDtoOfUserDto, Integer, Hash)>] ListResponseDtoOfUserDto data, response status code and response headers
397
364
  def users_get_users_with_http_info(app_id, opts = {})
398
365
  if @api_client.config.debugging
@@ -403,13 +370,14 @@ module Notifo
403
370
  fail ArgumentError, "Missing the required parameter 'app_id' when calling UsersApi.users_get_users"
404
371
  end
405
372
  # resource path
406
- local_var_path = '/api/apps/{appId}/users'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s))
373
+ local_var_path = '/api/apps/{appId}/users'.sub('{' + 'appId' + '}', app_id.to_s)
407
374
 
408
375
  # query parameters
409
376
  query_params = opts[:query_params] || {}
410
377
  query_params[:'query'] = opts[:'query'] if !opts[:'query'].nil?
411
378
  query_params[:'take'] = opts[:'take'] if !opts[:'take'].nil?
412
379
  query_params[:'skip'] = opts[:'skip'] if !opts[:'skip'].nil?
380
+ query_params[:'withDetails'] = opts[:'with_details'] if !opts[:'with_details'].nil?
413
381
 
414
382
  # header parameters
415
383
  header_params = opts[:header_params] || {}
@@ -420,52 +388,49 @@ module Notifo
420
388
  form_params = opts[:form_params] || {}
421
389
 
422
390
  # http body (model)
423
- post_body = opts[:debug_body]
391
+ post_body = opts[:body]
424
392
 
425
- # return_type
426
- return_type = opts[:debug_return_type] || 'ListResponseDtoOfUserDto'
393
+ return_type = opts[:return_type] || 'ListResponseDtoOfUserDto'
427
394
 
428
- # auth_names
429
- auth_names = opts[:debug_auth_names] || []
430
-
431
- new_options = opts.merge(
432
- :operation => :"UsersApi.users_get_users",
395
+ auth_names = opts[:auth_names] || []
396
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
433
397
  :header_params => header_params,
434
398
  :query_params => query_params,
435
399
  :form_params => form_params,
436
400
  :body => post_body,
437
401
  :auth_names => auth_names,
438
- :return_type => return_type
439
- )
402
+ :return_type => return_type)
440
403
 
441
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
442
404
  if @api_client.config.debugging
443
405
  @api_client.config.logger.debug "API called: UsersApi#users_get_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
444
406
  end
445
407
  return data, status_code, headers
446
408
  end
447
-
448
409
  # Add an allowed topic.
449
- # @param app_id [String] The app where the users belong to.
450
- # @param id [String] The user id.
451
- # @param add_allowed_topic_dto [AddAllowedTopicDto] The upsert request.
410
+ # @param body The upsert request.
411
+ # @param app_id The app where the users belong to.
412
+ # @param id The user ID.
452
413
  # @param [Hash] opts the optional parameters
453
414
  # @return [nil]
454
- def users_post_allowed_topic(app_id, id, add_allowed_topic_dto, opts = {})
455
- users_post_allowed_topic_with_http_info(app_id, id, add_allowed_topic_dto, opts)
415
+ def users_post_allowed_topic(body, app_id, id, opts = {})
416
+ users_post_allowed_topic_with_http_info(body, app_id, id, opts)
456
417
  nil
457
418
  end
458
419
 
459
420
  # Add an allowed topic.
460
- # @param app_id [String] The app where the users belong to.
461
- # @param id [String] The user id.
462
- # @param add_allowed_topic_dto [AddAllowedTopicDto] The upsert request.
421
+ # @param body The upsert request.
422
+ # @param app_id The app where the users belong to.
423
+ # @param id The user ID.
463
424
  # @param [Hash] opts the optional parameters
464
425
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
465
- def users_post_allowed_topic_with_http_info(app_id, id, add_allowed_topic_dto, opts = {})
426
+ def users_post_allowed_topic_with_http_info(body, app_id, id, opts = {})
466
427
  if @api_client.config.debugging
467
428
  @api_client.config.logger.debug 'Calling API: UsersApi.users_post_allowed_topic ...'
468
429
  end
430
+ # verify the required parameter 'body' is set
431
+ if @api_client.config.client_side_validation && body.nil?
432
+ fail ArgumentError, "Missing the required parameter 'body' when calling UsersApi.users_post_allowed_topic"
433
+ end
469
434
  # verify the required parameter 'app_id' is set
470
435
  if @api_client.config.client_side_validation && app_id.nil?
471
436
  fail ArgumentError, "Missing the required parameter 'app_id' when calling UsersApi.users_post_allowed_topic"
@@ -474,12 +439,8 @@ module Notifo
474
439
  if @api_client.config.client_side_validation && id.nil?
475
440
  fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_post_allowed_topic"
476
441
  end
477
- # verify the required parameter 'add_allowed_topic_dto' is set
478
- if @api_client.config.client_side_validation && add_allowed_topic_dto.nil?
479
- fail ArgumentError, "Missing the required parameter 'add_allowed_topic_dto' when calling UsersApi.users_post_allowed_topic"
480
- end
481
442
  # resource path
482
- local_var_path = '/api/apps/{appId}/users/{id}/allowed-topics'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s))
443
+ local_var_path = '/api/apps/{appId}/users/{id}/allowed-topics'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s)
483
444
 
484
445
  # query parameters
485
446
  query_params = opts[:query_params] || {}
@@ -495,66 +456,59 @@ module Notifo
495
456
  form_params = opts[:form_params] || {}
496
457
 
497
458
  # http body (model)
498
- post_body = opts[:debug_body] || @api_client.object_to_http_body(add_allowed_topic_dto)
459
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
499
460
 
500
- # return_type
501
- return_type = opts[:debug_return_type]
461
+ return_type = opts[:return_type]
502
462
 
503
- # auth_names
504
- auth_names = opts[:debug_auth_names] || []
505
-
506
- new_options = opts.merge(
507
- :operation => :"UsersApi.users_post_allowed_topic",
463
+ auth_names = opts[:auth_names] || []
464
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
508
465
  :header_params => header_params,
509
466
  :query_params => query_params,
510
467
  :form_params => form_params,
511
468
  :body => post_body,
512
469
  :auth_names => auth_names,
513
- :return_type => return_type
514
- )
470
+ :return_type => return_type)
515
471
 
516
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
517
472
  if @api_client.config.debugging
518
473
  @api_client.config.logger.debug "API called: UsersApi#users_post_allowed_topic\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
519
474
  end
520
475
  return data, status_code, headers
521
476
  end
522
-
523
- # Upsert a user subscriptions.
524
- # @param app_id [String] The app where the user belongs to.
525
- # @param id [String] The user id.
526
- # @param subscription_dto [SubscriptionDto] The subscription object.
477
+ # Upserts or deletes multiple user subscriptions.
478
+ # @param body The subscription object.
479
+ # @param app_id The app where the user belongs to.
480
+ # @param id The user ID.
527
481
  # @param [Hash] opts the optional parameters
528
482
  # @return [nil]
529
- def users_post_subscription(app_id, id, subscription_dto, opts = {})
530
- users_post_subscription_with_http_info(app_id, id, subscription_dto, opts)
483
+ def users_post_subscriptions(body, app_id, id, opts = {})
484
+ users_post_subscriptions_with_http_info(body, app_id, id, opts)
531
485
  nil
532
486
  end
533
487
 
534
- # Upsert a user subscriptions.
535
- # @param app_id [String] The app where the user belongs to.
536
- # @param id [String] The user id.
537
- # @param subscription_dto [SubscriptionDto] The subscription object.
488
+ # Upserts or deletes multiple user subscriptions.
489
+ # @param body The subscription object.
490
+ # @param app_id The app where the user belongs to.
491
+ # @param id The user ID.
538
492
  # @param [Hash] opts the optional parameters
539
493
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
540
- def users_post_subscription_with_http_info(app_id, id, subscription_dto, opts = {})
494
+ def users_post_subscriptions_with_http_info(body, app_id, id, opts = {})
541
495
  if @api_client.config.debugging
542
- @api_client.config.logger.debug 'Calling API: UsersApi.users_post_subscription ...'
496
+ @api_client.config.logger.debug 'Calling API: UsersApi.users_post_subscriptions ...'
497
+ end
498
+ # verify the required parameter 'body' is set
499
+ if @api_client.config.client_side_validation && body.nil?
500
+ fail ArgumentError, "Missing the required parameter 'body' when calling UsersApi.users_post_subscriptions"
543
501
  end
544
502
  # verify the required parameter 'app_id' is set
545
503
  if @api_client.config.client_side_validation && app_id.nil?
546
- fail ArgumentError, "Missing the required parameter 'app_id' when calling UsersApi.users_post_subscription"
504
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling UsersApi.users_post_subscriptions"
547
505
  end
548
506
  # verify the required parameter 'id' is set
549
507
  if @api_client.config.client_side_validation && id.nil?
550
- fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_post_subscription"
551
- end
552
- # verify the required parameter 'subscription_dto' is set
553
- if @api_client.config.client_side_validation && subscription_dto.nil?
554
- fail ArgumentError, "Missing the required parameter 'subscription_dto' when calling UsersApi.users_post_subscription"
508
+ fail ArgumentError, "Missing the required parameter 'id' when calling UsersApi.users_post_subscriptions"
555
509
  end
556
510
  # resource path
557
- local_var_path = '/api/apps/{appId}/users/{id}/subscriptions'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'id' + '}', CGI.escape(id.to_s))
511
+ local_var_path = '/api/apps/{appId}/users/{id}/subscriptions'.sub('{' + 'appId' + '}', app_id.to_s).sub('{' + 'id' + '}', id.to_s)
558
512
 
559
513
  # query parameters
560
514
  query_params = opts[:query_params] || {}
@@ -570,60 +524,53 @@ module Notifo
570
524
  form_params = opts[:form_params] || {}
571
525
 
572
526
  # http body (model)
573
- post_body = opts[:debug_body] || @api_client.object_to_http_body(subscription_dto)
527
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
574
528
 
575
- # return_type
576
- return_type = opts[:debug_return_type]
529
+ return_type = opts[:return_type]
577
530
 
578
- # auth_names
579
- auth_names = opts[:debug_auth_names] || []
580
-
581
- new_options = opts.merge(
582
- :operation => :"UsersApi.users_post_subscription",
531
+ auth_names = opts[:auth_names] || []
532
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
583
533
  :header_params => header_params,
584
534
  :query_params => query_params,
585
535
  :form_params => form_params,
586
536
  :body => post_body,
587
537
  :auth_names => auth_names,
588
- :return_type => return_type
589
- )
538
+ :return_type => return_type)
590
539
 
591
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
592
540
  if @api_client.config.debugging
593
- @api_client.config.logger.debug "API called: UsersApi#users_post_subscription\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
541
+ @api_client.config.logger.debug "API called: UsersApi#users_post_subscriptions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
594
542
  end
595
543
  return data, status_code, headers
596
544
  end
597
-
598
545
  # Upsert users.
599
- # @param app_id [String] The app where the users belong to.
600
- # @param upsert_users_dto [UpsertUsersDto] The upsert request.
546
+ # @param body The upsert request.
547
+ # @param app_id The app where the users belong to.
601
548
  # @param [Hash] opts the optional parameters
602
549
  # @return [Array<UserDto>]
603
- def users_post_users(app_id, upsert_users_dto, opts = {})
604
- data, _status_code, _headers = users_post_users_with_http_info(app_id, upsert_users_dto, opts)
550
+ def users_post_users(body, app_id, opts = {})
551
+ data, _status_code, _headers = users_post_users_with_http_info(body, app_id, opts)
605
552
  data
606
553
  end
607
554
 
608
555
  # Upsert users.
609
- # @param app_id [String] The app where the users belong to.
610
- # @param upsert_users_dto [UpsertUsersDto] The upsert request.
556
+ # @param body The upsert request.
557
+ # @param app_id The app where the users belong to.
611
558
  # @param [Hash] opts the optional parameters
612
559
  # @return [Array<(Array<UserDto>, Integer, Hash)>] Array<UserDto> data, response status code and response headers
613
- def users_post_users_with_http_info(app_id, upsert_users_dto, opts = {})
560
+ def users_post_users_with_http_info(body, app_id, opts = {})
614
561
  if @api_client.config.debugging
615
562
  @api_client.config.logger.debug 'Calling API: UsersApi.users_post_users ...'
616
563
  end
564
+ # verify the required parameter 'body' is set
565
+ if @api_client.config.client_side_validation && body.nil?
566
+ fail ArgumentError, "Missing the required parameter 'body' when calling UsersApi.users_post_users"
567
+ end
617
568
  # verify the required parameter 'app_id' is set
618
569
  if @api_client.config.client_side_validation && app_id.nil?
619
570
  fail ArgumentError, "Missing the required parameter 'app_id' when calling UsersApi.users_post_users"
620
571
  end
621
- # verify the required parameter 'upsert_users_dto' is set
622
- if @api_client.config.client_side_validation && upsert_users_dto.nil?
623
- fail ArgumentError, "Missing the required parameter 'upsert_users_dto' when calling UsersApi.users_post_users"
624
- end
625
572
  # resource path
626
- local_var_path = '/api/apps/{appId}/users'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s))
573
+ local_var_path = '/api/apps/{appId}/users'.sub('{' + 'appId' + '}', app_id.to_s)
627
574
 
628
575
  # query parameters
629
576
  query_params = opts[:query_params] || {}
@@ -639,25 +586,19 @@ module Notifo
639
586
  form_params = opts[:form_params] || {}
640
587
 
641
588
  # http body (model)
642
- post_body = opts[:debug_body] || @api_client.object_to_http_body(upsert_users_dto)
643
-
644
- # return_type
645
- return_type = opts[:debug_return_type] || 'Array<UserDto>'
589
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
646
590
 
647
- # auth_names
648
- auth_names = opts[:debug_auth_names] || []
591
+ return_type = opts[:return_type] || 'Array<UserDto>'
649
592
 
650
- new_options = opts.merge(
651
- :operation => :"UsersApi.users_post_users",
593
+ auth_names = opts[:auth_names] || []
594
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
652
595
  :header_params => header_params,
653
596
  :query_params => query_params,
654
597
  :form_params => form_params,
655
598
  :body => post_body,
656
599
  :auth_names => auth_names,
657
- :return_type => return_type
658
- )
600
+ :return_type => return_type)
659
601
 
660
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
661
602
  if @api_client.config.debugging
662
603
  @api_client.config.logger.debug "API called: UsersApi#users_post_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
663
604
  end