slack-apimatic-sdk 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (426) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +221 -0
  4. data/bin/console +15 -0
  5. data/lib/slack_web_api/api_helper.rb +10 -0
  6. data/lib/slack_web_api/apis/admin_apps_api.rb +78 -0
  7. data/lib/slack_web_api/apis/admin_apps_approved_api.rb +48 -0
  8. data/lib/slack_web_api/apis/admin_apps_requests_api.rb +44 -0
  9. data/lib/slack_web_api/apis/admin_apps_restricted_api.rb +48 -0
  10. data/lib/slack_web_api/apis/admin_conversations_api.rb +472 -0
  11. data/lib/slack_web_api/apis/admin_conversations_ekm_api.rb +51 -0
  12. data/lib/slack_web_api/apis/admin_conversations_restrict_access_api.rb +129 -0
  13. data/lib/slack_web_api/apis/admin_emoji_api.rb +175 -0
  14. data/lib/slack_web_api/apis/admin_invite_requests_api.rb +112 -0
  15. data/lib/slack_web_api/apis/admin_invite_requests_approved_api.rb +46 -0
  16. data/lib/slack_web_api/apis/admin_invite_requests_denied_api.rb +46 -0
  17. data/lib/slack_web_api/apis/admin_teams_admins_api.rb +45 -0
  18. data/lib/slack_web_api/apis/admin_teams_api.rb +84 -0
  19. data/lib/slack_web_api/apis/admin_teams_owners_api.rb +45 -0
  20. data/lib/slack_web_api/apis/admin_teams_settings_api.rb +206 -0
  21. data/lib/slack_web_api/apis/admin_usergroups_api.rb +161 -0
  22. data/lib/slack_web_api/apis/admin_users_api.rb +333 -0
  23. data/lib/slack_web_api/apis/admin_users_session_api.rb +80 -0
  24. data/lib/slack_web_api/apis/api.rb +34 -0
  25. data/lib/slack_web_api/apis/apps_api.rb +40 -0
  26. data/lib/slack_web_api/apis/apps_event_authorizations_api.rb +45 -0
  27. data/lib/slack_web_api/apis/apps_permissions_api.rb +66 -0
  28. data/lib/slack_web_api/apis/apps_permissions_resources_api.rb +43 -0
  29. data/lib/slack_web_api/apis/apps_permissions_scopes_api.rb +33 -0
  30. data/lib/slack_web_api/apis/apps_permissions_users_api.rb +84 -0
  31. data/lib/slack_web_api/apis/auth_api.rb +62 -0
  32. data/lib/slack_web_api/apis/base_api.rb +67 -0
  33. data/lib/slack_web_api/apis/bots_api.rb +36 -0
  34. data/lib/slack_web_api/apis/calls_api.rb +174 -0
  35. data/lib/slack_web_api/apis/calls_participants_api.rb +79 -0
  36. data/lib/slack_web_api/apis/chat_api.rb +528 -0
  37. data/lib/slack_web_api/apis/chat_scheduled_messages_api.rb +54 -0
  38. data/lib/slack_web_api/apis/conversations_api.rb +624 -0
  39. data/lib/slack_web_api/apis/dialog_api.rb +44 -0
  40. data/lib/slack_web_api/apis/dnd_api.rb +141 -0
  41. data/lib/slack_web_api/apis/emoji_api.rb +33 -0
  42. data/lib/slack_web_api/apis/files_api.rb +244 -0
  43. data/lib/slack_web_api/apis/files_comments_api.rb +38 -0
  44. data/lib/slack_web_api/apis/files_remote_api.rb +249 -0
  45. data/lib/slack_web_api/apis/migration_api.rb +47 -0
  46. data/lib/slack_web_api/apis/oauth_api.rb +88 -0
  47. data/lib/slack_web_api/apis/oauth_authorization_api.rb +87 -0
  48. data/lib/slack_web_api/apis/oauth_v2_api.rb +45 -0
  49. data/lib/slack_web_api/apis/pins_api.rb +102 -0
  50. data/lib/slack_web_api/apis/reactions_api.rb +182 -0
  51. data/lib/slack_web_api/apis/reminders_api.rb +151 -0
  52. data/lib/slack_web_api/apis/rtm_api.rb +42 -0
  53. data/lib/slack_web_api/apis/search_api.rb +56 -0
  54. data/lib/slack_web_api/apis/stars_api.rb +130 -0
  55. data/lib/slack_web_api/apis/team_api.rb +148 -0
  56. data/lib/slack_web_api/apis/team_profile_api.rb +36 -0
  57. data/lib/slack_web_api/apis/usergroups_api.rb +205 -0
  58. data/lib/slack_web_api/apis/usergroups_users_api.rb +81 -0
  59. data/lib/slack_web_api/apis/users_api.rb +325 -0
  60. data/lib/slack_web_api/apis/users_profile_api.rb +82 -0
  61. data/lib/slack_web_api/apis/views_api.rb +158 -0
  62. data/lib/slack_web_api/apis/workflows_api.rb +130 -0
  63. data/lib/slack_web_api/client.rb +410 -0
  64. data/lib/slack_web_api/configuration.rb +173 -0
  65. data/lib/slack_web_api/exceptions/admin_conversations_archive_error_schema_exception.rb +50 -0
  66. data/lib/slack_web_api/exceptions/admin_conversations_convert_to_private_error_schema_exception.rb +50 -0
  67. data/lib/slack_web_api/exceptions/admin_conversations_create_error_schema_exception.rb +50 -0
  68. data/lib/slack_web_api/exceptions/admin_conversations_delete_error_schema_exception.rb +50 -0
  69. data/lib/slack_web_api/exceptions/admin_conversations_disconnect_shared_error_schema_exception.rb +50 -0
  70. data/lib/slack_web_api/exceptions/admin_conversations_get_teams_error_schema_exception.rb +50 -0
  71. data/lib/slack_web_api/exceptions/admin_conversations_invite_error_schema_exception.rb +50 -0
  72. data/lib/slack_web_api/exceptions/admin_conversations_search_error_schema_exception.rb +50 -0
  73. data/lib/slack_web_api/exceptions/admin_conversations_set_conversation_prefs_error_schema_exception.rb +50 -0
  74. data/lib/slack_web_api/exceptions/admin_conversations_unarchive_error_schema2_exception.rb +50 -0
  75. data/lib/slack_web_api/exceptions/admin_conversations_unarchive_error_schema3_exception.rb +50 -0
  76. data/lib/slack_web_api/exceptions/admin_conversations_unarchive_error_schema_exception.rb +50 -0
  77. data/lib/slack_web_api/exceptions/api_exception.rb +21 -0
  78. data/lib/slack_web_api/exceptions/api_test_error_schema_exception.rb +50 -0
  79. data/lib/slack_web_api/exceptions/apps_permissions_info_error_schema_exception.rb +56 -0
  80. data/lib/slack_web_api/exceptions/apps_permissions_request_error_schema_exception.rb +56 -0
  81. data/lib/slack_web_api/exceptions/apps_permissions_resources_list_error_schema_exception.rb +56 -0
  82. data/lib/slack_web_api/exceptions/apps_permissions_scopes_list_error_schema_exception.rb +56 -0
  83. data/lib/slack_web_api/exceptions/apps_uninstall_error_schema_exception.rb +56 -0
  84. data/lib/slack_web_api/exceptions/auth_revoke_error_schema_exception.rb +56 -0
  85. data/lib/slack_web_api/exceptions/auth_test_error_schema_exception.rb +56 -0
  86. data/lib/slack_web_api/exceptions/bots_info_error_schema_exception.rb +56 -0
  87. data/lib/slack_web_api/exceptions/chat_delete_error_schema_exception.rb +56 -0
  88. data/lib/slack_web_api/exceptions/chat_delete_scheduled_message_error_schema_exception.rb +56 -0
  89. data/lib/slack_web_api/exceptions/chat_get_permalink_error_schema_exception.rb +56 -0
  90. data/lib/slack_web_api/exceptions/chat_me_message_error_schema_exception.rb +56 -0
  91. data/lib/slack_web_api/exceptions/chat_post_ephemeral_error_schema_exception.rb +56 -0
  92. data/lib/slack_web_api/exceptions/chat_post_message_error_schema_exception.rb +56 -0
  93. data/lib/slack_web_api/exceptions/chat_schedule_message_error_schema_exception.rb +56 -0
  94. data/lib/slack_web_api/exceptions/chat_scheduled_messages_list_error_schema_exception.rb +56 -0
  95. data/lib/slack_web_api/exceptions/chat_unfurl_error_schema_exception.rb +56 -0
  96. data/lib/slack_web_api/exceptions/chat_update_error_schema_exception.rb +56 -0
  97. data/lib/slack_web_api/exceptions/conversations_archive_error_schema_exception.rb +67 -0
  98. data/lib/slack_web_api/exceptions/conversations_close_error_schema_exception.rb +67 -0
  99. data/lib/slack_web_api/exceptions/conversations_create_error_schema_exception.rb +73 -0
  100. data/lib/slack_web_api/exceptions/conversations_history_error_schema_exception.rb +67 -0
  101. data/lib/slack_web_api/exceptions/conversations_info_error_schema_exception.rb +67 -0
  102. data/lib/slack_web_api/exceptions/conversations_invite_error_schema1_exception.rb +82 -0
  103. data/lib/slack_web_api/exceptions/conversations_join_error_schema_exception.rb +67 -0
  104. data/lib/slack_web_api/exceptions/conversations_kick_error_schema_exception.rb +67 -0
  105. data/lib/slack_web_api/exceptions/conversations_leave_error_schema_exception.rb +67 -0
  106. data/lib/slack_web_api/exceptions/conversations_list_error_schema_exception.rb +67 -0
  107. data/lib/slack_web_api/exceptions/conversations_mark_error_schema_exception.rb +67 -0
  108. data/lib/slack_web_api/exceptions/conversations_members_error_schema_exception.rb +56 -0
  109. data/lib/slack_web_api/exceptions/conversations_open_error_schema_exception.rb +56 -0
  110. data/lib/slack_web_api/exceptions/conversations_rename_error_schema_exception.rb +67 -0
  111. data/lib/slack_web_api/exceptions/conversations_replies_error_schema_exception.rb +67 -0
  112. data/lib/slack_web_api/exceptions/conversations_set_purpose_error_schema_exception.rb +67 -0
  113. data/lib/slack_web_api/exceptions/conversations_set_topic_error_schema_exception.rb +67 -0
  114. data/lib/slack_web_api/exceptions/conversations_unarchive_error_schema_exception.rb +67 -0
  115. data/lib/slack_web_api/exceptions/default_error_template_exception.rb +47 -0
  116. data/lib/slack_web_api/exceptions/dialog_open_error_schema_exception.rb +56 -0
  117. data/lib/slack_web_api/exceptions/dnd_end_dnd_error_schema_exception.rb +56 -0
  118. data/lib/slack_web_api/exceptions/dnd_end_snooze_error_schema_exception.rb +56 -0
  119. data/lib/slack_web_api/exceptions/dnd_info_error_schema_exception.rb +56 -0
  120. data/lib/slack_web_api/exceptions/dnd_set_snooze_error_schema_exception.rb +56 -0
  121. data/lib/slack_web_api/exceptions/files_comments_delete_error_schema_exception.rb +56 -0
  122. data/lib/slack_web_api/exceptions/files_delete_error_schema_exception.rb +56 -0
  123. data/lib/slack_web_api/exceptions/files_info_error_schema_exception.rb +56 -0
  124. data/lib/slack_web_api/exceptions/files_list_error_schema_exception.rb +56 -0
  125. data/lib/slack_web_api/exceptions/files_revoke_public_url_error_schema_exception.rb +56 -0
  126. data/lib/slack_web_api/exceptions/files_shared_public_url_error_schema_exception.rb +56 -0
  127. data/lib/slack_web_api/exceptions/files_upload_error_schema_exception.rb +56 -0
  128. data/lib/slack_web_api/exceptions/migration_exchange_error_schema_exception.rb +56 -0
  129. data/lib/slack_web_api/exceptions/oauth_provider_exception.rb +64 -0
  130. data/lib/slack_web_api/exceptions/pins_add_error_schema_exception.rb +56 -0
  131. data/lib/slack_web_api/exceptions/pins_list_error_schema_exception.rb +56 -0
  132. data/lib/slack_web_api/exceptions/pins_remove_error_schema_exception.rb +56 -0
  133. data/lib/slack_web_api/exceptions/reactions_add_error_schema_exception.rb +56 -0
  134. data/lib/slack_web_api/exceptions/reactions_get_error_schema_exception.rb +56 -0
  135. data/lib/slack_web_api/exceptions/reactions_list_error_schema_exception.rb +56 -0
  136. data/lib/slack_web_api/exceptions/reactions_remove_error_schema_exception.rb +56 -0
  137. data/lib/slack_web_api/exceptions/reminders_add_error_schema_exception.rb +56 -0
  138. data/lib/slack_web_api/exceptions/reminders_complete_error_schema_exception.rb +56 -0
  139. data/lib/slack_web_api/exceptions/reminders_delete_error_schema_exception.rb +56 -0
  140. data/lib/slack_web_api/exceptions/reminders_info_error_schema_exception.rb +56 -0
  141. data/lib/slack_web_api/exceptions/reminders_list_error_schema_exception.rb +56 -0
  142. data/lib/slack_web_api/exceptions/rtm_connect_error_schema_exception.rb +56 -0
  143. data/lib/slack_web_api/exceptions/stars_add_error_schema_exception.rb +56 -0
  144. data/lib/slack_web_api/exceptions/stars_list_error_schema_exception.rb +56 -0
  145. data/lib/slack_web_api/exceptions/stars_remove_error_schema_exception.rb +56 -0
  146. data/lib/slack_web_api/exceptions/team_access_logs_error_schema_exception.rb +56 -0
  147. data/lib/slack_web_api/exceptions/team_info_error_schema_exception.rb +56 -0
  148. data/lib/slack_web_api/exceptions/team_integration_logs_error_schema_exception.rb +56 -0
  149. data/lib/slack_web_api/exceptions/team_profile_get_error_schema_exception.rb +56 -0
  150. data/lib/slack_web_api/exceptions/usergroups_create_error_schema_exception.rb +56 -0
  151. data/lib/slack_web_api/exceptions/usergroups_disable_error_schema_exception.rb +56 -0
  152. data/lib/slack_web_api/exceptions/usergroups_enable_error_schema_exception.rb +56 -0
  153. data/lib/slack_web_api/exceptions/usergroups_list_error_schema_exception.rb +56 -0
  154. data/lib/slack_web_api/exceptions/usergroups_update_error_schema_exception.rb +56 -0
  155. data/lib/slack_web_api/exceptions/usergroups_users_list_error_schema_exception.rb +56 -0
  156. data/lib/slack_web_api/exceptions/usergroups_users_update_error_schema_exception.rb +56 -0
  157. data/lib/slack_web_api/exceptions/users_conversations_error_schema_exception.rb +56 -0
  158. data/lib/slack_web_api/exceptions/users_counts_error_schema_exception.rb +50 -0
  159. data/lib/slack_web_api/exceptions/users_delete_photo_error_schema_exception.rb +56 -0
  160. data/lib/slack_web_api/exceptions/users_identity_error_schema_exception.rb +56 -0
  161. data/lib/slack_web_api/exceptions/users_info_error_schema_exception.rb +56 -0
  162. data/lib/slack_web_api/exceptions/users_list_error_schema_exception.rb +56 -0
  163. data/lib/slack_web_api/exceptions/users_lookup_by_email_error_schema_exception.rb +56 -0
  164. data/lib/slack_web_api/exceptions/users_profile_get_error_schema_exception.rb +56 -0
  165. data/lib/slack_web_api/exceptions/users_profile_set_error_schema_exception.rb +56 -0
  166. data/lib/slack_web_api/exceptions/users_set_active_error_schema_exception.rb +56 -0
  167. data/lib/slack_web_api/exceptions/users_set_photo_error_schema_exception.rb +73 -0
  168. data/lib/slack_web_api/exceptions/users_set_presence_error_schema_exception.rb +56 -0
  169. data/lib/slack_web_api/http/api_response.rb +19 -0
  170. data/lib/slack_web_api/http/auth/oauth_2.rb +162 -0
  171. data/lib/slack_web_api/http/http_call_back.rb +10 -0
  172. data/lib/slack_web_api/http/http_method_enum.rb +10 -0
  173. data/lib/slack_web_api/http/http_request.rb +10 -0
  174. data/lib/slack_web_api/http/http_response.rb +10 -0
  175. data/lib/slack_web_api/http/proxy_settings.rb +22 -0
  176. data/lib/slack_web_api/logging/configuration/api_logging_configuration.rb +186 -0
  177. data/lib/slack_web_api/logging/sdk_logger.rb +17 -0
  178. data/lib/slack_web_api/models/admin_conversations_archive_error_enum.rb +60 -0
  179. data/lib/slack_web_api/models/admin_conversations_archive_schema.rb +71 -0
  180. data/lib/slack_web_api/models/admin_conversations_convert_to_private_error_enum.rb +65 -0
  181. data/lib/slack_web_api/models/admin_conversations_convert_to_private_schema.rb +71 -0
  182. data/lib/slack_web_api/models/admin_conversations_create_error_enum.rb +60 -0
  183. data/lib/slack_web_api/models/admin_conversations_create_schema.rb +82 -0
  184. data/lib/slack_web_api/models/admin_conversations_delete_error_enum.rb +60 -0
  185. data/lib/slack_web_api/models/admin_conversations_delete_schema.rb +71 -0
  186. data/lib/slack_web_api/models/admin_conversations_disconnect_shared_error_enum.rb +80 -0
  187. data/lib/slack_web_api/models/admin_conversations_get_conversation_prefs_error_enum.rb +60 -0
  188. data/lib/slack_web_api/models/admin_conversations_get_conversation_prefs_schema.rb +82 -0
  189. data/lib/slack_web_api/models/admin_conversations_get_teams_error_enum.rb +60 -0
  190. data/lib/slack_web_api/models/admin_conversations_get_teams_schema.rb +92 -0
  191. data/lib/slack_web_api/models/admin_conversations_invite_error_enum.rb +56 -0
  192. data/lib/slack_web_api/models/admin_conversations_invite_schema.rb +71 -0
  193. data/lib/slack_web_api/models/admin_conversations_rename_error_enum.rb +56 -0
  194. data/lib/slack_web_api/models/admin_conversations_rename_schema.rb +71 -0
  195. data/lib/slack_web_api/models/admin_conversations_rename_schema1.rb +71 -0
  196. data/lib/slack_web_api/models/admin_conversations_search_error_enum.rb +68 -0
  197. data/lib/slack_web_api/models/admin_conversations_search_schema.rb +91 -0
  198. data/lib/slack_web_api/models/admin_conversations_set_conversation_prefs_error_enum.rb +60 -0
  199. data/lib/slack_web_api/models/admin_conversations_set_conversation_prefs_schema.rb +71 -0
  200. data/lib/slack_web_api/models/admin_conversations_unarchive_error_enum.rb +60 -0
  201. data/lib/slack_web_api/models/admin_conversations_unarchive_schema.rb +71 -0
  202. data/lib/slack_web_api/models/api_method_users_get_presence.rb +133 -0
  203. data/lib/slack_web_api/models/api_permissions_scopes_list_success_schema.rb +80 -0
  204. data/lib/slack_web_api/models/api_test_success_schema.rb +71 -0
  205. data/lib/slack_web_api/models/app_home.rb +86 -0
  206. data/lib/slack_web_api/models/apps_permissions_info_error_enum.rb +104 -0
  207. data/lib/slack_web_api/models/apps_permissions_info_schema.rb +80 -0
  208. data/lib/slack_web_api/models/apps_permissions_request_error_enum.rb +120 -0
  209. data/lib/slack_web_api/models/apps_permissions_request_schema.rb +71 -0
  210. data/lib/slack_web_api/models/apps_permissions_resources_list_error_enum.rb +108 -0
  211. data/lib/slack_web_api/models/apps_permissions_resources_list_success_schema.rb +101 -0
  212. data/lib/slack_web_api/models/apps_uninstall_error_enum.rb +116 -0
  213. data/lib/slack_web_api/models/apps_uninstall_schema.rb +71 -0
  214. data/lib/slack_web_api/models/attachment.rb +125 -0
  215. data/lib/slack_web_api/models/auth_revoke_error_enum.rb +100 -0
  216. data/lib/slack_web_api/models/auth_revoke_schema.rb +80 -0
  217. data/lib/slack_web_api/models/auth_test_error_enum.rb +84 -0
  218. data/lib/slack_web_api/models/auth_test_success_schema.rb +136 -0
  219. data/lib/slack_web_api/models/base_model.rb +110 -0
  220. data/lib/slack_web_api/models/block_kit_block.rb +72 -0
  221. data/lib/slack_web_api/models/bot.rb +128 -0
  222. data/lib/slack_web_api/models/bot_profile_object.rb +126 -0
  223. data/lib/slack_web_api/models/bots_info_error_enum.rb +104 -0
  224. data/lib/slack_web_api/models/bots_info_schema.rb +80 -0
  225. data/lib/slack_web_api/models/can_thread.rb +85 -0
  226. data/lib/slack_web_api/models/channel.rb +86 -0
  227. data/lib/slack_web_api/models/channel_object.rb +382 -0
  228. data/lib/slack_web_api/models/chat_delete_error_enum.rb +112 -0
  229. data/lib/slack_web_api/models/chat_delete_scheduled_message_error_enum.rb +120 -0
  230. data/lib/slack_web_api/models/chat_delete_scheduled_message_schema.rb +71 -0
  231. data/lib/slack_web_api/models/chat_delete_success_schema.rb +88 -0
  232. data/lib/slack_web_api/models/chat_get_permalink_error_enum.rb +108 -0
  233. data/lib/slack_web_api/models/chat_get_permalink_success_schema.rb +88 -0
  234. data/lib/slack_web_api/models/chat_me_message_error_enum.rb +124 -0
  235. data/lib/slack_web_api/models/chat_me_message_schema.rb +91 -0
  236. data/lib/slack_web_api/models/chat_post_ephemeral_error_enum.rb +128 -0
  237. data/lib/slack_web_api/models/chat_post_ephemeral_success_schema.rb +80 -0
  238. data/lib/slack_web_api/models/chat_post_message_error_enum.rb +92 -0
  239. data/lib/slack_web_api/models/chat_post_message_success_schema.rb +96 -0
  240. data/lib/slack_web_api/models/chat_schedule_message_error_enum.rb +166 -0
  241. data/lib/slack_web_api/models/chat_schedule_message_success_schema.rb +108 -0
  242. data/lib/slack_web_api/models/chat_scheduled_messages_list_error_enum.rb +112 -0
  243. data/lib/slack_web_api/models/chat_scheduled_messages_list_schema.rb +100 -0
  244. data/lib/slack_web_api/models/chat_unfurl_error_enum.rb +120 -0
  245. data/lib/slack_web_api/models/chat_unfurl_success_schema.rb +71 -0
  246. data/lib/slack_web_api/models/chat_update_error_enum.rb +128 -0
  247. data/lib/slack_web_api/models/chat_update_success_schema.rb +105 -0
  248. data/lib/slack_web_api/models/conversations_archive_error_enum.rb +133 -0
  249. data/lib/slack_web_api/models/conversations_archive_success_schema.rb +71 -0
  250. data/lib/slack_web_api/models/conversations_close_error_enum.rb +101 -0
  251. data/lib/slack_web_api/models/conversations_close_success_schema.rb +93 -0
  252. data/lib/slack_web_api/models/conversations_create_error_enum.rb +133 -0
  253. data/lib/slack_web_api/models/conversations_create_success_schema.rb +80 -0
  254. data/lib/slack_web_api/models/conversations_history_error_enum.rb +96 -0
  255. data/lib/slack_web_api/models/conversations_history_success_schema.rb +127 -0
  256. data/lib/slack_web_api/models/conversations_info_error_enum.rb +92 -0
  257. data/lib/slack_web_api/models/conversations_info_success_schema.rb +80 -0
  258. data/lib/slack_web_api/models/conversations_invite_error_enum.rb +153 -0
  259. data/lib/slack_web_api/models/conversations_invite_error_schema.rb +80 -0
  260. data/lib/slack_web_api/models/conversations_join_error_enum.rb +121 -0
  261. data/lib/slack_web_api/models/conversations_join_success_schema.rb +102 -0
  262. data/lib/slack_web_api/models/conversations_kick_error_enum.rb +121 -0
  263. data/lib/slack_web_api/models/conversations_kick_success_schema.rb +71 -0
  264. data/lib/slack_web_api/models/conversations_leave_error_enum.rb +129 -0
  265. data/lib/slack_web_api/models/conversations_leave_success_schema.rb +83 -0
  266. data/lib/slack_web_api/models/conversations_list_error_enum.rb +84 -0
  267. data/lib/slack_web_api/models/conversations_list_success_schema.rb +92 -0
  268. data/lib/slack_web_api/models/conversations_mark_error_enum.rb +105 -0
  269. data/lib/slack_web_api/models/conversations_mark_success_schema.rb +71 -0
  270. data/lib/slack_web_api/models/conversations_members_error_enum.rb +100 -0
  271. data/lib/slack_web_api/models/conversations_members_success_schema.rb +89 -0
  272. data/lib/slack_web_api/models/conversations_open_error_enum.rb +121 -0
  273. data/lib/slack_web_api/models/conversations_open_success_schema.rb +102 -0
  274. data/lib/slack_web_api/models/conversations_rename_error_enum.rb +129 -0
  275. data/lib/slack_web_api/models/conversations_rename_success_schema.rb +80 -0
  276. data/lib/slack_web_api/models/conversations_replies_error_enum.rb +96 -0
  277. data/lib/slack_web_api/models/conversations_replies_success_schema.rb +90 -0
  278. data/lib/slack_web_api/models/conversations_set_purpose_error_enum.rb +113 -0
  279. data/lib/slack_web_api/models/conversations_set_purpose_success_schema.rb +80 -0
  280. data/lib/slack_web_api/models/conversations_set_topic_success_schema.rb +80 -0
  281. data/lib/slack_web_api/models/conversations_unarchive_error_enum.rb +121 -0
  282. data/lib/slack_web_api/models/conversations_unarchive_success_schema.rb +71 -0
  283. data/lib/slack_web_api/models/current.rb +82 -0
  284. data/lib/slack_web_api/models/default_success_template.rb +72 -0
  285. data/lib/slack_web_api/models/dialog_open_error_enum.rb +136 -0
  286. data/lib/slack_web_api/models/dialog_open_schema.rb +71 -0
  287. data/lib/slack_web_api/models/dnd_end_dnd_error_enum.rb +108 -0
  288. data/lib/slack_web_api/models/dnd_end_dnd_schema.rb +71 -0
  289. data/lib/slack_web_api/models/dnd_end_snooze_error_enum.rb +112 -0
  290. data/lib/slack_web_api/models/dnd_end_snooze_schema.rb +111 -0
  291. data/lib/slack_web_api/models/dnd_info_error_enum.rb +104 -0
  292. data/lib/slack_web_api/models/dnd_info_schema.rb +136 -0
  293. data/lib/slack_web_api/models/dnd_set_snooze_error_enum.rb +116 -0
  294. data/lib/slack_web_api/models/dnd_set_snooze_schema.rb +102 -0
  295. data/lib/slack_web_api/models/errors_is_returned_when_an_error_associates_an_user.rb +90 -0
  296. data/lib/slack_web_api/models/external_org_migrations.rb +91 -0
  297. data/lib/slack_web_api/models/file_comment_object.rb +176 -0
  298. data/lib/slack_web_api/models/file_object.rb +790 -0
  299. data/lib/slack_web_api/models/files_comments_delete_error_enum.rb +92 -0
  300. data/lib/slack_web_api/models/files_comments_delete_schema.rb +71 -0
  301. data/lib/slack_web_api/models/files_delete_error_enum.rb +100 -0
  302. data/lib/slack_web_api/models/files_delete_schema.rb +71 -0
  303. data/lib/slack_web_api/models/files_info_error_enum.rb +100 -0
  304. data/lib/slack_web_api/models/files_info_schema.rb +133 -0
  305. data/lib/slack_web_api/models/files_list_error_enum.rb +100 -0
  306. data/lib/slack_web_api/models/files_list_schema.rb +97 -0
  307. data/lib/slack_web_api/models/files_revoke_public_url_error_enum.rb +112 -0
  308. data/lib/slack_web_api/models/files_revoke_public_url_schema.rb +80 -0
  309. data/lib/slack_web_api/models/files_shared_public_url_error_enum.rb +116 -0
  310. data/lib/slack_web_api/models/files_shared_public_url_schema.rb +80 -0
  311. data/lib/slack_web_api/models/files_upload_error_enum.rb +108 -0
  312. data/lib/slack_web_api/models/files_upload_schema.rb +80 -0
  313. data/lib/slack_web_api/models/group.rb +86 -0
  314. data/lib/slack_web_api/models/icons.rb +90 -0
  315. data/lib/slack_web_api/models/icons1.rb +85 -0
  316. data/lib/slack_web_api/models/im.rb +86 -0
  317. data/lib/slack_web_api/models/info.rb +116 -0
  318. data/lib/slack_web_api/models/log.rb +168 -0
  319. data/lib/slack_web_api/models/login.rb +158 -0
  320. data/lib/slack_web_api/models/message.rb +128 -0
  321. data/lib/slack_web_api/models/message_object.rb +552 -0
  322. data/lib/slack_web_api/models/message_object1.rb +94 -0
  323. data/lib/slack_web_api/models/migration_exchange_error_enum.rb +108 -0
  324. data/lib/slack_web_api/models/migration_exchange_success_schema.rb +111 -0
  325. data/lib/slack_web_api/models/mpim.rb +86 -0
  326. data/lib/slack_web_api/models/mself.rb +82 -0
  327. data/lib/slack_web_api/models/oauth_provider_error.rb +62 -0
  328. data/lib/slack_web_api/models/oauth_scope.rb +296 -0
  329. data/lib/slack_web_api/models/oauth_token.rb +96 -0
  330. data/lib/slack_web_api/models/objs_enterprise_user.rb +119 -0
  331. data/lib/slack_web_api/models/objs_icon.rb +147 -0
  332. data/lib/slack_web_api/models/objs_primary_owner.rb +82 -0
  333. data/lib/slack_web_api/models/objs_reminder.rb +129 -0
  334. data/lib/slack_web_api/models/objs_team_profile_field.rb +154 -0
  335. data/lib/slack_web_api/models/objs_team_profile_field_option.rb +112 -0
  336. data/lib/slack_web_api/models/objs_user_profile_short.rb +174 -0
  337. data/lib/slack_web_api/models/paging_object.rb +121 -0
  338. data/lib/slack_web_api/models/pins_add_error_enum.rb +120 -0
  339. data/lib/slack_web_api/models/pins_add_schema.rb +71 -0
  340. data/lib/slack_web_api/models/pins_list_error_enum.rb +92 -0
  341. data/lib/slack_web_api/models/pins_remove_error_enum.rb +116 -0
  342. data/lib/slack_web_api/models/pins_remove_schema.rb +71 -0
  343. data/lib/slack_web_api/models/plan.rb +44 -0
  344. data/lib/slack_web_api/models/prefs.rb +82 -0
  345. data/lib/slack_web_api/models/prefs1.rb +86 -0
  346. data/lib/slack_web_api/models/profile.rb +82 -0
  347. data/lib/slack_web_api/models/profile1.rb +146 -0
  348. data/lib/slack_web_api/models/purpose.rb +90 -0
  349. data/lib/slack_web_api/models/reaction_object.rb +90 -0
  350. data/lib/slack_web_api/models/reactions_add_error_enum.rb +116 -0
  351. data/lib/slack_web_api/models/reactions_add_schema.rb +71 -0
  352. data/lib/slack_web_api/models/reactions_get_error_enum.rb +104 -0
  353. data/lib/slack_web_api/models/reactions_list_error_enum.rb +96 -0
  354. data/lib/slack_web_api/models/reactions_list_schema.rb +102 -0
  355. data/lib/slack_web_api/models/reactions_remove_error_enum.rb +120 -0
  356. data/lib/slack_web_api/models/reactions_remove_schema.rb +71 -0
  357. data/lib/slack_web_api/models/reminders_add_error_enum.rb +128 -0
  358. data/lib/slack_web_api/models/reminders_add_schema.rb +80 -0
  359. data/lib/slack_web_api/models/reminders_complete_error_enum.rb +116 -0
  360. data/lib/slack_web_api/models/reminders_complete_schema.rb +71 -0
  361. data/lib/slack_web_api/models/reminders_delete_error_enum.rb +108 -0
  362. data/lib/slack_web_api/models/reminders_delete_schema.rb +71 -0
  363. data/lib/slack_web_api/models/reminders_info_schema.rb +80 -0
  364. data/lib/slack_web_api/models/reminders_list_schema.rb +89 -0
  365. data/lib/slack_web_api/models/resource.rb +85 -0
  366. data/lib/slack_web_api/models/resources_in_info_from_apps_permissions_info.rb +94 -0
  367. data/lib/slack_web_api/models/response_metadata.rb +74 -0
  368. data/lib/slack_web_api/models/response_metadata3.rb +75 -0
  369. data/lib/slack_web_api/models/rtm_connect_error_enum.rb +96 -0
  370. data/lib/slack_web_api/models/rtm_connect_schema.rb +96 -0
  371. data/lib/slack_web_api/models/scheduled_message.rb +110 -0
  372. data/lib/slack_web_api/models/scopes.rb +134 -0
  373. data/lib/slack_web_api/models/shares.rb +85 -0
  374. data/lib/slack_web_api/models/sso_provider.rb +95 -0
  375. data/lib/slack_web_api/models/stars_add_error_enum.rb +128 -0
  376. data/lib/slack_web_api/models/stars_add_schema.rb +71 -0
  377. data/lib/slack_web_api/models/stars_list_schema.rb +90 -0
  378. data/lib/slack_web_api/models/stars_remove_error_enum.rb +128 -0
  379. data/lib/slack_web_api/models/stars_remove_schema.rb +71 -0
  380. data/lib/slack_web_api/models/subteam_usergroup_object.rb +260 -0
  381. data/lib/slack_web_api/models/team.rb +83 -0
  382. data/lib/slack_web_api/models/team1.rb +90 -0
  383. data/lib/slack_web_api/models/team_access_logs_error_enum.rb +112 -0
  384. data/lib/slack_web_api/models/team_access_logs_schema.rb +97 -0
  385. data/lib/slack_web_api/models/team_info_schema.rb +80 -0
  386. data/lib/slack_web_api/models/team_integration_logs_schema.rb +97 -0
  387. data/lib/slack_web_api/models/team_object.rb +368 -0
  388. data/lib/slack_web_api/models/team_profile_get_error_enum.rb +92 -0
  389. data/lib/slack_web_api/models/team_profile_get_success_schema.rb +80 -0
  390. data/lib/slack_web_api/models/topic.rb +90 -0
  391. data/lib/slack_web_api/models/type.rb +52 -0
  392. data/lib/slack_web_api/models/user_profile_object.rb +542 -0
  393. data/lib/slack_web_api/models/usergroups_create_error_enum.rb +112 -0
  394. data/lib/slack_web_api/models/usergroups_create_schema.rb +80 -0
  395. data/lib/slack_web_api/models/usergroups_disable_schema.rb +80 -0
  396. data/lib/slack_web_api/models/usergroups_enable_error_enum.rb +116 -0
  397. data/lib/slack_web_api/models/usergroups_enable_schema.rb +80 -0
  398. data/lib/slack_web_api/models/usergroups_list_schema.rb +89 -0
  399. data/lib/slack_web_api/models/usergroups_update_error_enum.rb +120 -0
  400. data/lib/slack_web_api/models/usergroups_update_schema.rb +80 -0
  401. data/lib/slack_web_api/models/usergroups_users_list_schema.rb +80 -0
  402. data/lib/slack_web_api/models/usergroups_users_update_schema.rb +80 -0
  403. data/lib/slack_web_api/models/users_conversations_error_enum.rb +117 -0
  404. data/lib/slack_web_api/models/users_conversations_success_schema.rb +93 -0
  405. data/lib/slack_web_api/models/users_delete_photo_schema.rb +71 -0
  406. data/lib/slack_web_api/models/users_info_error_enum.rb +92 -0
  407. data/lib/slack_web_api/models/users_info_success_schema.rb +80 -0
  408. data/lib/slack_web_api/models/users_list_error_enum.rb +100 -0
  409. data/lib/slack_web_api/models/users_list_schema.rb +102 -0
  410. data/lib/slack_web_api/models/users_lookup_by_email_error_enum.rb +100 -0
  411. data/lib/slack_web_api/models/users_lookup_by_email_success_schema.rb +80 -0
  412. data/lib/slack_web_api/models/users_profile_get_error_enum.rb +108 -0
  413. data/lib/slack_web_api/models/users_profile_get_schema.rb +80 -0
  414. data/lib/slack_web_api/models/users_profile_set_error_enum.rb +128 -0
  415. data/lib/slack_web_api/models/users_profile_set_schema.rb +100 -0
  416. data/lib/slack_web_api/models/users_set_active_error_enum.rb +100 -0
  417. data/lib/slack_web_api/models/users_set_active_schema.rb +71 -0
  418. data/lib/slack_web_api/models/users_set_photo_error_enum.rb +120 -0
  419. data/lib/slack_web_api/models/users_set_photo_schema.rb +80 -0
  420. data/lib/slack_web_api/models/users_set_presence_error_enum.rb +104 -0
  421. data/lib/slack_web_api/models/users_set_presence_schema.rb +71 -0
  422. data/lib/slack_web_api/models/who_can_post.rb +85 -0
  423. data/lib/slack_web_api/utilities/date_time_helper.rb +11 -0
  424. data/lib/slack_web_api/utilities/file_wrapper.rb +28 -0
  425. data/lib/slack_web_api.rb +532 -0
  426. metadata +509 -0
