sunshine-conversations-client 9.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (536) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG_RB.md +12 -0
  3. data/Gemfile +9 -0
  4. data/LICENSE +176 -0
  5. data/README.md +456 -0
  6. data/Rakefile +10 -0
  7. data/docs/AcceptControlBody.md +17 -0
  8. data/docs/Action.md +41 -0
  9. data/docs/ActionSubset.md +39 -0
  10. data/docs/ActivitiesApi.md +71 -0
  11. data/docs/Activity.md +21 -0
  12. data/docs/ActivityAllOf.md +19 -0
  13. data/docs/ActivityPost.md +19 -0
  14. data/docs/ActivityPostAllOf.md +17 -0
  15. data/docs/ActivityTypes.md +17 -0
  16. data/docs/Android.md +23 -0
  17. data/docs/AndroidAllOf.md +23 -0
  18. data/docs/AndroidUpdate.md +23 -0
  19. data/docs/AndroidUpdateAllOf.md +21 -0
  20. data/docs/ApiKey.md +21 -0
  21. data/docs/App.md +23 -0
  22. data/docs/AppCreateBody.md +21 -0
  23. data/docs/AppKey.md +21 -0
  24. data/docs/AppKeyCreateBody.md +17 -0
  25. data/docs/AppKeyListResponse.md +17 -0
  26. data/docs/AppKeyResponse.md +17 -0
  27. data/docs/AppKeysApi.md +250 -0
  28. data/docs/AppListFilter.md +17 -0
  29. data/docs/AppListResponse.md +21 -0
  30. data/docs/AppResponse.md +17 -0
  31. data/docs/AppSettings.md +31 -0
  32. data/docs/AppSubSchema.md +17 -0
  33. data/docs/AppUpdateBody.md +21 -0
  34. data/docs/Apple.md +23 -0
  35. data/docs/AppleAllOf.md +23 -0
  36. data/docs/AppleUpdate.md +16 -0
  37. data/docs/AppsApi.md +309 -0
  38. data/docs/AttachmentDeleteBody.md +17 -0
  39. data/docs/AttachmentMediaTokenBody.md +17 -0
  40. data/docs/AttachmentMediaTokenResponse.md +17 -0
  41. data/docs/AttachmentResponse.md +17 -0
  42. data/docs/AttachmentSchema.md +19 -0
  43. data/docs/AttachmentUploadBody.md +17 -0
  44. data/docs/AttachmentsApi.md +254 -0
  45. data/docs/Author.md +25 -0
  46. data/docs/AuthorWebhook.md +21 -0
  47. data/docs/Buy.md +25 -0
  48. data/docs/CarouselMessage.md +23 -0
  49. data/docs/CarouselMessageDisplaySettings.md +17 -0
  50. data/docs/Client.md +37 -0
  51. data/docs/ClientAssociation.md +19 -0
  52. data/docs/ClientCreate.md +21 -0
  53. data/docs/ClientListResponse.md +21 -0
  54. data/docs/ClientResponse.md +17 -0
  55. data/docs/ClientType.md +16 -0
  56. data/docs/ClientsApi.md +199 -0
  57. data/docs/Confirmation.md +19 -0
  58. data/docs/Content.md +41 -0
  59. data/docs/Conversation.md +37 -0
  60. data/docs/ConversationAllOf.md +29 -0
  61. data/docs/ConversationCreateBody.md +27 -0
  62. data/docs/ConversationCreateEvent.md +23 -0
  63. data/docs/ConversationCreateEventAllOf.md +17 -0
  64. data/docs/ConversationCreateEventAllOfPayload.md +25 -0
  65. data/docs/ConversationListFilter.md +19 -0
  66. data/docs/ConversationListResponse.md +21 -0
  67. data/docs/ConversationMessageDeliveryChannelEvent.md +23 -0
  68. data/docs/ConversationMessageDeliveryChannelEventAllOf.md +17 -0
  69. data/docs/ConversationMessageDeliveryFailureEvent.md +23 -0
  70. data/docs/ConversationMessageDeliveryFailureEventAllOf.md +17 -0
  71. data/docs/ConversationMessageDeliveryPayload.md +27 -0
  72. data/docs/ConversationMessageDeliveryPayloadDestination.md +19 -0
  73. data/docs/ConversationMessageDeliveryPayloadExternalMessages.md +17 -0
  74. data/docs/ConversationMessageDeliveryPayloadMessage.md +17 -0
  75. data/docs/ConversationMessageDeliveryUserEvent.md +23 -0
  76. data/docs/ConversationMessageEvent.md +23 -0
  77. data/docs/ConversationMessageEventAllOf.md +17 -0
  78. data/docs/ConversationMessageEventAllOfPayload.md +21 -0
  79. data/docs/ConversationPostbackEvent.md +23 -0
  80. data/docs/ConversationPostbackEventAllOf.md +17 -0
  81. data/docs/ConversationPostbackEventAllOfPayload.md +23 -0
  82. data/docs/ConversationReadEvent.md +23 -0
  83. data/docs/ConversationReadEventAllOf.md +17 -0
  84. data/docs/ConversationReadEventAllOfPayload.md +19 -0
  85. data/docs/ConversationResponse.md +17 -0
  86. data/docs/ConversationTruncated.md +23 -0
  87. data/docs/ConversationType.md +16 -0
  88. data/docs/ConversationTypingEvent.md +23 -0
  89. data/docs/ConversationTypingEventAllOf.md +17 -0
  90. data/docs/ConversationTypingEventAllOfPayload.md +19 -0
  91. data/docs/ConversationUpdateBody.md +23 -0
  92. data/docs/ConversationsApi.md +319 -0
  93. data/docs/Custom.md +19 -0
  94. data/docs/CustomAllOf.md +19 -0
  95. data/docs/CustomIntegrationApiKeysApi.md +258 -0
  96. data/docs/CustomUpdate.md +16 -0
  97. data/docs/Destination.md +19 -0
  98. data/docs/Device.md +35 -0
  99. data/docs/EventSubSchema.md +21 -0
  100. data/docs/ExtraChannelOptions.md +17 -0
  101. data/docs/ExtraChannelOptionsMessenger.md +19 -0
  102. data/docs/Field.md +35 -0
  103. data/docs/FileMessage.md +25 -0
  104. data/docs/FormMessage.md +21 -0
  105. data/docs/FormResponseMessage.md +21 -0
  106. data/docs/ImageMessage.md +23 -0
  107. data/docs/InlineObject.md +23 -0
  108. data/docs/Integration.md +23 -0
  109. data/docs/IntegrationApiKey.md +17 -0
  110. data/docs/IntegrationApiKeyListResponse.md +17 -0
  111. data/docs/IntegrationApiKeyResponse.md +17 -0
  112. data/docs/IntegrationId.md +17 -0
  113. data/docs/IntegrationListFilter.md +17 -0
  114. data/docs/IntegrationListResponse.md +21 -0
  115. data/docs/IntegrationResponse.md +17 -0
  116. data/docs/IntegrationType.md +17 -0
  117. data/docs/IntegrationUpdate.md +71 -0
  118. data/docs/IntegrationUpdateBase.md +17 -0
  119. data/docs/IntegrationsApi.md +319 -0
  120. data/docs/Ios.md +27 -0
  121. data/docs/IosAllOf.md +27 -0
  122. data/docs/IosUpdate.md +27 -0
  123. data/docs/IosUpdateAllOf.md +25 -0
  124. data/docs/Item.md +29 -0
  125. data/docs/Line.md +31 -0
  126. data/docs/LineAllOf.md +31 -0
  127. data/docs/LineUpdate.md +16 -0
  128. data/docs/Link.md +27 -0
  129. data/docs/Links.md +19 -0
  130. data/docs/ListMessage.md +21 -0
  131. data/docs/LocationMessage.md +23 -0
  132. data/docs/LocationMessageCoordinates.md +19 -0
  133. data/docs/LocationMessageLocation.md +19 -0
  134. data/docs/LocationRequest.md +21 -0
  135. data/docs/Mailgun.md +27 -0
  136. data/docs/MailgunAllOf.md +27 -0
  137. data/docs/MailgunUpdate.md +21 -0
  138. data/docs/MailgunUpdateAllOf.md +19 -0
  139. data/docs/MatchCriteria.md +27 -0
  140. data/docs/MatchCriteriaBase.md +21 -0
  141. data/docs/MatchCriteriaMailgun.md +25 -0
  142. data/docs/MatchCriteriaMailgunAllOf.md +21 -0
  143. data/docs/MatchCriteriaMessagebird.md +23 -0
  144. data/docs/MatchCriteriaMessagebirdAllOf.md +19 -0
  145. data/docs/MatchCriteriaTwilio.md +23 -0
  146. data/docs/MatchCriteriaTwilioAllOf.md +19 -0
  147. data/docs/MatchCriteriaWhatsapp.md +23 -0
  148. data/docs/MatchCriteriaWhatsappAllOf.md +19 -0
  149. data/docs/Message.md +31 -0
  150. data/docs/MessageBirdUpdate.md +16 -0
  151. data/docs/MessageListResponse.md +21 -0
  152. data/docs/MessageOverride.md +23 -0
  153. data/docs/MessageOverrideApple.md +17 -0
  154. data/docs/MessageOverrideLine.md +17 -0
  155. data/docs/MessageOverrideMessenger.md +17 -0
  156. data/docs/MessageOverridePayload.md +17 -0
  157. data/docs/MessageOverrideWhatsapp.md +17 -0
  158. data/docs/MessagePost.md +27 -0
  159. data/docs/MessagePostResponse.md +17 -0
  160. data/docs/MessageWebhook.md +31 -0
  161. data/docs/Messagebird.md +25 -0
  162. data/docs/MessagebirdAllOf.md +25 -0
  163. data/docs/MessagesApi.md +260 -0
  164. data/docs/Messenger.md +23 -0
  165. data/docs/MessengerAllOf.md +23 -0
  166. data/docs/MessengerUpdate.md +19 -0
  167. data/docs/MessengerUpdateAllOf.md +17 -0
  168. data/docs/Meta.md +21 -0
  169. data/docs/OAuthEndpointsApi.md +168 -0
  170. data/docs/OfferControlBody.md +19 -0
  171. data/docs/Page.md +21 -0
  172. data/docs/Participant.md +27 -0
  173. data/docs/ParticipantJoinBody.md +16 -0
  174. data/docs/ParticipantLeaveBody.md +21 -0
  175. data/docs/ParticipantLeaveBodyParticipantId.md +17 -0
  176. data/docs/ParticipantLeaveBodyUserExternalId.md +17 -0
  177. data/docs/ParticipantLeaveBodyUserId.md +17 -0
  178. data/docs/ParticipantListResponse.md +21 -0
  179. data/docs/ParticipantResponse.md +17 -0
  180. data/docs/ParticipantSubSchema.md +21 -0
  181. data/docs/ParticipantWithUserExternalId.md +19 -0
  182. data/docs/ParticipantWithUserId.md +19 -0
  183. data/docs/ParticipantsApi.md +199 -0
  184. data/docs/PassControlBody.md +19 -0
  185. data/docs/Postback.md +23 -0
  186. data/docs/PostbackWebhook.md +19 -0
  187. data/docs/PrechatCapture.md +23 -0
  188. data/docs/Profile.md +23 -0
  189. data/docs/QuotedMessage.md +21 -0
  190. data/docs/QuotedMessageExternalMessageId.md +19 -0
  191. data/docs/QuotedMessageMessage.md +19 -0
  192. data/docs/Referral.md +19 -0
  193. data/docs/ReferralDetails.md +21 -0
  194. data/docs/Reply.md +25 -0
  195. data/docs/Source.md +27 -0
  196. data/docs/SourceWebhook.md +27 -0
  197. data/docs/Status.md +16 -0
  198. data/docs/Switchboard.md +21 -0
  199. data/docs/SwitchboardAcceptControl.md +23 -0
  200. data/docs/SwitchboardAcceptControlAllOf.md +17 -0
  201. data/docs/SwitchboardAcceptControlAllOfPayload.md +19 -0
  202. data/docs/SwitchboardAcceptControlFailure.md +23 -0
  203. data/docs/SwitchboardAcceptControlFailureAllOf.md +17 -0
  204. data/docs/SwitchboardAcceptControlFailureAllOfPayload.md +21 -0
  205. data/docs/SwitchboardActionsApi.md +197 -0
  206. data/docs/SwitchboardIntegration.md +29 -0
  207. data/docs/SwitchboardIntegrationCreateBody.md +27 -0
  208. data/docs/SwitchboardIntegrationListResponse.md +17 -0
  209. data/docs/SwitchboardIntegrationResponse.md +17 -0
  210. data/docs/SwitchboardIntegrationUpdateBody.md +27 -0
  211. data/docs/SwitchboardIntegrationWebhook.md +23 -0
  212. data/docs/SwitchboardIntegrationsApi.md +260 -0
  213. data/docs/SwitchboardListResponse.md +17 -0
  214. data/docs/SwitchboardOfferControl.md +23 -0
  215. data/docs/SwitchboardOfferControlAllOf.md +17 -0
  216. data/docs/SwitchboardOfferControlAllOfPayload.md +19 -0
  217. data/docs/SwitchboardOfferControlFailure.md +23 -0
  218. data/docs/SwitchboardPassControl.md +23 -0
  219. data/docs/SwitchboardPassControlAllOf.md +17 -0
  220. data/docs/SwitchboardPassControlAllOfPayload.md +19 -0
  221. data/docs/SwitchboardPassControlFailure.md +23 -0
  222. data/docs/SwitchboardResponse.md +17 -0
  223. data/docs/SwitchboardUpdateBody.md +19 -0
  224. data/docs/SwitchboardsApi.md +250 -0
  225. data/docs/Target.md +17 -0
  226. data/docs/Telegram.md +23 -0
  227. data/docs/TelegramAllOf.md +23 -0
  228. data/docs/TelegramUpdate.md +16 -0
  229. data/docs/TextMessage.md +21 -0
  230. data/docs/Twilio.md +23 -0
  231. data/docs/TwilioAllOf.md +23 -0
  232. data/docs/TwilioUpdate.md +16 -0
  233. data/docs/Twitter.md +29 -0
  234. data/docs/TwitterAllOf.md +29 -0
  235. data/docs/TwitterUpdate.md +16 -0
  236. data/docs/User.md +25 -0
  237. data/docs/UserAllOf.md +21 -0
  238. data/docs/UserCreateBody.md +23 -0
  239. data/docs/UserMergeEvent.md +23 -0
  240. data/docs/UserMergeEventAllOf.md +17 -0
  241. data/docs/UserMergeEventAllOfPayload.md +21 -0
  242. data/docs/UserMergeEventAllOfPayloadMergedConversations.md +19 -0
  243. data/docs/UserMergeEventAllOfPayloadMergedUsers.md +19 -0
  244. data/docs/UserResponse.md +17 -0
  245. data/docs/UserTruncated.md +19 -0
  246. data/docs/UserUpdateBody.md +21 -0
  247. data/docs/UsersApi.md +315 -0
  248. data/docs/Viber.md +23 -0
  249. data/docs/ViberAllOf.md +23 -0
  250. data/docs/ViberUpdate.md +16 -0
  251. data/docs/Web.md +47 -0
  252. data/docs/WebAllOf.md +47 -0
  253. data/docs/WebUpdate.md +47 -0
  254. data/docs/WebUpdateAllOf.md +45 -0
  255. data/docs/Webhook.md +29 -0
  256. data/docs/WebhookBody.md +23 -0
  257. data/docs/WebhookCreateBody.md +16 -0
  258. data/docs/WebhookListResponse.md +17 -0
  259. data/docs/WebhookResponse.md +17 -0
  260. data/docs/WebhookSubSchema.md +19 -0
  261. data/docs/WebhooksApi.md +323 -0
  262. data/docs/Webview.md +33 -0
  263. data/docs/WhatsAppUpdate.md +23 -0
  264. data/docs/WhatsAppUpdateAllOf.md +21 -0
  265. data/docs/Whatsapp.md +25 -0
  266. data/docs/WhatsappAllOf.md +25 -0
  267. data/lib/sunshine-conversations-client.rb +306 -0
  268. data/lib/sunshine-conversations-client/api/activities_api.rb +95 -0
  269. data/lib/sunshine-conversations-client/api/app_keys_api.rb +287 -0
  270. data/lib/sunshine-conversations-client/api/apps_api.rb +339 -0
  271. data/lib/sunshine-conversations-client/api/attachments_api.rb +305 -0
  272. data/lib/sunshine-conversations-client/api/clients_api.rb +240 -0
  273. data/lib/sunshine-conversations-client/api/conversations_api.rb +373 -0
  274. data/lib/sunshine-conversations-client/api/custom_integration_api_keys_api.rb +311 -0
  275. data/lib/sunshine-conversations-client/api/integrations_api.rb +369 -0
  276. data/lib/sunshine-conversations-client/api/messages_api.rb +308 -0
  277. data/lib/sunshine-conversations-client/api/o_auth_endpoints_api.rb +213 -0
  278. data/lib/sunshine-conversations-client/api/participants_api.rb +242 -0
  279. data/lib/sunshine-conversations-client/api/switchboard_actions_api.rb +247 -0
  280. data/lib/sunshine-conversations-client/api/switchboard_integrations_api.rb +319 -0
  281. data/lib/sunshine-conversations-client/api/switchboards_api.rb +287 -0
  282. data/lib/sunshine-conversations-client/api/users_api.rb +369 -0
  283. data/lib/sunshine-conversations-client/api/webhooks_api.rb +393 -0
  284. data/lib/sunshine-conversations-client/api_client.rb +348 -0
  285. data/lib/sunshine-conversations-client/api_error.rb +54 -0
  286. data/lib/sunshine-conversations-client/configuration.rb +284 -0
  287. data/lib/sunshine-conversations-client/models/accept_control_body.rb +204 -0
  288. data/lib/sunshine-conversations-client/models/action.rb +421 -0
  289. data/lib/sunshine-conversations-client/models/action_subset.rb +409 -0
  290. data/lib/sunshine-conversations-client/models/activity.rb +265 -0
  291. data/lib/sunshine-conversations-client/models/activity_all_of.rb +213 -0
  292. data/lib/sunshine-conversations-client/models/activity_post.rb +266 -0
  293. data/lib/sunshine-conversations-client/models/activity_post_all_of.rb +204 -0
  294. data/lib/sunshine-conversations-client/models/activity_types.rb +238 -0
  295. data/lib/sunshine-conversations-client/models/android.rb +280 -0
  296. data/lib/sunshine-conversations-client/models/android_all_of.rb +268 -0
  297. data/lib/sunshine-conversations-client/models/android_update.rb +299 -0
  298. data/lib/sunshine-conversations-client/models/android_update_all_of.rb +256 -0
  299. data/lib/sunshine-conversations-client/models/api_key.rb +225 -0
  300. data/lib/sunshine-conversations-client/models/app.rb +234 -0
  301. data/lib/sunshine-conversations-client/models/app_create_body.rb +229 -0
  302. data/lib/sunshine-conversations-client/models/app_key.rb +224 -0
  303. data/lib/sunshine-conversations-client/models/app_key_create_body.rb +209 -0
  304. data/lib/sunshine-conversations-client/models/app_key_list_response.rb +203 -0
  305. data/lib/sunshine-conversations-client/models/app_key_response.rb +204 -0
  306. data/lib/sunshine-conversations-client/models/app_list_filter.rb +204 -0
  307. data/lib/sunshine-conversations-client/models/app_list_response.rb +221 -0
  308. data/lib/sunshine-conversations-client/models/app_response.rb +204 -0
  309. data/lib/sunshine-conversations-client/models/app_settings.rb +290 -0
  310. data/lib/sunshine-conversations-client/models/app_sub_schema.rb +205 -0
  311. data/lib/sunshine-conversations-client/models/app_update_body.rb +224 -0
  312. data/lib/sunshine-conversations-client/models/apple.rb +263 -0
  313. data/lib/sunshine-conversations-client/models/apple_all_of.rb +252 -0
  314. data/lib/sunshine-conversations-client/models/apple_update.rb +205 -0
  315. data/lib/sunshine-conversations-client/models/attachment_delete_body.rb +209 -0
  316. data/lib/sunshine-conversations-client/models/attachment_media_token_body.rb +208 -0
  317. data/lib/sunshine-conversations-client/models/attachment_media_token_response.rb +203 -0
  318. data/lib/sunshine-conversations-client/models/attachment_response.rb +204 -0
  319. data/lib/sunshine-conversations-client/models/attachment_schema.rb +214 -0
  320. data/lib/sunshine-conversations-client/models/attachment_upload_body.rb +208 -0
  321. data/lib/sunshine-conversations-client/models/author.rb +284 -0
  322. data/lib/sunshine-conversations-client/models/author_webhook.rb +264 -0
  323. data/lib/sunshine-conversations-client/models/buy.rb +262 -0
  324. data/lib/sunshine-conversations-client/models/carousel_message.rb +245 -0
  325. data/lib/sunshine-conversations-client/models/carousel_message_display_settings.rb +239 -0
  326. data/lib/sunshine-conversations-client/models/client.rb +345 -0
  327. data/lib/sunshine-conversations-client/models/client_association.rb +213 -0
  328. data/lib/sunshine-conversations-client/models/client_create.rb +236 -0
  329. data/lib/sunshine-conversations-client/models/client_list_response.rb +221 -0
  330. data/lib/sunshine-conversations-client/models/client_response.rb +203 -0
  331. data/lib/sunshine-conversations-client/models/client_type.rb +42 -0
  332. data/lib/sunshine-conversations-client/models/confirmation.rb +254 -0
  333. data/lib/sunshine-conversations-client/models/content.rb +380 -0
  334. data/lib/sunshine-conversations-client/models/conversation.rb +366 -0
  335. data/lib/sunshine-conversations-client/models/conversation_all_of.rb +317 -0
  336. data/lib/sunshine-conversations-client/models/conversation_create_body.rb +308 -0
  337. data/lib/sunshine-conversations-client/models/conversation_create_event.rb +241 -0
  338. data/lib/sunshine-conversations-client/models/conversation_create_event_all_of.rb +203 -0
  339. data/lib/sunshine-conversations-client/models/conversation_create_event_all_of_payload.rb +281 -0
  340. data/lib/sunshine-conversations-client/models/conversation_list_filter.rb +214 -0
  341. data/lib/sunshine-conversations-client/models/conversation_list_response.rb +221 -0
  342. data/lib/sunshine-conversations-client/models/conversation_message_delivery_channel_event.rb +241 -0
  343. data/lib/sunshine-conversations-client/models/conversation_message_delivery_channel_event_all_of.rb +203 -0
  344. data/lib/sunshine-conversations-client/models/conversation_message_delivery_failure_event.rb +241 -0
  345. data/lib/sunshine-conversations-client/models/conversation_message_delivery_failure_event_all_of.rb +203 -0
  346. data/lib/sunshine-conversations-client/models/conversation_message_delivery_payload.rb +253 -0
  347. data/lib/sunshine-conversations-client/models/conversation_message_delivery_payload_destination.rb +215 -0
  348. data/lib/sunshine-conversations-client/models/conversation_message_delivery_payload_external_messages.rb +204 -0
  349. data/lib/sunshine-conversations-client/models/conversation_message_delivery_payload_message.rb +205 -0
  350. data/lib/sunshine-conversations-client/models/conversation_message_delivery_user_event.rb +241 -0
  351. data/lib/sunshine-conversations-client/models/conversation_message_event.rb +241 -0
  352. data/lib/sunshine-conversations-client/models/conversation_message_event_all_of.rb +203 -0
  353. data/lib/sunshine-conversations-client/models/conversation_message_event_all_of_payload.rb +224 -0
  354. data/lib/sunshine-conversations-client/models/conversation_postback_event.rb +241 -0
  355. data/lib/sunshine-conversations-client/models/conversation_postback_event_all_of.rb +203 -0
  356. data/lib/sunshine-conversations-client/models/conversation_postback_event_all_of_payload.rb +235 -0
  357. data/lib/sunshine-conversations-client/models/conversation_read_event.rb +241 -0
  358. data/lib/sunshine-conversations-client/models/conversation_read_event_all_of.rb +203 -0
  359. data/lib/sunshine-conversations-client/models/conversation_read_event_all_of_payload.rb +215 -0
  360. data/lib/sunshine-conversations-client/models/conversation_response.rb +204 -0
  361. data/lib/sunshine-conversations-client/models/conversation_truncated.rb +235 -0
  362. data/lib/sunshine-conversations-client/models/conversation_type.rb +33 -0
  363. data/lib/sunshine-conversations-client/models/conversation_typing_event.rb +241 -0
  364. data/lib/sunshine-conversations-client/models/conversation_typing_event_all_of.rb +203 -0
  365. data/lib/sunshine-conversations-client/models/conversation_typing_event_all_of_payload.rb +215 -0
  366. data/lib/sunshine-conversations-client/models/conversation_update_body.rb +285 -0
  367. data/lib/sunshine-conversations-client/models/custom.rb +232 -0
  368. data/lib/sunshine-conversations-client/models/custom_all_of.rb +220 -0
  369. data/lib/sunshine-conversations-client/models/custom_update.rb +205 -0
  370. data/lib/sunshine-conversations-client/models/destination.rb +239 -0
  371. data/lib/sunshine-conversations-client/models/device.rb +343 -0
  372. data/lib/sunshine-conversations-client/models/event_sub_schema.rb +224 -0
  373. data/lib/sunshine-conversations-client/models/extra_channel_options.rb +204 -0
  374. data/lib/sunshine-conversations-client/models/extra_channel_options_messenger.rb +251 -0
  375. data/lib/sunshine-conversations-client/models/field.rb +522 -0
  376. data/lib/sunshine-conversations-client/models/file_message.rb +256 -0
  377. data/lib/sunshine-conversations-client/models/form_message.rb +236 -0
  378. data/lib/sunshine-conversations-client/models/form_response_message.rb +236 -0
  379. data/lib/sunshine-conversations-client/models/image_message.rb +245 -0
  380. data/lib/sunshine-conversations-client/models/inline_object.rb +254 -0
  381. data/lib/sunshine-conversations-client/models/integration.rb +260 -0
  382. data/lib/sunshine-conversations-client/models/integration_api_key.rb +209 -0
  383. data/lib/sunshine-conversations-client/models/integration_api_key_list_response.rb +203 -0
  384. data/lib/sunshine-conversations-client/models/integration_api_key_response.rb +203 -0
  385. data/lib/sunshine-conversations-client/models/integration_id.rb +204 -0
  386. data/lib/sunshine-conversations-client/models/integration_list_filter.rb +204 -0
  387. data/lib/sunshine-conversations-client/models/integration_list_response.rb +221 -0
  388. data/lib/sunshine-conversations-client/models/integration_response.rb +203 -0
  389. data/lib/sunshine-conversations-client/models/integration_type.rb +204 -0
  390. data/lib/sunshine-conversations-client/models/integration_update.rb +619 -0
  391. data/lib/sunshine-conversations-client/models/integration_update_base.rb +229 -0
  392. data/lib/sunshine-conversations-client/models/ios.rb +284 -0
  393. data/lib/sunshine-conversations-client/models/ios_all_of.rb +272 -0
  394. data/lib/sunshine-conversations-client/models/ios_update.rb +303 -0
  395. data/lib/sunshine-conversations-client/models/ios_update_all_of.rb +260 -0
  396. data/lib/sunshine-conversations-client/models/item.rb +381 -0
  397. data/lib/sunshine-conversations-client/models/line.rb +313 -0
  398. data/lib/sunshine-conversations-client/models/line_all_of.rb +302 -0
  399. data/lib/sunshine-conversations-client/models/line_update.rb +205 -0
  400. data/lib/sunshine-conversations-client/models/link.rb +272 -0
  401. data/lib/sunshine-conversations-client/models/links.rb +215 -0
  402. data/lib/sunshine-conversations-client/models/list_message.rb +235 -0
  403. data/lib/sunshine-conversations-client/models/location_message.rb +245 -0
  404. data/lib/sunshine-conversations-client/models/location_message_coordinates.rb +225 -0
  405. data/lib/sunshine-conversations-client/models/location_message_location.rb +215 -0
  406. data/lib/sunshine-conversations-client/models/location_request.rb +238 -0
  407. data/lib/sunshine-conversations-client/models/mailgun.rb +356 -0
  408. data/lib/sunshine-conversations-client/models/mailgun_all_of.rb +345 -0
  409. data/lib/sunshine-conversations-client/models/mailgun_update.rb +273 -0
  410. data/lib/sunshine-conversations-client/models/mailgun_update_all_of.rb +230 -0
  411. data/lib/sunshine-conversations-client/models/match_criteria.rb +312 -0
  412. data/lib/sunshine-conversations-client/models/match_criteria_base.rb +237 -0
  413. data/lib/sunshine-conversations-client/models/match_criteria_mailgun.rb +273 -0
  414. data/lib/sunshine-conversations-client/models/match_criteria_mailgun_all_of.rb +234 -0
  415. data/lib/sunshine-conversations-client/models/match_criteria_messagebird.rb +261 -0
  416. data/lib/sunshine-conversations-client/models/match_criteria_messagebird_all_of.rb +222 -0
  417. data/lib/sunshine-conversations-client/models/match_criteria_twilio.rb +261 -0
  418. data/lib/sunshine-conversations-client/models/match_criteria_twilio_all_of.rb +222 -0
  419. data/lib/sunshine-conversations-client/models/match_criteria_whatsapp.rb +261 -0
  420. data/lib/sunshine-conversations-client/models/match_criteria_whatsapp_all_of.rb +222 -0
  421. data/lib/sunshine-conversations-client/models/message.rb +274 -0
  422. data/lib/sunshine-conversations-client/models/message_bird_update.rb +205 -0
  423. data/lib/sunshine-conversations-client/models/message_list_response.rb +221 -0
  424. data/lib/sunshine-conversations-client/models/message_override.rb +253 -0
  425. data/lib/sunshine-conversations-client/models/message_override_apple.rb +203 -0
  426. data/lib/sunshine-conversations-client/models/message_override_line.rb +203 -0
  427. data/lib/sunshine-conversations-client/models/message_override_messenger.rb +203 -0
  428. data/lib/sunshine-conversations-client/models/message_override_payload.rb +204 -0
  429. data/lib/sunshine-conversations-client/models/message_override_whatsapp.rb +203 -0
  430. data/lib/sunshine-conversations-client/models/message_post.rb +263 -0
  431. data/lib/sunshine-conversations-client/models/message_post_response.rb +203 -0
  432. data/lib/sunshine-conversations-client/models/message_webhook.rb +274 -0
  433. data/lib/sunshine-conversations-client/models/messagebird.rb +330 -0
  434. data/lib/sunshine-conversations-client/models/messagebird_all_of.rb +319 -0
  435. data/lib/sunshine-conversations-client/models/messenger.rb +263 -0
  436. data/lib/sunshine-conversations-client/models/messenger_all_of.rb +252 -0
  437. data/lib/sunshine-conversations-client/models/messenger_update.rb +247 -0
  438. data/lib/sunshine-conversations-client/models/messenger_update_all_of.rb +204 -0
  439. data/lib/sunshine-conversations-client/models/meta.rb +225 -0
  440. data/lib/sunshine-conversations-client/models/offer_control_body.rb +219 -0
  441. data/lib/sunshine-conversations-client/models/page.rb +250 -0
  442. data/lib/sunshine-conversations-client/models/participant.rb +255 -0
  443. data/lib/sunshine-conversations-client/models/participant_join_body.rb +205 -0
  444. data/lib/sunshine-conversations-client/models/participant_leave_body.rb +249 -0
  445. data/lib/sunshine-conversations-client/models/participant_leave_body_participant_id.rb +204 -0
  446. data/lib/sunshine-conversations-client/models/participant_leave_body_user_external_id.rb +204 -0
  447. data/lib/sunshine-conversations-client/models/participant_leave_body_user_id.rb +204 -0
  448. data/lib/sunshine-conversations-client/models/participant_list_response.rb +221 -0
  449. data/lib/sunshine-conversations-client/models/participant_response.rb +204 -0
  450. data/lib/sunshine-conversations-client/models/participant_sub_schema.rb +244 -0
  451. data/lib/sunshine-conversations-client/models/participant_with_user_external_id.rb +214 -0
  452. data/lib/sunshine-conversations-client/models/participant_with_user_id.rb +214 -0
  453. data/lib/sunshine-conversations-client/models/pass_control_body.rb +219 -0
  454. data/lib/sunshine-conversations-client/models/postback.rb +252 -0
  455. data/lib/sunshine-conversations-client/models/postback_webhook.rb +215 -0
  456. data/lib/sunshine-conversations-client/models/prechat_capture.rb +239 -0
  457. data/lib/sunshine-conversations-client/models/profile.rb +335 -0
  458. data/lib/sunshine-conversations-client/models/quoted_message.rb +249 -0
  459. data/lib/sunshine-conversations-client/models/quoted_message_external_message_id.rb +216 -0
  460. data/lib/sunshine-conversations-client/models/quoted_message_message.rb +215 -0
  461. data/lib/sunshine-conversations-client/models/referral.rb +214 -0
  462. data/lib/sunshine-conversations-client/models/referral_details.rb +226 -0
  463. data/lib/sunshine-conversations-client/models/reply.rb +260 -0
  464. data/lib/sunshine-conversations-client/models/source.rb +265 -0
  465. data/lib/sunshine-conversations-client/models/source_webhook.rb +258 -0
  466. data/lib/sunshine-conversations-client/models/status.rb +34 -0
  467. data/lib/sunshine-conversations-client/models/switchboard.rb +234 -0
  468. data/lib/sunshine-conversations-client/models/switchboard_accept_control.rb +241 -0
  469. data/lib/sunshine-conversations-client/models/switchboard_accept_control_all_of.rb +203 -0
  470. data/lib/sunshine-conversations-client/models/switchboard_accept_control_all_of_payload.rb +216 -0
  471. data/lib/sunshine-conversations-client/models/switchboard_accept_control_failure.rb +241 -0
  472. data/lib/sunshine-conversations-client/models/switchboard_accept_control_failure_all_of.rb +203 -0
  473. data/lib/sunshine-conversations-client/models/switchboard_accept_control_failure_all_of_payload.rb +226 -0
  474. data/lib/sunshine-conversations-client/models/switchboard_integration.rb +333 -0
  475. data/lib/sunshine-conversations-client/models/switchboard_integration_create_body.rb +302 -0
  476. data/lib/sunshine-conversations-client/models/switchboard_integration_list_response.rb +203 -0
  477. data/lib/sunshine-conversations-client/models/switchboard_integration_response.rb +204 -0
  478. data/lib/sunshine-conversations-client/models/switchboard_integration_update_body.rb +294 -0
  479. data/lib/sunshine-conversations-client/models/switchboard_integration_webhook.rb +249 -0
  480. data/lib/sunshine-conversations-client/models/switchboard_list_response.rb +203 -0
  481. data/lib/sunshine-conversations-client/models/switchboard_offer_control.rb +241 -0
  482. data/lib/sunshine-conversations-client/models/switchboard_offer_control_all_of.rb +203 -0
  483. data/lib/sunshine-conversations-client/models/switchboard_offer_control_all_of_payload.rb +216 -0
  484. data/lib/sunshine-conversations-client/models/switchboard_offer_control_failure.rb +241 -0
  485. data/lib/sunshine-conversations-client/models/switchboard_pass_control.rb +241 -0
  486. data/lib/sunshine-conversations-client/models/switchboard_pass_control_all_of.rb +203 -0
  487. data/lib/sunshine-conversations-client/models/switchboard_pass_control_all_of_payload.rb +216 -0
  488. data/lib/sunshine-conversations-client/models/switchboard_pass_control_failure.rb +241 -0
  489. data/lib/sunshine-conversations-client/models/switchboard_response.rb +204 -0
  490. data/lib/sunshine-conversations-client/models/switchboard_update_body.rb +214 -0
  491. data/lib/sunshine-conversations-client/models/target.rb +210 -0
  492. data/lib/sunshine-conversations-client/models/telegram.rb +272 -0
  493. data/lib/sunshine-conversations-client/models/telegram_all_of.rb +261 -0
  494. data/lib/sunshine-conversations-client/models/telegram_update.rb +205 -0
  495. data/lib/sunshine-conversations-client/models/text_message.rb +245 -0
  496. data/lib/sunshine-conversations-client/models/twilio.rb +301 -0
  497. data/lib/sunshine-conversations-client/models/twilio_all_of.rb +290 -0
  498. data/lib/sunshine-conversations-client/models/twilio_update.rb +205 -0
  499. data/lib/sunshine-conversations-client/models/twitter.rb +419 -0
  500. data/lib/sunshine-conversations-client/models/twitter_all_of.rb +408 -0
  501. data/lib/sunshine-conversations-client/models/twitter_update.rb +205 -0
  502. data/lib/sunshine-conversations-client/models/user.rb +250 -0
  503. data/lib/sunshine-conversations-client/models/user_all_of.rb +221 -0
  504. data/lib/sunshine-conversations-client/models/user_create_body.rb +267 -0
  505. data/lib/sunshine-conversations-client/models/user_merge_event.rb +241 -0
  506. data/lib/sunshine-conversations-client/models/user_merge_event_all_of.rb +203 -0
  507. data/lib/sunshine-conversations-client/models/user_merge_event_all_of_payload.rb +225 -0
  508. data/lib/sunshine-conversations-client/models/user_merge_event_all_of_payload_merged_conversations.rb +215 -0
  509. data/lib/sunshine-conversations-client/models/user_merge_event_all_of_payload_merged_users.rb +215 -0
  510. data/lib/sunshine-conversations-client/models/user_response.rb +204 -0
  511. data/lib/sunshine-conversations-client/models/user_truncated.rb +215 -0
  512. data/lib/sunshine-conversations-client/models/user_update_body.rb +223 -0
  513. data/lib/sunshine-conversations-client/models/viber.rb +272 -0
  514. data/lib/sunshine-conversations-client/models/viber_all_of.rb +261 -0
  515. data/lib/sunshine-conversations-client/models/viber_update.rb +205 -0
  516. data/lib/sunshine-conversations-client/models/web.rb +383 -0
  517. data/lib/sunshine-conversations-client/models/web_all_of.rb +372 -0
  518. data/lib/sunshine-conversations-client/models/web_update.rb +402 -0
  519. data/lib/sunshine-conversations-client/models/web_update_all_of.rb +360 -0
  520. data/lib/sunshine-conversations-client/models/webhook.rb +277 -0
  521. data/lib/sunshine-conversations-client/models/webhook_body.rb +237 -0
  522. data/lib/sunshine-conversations-client/models/webhook_create_body.rb +205 -0
  523. data/lib/sunshine-conversations-client/models/webhook_list_response.rb +203 -0
  524. data/lib/sunshine-conversations-client/models/webhook_response.rb +204 -0
  525. data/lib/sunshine-conversations-client/models/webhook_sub_schema.rb +215 -0
  526. data/lib/sunshine-conversations-client/models/webview.rb +339 -0
  527. data/lib/sunshine-conversations-client/models/whats_app_update.rb +272 -0
  528. data/lib/sunshine-conversations-client/models/whats_app_update_all_of.rb +229 -0
  529. data/lib/sunshine-conversations-client/models/whatsapp.rb +268 -0
  530. data/lib/sunshine-conversations-client/models/whatsapp_all_of.rb +257 -0
  531. data/lib/sunshine-conversations-client/version.rb +12 -0
  532. data/spec/api_client_spec.rb +223 -0
  533. data/spec/configuration_spec.rb +39 -0
  534. data/spec/spec_helper.rb +108 -0
  535. data/sunshine-conversations-client.gemspec +36 -0
  536. metadata +641 -0
