slack-ruby-client 3.2.0 → 3.3.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 (307) hide show
  1. checksums.yaml +4 -4
  2. data/.coveralls.yml +0 -0
  3. data/.github/FUNDING.yml +0 -0
  4. data/.github/dependabot.yml +0 -0
  5. data/.github/prompts/changelog-entries.prompt.yml +32 -0
  6. data/.github/workflows/danger-comment.yml +0 -0
  7. data/.github/workflows/danger.yml +0 -0
  8. data/.github/workflows/lint.yml +2 -0
  9. data/.github/workflows/test.yml +0 -0
  10. data/.github/workflows/update_api.yml +86 -6
  11. data/.gitignore +0 -0
  12. data/.gitmodules +0 -0
  13. data/.rspec +0 -0
  14. data/.rubocop.yml +2 -1
  15. data/.rubocop_todo.yml +13 -2
  16. data/.ruby-version +0 -0
  17. data/AGENTS.md +12 -0
  18. data/CHANGELOG.md +33 -0
  19. data/CONTRIBUTING.md +10 -1
  20. data/Dangerfile +0 -0
  21. data/Gemfile +17 -5
  22. data/LICENSE.md +0 -0
  23. data/README.md +47 -2
  24. data/RELEASING.md +2 -2
  25. data/Rakefile +7 -3
  26. data/SECURITY.md +0 -0
  27. data/UPGRADING.md +12 -0
  28. data/bin/commands/admin_analytics.rb +0 -0
  29. data/bin/commands/admin_analytics_messages.rb +2 -2
  30. data/bin/commands/admin_apps.rb +0 -0
  31. data/bin/commands/admin_apps_activities.rb +0 -0
  32. data/bin/commands/admin_apps_approved.rb +0 -0
  33. data/bin/commands/admin_apps_config.rb +0 -0
  34. data/bin/commands/admin_apps_mcp_servers.rb +21 -0
  35. data/bin/commands/admin_apps_mcp_servers_permissions.rb +33 -0
  36. data/bin/commands/admin_apps_permissions.rb +58 -0
  37. data/bin/commands/admin_apps_requests.rb +0 -0
  38. data/bin/commands/admin_apps_restricted.rb +0 -0
  39. data/bin/commands/admin_audit_anomaly_allow.rb +0 -0
  40. data/bin/commands/admin_auth_policy.rb +0 -0
  41. data/bin/commands/admin_barriers.rb +0 -0
  42. data/bin/commands/admin_conversations.rb +12 -2
  43. data/bin/commands/admin_conversations_ekm.rb +0 -0
  44. data/bin/commands/admin_conversations_restrictAccess.rb +0 -0
  45. data/bin/commands/admin_emoji.rb +0 -0
  46. data/bin/commands/admin_functions.rb +1 -1
  47. data/bin/commands/admin_functions_permissions.rb +0 -0
  48. data/bin/commands/admin_inviteRequests.rb +0 -0
  49. data/bin/commands/admin_inviteRequests_approved.rb +0 -0
  50. data/bin/commands/admin_inviteRequests_denied.rb +0 -0
  51. data/bin/commands/admin_roles.rb +0 -0
  52. data/bin/commands/admin_teams.rb +0 -0
  53. data/bin/commands/admin_teams_admins.rb +0 -0
  54. data/bin/commands/admin_teams_owners.rb +0 -0
  55. data/bin/commands/admin_teams_settings.rb +0 -0
  56. data/bin/commands/admin_usergroups.rb +74 -0
  57. data/bin/commands/admin_users.rb +0 -0
  58. data/bin/commands/admin_users_session.rb +0 -1
  59. data/bin/commands/admin_users_unsupportedVersions.rb +0 -0
  60. data/bin/commands/admin_workflows.rb +0 -0
  61. data/bin/commands/admin_workflows_collaborators.rb +0 -0
  62. data/bin/commands/admin_workflows_permissions.rb +0 -0
  63. data/bin/commands/admin_workflows_triggers_types_permissions.rb +0 -0
  64. data/bin/commands/agents_sessions.rb +38 -0
  65. data/bin/commands/api.rb +0 -0
  66. data/bin/commands/apps.rb +0 -0
  67. data/bin/commands/apps_activities.rb +0 -0
  68. data/bin/commands/apps_auth_external.rb +0 -0
  69. data/bin/commands/apps_connections.rb +0 -0
  70. data/bin/commands/apps_datastore.rb +0 -0
  71. data/bin/commands/apps_event_authorizations.rb +0 -0
  72. data/bin/commands/apps_icon.rb +0 -0
  73. data/bin/commands/apps_managed_permissions.rb +21 -0
  74. data/bin/commands/apps_manifest.rb +0 -0
  75. data/bin/commands/apps_user_connection.rb +0 -0
  76. data/bin/commands/assistant_search.rb +0 -0
  77. data/bin/commands/assistant_threads.rb +1 -1
  78. data/bin/commands/auth.rb +0 -0
  79. data/bin/commands/auth_teams.rb +0 -0
  80. data/bin/commands/blocks.rb +0 -0
  81. data/bin/commands/bookmarks.rb +0 -0
  82. data/bin/commands/bots.rb +0 -0
  83. data/bin/commands/calls.rb +0 -0
  84. data/bin/commands/calls_participants.rb +0 -0
  85. data/bin/commands/canvases.rb +12 -2
  86. data/bin/commands/canvases_access.rb +0 -0
  87. data/bin/commands/canvases_sections.rb +0 -0
  88. data/bin/commands/chat.rb +9 -6
  89. data/bin/commands/chat_scheduledMessages.rb +0 -0
  90. data/bin/commands/conversations.rb +1 -1
  91. data/bin/commands/conversations_canvases.rb +1 -1
  92. data/bin/commands/conversations_externalInvitePermissions.rb +0 -0
  93. data/bin/commands/conversations_requestSharedInvite.rb +0 -0
  94. data/bin/commands/dialog.rb +0 -0
  95. data/bin/commands/dnd.rb +0 -0
  96. data/bin/commands/emoji.rb +0 -0
  97. data/bin/commands/entity.rb +27 -0
  98. data/bin/commands/files.rb +3 -0
  99. data/bin/commands/files_comments.rb +0 -0
  100. data/bin/commands/files_remote.rb +0 -0
  101. data/bin/commands/functions.rb +0 -0
  102. data/bin/commands/functions_distributions_permissions.rb +0 -0
  103. data/bin/commands/functions_workflows_steps.rb +0 -0
  104. data/bin/commands/functions_workflows_steps_responses.rb +0 -0
  105. data/bin/commands/migration.rb +0 -0
  106. data/bin/commands/oauth.rb +0 -0
  107. data/bin/commands/oauth_v2.rb +21 -0
  108. data/bin/commands/oauth_v2_user.rb +0 -0
  109. data/bin/commands/openid_connect.rb +0 -0
  110. data/bin/commands/pins.rb +0 -0
  111. data/bin/commands/reactions.rb +0 -0
  112. data/bin/commands/reminders.rb +0 -0
  113. data/bin/commands/rtm.rb +0 -0
  114. data/bin/commands/search.rb +0 -0
  115. data/bin/commands/slackLists.rb +0 -0
  116. data/bin/commands/slackLists_access.rb +0 -0
  117. data/bin/commands/slackLists_download.rb +6 -0
  118. data/bin/commands/slackLists_items.rb +1 -0
  119. data/bin/commands/stars.rb +0 -0
  120. data/bin/commands/team.rb +0 -0
  121. data/bin/commands/team_billing.rb +0 -0
  122. data/bin/commands/team_externalTeams.rb +0 -0
  123. data/bin/commands/team_preferences.rb +0 -0
  124. data/bin/commands/team_profile.rb +0 -0
  125. data/bin/commands/tooling_tokens.rb +0 -0
  126. data/bin/commands/usergroups.rb +0 -0
  127. data/bin/commands/usergroups_users.rb +0 -0
  128. data/bin/commands/users.rb +1 -0
  129. data/bin/commands/users_admin.rb +0 -0
  130. data/bin/commands/users_discoverableContacts.rb +0 -0
  131. data/bin/commands/users_prefs.rb +0 -0
  132. data/bin/commands/users_profile.rb +0 -0
  133. data/bin/commands/views.rb +0 -0
  134. data/bin/commands/workflows_featured.rb +0 -0
  135. data/bin/commands/workflows_triggers_permissions.rb +0 -0
  136. data/bin/slack +5 -1
  137. data/examples/files_upload_v2/.env.example +0 -0
  138. data/examples/files_upload_v2/Gemfile +0 -0
  139. data/examples/files_upload_v2/README.md +0 -0
  140. data/examples/files_upload_v2/files_upload_v2.rb +1 -1
  141. data/examples/hi_web/Gemfile +0 -0
  142. data/examples/hi_web/hi.gif +0 -0
  143. data/examples/hi_web/hi.rb +1 -1
  144. data/examples/new_ticket/Gemfile +0 -0
  145. data/examples/new_ticket/new_ticket.rb +1 -1
  146. data/examples/oauth_v2/.env.example +0 -0
  147. data/examples/oauth_v2/Gemfile +0 -0
  148. data/examples/oauth_v2/README.md +0 -0
  149. data/examples/oauth_v2/oauth_v2.rb +6 -6
  150. data/lib/slack/config.rb +0 -0
  151. data/lib/slack/events/config.rb +1 -1
  152. data/lib/slack/events/request.rb +2 -2
  153. data/lib/slack/logger.rb +0 -0
  154. data/lib/slack/messages/formatting.rb +0 -0
  155. data/lib/slack/messages/message.rb +0 -0
  156. data/lib/slack/utils/security.rb +0 -0
  157. data/lib/slack/version.rb +1 -1
  158. data/lib/slack/web/api/endpoints/admin_analytics.rb +0 -0
  159. data/lib/slack/web/api/endpoints/admin_analytics_messages.rb +2 -2
  160. data/lib/slack/web/api/endpoints/admin_apps.rb +0 -0
  161. data/lib/slack/web/api/endpoints/admin_apps_activities.rb +0 -0
  162. data/lib/slack/web/api/endpoints/admin_apps_approved.rb +0 -0
  163. data/lib/slack/web/api/endpoints/admin_apps_config.rb +0 -0
  164. data/lib/slack/web/api/endpoints/admin_apps_mcp_servers.rb +31 -0
  165. data/lib/slack/web/api/endpoints/admin_apps_mcp_servers_permissions.rb +46 -0
  166. data/lib/slack/web/api/endpoints/admin_apps_permissions.rb +83 -0
  167. data/lib/slack/web/api/endpoints/admin_apps_requests.rb +0 -0
  168. data/lib/slack/web/api/endpoints/admin_apps_restricted.rb +0 -0
  169. data/lib/slack/web/api/endpoints/admin_audit_anomaly_allow.rb +0 -0
  170. data/lib/slack/web/api/endpoints/admin_auth_policy.rb +0 -0
  171. data/lib/slack/web/api/endpoints/admin_barriers.rb +0 -0
  172. data/lib/slack/web/api/endpoints/admin_conversations.rb +16 -1
  173. data/lib/slack/web/api/endpoints/admin_conversations_ekm.rb +0 -0
  174. data/lib/slack/web/api/endpoints/admin_conversations_restrictAccess.rb +0 -0
  175. data/lib/slack/web/api/endpoints/admin_emoji.rb +0 -1
  176. data/lib/slack/web/api/endpoints/admin_functions.rb +1 -1
  177. data/lib/slack/web/api/endpoints/admin_functions_permissions.rb +0 -0
  178. data/lib/slack/web/api/endpoints/admin_inviteRequests.rb +0 -0
  179. data/lib/slack/web/api/endpoints/admin_inviteRequests_approved.rb +0 -0
  180. data/lib/slack/web/api/endpoints/admin_inviteRequests_denied.rb +0 -0
  181. data/lib/slack/web/api/endpoints/admin_roles.rb +0 -0
  182. data/lib/slack/web/api/endpoints/admin_teams.rb +0 -0
  183. data/lib/slack/web/api/endpoints/admin_teams_admins.rb +0 -0
  184. data/lib/slack/web/api/endpoints/admin_teams_owners.rb +0 -0
  185. data/lib/slack/web/api/endpoints/admin_teams_settings.rb +0 -0
  186. data/lib/slack/web/api/endpoints/admin_usergroups.rb +111 -0
  187. data/lib/slack/web/api/endpoints/admin_users.rb +1 -0
  188. data/lib/slack/web/api/endpoints/admin_users_session.rb +0 -2
  189. data/lib/slack/web/api/endpoints/admin_users_unsupportedVersions.rb +0 -0
  190. data/lib/slack/web/api/endpoints/admin_workflows.rb +0 -0
  191. data/lib/slack/web/api/endpoints/admin_workflows_collaborators.rb +0 -0
  192. data/lib/slack/web/api/endpoints/admin_workflows_permissions.rb +0 -0
  193. data/lib/slack/web/api/endpoints/admin_workflows_triggers_types_permissions.rb +0 -0
  194. data/lib/slack/web/api/endpoints/agents_sessions.rb +54 -0
  195. data/lib/slack/web/api/endpoints/api.rb +0 -0
  196. data/lib/slack/web/api/endpoints/apps.rb +0 -0
  197. data/lib/slack/web/api/endpoints/apps_activities.rb +0 -0
  198. data/lib/slack/web/api/endpoints/apps_auth_external.rb +0 -0
  199. data/lib/slack/web/api/endpoints/apps_connections.rb +0 -0
  200. data/lib/slack/web/api/endpoints/apps_datastore.rb +0 -0
  201. data/lib/slack/web/api/endpoints/apps_event_authorizations.rb +0 -0
  202. data/lib/slack/web/api/endpoints/apps_icon.rb +0 -0
  203. data/lib/slack/web/api/endpoints/apps_managed_permissions.rb +27 -0
  204. data/lib/slack/web/api/endpoints/apps_manifest.rb +0 -0
  205. data/lib/slack/web/api/endpoints/apps_user_connection.rb +0 -0
  206. data/lib/slack/web/api/endpoints/assistant_search.rb +0 -0
  207. data/lib/slack/web/api/endpoints/assistant_threads.rb +1 -1
  208. data/lib/slack/web/api/endpoints/auth.rb +0 -0
  209. data/lib/slack/web/api/endpoints/auth_teams.rb +0 -0
  210. data/lib/slack/web/api/endpoints/blocks.rb +0 -0
  211. data/lib/slack/web/api/endpoints/bookmarks.rb +0 -0
  212. data/lib/slack/web/api/endpoints/bots.rb +0 -0
  213. data/lib/slack/web/api/endpoints/calls.rb +0 -0
  214. data/lib/slack/web/api/endpoints/calls_participants.rb +0 -0
  215. data/lib/slack/web/api/endpoints/canvases.rb +16 -2
  216. data/lib/slack/web/api/endpoints/canvases_access.rb +0 -0
  217. data/lib/slack/web/api/endpoints/canvases_sections.rb +0 -0
  218. data/lib/slack/web/api/endpoints/chat.rb +13 -9
  219. data/lib/slack/web/api/endpoints/chat_scheduledMessages.rb +0 -0
  220. data/lib/slack/web/api/endpoints/conversations.rb +1 -1
  221. data/lib/slack/web/api/endpoints/conversations_canvases.rb +1 -1
  222. data/lib/slack/web/api/endpoints/conversations_externalInvitePermissions.rb +0 -0
  223. data/lib/slack/web/api/endpoints/conversations_requestSharedInvite.rb +0 -0
  224. data/lib/slack/web/api/endpoints/dialog.rb +0 -0
  225. data/lib/slack/web/api/endpoints/dnd.rb +0 -0
  226. data/lib/slack/web/api/endpoints/emoji.rb +0 -0
  227. data/lib/slack/web/api/endpoints/entity.rb +48 -0
  228. data/lib/slack/web/api/endpoints/files.rb +7 -0
  229. data/lib/slack/web/api/endpoints/files_comments.rb +0 -0
  230. data/lib/slack/web/api/endpoints/files_remote.rb +0 -0
  231. data/lib/slack/web/api/endpoints/functions.rb +0 -0
  232. data/lib/slack/web/api/endpoints/functions_distributions_permissions.rb +0 -0
  233. data/lib/slack/web/api/endpoints/functions_workflows_steps.rb +0 -0
  234. data/lib/slack/web/api/endpoints/functions_workflows_steps_responses.rb +0 -0
  235. data/lib/slack/web/api/endpoints/migration.rb +0 -0
  236. data/lib/slack/web/api/endpoints/oauth.rb +0 -0
  237. data/lib/slack/web/api/endpoints/oauth_v2.rb +33 -0
  238. data/lib/slack/web/api/endpoints/oauth_v2_user.rb +0 -0
  239. data/lib/slack/web/api/endpoints/openid_connect.rb +0 -0
  240. data/lib/slack/web/api/endpoints/pins.rb +0 -0
  241. data/lib/slack/web/api/endpoints/reactions.rb +0 -0
  242. data/lib/slack/web/api/endpoints/reminders.rb +0 -0
  243. data/lib/slack/web/api/endpoints/rtm.rb +0 -0
  244. data/lib/slack/web/api/endpoints/search.rb +0 -0
  245. data/lib/slack/web/api/endpoints/slackLists.rb +0 -0
  246. data/lib/slack/web/api/endpoints/slackLists_access.rb +0 -0
  247. data/lib/slack/web/api/endpoints/slackLists_download.rb +12 -0
  248. data/lib/slack/web/api/endpoints/slackLists_items.rb +2 -0
  249. data/lib/slack/web/api/endpoints/stars.rb +0 -0
  250. data/lib/slack/web/api/endpoints/team.rb +0 -0
  251. data/lib/slack/web/api/endpoints/team_billing.rb +0 -0
  252. data/lib/slack/web/api/endpoints/team_externalTeams.rb +0 -0
  253. data/lib/slack/web/api/endpoints/team_preferences.rb +0 -0
  254. data/lib/slack/web/api/endpoints/team_profile.rb +0 -0
  255. data/lib/slack/web/api/endpoints/tooling_tokens.rb +0 -0
  256. data/lib/slack/web/api/endpoints/usergroups.rb +0 -0
  257. data/lib/slack/web/api/endpoints/usergroups_users.rb +0 -0
  258. data/lib/slack/web/api/endpoints/users.rb +2 -1
  259. data/lib/slack/web/api/endpoints/users_admin.rb +0 -0
  260. data/lib/slack/web/api/endpoints/users_discoverableContacts.rb +0 -0
  261. data/lib/slack/web/api/endpoints/users_prefs.rb +0 -0
  262. data/lib/slack/web/api/endpoints/users_profile.rb +0 -0
  263. data/lib/slack/web/api/endpoints/views.rb +0 -0
  264. data/lib/slack/web/api/endpoints/workflows_featured.rb +0 -0
  265. data/lib/slack/web/api/endpoints/workflows_triggers_permissions.rb +0 -0
  266. data/lib/slack/web/api/endpoints.rb +10 -0
  267. data/lib/slack/web/api/error.rb +0 -0
  268. data/lib/slack/web/api/errors/server_error.rb +1 -1
  269. data/lib/slack/web/api/errors/slack_error.rb +1 -1
  270. data/lib/slack/web/api/errors/too_many_requests_error.rb +1 -1
  271. data/lib/slack/web/api/errors.rb +126 -8
  272. data/lib/slack/web/api/helpers/files.rb +2 -2
  273. data/lib/slack/web/api/helpers.rb +0 -0
  274. data/lib/slack/web/api/mixins/conversations.id.rb +2 -1
  275. data/lib/slack/web/api/mixins/ids.id.rb +0 -0
  276. data/lib/slack/web/api/mixins/users.id.json +0 -0
  277. data/lib/slack/web/api/mixins/users.id.rb +2 -1
  278. data/lib/slack/web/api/mixins/users.search.json +0 -0
  279. data/lib/slack/web/api/mixins/users.search.rb +1 -1
  280. data/lib/slack/web/api/mixins.rb +0 -0
  281. data/lib/slack/web/api/options.rb +0 -0
  282. data/lib/slack/web/api/patches/.gitkeep +0 -0
  283. data/lib/slack/web/api/patches/files.default-filename.patch +12 -0
  284. data/lib/slack/web/api/schema/group.json +0 -0
  285. data/lib/slack/web/api/schema/method.json +0 -0
  286. data/lib/slack/web/api/templates/command.erb +0 -0
  287. data/lib/slack/web/api/templates/endpoints.erb +0 -0
  288. data/lib/slack/web/api/templates/errors.erb +0 -0
  289. data/lib/slack/web/api/templates/method.erb +0 -0
  290. data/lib/slack/web/api/templates/method_spec.erb +0 -0
  291. data/lib/slack/web/client.rb +29 -0
  292. data/lib/slack/web/config.rb +0 -0
  293. data/lib/slack/web/faraday/connection.rb +0 -0
  294. data/lib/slack/web/faraday/options.rb +0 -0
  295. data/lib/slack/web/faraday/request.rb +22 -2
  296. data/lib/slack/web/faraday/response/raise_error.rb +0 -0
  297. data/lib/slack/web/faraday/response/wrap_error.rb +0 -0
  298. data/lib/slack/web/pagination/cursor.rb +0 -0
  299. data/lib/slack-ruby-client.rb +0 -0
  300. data/lib/slack.rb +0 -0
  301. data/lib/slack_ruby_client.rb +0 -0
  302. data/lib/tasks/git.rake +0 -0
  303. data/lib/tasks/update.rake +0 -0
  304. data/lib/tasks/web.rake +0 -0
  305. data/slack-ruby-client.gemspec +0 -1
  306. data/slack.png +0 -0
  307. metadata +20 -17