@@ -0,0 +1,141 @@
1
+ # slack_web_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module SlackWebApi
7
+ # DndApi
8
+ class DndApi < BaseApi
9
+ # Ends the current user's Do Not Disturb session immediately.
10
+ # @param [String] token Required parameter: Authentication token. Requires
11
+ # scope: `dnd:write`
12
+ # @return [ApiResponse] Complete http response with raw body and status code.
13
+ def dnd_end_dnd(token)
14
+ @api_call
15
+ .request(new_request_builder(HttpMethodEnum::POST,
16
+ '/dnd.endDnd',
17
+ Server::DEFAULT)
18
+ .header_param(new_parameter(token, key: 'token')
19
+ .is_required(true))
20
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
21
+ .header_param(new_parameter('application/json', key: 'accept'))
22
+ .auth(Single.new('slackAuth')))
23
+ .response(new_response_handler
24
+ .deserializer(APIHelper.method(:custom_type_deserializer))
25
+ .deserialize_into(DndEndDndSchema.method(:from_hash))
26
+ .is_api_response(true)
27
+ .local_error('default',
28
+ 'Typical error response',
29
+ DndEndDndErrorSchemaException))
30
+ .execute
31
+ end
32
+
33
+ # Ends the current user's snooze mode immediately.
34
+ # @param [String] token Required parameter: Authentication token. Requires
35
+ # scope: `dnd:write`
36
+ # @return [ApiResponse] Complete http response with raw body and status code.
37
+ def dnd_end_snooze(token)
38
+ @api_call
39
+ .request(new_request_builder(HttpMethodEnum::POST,
40
+ '/dnd.endSnooze',
41
+ Server::DEFAULT)
42
+ .header_param(new_parameter(token, key: 'token')
43
+ .is_required(true))
44
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
45
+ .header_param(new_parameter('application/json', key: 'accept'))
46
+ .auth(Single.new('slackAuth')))
47
+ .response(new_response_handler
48
+ .deserializer(APIHelper.method(:custom_type_deserializer))
49
+ .deserialize_into(DndEndSnoozeSchema.method(:from_hash))
50
+ .is_api_response(true)
51
+ .local_error('default',
52
+ 'Typical error response',
53
+ DndEndSnoozeErrorSchemaException))
54
+ .execute
55
+ end
56
+
57
+ # Retrieves a user's current Do Not Disturb status.
58
+ # @param [String] token Optional parameter: Authentication token. Requires
59
+ # scope: `dnd:read`
60
+ # @param [String] user Optional parameter: User to fetch status for
61
+ # (defaults to current user)
62
+ # @return [ApiResponse] Complete http response with raw body and status code.
63
+ def dnd_info(token: nil,
64
+ user: nil)
65
+ @api_call
66
+ .request(new_request_builder(HttpMethodEnum::GET,
67
+ '/dnd.info',
68
+ Server::DEFAULT)
69
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
70
+ .query_param(new_parameter(token, key: 'token'))
71
+ .query_param(new_parameter(user, key: 'user'))
72
+ .header_param(new_parameter('application/json', key: 'accept'))
73
+ .auth(Single.new('slackAuth')))
74
+ .response(new_response_handler
75
+ .deserializer(APIHelper.method(:custom_type_deserializer))
76
+ .deserialize_into(DndInfoSchema.method(:from_hash))
77
+ .is_api_response(true)
78
+ .local_error('default',
79
+ 'Typical error response',
80
+ DndInfoErrorSchemaException))
81
+ .execute
82
+ end
83
+
84
+ # Turns on Do Not Disturb mode for the current user, or changes its
85
+ # duration.
86
+ # @param [String] token Required parameter: Authentication token. Requires
87
+ # scope: `dnd:write`
88
+ # @param [String] num_minutes Required parameter: Number of minutes, from
89
+ # now, to snooze until.
90
+ # @return [ApiResponse] Complete http response with raw body and status code.
91
+ def dnd_set_snooze(token,
92
+ num_minutes)
93
+ @api_call
94
+ .request(new_request_builder(HttpMethodEnum::POST,
95
+ '/dnd.setSnooze',
96
+ Server::DEFAULT)
97
+ .form_param(new_parameter(token, key: 'token')
98
+ .is_required(true))
99
+ .form_param(new_parameter(num_minutes, key: 'num_minutes')
100
+ .is_required(true))
101
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
102
+ .header_param(new_parameter('application/json', key: 'accept'))
103
+ .auth(Single.new('slackAuth')))
104
+ .response(new_response_handler
105
+ .deserializer(APIHelper.method(:custom_type_deserializer))
106
+ .deserialize_into(DndSetSnoozeSchema.method(:from_hash))
107
+ .is_api_response(true)
108
+ .local_error('default',
109
+ 'Typical error response',
110
+ DndSetSnoozeErrorSchemaException))
111
+ .execute
112
+ end
113
+
114
+ # Retrieves the Do Not Disturb status for up to 50 users on a team.
115
+ # @param [String] token Optional parameter: Authentication token. Requires
116
+ # scope: `dnd:read`
117
+ # @param [String] users Optional parameter: Comma-separated list of users to
118
+ # fetch Do Not Disturb status for
119
+ # @return [ApiResponse] Complete http response with raw body and status code.
120
+ def dnd_team_info(token: nil,
121
+ users: nil)
122
+ @api_call
123
+ .request(new_request_builder(HttpMethodEnum::GET,
124
+ '/dnd.teamInfo',
125
+ Server::DEFAULT)
126
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
127
+ .query_param(new_parameter(token, key: 'token'))
128
+ .query_param(new_parameter(users, key: 'users'))
129
+ .header_param(new_parameter('application/json', key: 'accept'))
130
+ .auth(Single.new('slackAuth')))
131
+ .response(new_response_handler
132
+ .deserializer(APIHelper.method(:custom_type_deserializer))
133
+ .deserialize_into(DefaultSuccessTemplate.method(:from_hash))
134
+ .is_api_response(true)
135
+ .local_error('default',
136
+ 'Typical error response',
137
+ DefaultErrorTemplateException))
138
+ .execute
139
+ end
140
+ end
141
+ end
@@ -0,0 +1,33 @@
1
+ # slack_web_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module SlackWebApi
7
+ # EmojiApi
8
+ class EmojiApi < BaseApi
9
+ # Lists custom emoji for a team.
10
+ # @param [String] token Required parameter: Authentication token. Requires
11
+ # scope: `emoji:read`
12
+ # @return [ApiResponse] Complete http response with raw body and status code.
13
+ def emoji_list(token)
14
+ @api_call
15
+ .request(new_request_builder(HttpMethodEnum::GET,
16
+ '/emoji.list',
17
+ Server::DEFAULT)
18
+ .query_param(new_parameter(token, key: 'token')
19
+ .is_required(true))
20
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
21
+ .header_param(new_parameter('application/json', key: 'accept'))
22
+ .auth(Single.new('slackAuth')))
23
+ .response(new_response_handler
24
+ .deserializer(APIHelper.method(:custom_type_deserializer))
25
+ .deserialize_into(DefaultSuccessTemplate.method(:from_hash))
26
+ .is_api_response(true)
27
+ .local_error('default',
28
+ 'Typical error response',
29
+ DefaultErrorTemplateException))
30
+ .execute
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,244 @@
1
+ # slack_web_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module SlackWebApi
7
+ # FilesApi
8
+ class FilesApi < BaseApi
9
+ # Deletes a file.
10
+ # @param [String] token Optional parameter: Authentication token. Requires
11
+ # scope: `files:write:user`
12
+ # @param [String] file Optional parameter: ID of file to delete.
13
+ # @return [ApiResponse] Complete http response with raw body and status code.
14
+ def files_delete(token: nil,
15
+ file: nil)
16
+ @api_call
17
+ .request(new_request_builder(HttpMethodEnum::POST,
18
+ '/files.delete',
19
+ Server::DEFAULT)
20
+ .header_param(new_parameter(token, key: 'token'))
21
+ .form_param(new_parameter(file, key: 'file'))
22
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
23
+ .header_param(new_parameter('application/json', key: 'accept'))
24
+ .auth(Single.new('slackAuth')))
25
+ .response(new_response_handler
26
+ .deserializer(APIHelper.method(:custom_type_deserializer))
27
+ .deserialize_into(FilesDeleteSchema.method(:from_hash))
28
+ .is_api_response(true)
29
+ .local_error('default',
30
+ 'Typical error response',
31
+ FilesDeleteErrorSchemaException))
32
+ .execute
33
+ end
34
+
35
+ # Gets information about a file.
36
+ # @param [String] token Optional parameter: Authentication token. Requires
37
+ # scope: `files:read`
38
+ # @param [String] file Optional parameter: Specify a file by providing its
39
+ # ID.
40
+ # @param [String] count Optional parameter: TODO: type description here
41
+ # @param [String] page Optional parameter: TODO: type description here
42
+ # @param [Integer] limit Optional parameter: The maximum number of items to
43
+ # return. Fewer than the requested number of items may be returned, even if
44
+ # the end of the list hasn't been reached.
45
+ # @param [String] cursor Optional parameter: Parameter for pagination. File
46
+ # comments are paginated for a single file. Set `cursor` equal to the
47
+ # `next_cursor` attribute returned by the previous request's
48
+ # `response_metadata`. This parameter is optional, but pagination is
49
+ # mandatory: the default value simply fetches the first "page" of the
50
+ # collection of comments.
51
+ # @return [ApiResponse] Complete http response with raw body and status code.
52
+ def files_info(token: nil,
53
+ file: nil,
54
+ count: nil,
55
+ page: nil,
56
+ limit: nil,
57
+ cursor: nil)
58
+ @api_call
59
+ .request(new_request_builder(HttpMethodEnum::GET,
60
+ '/files.info',
61
+ Server::DEFAULT)
62
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
63
+ .query_param(new_parameter(token, key: 'token'))
64
+ .query_param(new_parameter(file, key: 'file'))
65
+ .query_param(new_parameter(count, key: 'count'))
66
+ .query_param(new_parameter(page, key: 'page'))
67
+ .query_param(new_parameter(limit, key: 'limit'))
68
+ .query_param(new_parameter(cursor, key: 'cursor'))
69
+ .header_param(new_parameter('application/json', key: 'accept'))
70
+ .auth(Single.new('slackAuth')))
71
+ .response(new_response_handler
72
+ .deserializer(APIHelper.method(:custom_type_deserializer))
73
+ .deserialize_into(FilesInfoSchema.method(:from_hash))
74
+ .is_api_response(true)
75
+ .local_error('default',
76
+ 'Typical error response',
77
+ FilesInfoErrorSchemaException))
78
+ .execute
79
+ end
80
+
81
+ # List for a team, in a channel, or from a user with applied filters.
82
+ # @param [String] token Optional parameter: Authentication token. Requires
83
+ # scope: `files:read`
84
+ # @param [String] user Optional parameter: Filter files created by a single
85
+ # user.
86
+ # @param [String] channel Optional parameter: Filter files appearing in a
87
+ # specific channel, indicated by its ID.
88
+ # @param [Float] ts_from Optional parameter: Filter files created after this
89
+ # timestamp (inclusive).
90
+ # @param [Float] ts_to Optional parameter: Filter files created before this
91
+ # timestamp (inclusive).
92
+ # @param [String] types Optional parameter: Filter files by type ([see
93
+ # below](#file_types)). You can pass multiple values in the types argument,
94
+ # like `types=spaces,snippets`.The default value is `all`, which does not
95
+ # filter the list.
96
+ # @param [String] count Optional parameter: TODO: type description here
97
+ # @param [String] page Optional parameter: TODO: type description here
98
+ # @param [TrueClass | FalseClass] show_files_hidden_by_limit Optional
99
+ # parameter: Show truncated file info for files hidden due to being too old,
100
+ # and the team who owns the file being over the file limit.
101
+ # @return [ApiResponse] Complete http response with raw body and status code.
102
+ def files_list(token: nil,
103
+ user: nil,
104
+ channel: nil,
105
+ ts_from: nil,
106
+ ts_to: nil,
107
+ types: nil,
108
+ count: nil,
109
+ page: nil,
110
+ show_files_hidden_by_limit: nil)
111
+ @api_call
112
+ .request(new_request_builder(HttpMethodEnum::GET,
113
+ '/files.list',
114
+ Server::DEFAULT)
115
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'Content-Type'))
116
+ .query_param(new_parameter(token, key: 'token'))
117
+ .query_param(new_parameter(user, key: 'user'))
118
+ .query_param(new_parameter(channel, key: 'channel'))
119
+ .query_param(new_parameter(ts_from, key: 'ts_from'))
120
+ .query_param(new_parameter(ts_to, key: 'ts_to'))
121
+ .query_param(new_parameter(types, key: 'types'))
122
+ .query_param(new_parameter(count, key: 'count'))
123
+ .query_param(new_parameter(page, key: 'page'))
124
+ .query_param(new_parameter(show_files_hidden_by_limit, key: 'show_files_hidden_by_limit'))
125
+ .header_param(new_parameter('application/json', key: 'accept'))
126
+ .auth(Single.new('slackAuth')))
127
+ .response(new_response_handler
128
+ .deserializer(APIHelper.method(:custom_type_deserializer))
129
+ .deserialize_into(FilesListSchema.method(:from_hash))
130
+ .is_api_response(true)
131
+ .local_error('default',
132
+ 'Typical error response',
133
+ FilesListErrorSchemaException))
134
+ .execute
135
+ end
136
+
137
+ # Revokes public/external sharing access for a file
138
+ # @param [String] token Optional parameter: Authentication token. Requires
139
+ # scope: `files:write:user`
140
+ # @param [String] file Optional parameter: File to revoke
141
+ # @return [ApiResponse] Complete http response with raw body and status code.
142
+ def files_revoke_public_url(token: nil,
143
+ file: nil)
144
+ @api_call
145
+ .request(new_request_builder(HttpMethodEnum::POST,
146
+ '/files.revokePublicURL',
147
+ Server::DEFAULT)
148
+ .header_param(new_parameter(token, key: 'token'))
149
+ .form_param(new_parameter(file, key: 'file'))
150
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
151
+ .header_param(new_parameter('application/json', key: 'accept'))
152
+ .auth(Single.new('slackAuth')))
153
+ .response(new_response_handler
154
+ .deserializer(APIHelper.method(:custom_type_deserializer))
155
+ .deserialize_into(FilesRevokePublicUrlSchema.method(:from_hash))
156
+ .is_api_response(true)
157
+ .local_error('default',
158
+ 'Typical error response',
159
+ FilesRevokePublicUrlErrorSchemaException))
160
+ .execute
161
+ end
162
+
163
+ # Enables a file for public/external sharing.
164
+ # @param [String] token Optional parameter: Authentication token. Requires
165
+ # scope: `files:write:user`
166
+ # @param [String] file Optional parameter: File to share
167
+ # @return [ApiResponse] Complete http response with raw body and status code.
168
+ def files_shared_public_url(token: nil,
169
+ file: nil)
170
+ @api_call
171
+ .request(new_request_builder(HttpMethodEnum::POST,
172
+ '/files.sharedPublicURL',
173
+ Server::DEFAULT)
174
+ .header_param(new_parameter(token, key: 'token'))
175
+ .form_param(new_parameter(file, key: 'file'))
176
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
177
+ .header_param(new_parameter('application/json', key: 'accept'))
178
+ .auth(Single.new('slackAuth')))
179
+ .response(new_response_handler
180
+ .deserializer(APIHelper.method(:custom_type_deserializer))
181
+ .deserialize_into(FilesSharedPublicUrlSchema.method(:from_hash))
182
+ .is_api_response(true)
183
+ .local_error('default',
184
+ 'Typical error response',
185
+ FilesSharedPublicUrlErrorSchemaException))
186
+ .execute
187
+ end
188
+
189
+ # Uploads or creates a file.
190
+ # @param [String] token Optional parameter: Authentication token. Requires
191
+ # scope: `files:write:user`
192
+ # @param [String] file Optional parameter: File contents via
193
+ # `multipart/form-data`. If omitting this parameter, you must submit
194
+ # `content`.
195
+ # @param [String] content Optional parameter: File contents via a POST
196
+ # variable. If omitting this parameter, you must provide a `file`.
197
+ # @param [String] filetype Optional parameter: A [file
198
+ # type](/types/file#file_types) identifier.
199
+ # @param [String] filename Optional parameter: Filename of file.
200
+ # @param [String] title Optional parameter: Title of file.
201
+ # @param [String] initial_comment Optional parameter: The message text
202
+ # introducing the file in specified `channels`.
203
+ # @param [String] channels Optional parameter: Comma-separated list of
204
+ # channel names or IDs where the file will be shared.
205
+ # @param [Float] thread_ts Optional parameter: Provide another message's
206
+ # `ts` value to upload this file as a reply. Never use a reply's `ts` value;
207
+ # use its parent instead.
208
+ # @return [ApiResponse] Complete http response with raw body and status code.
209
+ def files_upload(token: nil,
210
+ file: nil,
211
+ content: nil,
212
+ filetype: nil,
213
+ filename: nil,
214
+ title: nil,
215
+ initial_comment: nil,
216
+ channels: nil,
217
+ thread_ts: nil)
218
+ @api_call
219
+ .request(new_request_builder(HttpMethodEnum::POST,
220
+ '/files.upload',
221
+ Server::DEFAULT)
222
+ .form_param(new_parameter(token, key: 'token'))
223
+ .form_param(new_parameter(file, key: 'file'))
224
+ .form_param(new_parameter(content, key: 'content'))
225
+ .form_param(new_parameter(filetype, key: 'filetype'))
226
+ .form_param(new_parameter(filename, key: 'filename'))
227
+ .form_param(new_parameter(title, key: 'title'))
228
+ .form_param(new_parameter(initial_comment, key: 'initial_comment'))
229
+ .form_param(new_parameter(channels, key: 'channels'))
230
+ .form_param(new_parameter(thread_ts, key: 'thread_ts'))
231
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
232
+ .header_param(new_parameter('application/json', key: 'accept'))
233
+ .auth(Single.new('slackAuth')))
234
+ .response(new_response_handler
235
+ .deserializer(APIHelper.method(:custom_type_deserializer))
236
+ .deserialize_into(FilesUploadSchema.method(:from_hash))
237
+ .is_api_response(true)
238
+ .local_error('default',
239
+ 'Typical error response',
240
+ FilesUploadErrorSchemaException))
241
+ .execute
242
+ end
243
+ end
244
+ end
@@ -0,0 +1,38 @@
1
+ # slack_web_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module SlackWebApi
7
+ # FilesCommentsApi
8
+ class FilesCommentsApi < BaseApi
9
+ # Deletes an existing comment on a file.
10
+ # @param [String] token Optional parameter: Authentication token. Requires
11
+ # scope: `files:write:user`
12
+ # @param [String] file Optional parameter: File to delete a comment from.
13
+ # @param [String] id Optional parameter: The comment to delete.
14
+ # @return [ApiResponse] Complete http response with raw body and status code.
15
+ def files_comments_delete(token: nil,
16
+ file: nil,
17
+ id: nil)
18
+ @api_call
19
+ .request(new_request_builder(HttpMethodEnum::POST,
20
+ '/files.comments.delete',
21
+ Server::DEFAULT)
22
+ .header_param(new_parameter(token, key: 'token'))
23
+ .form_param(new_parameter(file, key: 'file'))
24
+ .form_param(new_parameter(id, key: 'id'))
25
+ .header_param(new_parameter('application/x-www-form-urlencoded', key: 'content-type'))
26
+ .header_param(new_parameter('application/json', key: 'accept'))
27
+ .auth(Single.new('slackAuth')))
28
+ .response(new_response_handler
29
+ .deserializer(APIHelper.method(:custom_type_deserializer))
30
+ .deserialize_into(FilesCommentsDeleteSchema.method(:from_hash))
31
+ .is_api_response(true)
32
+ .local_error('default',
33
+ 'Standard failure response when used with an invalid token',
34
+ FilesCommentsDeleteErrorSchemaException))
35
+ .execute
36
+ end
37
+ end
38
+ end