@@ -0,0 +1,369 @@
1
+ =begin
2
+ #Sunshine Conversations API
3
+
4
+ The version of the OpenAPI document: 9.1.0
5
+
6
+ Generated by: https://openapi-generator.tech
7
+ OpenAPI Generator version: 4.3.1
8
+ =end
9
+
10
+ require 'cgi'
11
+
12
+ module SunshineConversationsClient
13
+ class IntegrationsApi
14
+ attr_accessor :api_client
15
+
16
+ def initialize(api_client = ApiClient.default)
17
+ @api_client = api_client
18
+ end
19
+ # Create Integration
20
+ # The Create Integration endpoint allows you to provision apps with front-end messaging channels. Selecting a `custom` integration allows the creation of webhooks.
21
+ # @param app_id [String] Identifies the app.
22
+ # @param integration [Integration]
23
+ # @param [Hash] opts the optional parameters
24
+ # @return [IntegrationResponse]
25
+ def create_integration(app_id, integration, opts = {})
26
+ data, _status_code, _headers = create_integration_with_http_info(app_id, integration, opts)
27
+ data
28
+ end
29
+
30
+ # Create Integration
31
+ # The Create Integration endpoint allows you to provision apps with front-end messaging channels. Selecting a `custom` integration allows the creation of webhooks.
32
+ # @param app_id [String] Identifies the app.
33
+ # @param integration [Integration]
34
+ # @param [Hash] opts the optional parameters
35
+ # @return [Array<(IntegrationResponse, Integer, Hash)>] IntegrationResponse data, response status code and response headers
36
+ def create_integration_with_http_info(app_id, integration, opts = {})
37
+ if @api_client.config.debugging
38
+ @api_client.config.logger.debug 'Calling API: IntegrationsApi.create_integration ...'
39
+ end
40
+ # verify the required parameter 'app_id' is set
41
+ if @api_client.config.client_side_validation && app_id.nil?
42
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationsApi.create_integration"
43
+ end
44
+ # verify the required parameter 'integration' is set
45
+ if @api_client.config.client_side_validation && integration.nil?
46
+ fail ArgumentError, "Missing the required parameter 'integration' when calling IntegrationsApi.create_integration"
47
+ end
48
+ # resource path
49
+ local_var_path = '/v2/apps/{appId}/integrations'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s))
50
+
51
+ # query parameters
52
+ query_params = opts[:query_params] || {}
53
+
54
+ # header parameters
55
+ header_params = opts[:header_params] || {}
56
+ # HTTP header 'Accept' (if needed)
57
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
58
+ # HTTP header 'Content-Type'
59
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
60
+
61
+ # form parameters
62
+ form_params = opts[:form_params] || {}
63
+
64
+ # http body (model)
65
+ post_body = opts[:body] || @api_client.object_to_http_body(integration)
66
+
67
+ # return_type
68
+ return_type = opts[:return_type] || 'IntegrationResponse'
69
+
70
+ # auth_names
71
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
72
+
73
+ new_options = opts.merge(
74
+ :header_params => header_params,
75
+ :query_params => query_params,
76
+ :form_params => form_params,
77
+ :body => post_body,
78
+ :auth_names => auth_names,
79
+ :return_type => return_type
80
+ )
81
+
82
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
83
+ if @api_client.config.debugging
84
+ @api_client.config.logger.debug "API called: IntegrationsApi#create_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
85
+ end
86
+ return data, status_code, headers
87
+ end
88
+
89
+ # Delete Integration
90
+ # Delete the specified integration.
91
+ # @param app_id [String] Identifies the app.
92
+ # @param integration_id [String] The id of the integration.
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [Object]
95
+ def delete_integration(app_id, integration_id, opts = {})
96
+ data, _status_code, _headers = delete_integration_with_http_info(app_id, integration_id, opts)
97
+ data
98
+ end
99
+
100
+ # Delete Integration
101
+ # Delete the specified integration.
102
+ # @param app_id [String] Identifies the app.
103
+ # @param integration_id [String] The id of the integration.
104
+ # @param [Hash] opts the optional parameters
105
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
106
+ def delete_integration_with_http_info(app_id, integration_id, opts = {})
107
+ if @api_client.config.debugging
108
+ @api_client.config.logger.debug 'Calling API: IntegrationsApi.delete_integration ...'
109
+ end
110
+ # verify the required parameter 'app_id' is set
111
+ if @api_client.config.client_side_validation && app_id.nil?
112
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationsApi.delete_integration"
113
+ end
114
+ # verify the required parameter 'integration_id' is set
115
+ if @api_client.config.client_side_validation && integration_id.nil?
116
+ fail ArgumentError, "Missing the required parameter 'integration_id' when calling IntegrationsApi.delete_integration"
117
+ end
118
+ # resource path
119
+ local_var_path = '/v2/apps/{appId}/integrations/{integrationId}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integrationId' + '}', CGI.escape(integration_id.to_s))
120
+
121
+ # query parameters
122
+ query_params = opts[:query_params] || {}
123
+
124
+ # header parameters
125
+ header_params = opts[:header_params] || {}
126
+ # HTTP header 'Accept' (if needed)
127
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
128
+
129
+ # form parameters
130
+ form_params = opts[:form_params] || {}
131
+
132
+ # http body (model)
133
+ post_body = opts[:body]
134
+
135
+ # return_type
136
+ return_type = opts[:return_type] || 'Object'
137
+
138
+ # auth_names
139
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
140
+
141
+ new_options = opts.merge(
142
+ :header_params => header_params,
143
+ :query_params => query_params,
144
+ :form_params => form_params,
145
+ :body => post_body,
146
+ :auth_names => auth_names,
147
+ :return_type => return_type
148
+ )
149
+
150
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
151
+ if @api_client.config.debugging
152
+ @api_client.config.logger.debug "API called: IntegrationsApi#delete_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
153
+ end
154
+ return data, status_code, headers
155
+ end
156
+
157
+ # Get Integration
158
+ # Get integration.
159
+ # @param app_id [String] Identifies the app.
160
+ # @param integration_id [String] The id of the integration.
161
+ # @param [Hash] opts the optional parameters
162
+ # @return [IntegrationResponse]
163
+ def get_integration(app_id, integration_id, opts = {})
164
+ data, _status_code, _headers = get_integration_with_http_info(app_id, integration_id, opts)
165
+ data
166
+ end
167
+
168
+ # Get Integration
169
+ # Get integration.
170
+ # @param app_id [String] Identifies the app.
171
+ # @param integration_id [String] The id of the integration.
172
+ # @param [Hash] opts the optional parameters
173
+ # @return [Array<(IntegrationResponse, Integer, Hash)>] IntegrationResponse data, response status code and response headers
174
+ def get_integration_with_http_info(app_id, integration_id, opts = {})
175
+ if @api_client.config.debugging
176
+ @api_client.config.logger.debug 'Calling API: IntegrationsApi.get_integration ...'
177
+ end
178
+ # verify the required parameter 'app_id' is set
179
+ if @api_client.config.client_side_validation && app_id.nil?
180
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationsApi.get_integration"
181
+ end
182
+ # verify the required parameter 'integration_id' is set
183
+ if @api_client.config.client_side_validation && integration_id.nil?
184
+ fail ArgumentError, "Missing the required parameter 'integration_id' when calling IntegrationsApi.get_integration"
185
+ end
186
+ # resource path
187
+ local_var_path = '/v2/apps/{appId}/integrations/{integrationId}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integrationId' + '}', CGI.escape(integration_id.to_s))
188
+
189
+ # query parameters
190
+ query_params = opts[:query_params] || {}
191
+
192
+ # header parameters
193
+ header_params = opts[:header_params] || {}
194
+ # HTTP header 'Accept' (if needed)
195
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
196
+
197
+ # form parameters
198
+ form_params = opts[:form_params] || {}
199
+
200
+ # http body (model)
201
+ post_body = opts[:body]
202
+
203
+ # return_type
204
+ return_type = opts[:return_type] || 'IntegrationResponse'
205
+
206
+ # auth_names
207
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
208
+
209
+ new_options = opts.merge(
210
+ :header_params => header_params,
211
+ :query_params => query_params,
212
+ :form_params => form_params,
213
+ :body => post_body,
214
+ :auth_names => auth_names,
215
+ :return_type => return_type
216
+ )
217
+
218
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
219
+ if @api_client.config.debugging
220
+ @api_client.config.logger.debug "API called: IntegrationsApi#get_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
221
+ end
222
+ return data, status_code, headers
223
+ end
224
+
225
+ # List Integrations
226
+ # List available integrations. This API is paginated through [cursor pagination](#section/Introduction/API-pagination-and-records-limits). ```shell /v2/apps/:appId/integrations?page[after]=5e1606762556d93e9c176f69&page[size]=10&filter[types]=custom,web ```
227
+ # @param app_id [String] Identifies the app.
228
+ # @param [Hash] opts the optional parameters
229
+ # @option opts [Page] :page Contains parameters for applying cursor pagination.
230
+ # @option opts [IntegrationListFilter] :filter Contains parameters for filtering the results.
231
+ # @return [IntegrationListResponse]
232
+ def list_integrations(app_id, opts = {})
233
+ data, _status_code, _headers = list_integrations_with_http_info(app_id, opts)
234
+ data
235
+ end
236
+
237
+ # List Integrations
238
+ # List available integrations. This API is paginated through [cursor pagination](#section/Introduction/API-pagination-and-records-limits). &#x60;&#x60;&#x60;shell /v2/apps/:appId/integrations?page[after]&#x3D;5e1606762556d93e9c176f69&amp;page[size]&#x3D;10&amp;filter[types]&#x3D;custom,web &#x60;&#x60;&#x60;
239
+ # @param app_id [String] Identifies the app.
240
+ # @param [Hash] opts the optional parameters
241
+ # @option opts [Page] :page Contains parameters for applying cursor pagination.
242
+ # @option opts [IntegrationListFilter] :filter Contains parameters for filtering the results.
243
+ # @return [Array<(IntegrationListResponse, Integer, Hash)>] IntegrationListResponse data, response status code and response headers
244
+ def list_integrations_with_http_info(app_id, opts = {})
245
+ if @api_client.config.debugging
246
+ @api_client.config.logger.debug 'Calling API: IntegrationsApi.list_integrations ...'
247
+ end
248
+ # verify the required parameter 'app_id' is set
249
+ if @api_client.config.client_side_validation && app_id.nil?
250
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationsApi.list_integrations"
251
+ end
252
+ # resource path
253
+ local_var_path = '/v2/apps/{appId}/integrations'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s))
254
+
255
+ # query parameters
256
+ query_params = opts[:query_params] || {}
257
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
258
+ query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
259
+
260
+ # header parameters
261
+ header_params = opts[:header_params] || {}
262
+ # HTTP header 'Accept' (if needed)
263
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
264
+
265
+ # form parameters
266
+ form_params = opts[:form_params] || {}
267
+
268
+ # http body (model)
269
+ post_body = opts[:body]
270
+
271
+ # return_type
272
+ return_type = opts[:return_type] || 'IntegrationListResponse'
273
+
274
+ # auth_names
275
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
276
+
277
+ new_options = opts.merge(
278
+ :header_params => header_params,
279
+ :query_params => query_params,
280
+ :form_params => form_params,
281
+ :body => post_body,
282
+ :auth_names => auth_names,
283
+ :return_type => return_type
284
+ )
285
+
286
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
287
+ if @api_client.config.debugging
288
+ @api_client.config.logger.debug "API called: IntegrationsApi#list_integrations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
289
+ end
290
+ return data, status_code, headers
291
+ end
292
+
293
+ # Update Integration
294
+ # Allows you to update certain fields of existing integrations. If updating a specific property is not supported, you must delete the integration and re-create it with the new data.
295
+ # @param app_id [String] Identifies the app.
296
+ # @param integration_id [String] The id of the integration.
297
+ # @param integration_update [IntegrationUpdate]
298
+ # @param [Hash] opts the optional parameters
299
+ # @return [IntegrationResponse]
300
+ def update_integration(app_id, integration_id, integration_update, opts = {})
301
+ data, _status_code, _headers = update_integration_with_http_info(app_id, integration_id, integration_update, opts)
302
+ data
303
+ end
304
+
305
+ # Update Integration
306
+ # Allows you to update certain fields of existing integrations. If updating a specific property is not supported, you must delete the integration and re-create it with the new data.
307
+ # @param app_id [String] Identifies the app.
308
+ # @param integration_id [String] The id of the integration.
309
+ # @param integration_update [IntegrationUpdate]
310
+ # @param [Hash] opts the optional parameters
311
+ # @return [Array<(IntegrationResponse, Integer, Hash)>] IntegrationResponse data, response status code and response headers
312
+ def update_integration_with_http_info(app_id, integration_id, integration_update, opts = {})
313
+ if @api_client.config.debugging
314
+ @api_client.config.logger.debug 'Calling API: IntegrationsApi.update_integration ...'
315
+ end
316
+ # verify the required parameter 'app_id' is set
317
+ if @api_client.config.client_side_validation && app_id.nil?
318
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationsApi.update_integration"
319
+ end
320
+ # verify the required parameter 'integration_id' is set
321
+ if @api_client.config.client_side_validation && integration_id.nil?
322
+ fail ArgumentError, "Missing the required parameter 'integration_id' when calling IntegrationsApi.update_integration"
323
+ end
324
+ # verify the required parameter 'integration_update' is set
325
+ if @api_client.config.client_side_validation && integration_update.nil?
326
+ fail ArgumentError, "Missing the required parameter 'integration_update' when calling IntegrationsApi.update_integration"
327
+ end
328
+ # resource path
329
+ local_var_path = '/v2/apps/{appId}/integrations/{integrationId}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integrationId' + '}', CGI.escape(integration_id.to_s))
330
+
331
+ # query parameters
332
+ query_params = opts[:query_params] || {}
333
+
334
+ # header parameters
335
+ header_params = opts[:header_params] || {}
336
+ # HTTP header 'Accept' (if needed)
337
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
338
+ # HTTP header 'Content-Type'
339
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
340
+
341
+ # form parameters
342
+ form_params = opts[:form_params] || {}
343
+
344
+ # http body (model)
345
+ post_body = opts[:body] || @api_client.object_to_http_body(integration_update)
346
+
347
+ # return_type
348
+ return_type = opts[:return_type] || 'IntegrationResponse'
349
+
350
+ # auth_names
351
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
352
+
353
+ new_options = opts.merge(
354
+ :header_params => header_params,
355
+ :query_params => query_params,
356
+ :form_params => form_params,
357
+ :body => post_body,
358
+ :auth_names => auth_names,
359
+ :return_type => return_type
360
+ )
361
+
362
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
363
+ if @api_client.config.debugging
364
+ @api_client.config.logger.debug "API called: IntegrationsApi#update_integration\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
365
+ end
366
+ return data, status_code, headers
367
+ end
368
+ end
369
+ end
@@ -0,0 +1,308 @@
1
+ =begin
2
+ #Sunshine Conversations API
3
+
4
+ The version of the OpenAPI document: 9.1.0
5
+
6
+ Generated by: https://openapi-generator.tech
7
+ OpenAPI Generator version: 4.3.1
8
+ =end
9
+
10
+ require 'cgi'
11
+
12
+ module SunshineConversationsClient
13
+ class MessagesApi
14
+ attr_accessor :api_client
15
+
16
+ def initialize(api_client = ApiClient.default)
17
+ @api_client = api_client
18
+ end
19
+ # Delete All Messages
20
+ # Delete all messages of a particular conversation.
21
+ # @param app_id [String] Identifies the app.
22
+ # @param conversation_id [String] Identifies the conversation.
23
+ # @param [Hash] opts the optional parameters
24
+ # @return [Object]
25
+ def delete_all_messages(app_id, conversation_id, opts = {})
26
+ data, _status_code, _headers = delete_all_messages_with_http_info(app_id, conversation_id, opts)
27
+ data
28
+ end
29
+
30
+ # Delete All Messages
31
+ # Delete all messages of a particular conversation.
32
+ # @param app_id [String] Identifies the app.
33
+ # @param conversation_id [String] Identifies the conversation.
34
+ # @param [Hash] opts the optional parameters
35
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
36
+ def delete_all_messages_with_http_info(app_id, conversation_id, opts = {})
37
+ if @api_client.config.debugging
38
+ @api_client.config.logger.debug 'Calling API: MessagesApi.delete_all_messages ...'
39
+ end
40
+ # verify the required parameter 'app_id' is set
41
+ if @api_client.config.client_side_validation && app_id.nil?
42
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling MessagesApi.delete_all_messages"
43
+ end
44
+ # verify the required parameter 'conversation_id' is set
45
+ if @api_client.config.client_side_validation && conversation_id.nil?
46
+ fail ArgumentError, "Missing the required parameter 'conversation_id' when calling MessagesApi.delete_all_messages"
47
+ end
48
+ # resource path
49
+ local_var_path = '/v2/apps/{appId}/conversations/{conversationId}/messages'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'conversationId' + '}', CGI.escape(conversation_id.to_s))
50
+
51
+ # query parameters
52
+ query_params = opts[:query_params] || {}
53
+
54
+ # header parameters
55
+ header_params = opts[:header_params] || {}
56
+ # HTTP header 'Accept' (if needed)
57
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
58
+
59
+ # form parameters
60
+ form_params = opts[:form_params] || {}
61
+
62
+ # http body (model)
63
+ post_body = opts[:body]
64
+
65
+ # return_type
66
+ return_type = opts[:return_type] || 'Object'
67
+
68
+ # auth_names
69
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
70
+
71
+ new_options = opts.merge(
72
+ :header_params => header_params,
73
+ :query_params => query_params,
74
+ :form_params => form_params,
75
+ :body => post_body,
76
+ :auth_names => auth_names,
77
+ :return_type => return_type
78
+ )
79
+
80
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
81
+ if @api_client.config.debugging
82
+ @api_client.config.logger.debug "API called: MessagesApi#delete_all_messages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
83
+ end
84
+ return data, status_code, headers
85
+ end
86
+
87
+ # Delete Message
88
+ # Delete a single message of a particular conversation.
89
+ # @param app_id [String] Identifies the app.
90
+ # @param conversation_id [String] Identifies the conversation.
91
+ # @param message_id [String] The id of the message.
92
+ # @param [Hash] opts the optional parameters
93
+ # @return [Object]
94
+ def delete_message(app_id, conversation_id, message_id, opts = {})
95
+ data, _status_code, _headers = delete_message_with_http_info(app_id, conversation_id, message_id, opts)
96
+ data
97
+ end
98
+
99
+ # Delete Message
100
+ # Delete a single message of a particular conversation.
101
+ # @param app_id [String] Identifies the app.
102
+ # @param conversation_id [String] Identifies the conversation.
103
+ # @param message_id [String] The id of the message.
104
+ # @param [Hash] opts the optional parameters
105
+ # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
106
+ def delete_message_with_http_info(app_id, conversation_id, message_id, opts = {})
107
+ if @api_client.config.debugging
108
+ @api_client.config.logger.debug 'Calling API: MessagesApi.delete_message ...'
109
+ end
110
+ # verify the required parameter 'app_id' is set
111
+ if @api_client.config.client_side_validation && app_id.nil?
112
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling MessagesApi.delete_message"
113
+ end
114
+ # verify the required parameter 'conversation_id' is set
115
+ if @api_client.config.client_side_validation && conversation_id.nil?
116
+ fail ArgumentError, "Missing the required parameter 'conversation_id' when calling MessagesApi.delete_message"
117
+ end
118
+ # verify the required parameter 'message_id' is set
119
+ if @api_client.config.client_side_validation && message_id.nil?
120
+ fail ArgumentError, "Missing the required parameter 'message_id' when calling MessagesApi.delete_message"
121
+ end
122
+ # resource path
123
+ local_var_path = '/v2/apps/{appId}/conversations/{conversationId}/messages/{messageId}'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'conversationId' + '}', CGI.escape(conversation_id.to_s)).sub('{' + 'messageId' + '}', CGI.escape(message_id.to_s))
124
+
125
+ # query parameters
126
+ query_params = opts[:query_params] || {}
127
+
128
+ # header parameters
129
+ header_params = opts[:header_params] || {}
130
+ # HTTP header 'Accept' (if needed)
131
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
132
+
133
+ # form parameters
134
+ form_params = opts[:form_params] || {}
135
+
136
+ # http body (model)
137
+ post_body = opts[:body]
138
+
139
+ # return_type
140
+ return_type = opts[:return_type] || 'Object'
141
+
142
+ # auth_names
143
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
144
+
145
+ new_options = opts.merge(
146
+ :header_params => header_params,
147
+ :query_params => query_params,
148
+ :form_params => form_params,
149
+ :body => post_body,
150
+ :auth_names => auth_names,
151
+ :return_type => return_type
152
+ )
153
+
154
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
155
+ if @api_client.config.debugging
156
+ @api_client.config.logger.debug "API called: MessagesApi#delete_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
157
+ end
158
+ return data, status_code, headers
159
+ end
160
+
161
+ # List Messages
162
+ # List all messages for a particular conversation. This API is paginated through [cursor pagination](#section/Introduction/API-pagination-and-records-limits), in the _backwards_ direction, with the most recent (i.e. last) page of messages being returned by default. The `hasMore` flag indicates whether more messages exist in the direction you are currently paginating through. To page backwards in the history, use the `beforeCursor` or follow the `prev` link. The page size limit is fixed at 100 messages per page. ```shell /v2/apps/:appId/conversations/:conversationId/messages?page[before]=5f32b88acf6bf25073b2be56 ```
163
+ # @param app_id [String] Identifies the app.
164
+ # @param conversation_id [String] Identifies the conversation.
165
+ # @param [Hash] opts the optional parameters
166
+ # @option opts [Page] :page Contains parameters for applying cursor pagination.
167
+ # @return [MessageListResponse]
168
+ def list_messages(app_id, conversation_id, opts = {})
169
+ data, _status_code, _headers = list_messages_with_http_info(app_id, conversation_id, opts)
170
+ data
171
+ end
172
+
173
+ # List Messages
174
+ # List all messages for a particular conversation. This API is paginated through [cursor pagination](#section/Introduction/API-pagination-and-records-limits), in the _backwards_ direction, with the most recent (i.e. last) page of messages being returned by default. The &#x60;hasMore&#x60; flag indicates whether more messages exist in the direction you are currently paginating through. To page backwards in the history, use the &#x60;beforeCursor&#x60; or follow the &#x60;prev&#x60; link. The page size limit is fixed at 100 messages per page. &#x60;&#x60;&#x60;shell /v2/apps/:appId/conversations/:conversationId/messages?page[before]&#x3D;5f32b88acf6bf25073b2be56 &#x60;&#x60;&#x60;
175
+ # @param app_id [String] Identifies the app.
176
+ # @param conversation_id [String] Identifies the conversation.
177
+ # @param [Hash] opts the optional parameters
178
+ # @option opts [Page] :page Contains parameters for applying cursor pagination.
179
+ # @return [Array<(MessageListResponse, Integer, Hash)>] MessageListResponse data, response status code and response headers
180
+ def list_messages_with_http_info(app_id, conversation_id, opts = {})
181
+ if @api_client.config.debugging
182
+ @api_client.config.logger.debug 'Calling API: MessagesApi.list_messages ...'
183
+ end
184
+ # verify the required parameter 'app_id' is set
185
+ if @api_client.config.client_side_validation && app_id.nil?
186
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling MessagesApi.list_messages"
187
+ end
188
+ # verify the required parameter 'conversation_id' is set
189
+ if @api_client.config.client_side_validation && conversation_id.nil?
190
+ fail ArgumentError, "Missing the required parameter 'conversation_id' when calling MessagesApi.list_messages"
191
+ end
192
+ # resource path
193
+ local_var_path = '/v2/apps/{appId}/conversations/{conversationId}/messages'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'conversationId' + '}', CGI.escape(conversation_id.to_s))
194
+
195
+ # query parameters
196
+ query_params = opts[:query_params] || {}
197
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
198
+
199
+ # header parameters
200
+ header_params = opts[:header_params] || {}
201
+ # HTTP header 'Accept' (if needed)
202
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
203
+
204
+ # form parameters
205
+ form_params = opts[:form_params] || {}
206
+
207
+ # http body (model)
208
+ post_body = opts[:body]
209
+
210
+ # return_type
211
+ return_type = opts[:return_type] || 'MessageListResponse'
212
+
213
+ # auth_names
214
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
215
+
216
+ new_options = opts.merge(
217
+ :header_params => header_params,
218
+ :query_params => query_params,
219
+ :form_params => form_params,
220
+ :body => post_body,
221
+ :auth_names => auth_names,
222
+ :return_type => return_type
223
+ )
224
+
225
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
226
+ if @api_client.config.debugging
227
+ @api_client.config.logger.debug "API called: MessagesApi#list_messages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
228
+ end
229
+ return data, status_code, headers
230
+ end
231
+
232
+ # Post Message
233
+ # Send a message in a particular conversation.
234
+ # @param app_id [String] Identifies the app.
235
+ # @param conversation_id [String] Identifies the conversation.
236
+ # @param message_post [MessagePost]
237
+ # @param [Hash] opts the optional parameters
238
+ # @return [MessagePostResponse]
239
+ def post_message(app_id, conversation_id, message_post, opts = {})
240
+ data, _status_code, _headers = post_message_with_http_info(app_id, conversation_id, message_post, opts)
241
+ data
242
+ end
243
+
244
+ # Post Message
245
+ # Send a message in a particular conversation.
246
+ # @param app_id [String] Identifies the app.
247
+ # @param conversation_id [String] Identifies the conversation.
248
+ # @param message_post [MessagePost]
249
+ # @param [Hash] opts the optional parameters
250
+ # @return [Array<(MessagePostResponse, Integer, Hash)>] MessagePostResponse data, response status code and response headers
251
+ def post_message_with_http_info(app_id, conversation_id, message_post, opts = {})
252
+ if @api_client.config.debugging
253
+ @api_client.config.logger.debug 'Calling API: MessagesApi.post_message ...'
254
+ end
255
+ # verify the required parameter 'app_id' is set
256
+ if @api_client.config.client_side_validation && app_id.nil?
257
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling MessagesApi.post_message"
258
+ end
259
+ # verify the required parameter 'conversation_id' is set
260
+ if @api_client.config.client_side_validation && conversation_id.nil?
261
+ fail ArgumentError, "Missing the required parameter 'conversation_id' when calling MessagesApi.post_message"
262
+ end
263
+ # verify the required parameter 'message_post' is set
264
+ if @api_client.config.client_side_validation && message_post.nil?
265
+ fail ArgumentError, "Missing the required parameter 'message_post' when calling MessagesApi.post_message"
266
+ end
267
+ # resource path
268
+ local_var_path = '/v2/apps/{appId}/conversations/{conversationId}/messages'.sub('{' + 'appId' + '}', CGI.escape(app_id.to_s)).sub('{' + 'conversationId' + '}', CGI.escape(conversation_id.to_s))
269
+
270
+ # query parameters
271
+ query_params = opts[:query_params] || {}
272
+
273
+ # header parameters
274
+ header_params = opts[:header_params] || {}
275
+ # HTTP header 'Accept' (if needed)
276
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
277
+ # HTTP header 'Content-Type'
278
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
279
+
280
+ # form parameters
281
+ form_params = opts[:form_params] || {}
282
+
283
+ # http body (model)
284
+ post_body = opts[:body] || @api_client.object_to_http_body(message_post)
285
+
286
+ # return_type
287
+ return_type = opts[:return_type] || 'MessagePostResponse'
288
+
289
+ # auth_names
290
+ auth_names = opts[:auth_names] || ['basicAuth', 'bearerAuth']
291
+
292
+ new_options = opts.merge(
293
+ :header_params => header_params,
294
+ :query_params => query_params,
295
+ :form_params => form_params,
296
+ :body => post_body,
297
+ :auth_names => auth_names,
298
+ :return_type => return_type
299
+ )
300
+
301
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
302
+ if @api_client.config.debugging
303
+ @api_client.config.logger.debug "API called: MessagesApi#post_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
304
+ end
305
+ return data, status_code, headers
306
+ end
307
+ end
308
+ end