@@ -0,0 +1,58 @@
1
+ # frozen_string_literal: true
2
+ # This file was auto-generated by lib/tasks/web.rake
3
+
4
+ module Slack
5
+ module Cli
6
+ class App
7
+ desc 'AdminAppsPermissions methods.'
8
+ command 'admin_apps_permissions' do |g|
9
+ g.desc 'Grant permission for entities to access an app that has its permission type set to named_entities'
10
+ g.long_desc %( Grant permission for entities to access an app that has its permission type set to named_entities )
11
+ g.command 'add' do |c|
12
+ c.flag 'app_id', desc: 'Encoded ID of the app.'
13
+ c.flag 'user_ids', desc: 'List of user IDs to allow for named_entities visibility.'
14
+ c.flag 'usergroup_ids', desc: 'List of encoded usergroup IDs.'
15
+ c.flag 'channel_ids', desc: "List of encoded channel IDs to add to the channel restriction list. Interpretation depends on the app's channel_restriction_mode, which is configured via the admin.apps.permissions.set method."
16
+ c.action do |_global_options, options, _args|
17
+ puts JSON.dump(@client.admin_apps_permissions_add(options))
18
+ end
19
+ end
20
+
21
+ g.desc 'Returns the permission type of an app and if applicable, includes the entities that have been granted access'
22
+ g.long_desc %( Returns the permission type of an app and if applicable, includes the entities that have been granted access )
23
+ g.command 'list' do |c|
24
+ c.flag 'app_id', desc: 'Encoded ID of the app.'
25
+ c.action do |_global_options, options, _args|
26
+ puts JSON.dump(@client.admin_apps_permissions_list(options))
27
+ end
28
+ end
29
+
30
+ g.desc "Revoke an entity's access to an app that has its permission type set to named_entities"
31
+ g.long_desc %( Revoke an entity's access to an app that has its permission type set to named_entities )
32
+ g.command 'remove' do |c|
33
+ c.flag 'app_id', desc: 'Encoded ID of the app.'
34
+ c.flag 'user_ids', desc: 'List of user IDs whose named_entities access will be revoked.'
35
+ c.flag 'usergroup_ids', desc: 'List of encoded usergroup IDs.'
36
+ c.flag 'channel_ids', desc: "List of encoded channel IDs to remove from the channel restriction list. Interpretation depends on the app's channel_restriction_mode, which is configured via the admin.apps.permissions.set method."
37
+ c.action do |_global_options, options, _args|
38
+ puts JSON.dump(@client.admin_apps_permissions_remove(options))
39
+ end
40
+ end
41
+
42
+ g.desc 'Set the permission type for who can access an app'
43
+ g.long_desc %( Set the permission type for who can access an app )
44
+ g.command 'set' do |c|
45
+ c.flag 'app_id', desc: 'Encoded ID of the app.'
46
+ c.flag 'permission_type', desc: 'The type of permission that defines who can access the app.'
47
+ c.flag 'user_ids', desc: 'List of user IDs to allow for named_entities visibility.'
48
+ c.flag 'usergroup_ids', desc: 'List of encoded usergroup IDs.'
49
+ c.flag 'channel_restriction_mode', desc: 'The mode that defines where the app can be used in channels.'
50
+ c.flag 'channel_ids', desc: 'List of encoded channel IDs for channel restrictions. Semantics depend on channel_restriction_mode: allowlist for specific_channels, exclusion list for all_channels_except.'
51
+ c.action do |_global_options, options, _args|
52
+ puts JSON.dump(@client.admin_apps_permissions_set(options))
53
+ end
54
+ end
55
+ end
56
+ end
57
+ end
58
+ end
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -43,8 +43,8 @@ module Slack
43
43
  end
44
44
  end
45
45
 
46
- g.desc 'Exclude channels from Slack AI in bulk'
47
- g.long_desc %( Exclude channels from Slack AI in bulk )
46
+ g.desc 'Exclude channels from Slack AI in bulk.'
47
+ g.long_desc %( Exclude channels from Slack AI in bulk. )
48
48
  g.command 'bulkSetExcludeFromSlackAi' do |c|
49
49
  c.flag 'channel_ids', desc: 'An array of channel IDs to exclude from Slack AI.'
50
50
  c.flag 'exclude', desc: 'Whether the channels should be excluded from Slack AI.'
@@ -53,6 +53,16 @@ module Slack
53
53
  end
54
54
  end
55
55
 
56
+ g.desc 'Set properties on channels in bulk.'
57
+ g.long_desc %( Set properties on channels in bulk. )
58
+ g.command 'bulkSetProperties' do |c|
59
+ c.flag 'channel_ids', desc: 'An array of channel IDs on which to set the property.'
60
+ c.flag 'property', desc: 'The property for this channel in a key value format. Only one property can be updated at a time.'
61
+ c.action do |_global_options, options, _args|
62
+ puts JSON.dump(@client.admin_conversations_bulkSetProperties(options))
63
+ end
64
+ end
65
+
56
66
  g.desc 'Convert a public channel to a private channel.'
57
67
  g.long_desc %( Convert a public channel to a private channel. )
58
68
  g.command 'convertToPrivate' do |c|
File without changes
File without changes
File without changes
@@ -11,7 +11,7 @@ module Slack
11
11
  g.command 'list' do |c|
12
12
  c.flag 'team_id', desc: 'The team context to retrieve functions from.'
13
13
  c.flag 'app_ids', desc: 'Comma-separated array of app IDs to get functions for; max 50.'
14
- c.flag 'include_non_distributed_functions', desc: 'Whether to also include functions that are not yet distributed to any users in the function count. This is needed for admins that are approving an app request and will only work if the team owns the app.'
14
+ c.flag 'include_non_distributed_functions', desc: 'Whether to also include functions that are not yet distributed to any users in the function list. This is needed for admins that are approving an app request and will only work if the team owns the app.'
15
15
  c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
16
16
  c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation. Must be between 1 and 1000, both inclusive.'
17
17
  c.action do |_global_options, options, _args|
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -28,6 +28,37 @@ module Slack
28
28
  end
29
29
  end
30
30
 
31
+ g.desc 'Add members to an existing organizational usergroup. This method is only available to Enterprise Grid organizations.'
32
+ g.long_desc %( Add members to an existing organizational usergroup. This method is only available to Enterprise Grid organizations. )
33
+ g.command 'addUsers' do |c|
34
+ c.flag 'id', desc: 'ID of the usergroup to add users to.'
35
+ c.flag 'users', desc: 'The encoded user IDs to add to the usergroup, provided as a JSON array or a comma-separated string.'
36
+ c.action do |_global_options, options, _args|
37
+ puts JSON.dump(@client.admin_usergroups_addUsers(options))
38
+ end
39
+ end
40
+
41
+ g.desc 'Create a new organizational usergroup. This method is only available to Enterprise Grid organizations.'
42
+ g.long_desc %( Create a new organizational usergroup. This method is only available to Enterprise Grid organizations. )
43
+ g.command 'create' do |c|
44
+ c.flag 'name', desc: 'Unique name for the usergroup.'
45
+ c.flag 'handle', desc: 'Optional handle used to mention the usergroup in channel, must be unique.'
46
+ c.flag 'purpose', desc: 'Optional purpose that describes what the usergroup is about.'
47
+ c.flag 'is_visible', desc: 'Configure whether or not this usergroup should be visible in the client.'
48
+ c.action do |_global_options, options, _args|
49
+ puts JSON.dump(@client.admin_usergroups_create(options))
50
+ end
51
+ end
52
+
53
+ g.desc 'Fetch an organizational usergroup.'
54
+ g.long_desc %( Fetch an organizational usergroup. )
55
+ g.command 'fetch' do |c|
56
+ c.flag 'id', desc: 'ID of the usergroup to fetch.'
57
+ c.action do |_global_options, options, _args|
58
+ puts JSON.dump(@client.admin_usergroups_fetch(options))
59
+ end
60
+ end
61
+
31
62
  g.desc 'List the channels linked to an org-level IDP group (user group).'
32
63
  g.long_desc %( List the channels linked to an org-level IDP group (user group). )
33
64
  g.command 'listChannels' do |c|
@@ -48,6 +79,49 @@ module Slack
48
79
  puts JSON.dump(@client.admin_usergroups_removeChannels(options))
49
80
  end
50
81
  end
82
+
83
+ g.desc 'Remove one or more default workspaces from an organization-wide IDP Group or Admin Group.'
84
+ g.long_desc %( Remove one or more default workspaces from an organization-wide IDP Group or Admin Group. )
85
+ g.command 'removeTeams' do |c|
86
+ c.flag 'usergroup_id', desc: 'An encoded usergroup (IDP Group) ID.'
87
+ c.flag 'team_ids', desc: 'A comma separated list of encoded team (workspace) IDs. Each workspace MUST belong to the organization associated with the token.'
88
+ c.action do |_global_options, options, _args|
89
+ puts JSON.dump(@client.admin_usergroups_removeTeams(options))
90
+ end
91
+ end
92
+
93
+ g.desc 'Remove members from an existing organizational usergroup. This method is only available to Enterprise Grid organizations.'
94
+ g.long_desc %( Remove members from an existing organizational usergroup. This method is only available to Enterprise Grid organizations. )
95
+ g.command 'removeUsers' do |c|
96
+ c.flag 'id', desc: 'ID of the usergroup to remove users from.'
97
+ c.flag 'users', desc: 'The encoded user IDs to remove from the usergroup, provided as a JSON array or a comma-separated string.'
98
+ c.action do |_global_options, options, _args|
99
+ puts JSON.dump(@client.admin_usergroups_removeUsers(options))
100
+ end
101
+ end
102
+
103
+ g.desc 'Update one or more properties of an existing organizational usergroup.'
104
+ g.long_desc %( Update one or more properties of an existing organizational usergroup. )
105
+ g.command 'update' do |c|
106
+ c.flag 'id', desc: 'ID of the usergroup to update.'
107
+ c.flag 'name', desc: 'The name of the group.'
108
+ c.flag 'handle', desc: 'The handle used for mentioning the group in a channel, must be unique.'
109
+ c.flag 'description', desc: "The usergroup's purpose or description."
110
+ c.flag 'is_visible', desc: 'Configure whether or not this usergroup should be visible in the client.'
111
+ c.action do |_global_options, options, _args|
112
+ puts JSON.dump(@client.admin_usergroups_update(options))
113
+ end
114
+ end
115
+
116
+ g.desc 'Add members to an existing organizational usergroup in bulk via CSV upload. This method is only available to Enterprise Grid organizations.'
117
+ g.long_desc %( Add members to an existing organizational usergroup in bulk via CSV upload. This method is only available to Enterprise Grid organizations. )
118
+ g.command 'uploadUsers' do |c|
119
+ c.flag 'id', desc: 'ID of the usergroup to upload users to.'
120
+ c.flag 'file', desc: 'Csv of users to upload in format member id, email.'
121
+ c.action do |_global_options, options, _args|
122
+ puts JSON.dump(@client.admin_usergroups_uploadUsers(options))
123
+ end
124
+ end
51
125
  end
52
126
  end
53
127
  end
File without changes
@@ -27,7 +27,6 @@ module Slack
27
27
  g.desc 'Revoke a single session for a user. The user will be forced to login to Slack.'
28
28
  g.long_desc %( Revoke a single session for a user. The user will be forced to login to Slack. )
29
29
  g.command 'invalidate' do |c|
30
- c.flag 'team_id', desc: 'ID of the workspace that the session belongs to.'
31
30
  c.flag 'user_id', desc: 'ID of the user that the session belongs to.'
32
31
  c.flag 'session_id', desc: 'ID of the session to invalidate.'
33
32
  c.action do |_global_options, options, _args|
File without changes
File without changes
File without changes
File without changes
@@ -0,0 +1,38 @@
1
+ # frozen_string_literal: true
2
+ # This file was auto-generated by lib/tasks/web.rake
3
+
4
+ module Slack
5
+ module Cli
6
+ class App
7
+ desc 'AgentsSessions methods.'
8
+ command 'agents_sessions' do |g|
9
+ g.desc 'Rename an agent session.'
10
+ g.long_desc %( Rename an agent session. )
11
+ g.command 'rename' do |c|
12
+ c.flag 'channel_id', desc: 'ID of the channel containing the agent session. Required for public channels.'
13
+ c.flag 'title', desc: 'New title for the agent session (1-200 characters). For a session channel, this also renames the channel.'
14
+ c.flag 'thread_ts', desc: 'Timestamp of the thread root message the session is scoped to. Required for thread-based sessions in regular channels and DMs. Must be omitted for session channels.'
15
+ c.action do |_global_options, options, _args|
16
+ puts JSON.dump(@client.agents_sessions_rename(options))
17
+ end
18
+ end
19
+
20
+ g.desc "Set an agent session's lifecycle status, creating the session if needed."
21
+ g.long_desc %( Set an agent session's lifecycle status, creating the session if needed. )
22
+ g.command 'setStatus' do |c|
23
+ c.flag 'channel_id', desc: 'ID of the channel containing the agent session. Required for public channels.'
24
+ c.flag 'status', desc: 'The lifecycle status to set.'
25
+ c.flag 'thread_ts', desc: 'Timestamp of the thread root message the session is scoped to. Required for thread-based sessions in regular channels and DMs. Must be omitted for session channels.'
26
+ c.flag 'title', desc: 'Title for the agent session (max 200 characters). Only used when creating a new session; ignored if the session already exists. To rename an existing session, use agents.sessions.rename.'
27
+ c.flag 'initiator_user_id', desc: 'The user who initiated the session. Only used when creating a new session; ignored if the session already exists. Must be a member of the channel.'
28
+ c.flag 'icon_emoji', desc: "Emoji to use as the agent's icon. Takes priority over icon_url. Remains in effect until you clear it (pass null) or set a new value. Requires the chat:write.customize scope."
29
+ c.flag 'icon_url', desc: "URL to an image to use as the agent's icon. Remains in effect until you clear it (pass null) or set a new value. Requires the chat:write.customize scope."
30
+ c.flag 'username', desc: 'Display name override for the agent (max 200 characters). Remains in effect until you clear it (pass null) or set a new value. Requires the chat:write.customize scope.'
31
+ c.action do |_global_options, options, _args|
32
+ puts JSON.dump(@client.agents_sessions_setStatus(options))
33
+ end
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
data/bin/commands/api.rb CHANGED
File without changes
data/bin/commands/apps.rb CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -0,0 +1,21 @@
1
+ # frozen_string_literal: true
2
+ # This file was auto-generated by lib/tasks/web.rake
3
+
4
+ module Slack
5
+ module Cli
6
+ class App
7
+ desc 'AppsManagedPermissions methods.'
8
+ command 'apps_managed_permissions' do |g|
9
+ g.desc "Set who can interact with a managed app. Lets the builder who created a managed app on a partner platform configure the app's permissions as themselves, using a user token from the manager app. Permissions can only be set before the app is installed: if the app is already installed, this method makes no change and returns the app's current permissions."
10
+ g.long_desc %( Set who can interact with a managed app. Lets the builder who created a managed app on a partner platform configure the app's permissions as themselves, using a user token from the manager app. Permissions can only be set before the app is installed: if the app is already installed, this method makes no change and returns the app's current permissions. )
11
+ g.command 'set' do |c|
12
+ c.flag 'app_id', desc: 'Encoded ID of the managed app to configure.'
13
+ c.flag 'permissions', desc: "Who can interact with the app. Use everyone to allow all members, or app_owner to restrict access to the app's owner."
14
+ c.action do |_global_options, options, _args|
15
+ puts JSON.dump(@client.apps_managed_permissions_set(options))
16
+ end
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
File without changes
File without changes
File without changes
@@ -25,7 +25,7 @@ module Slack
25
25
  g.long_desc %( Set suggested prompts for the given assistant thread )
26
26
  g.command 'setSuggestedPrompts' do |c|
27
27
  c.flag 'channel_id', desc: 'Channel ID containing the assistant thread.'
28
- c.flag 'thread_ts', desc: 'Message timestamp of the thread to set suggested prompts for.'
28
+ c.flag 'thread_ts', desc: 'Message timestamp of the thread to set suggested prompts for. If not provided, the prompts will be set for the latest message in the channel.'
29
29
  c.flag 'prompts', desc: 'Each prompt should be supplied with its title and message attribute.'
30
30
  c.flag 'title', desc: 'Title for the list of provided prompts. For example: Suggested Prompts, Related Questions.'
31
31
  c.action do |_global_options, options, _args|
data/bin/commands/auth.rb CHANGED
File without changes
File without changes
File without changes
File without changes
data/bin/commands/bots.rb CHANGED
File without changes
File without changes
File without changes
@@ -10,7 +10,7 @@ module Slack
10
10
  g.long_desc %( Create canvas for a user )
11
11
  g.command 'create' do |c|
12
12
  c.flag 'title', desc: 'Title of the newly created canvas.'
13
- c.flag 'document_content', desc: 'Structure describing the type and value of the content to create.'
13
+ c.flag 'document_content', desc: 'Structure describing the type and value of the content to create. The markdown content is limited to 1 MiB (1,048,576 characters).'
14
14
  c.flag 'channel_id', desc: 'Channel ID of the channel the canvas will be tabbed in. This is a required field for free teams.'
15
15
  c.action do |_global_options, options, _args|
16
16
  puts JSON.dump(@client.canvases_create(options))
@@ -30,11 +30,21 @@ module Slack
30
30
  g.long_desc %( Update an existing canvas )
31
31
  g.command 'edit' do |c|
32
32
  c.flag 'canvas_id', desc: 'Encoded ID of the canvas.'
33
- c.flag 'changes', desc: 'List of changes to apply on the specified canvas.'
33
+ c.flag 'changes', desc: 'List of changes to apply on the specified canvas. The markdown content of each change is limited to 1 MiB (1,048,576 characters).'
34
34
  c.action do |_global_options, options, _args|
35
35
  puts JSON.dump(@client.canvases_edit(options))
36
36
  end
37
37
  end
38
+
39
+ g.desc 'Get the content of a canvas as markdown (default) or HTML.'
40
+ g.long_desc %( Get the content of a canvas as markdown (default) or HTML. )
41
+ g.command 'getContent' do |c|
42
+ c.flag 'canvas_id', desc: 'Encoded ID of the canvas.'
43
+ c.flag 'content_type', desc: 'Format in which to return the canvas content. Defaults to markdown.'
44
+ c.action do |_global_options, options, _args|
45
+ puts JSON.dump(@client.canvases_getContent(options))
46
+ end
47
+ end
38
48
  end
39
49
  end
40
50
  end
File without changes
File without changes
data/bin/commands/chat.rb CHANGED
@@ -82,6 +82,7 @@ module Slack
82
82
  c.flag 'icon_url', desc: 'URL to an image to use as the icon for this message.'
83
83
  c.flag 'link_names', desc: 'Find and link channel names and usernames.'
84
84
  c.flag 'markdown_text', desc: 'Accepts message text formatted in markdown. This argument should not be used in conjunction with blocks or text. Limit this field to 12,000 characters.'
85
+ c.flag 'metadata', desc: 'JSON object with an entities array of work object entity metadata, presented as a URL-encoded string. Only entity metadata is supported: ephemeral messages are not persisted and never dispatch message_metadata_* events, so event_type/event_payload message metadata is ignored here. Each entity requires entity_type, entity_payload, external_ref, and url.'
85
86
  c.flag 'parse', desc: 'Change how messages are treated. Defaults to none. See below.'
86
87
  c.flag 'text', desc: 'How this field works and whether it is required depends on other fields you use in your API call. See below for more detail.'
87
88
  c.flag 'thread_ts', desc: "Provide another message's ts value to post this message in a thread. Avoid using a reply's ts value; use its parent's value instead. Ephemeral messages in threads are only shown if there is already an active thread."
@@ -113,6 +114,7 @@ module Slack
113
114
  c.flag 'unfurl_links', desc: 'Pass true to enable unfurling of primarily text-based content.'
114
115
  c.flag 'unfurl_media', desc: 'Pass false to disable unfurling of media content.'
115
116
  c.flag 'username', desc: "Set your bot's user name."
117
+ c.flag 'unfurl_app_links', desc: 'Pass true to unfurl links from installed apps, or false to prevent app links from unfurling. When omitted, app links follow the unfurl_links setting.'
116
118
  c.action do |_global_options, options, _args|
117
119
  puts JSON.dump(@client.chat_postMessage(options))
118
120
  end
@@ -143,13 +145,13 @@ module Slack
143
145
  g.desc 'Starts a new streaming conversation.'
144
146
  g.long_desc %( Starts a new streaming conversation. )
145
147
  g.command 'startStream' do |c|
146
- c.flag 'channel', desc: 'An encoded ID that represents a channel thread or DM.'
147
- c.flag 'chunks', desc: 'Array of streaming chunks.'
148
+ c.flag 'channel', desc: 'An encoded ID that represents a channel, thread, or DM.'
149
+ c.flag 'chunks', desc: 'Array of streaming chunks. Can include markdown text chunk objects, task update chunk objects, plan update chunks, or blocks chunks.'
148
150
  c.flag 'markdown_text', desc: 'Accepts message text formatted in markdown. Limit this field to 12,000 characters.'
149
- c.flag 'thread_ts', desc: "Provide another message's ts value to reply to. Streamed messages should always be replies to a user request."
151
+ c.flag 'thread_ts', desc: "Provide another message's ts value to reply to. Omit it to stream a top-level message instead of a thread reply; this is only supported in channels where the whole channel is one session, such as Slack Code, and returns invalid_thread_ts elsewhere. Passing '0' is equivalent to omitting it."
150
152
  c.flag 'recipient_user_id', desc: 'The encoded ID of the user to receive the streaming text. Required when streaming to channels.'
151
153
  c.flag 'recipient_team_id', desc: 'The encoded ID of the team the user receiving the streaming text belongs to. Required when streaming to channels.'
152
- c.flag 'task_display_mode', desc: "Specifies how tasks are displayed in the message. A timeline displays individual tasks with text in sequential order, plan displays all tasks together, with the first tasks's placement determining the placement of the rest of the tasks, and dense collapses consecutive tool calls into a single summarized task card."
154
+ c.flag 'task_display_mode', desc: 'Specifies how tasks are displayed in the message. timeline task updates render as individual task cards interleaved with streamed text. plan task updates render together in a plan block.'
153
155
  c.flag 'icon_emoji', desc: 'Emoji to use as the icon for this message. Overrides icon_url.'
154
156
  c.flag 'icon_url', desc: 'Image URL to use as the icon for this message.'
155
157
  c.flag 'username', desc: "The bot's username to display."
@@ -162,11 +164,12 @@ module Slack
162
164
  g.long_desc %( Stops a streaming conversation. )
163
165
  g.command 'stopStream' do |c|
164
166
  c.flag 'channel', desc: 'An encoded ID that represents a channel, private group, or DM.'
165
- c.flag 'chunks', desc: 'Array of streaming chunks.'
167
+ c.flag 'chunks', desc: 'Array of streaming chunks. Can include markdown text chunk objects, task update chunk objects, plan update chunks, or blocks chunks.'
166
168
  c.flag 'ts', desc: 'The timestamp of the streaming message.'
167
169
  c.flag 'markdown_text', desc: 'Accepts message text formatted in markdown. Limit this field to 12,000 characters.'
168
170
  c.flag 'blocks', desc: 'A list of blocks that will be rendered at the bottom of the finalized message.'
169
171
  c.flag 'metadata', desc: 'JSON object with event_type and event_payload fields, presented as a URL-encoded string. Metadata you post to Slack is accessible to any app or user who is a member of that workspace.'
172
+ c.flag 'session_status', desc: 'The session status to set after stopping the stream.'
170
173
  c.action do |_global_options, options, _args|
171
174
  puts JSON.dump(@client.chat_stopStream(options))
172
175
  end
@@ -177,7 +180,7 @@ module Slack
177
180
  g.command 'unfurl' do |c|
178
181
  c.flag 'channel', desc: 'Channel ID of the message. Both channel and ts must be provided together, or unfurl_id and source must be provided together. Required for public channels.'
179
182
  c.flag 'ts', desc: 'Timestamp of the message to add unfurl behavior to. Required for public channels.'
180
- c.flag 'unfurls', desc: 'URL-encoded JSON map with keys set to URLs featured in the the message, pointing to their unfurl blocks or message attachments. Required for public channels.'
183
+ c.flag 'unfurls', desc: 'URL-encoded JSON map with keys set to URLs featured in the message, pointing to their unfurl blocks or message attachments. Required for public channels.'
181
184
  c.flag 'user_auth_message', desc: 'Provide a simply-formatted string to send as an ephemeral message to the user as invitation to authenticate further and enable full unfurling behavior. Provides two buttons, Not now or Never ask me again.'
182
185
  c.flag 'user_auth_required', desc: 'Set to true or 1 to indicate the user must install your Slack app to trigger unfurls for this domain.'
183
186
  c.flag 'user_auth_url', desc: 'Send users to this custom URL where they will complete authentication in your app to fully trigger unfurling. Value should be properly URL-encoded.'
File without changes
@@ -100,7 +100,7 @@ module Slack
100
100
  g.command 'invite' do |c|
101
101
  c.flag 'channel', desc: 'The ID of the public or private channel to invite user(s) to.'
102
102
  c.flag 'force', desc: 'When set to true and multiple user IDs are provided, continue inviting the valid ones while disregarding invalid IDs. Defaults to false.'
103
- c.flag 'users', desc: 'A comma separated list of user IDs. Up to 100 users may be listed.'
103
+ c.flag 'users', desc: 'A comma separated list of user IDs. Up to 1000 users may be listed.'
104
104
  c.action do |_global_options, options, _args|
105
105
  puts JSON.dump(@client.conversations_invite(options))
106
106
  end
@@ -10,7 +10,7 @@ module Slack
10
10
  g.long_desc %( Create a channel canvas for a channel )
11
11
  g.command 'create' do |c|
12
12
  c.flag 'channel_id', desc: 'Channel ID of the channel the canvas will be tabbed in.'
13
- c.flag 'document_content', desc: 'Structure describing the type and value of the content to create.'
13
+ c.flag 'document_content', desc: 'Structure describing the type and value of the content to create. The markdown content is limited to 1 MiB (1,048,576 characters).'
14
14
  c.flag 'title', desc: 'Title of the newly created canvas.'
15
15
  c.action do |_global_options, options, _args|
16
16
  puts JSON.dump(@client.conversations_canvases_create(options))
File without changes
File without changes
data/bin/commands/dnd.rb CHANGED
File without changes
File without changes
@@ -6,6 +6,33 @@ module Slack
6
6
  class App
7
7
  desc 'Entity methods.'
8
8
  command 'entity' do |g|
9
+ g.desc 'Acknowledge a comment mutation (edit, delete, or post) on a work object entity. Apps call this endpoint to confirm they have processed a comment action, and the backend emits a dedicated RTM event to the user.'
10
+ g.long_desc %( Acknowledge a comment mutation (edit, delete, or post) on a work object entity. Apps call this endpoint to confirm they have processed a comment action, and the backend emits a dedicated RTM event to the user. )
11
+ g.command 'acknowledgeCommentAction' do |c|
12
+ c.flag 'trigger_id', desc: 'A reference to the original user action that initiated the comment mutation.'
13
+ c.flag 'comment', desc: 'The full comment data. Required for edit and post actions. See the comment schema for the full list of properties.'
14
+ c.flag 'error', desc: 'Error message if the action failed in the app. When present, signals that the mutation could not be completed.'
15
+ c.action do |_global_options, options, _args|
16
+ puts JSON.dump(@client.entity_acknowledgeCommentAction(options))
17
+ end
18
+ end
19
+
20
+ g.desc 'Provide comments for work objects. Apps call this endpoint to send per-user flexpane comment data to the client.'
21
+ g.long_desc %( Provide comments for work objects. Apps call this endpoint to send per-user flexpane comment data to the client. )
22
+ g.command 'presentComments' do |c|
23
+ c.flag 'comments', desc: 'Array of comments to present to the user. See the comment schema for the full list of properties.'
24
+ c.flag 'cursor', desc: 'App supplied cursor used for pagination, will be sent in the next request for comments.'
25
+ c.flag 'can_post_comment', desc: 'Indicates whether the user has permissions to post comments.'
26
+ c.flag 'trigger_id', desc: 'A reference to the original user action that initiated the request.'
27
+ c.flag 'delete_action_id', desc: 'The block action id that will be sent when a delete request is initiated for a comment.'
28
+ c.flag 'user_auth_required', desc: 'Set to true (or 1) to indicate that the user must authenticate to see the comments data.'
29
+ c.flag 'user_auth_url', desc: 'A custom URL to which users are directed for authentication if required.'
30
+ c.flag 'error', desc: ''
31
+ c.action do |_global_options, options, _args|
32
+ puts JSON.dump(@client.entity_presentComments(options))
33
+ end
34
+ end
35
+
9
36
  g.desc 'Provide custom flexpane behavior for Work Objects. Apps call this endpoint to send per-user flexpane metadata to the client.'
10
37
  g.long_desc %( Provide custom flexpane behavior for Work Objects. Apps call this endpoint to send per-user flexpane metadata to the client. )
11
38
  g.command 'presentDetails' do |c|
@@ -15,6 +15,9 @@ module Slack
15
15
  c.flag 'channels', desc: 'Comma-separated string of channel IDs or user IDs where the file will be shared.'
16
16
  c.flag 'initial_comment', desc: 'The message text introducing the file in specified channels.'
17
17
  c.flag 'blocks', desc: 'A JSON-based array of structured rich text blocks, presented as a URL-encoded string. If the initial_comment field is provided, the blocks field is ignored.'
18
+ c.flag 'username', desc: "Set your bot's user name for the file share message. Requires the chat:write.customize scope."
19
+ c.flag 'icon_url', desc: 'URL to an image to use as the icon for the file share message. Requires the chat:write.customize scope.'
20
+ c.flag 'icon_emoji', desc: 'Emoji to use as the icon for the file share message. Overrides icon_url. Requires the chat:write.customize scope.'
18
21
  c.action do |_global_options, options, _args|
19
22
  puts JSON.dump(@client.files_completeUploadExternal(options))
20
23
  end
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -22,6 +22,27 @@ module Slack
22
22
  end
23
23
  end
24
24
 
25
+ g.desc 'Call this to rotate the secret on an old API token with a short secret. Must be paired with a call to oauth.v2.completeShortTokenRotation to confirm the change.'
26
+ g.long_desc %( Call this to rotate the secret on an old API token with a short secret. Must be paired with a call to oauth.v2.completeShortTokenRotation to confirm the change. )
27
+ g.command 'beginShortTokenRotation' do |c|
28
+ c.flag 'client_id', desc: 'Issued when you created your application. Must be the app the token being rotated was issued to.'
29
+ c.flag 'client_secret', desc: 'Issued when you created your application.'
30
+ c.action do |_global_options, options, _args|
31
+ puts JSON.dump(@client.oauth_v2_beginShortTokenRotation(options))
32
+ end
33
+ end
34
+
35
+ g.desc 'Call this to finish rotating the secret on an old API token with a short secret. Must be paired with a call to oauth.v2.beginShortTokenRotation to start the process.'
36
+ g.long_desc %( Call this to finish rotating the secret on an old API token with a short secret. Must be paired with a call to oauth.v2.beginShortTokenRotation to start the process. )
37
+ g.command 'completeShortTokenRotation' do |c|
38
+ c.flag 'client_id', desc: 'Issued when you created your application. Must be the app the token being rotated was issued to.'
39
+ c.flag 'client_secret', desc: 'Issued when you created your application.'
40
+ c.flag 'new_token', desc: 'The new xoxp token returned by oauth.v2.beginShortTokenRotation.'
41
+ c.action do |_global_options, options, _args|
42
+ puts JSON.dump(@client.oauth_v2_completeShortTokenRotation(options))
43
+ end
44
+ end
45
+
25
46
  g.desc 'Exchanges a legacy access token for a new expiring access token and refresh token'
26
47
  g.long_desc %( Exchanges a legacy access token for a new expiring access token and refresh token )
27
48
  g.command 'exchange' do |c|
File without changes
File without changes
data/bin/commands/pins.rb CHANGED
File without changes