slack-ruby-client 2.7.0 → 3.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.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +3 -10
- data/.rubocop_todo.yml +45 -67
- data/CHANGELOG.md +7 -0
- data/Gemfile +0 -9
- data/LICENSE.md +1 -1
- data/README.md +16 -219
- data/Rakefile +0 -1
- data/UPGRADING.md +4 -0
- data/bin/commands/admin_analytics.rb +1 -1
- data/bin/commands/admin_apps.rb +4 -4
- data/bin/commands/admin_apps_activities.rb +7 -7
- data/bin/commands/admin_apps_approved.rb +4 -4
- data/bin/commands/admin_apps_config.rb +3 -1
- data/bin/commands/admin_apps_requests.rb +5 -5
- data/bin/commands/admin_apps_restricted.rb +4 -4
- data/bin/commands/admin_audit_anomaly_allow.rb +6 -6
- data/bin/commands/admin_auth_policy.rb +5 -5
- data/bin/commands/admin_barriers.rb +3 -3
- data/bin/commands/admin_conversations.rb +15 -15
- data/bin/commands/admin_conversations_ekm.rb +2 -2
- data/bin/commands/admin_conversations_restrictAccess.rb +5 -5
- data/bin/commands/admin_emoji.rb +5 -5
- data/bin/commands/admin_functions.rb +1 -1
- data/bin/commands/admin_inviteRequests.rb +3 -3
- data/bin/commands/admin_inviteRequests_approved.rb +1 -1
- data/bin/commands/admin_inviteRequests_denied.rb +1 -1
- data/bin/commands/admin_roles.rb +3 -3
- data/bin/commands/admin_teams.rb +3 -3
- data/bin/commands/admin_teams_admins.rb +2 -2
- data/bin/commands/admin_teams_owners.rb +2 -2
- data/bin/commands/admin_teams_settings.rb +5 -5
- data/bin/commands/admin_usergroups.rb +4 -4
- data/bin/commands/admin_users.rb +12 -11
- data/bin/commands/admin_users_session.rb +6 -5
- data/bin/commands/admin_users_unsupportedVersions.rb +1 -1
- data/bin/commands/admin_workflows.rb +6 -6
- data/bin/commands/admin_workflows_collaborators.rb +2 -2
- data/bin/commands/apps_activities.rb +7 -7
- data/bin/commands/apps_auth_external.rb +1 -1
- data/bin/commands/apps_datastore.rb +12 -12
- data/bin/commands/apps_event_authorizations.rb +3 -3
- data/bin/commands/apps_manifest.rb +1 -1
- data/bin/commands/assistant_search.rb +18 -2
- data/bin/commands/assistant_threads.rb +2 -2
- data/bin/commands/auth.rb +1 -1
- data/bin/commands/auth_teams.rb +1 -1
- data/bin/commands/bookmarks.rb +6 -6
- data/bin/commands/calls.rb +5 -5
- data/bin/commands/canvases.rb +2 -2
- data/bin/commands/canvases_access.rb +1 -1
- data/bin/commands/chat.rb +23 -24
- data/bin/commands/conversations.rb +8 -8
- data/bin/commands/conversations_canvases.rb +1 -1
- data/bin/commands/conversations_externalInvitePermissions.rb +1 -1
- data/bin/commands/conversations_requestSharedInvite.rb +4 -4
- data/bin/commands/dnd.rb +1 -1
- data/bin/commands/files.rb +5 -5
- data/bin/commands/files_remote.rb +1 -1
- data/bin/commands/functions.rb +1 -1
- data/bin/commands/functions_distributions_permissions.rb +15 -15
- data/bin/commands/functions_workflows_steps.rb +2 -2
- data/bin/commands/functions_workflows_steps_responses.rb +2 -2
- data/bin/commands/migration.rb +2 -2
- data/bin/commands/oauth_v2.rb +1 -1
- data/bin/commands/openid_connect.rb +1 -1
- data/bin/commands/reactions.rb +3 -3
- data/bin/commands/reminders.rb +2 -2
- data/bin/commands/rtm.rb +15 -0
- data/bin/commands/search.rb +4 -4
- data/bin/commands/slackLists.rb +37 -0
- data/bin/commands/slackLists_access.rb +34 -0
- data/bin/commands/slackLists_download.rb +31 -0
- data/bin/commands/slackLists_items.rb +76 -0
- data/bin/commands/team.rb +1 -1
- data/bin/commands/team_externalTeams.rb +4 -4
- data/bin/commands/usergroups.rb +10 -10
- data/bin/commands/usergroups_users.rb +5 -5
- data/bin/commands/users.rb +1 -1
- data/bin/commands/users_discoverableContacts.rb +1 -1
- data/bin/commands/views.rb +4 -4
- data/bin/commands/workflows_featured.rb +50 -0
- data/bin/commands/workflows_triggers_permissions.rb +7 -7
- data/lib/slack/version.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_analytics.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_apps.rb +8 -8
- data/lib/slack/web/api/endpoints/admin_apps_activities.rb +14 -14
- data/lib/slack/web/api/endpoints/admin_apps_approved.rb +5 -7
- data/lib/slack/web/api/endpoints/admin_apps_config.rb +6 -3
- data/lib/slack/web/api/endpoints/admin_apps_requests.rb +7 -9
- data/lib/slack/web/api/endpoints/admin_apps_restricted.rb +5 -7
- data/lib/slack/web/api/endpoints/admin_audit_anomaly_allow.rb +5 -5
- data/lib/slack/web/api/endpoints/admin_auth_policy.rb +14 -14
- data/lib/slack/web/api/endpoints/admin_barriers.rb +8 -8
- data/lib/slack/web/api/endpoints/admin_conversations.rb +27 -28
- data/lib/slack/web/api/endpoints/admin_conversations_ekm.rb +4 -4
- data/lib/slack/web/api/endpoints/admin_conversations_restrictAccess.rb +11 -12
- data/lib/slack/web/api/endpoints/admin_emoji.rb +5 -5
- data/lib/slack/web/api/endpoints/admin_functions.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_inviteRequests.rb +6 -6
- data/lib/slack/web/api/endpoints/admin_inviteRequests_approved.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_inviteRequests_denied.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_roles.rb +8 -8
- data/lib/slack/web/api/endpoints/admin_teams.rb +3 -3
- data/lib/slack/web/api/endpoints/admin_teams_admins.rb +3 -4
- data/lib/slack/web/api/endpoints/admin_teams_owners.rb +2 -3
- data/lib/slack/web/api/endpoints/admin_teams_settings.rb +12 -13
- data/lib/slack/web/api/endpoints/admin_usergroups.rb +11 -11
- data/lib/slack/web/api/endpoints/admin_users.rb +27 -25
- data/lib/slack/web/api/endpoints/admin_users_session.rb +12 -9
- data/lib/slack/web/api/endpoints/admin_users_unsupportedVersions.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_workflows.rb +12 -12
- data/lib/slack/web/api/endpoints/admin_workflows_collaborators.rb +6 -6
- data/lib/slack/web/api/endpoints/apps_activities.rb +14 -14
- data/lib/slack/web/api/endpoints/apps_auth_external.rb +2 -2
- data/lib/slack/web/api/endpoints/apps_datastore.rb +8 -15
- data/lib/slack/web/api/endpoints/apps_event_authorizations.rb +0 -3
- data/lib/slack/web/api/endpoints/apps_manifest.rb +5 -5
- data/lib/slack/web/api/endpoints/assistant_search.rb +28 -3
- data/lib/slack/web/api/endpoints/assistant_threads.rb +6 -6
- data/lib/slack/web/api/endpoints/auth.rb +1 -1
- data/lib/slack/web/api/endpoints/auth_teams.rb +2 -2
- data/lib/slack/web/api/endpoints/bookmarks.rb +14 -14
- data/lib/slack/web/api/endpoints/calls.rb +10 -10
- data/lib/slack/web/api/endpoints/canvases.rb +4 -4
- data/lib/slack/web/api/endpoints/canvases_access.rb +3 -3
- data/lib/slack/web/api/endpoints/chat.rb +53 -55
- data/lib/slack/web/api/endpoints/conversations.rb +16 -16
- data/lib/slack/web/api/endpoints/conversations_canvases.rb +1 -1
- data/lib/slack/web/api/endpoints/conversations_externalInvitePermissions.rb +3 -3
- data/lib/slack/web/api/endpoints/conversations_requestSharedInvite.rb +8 -8
- data/lib/slack/web/api/endpoints/dnd.rb +2 -2
- data/lib/slack/web/api/endpoints/files.rb +11 -11
- data/lib/slack/web/api/endpoints/files_remote.rb +2 -2
- data/lib/slack/web/api/endpoints/functions.rb +3 -3
- data/lib/slack/web/api/endpoints/functions_distributions_permissions.rb +24 -24
- data/lib/slack/web/api/endpoints/functions_workflows_steps.rb +4 -4
- data/lib/slack/web/api/endpoints/functions_workflows_steps_responses.rb +4 -4
- data/lib/slack/web/api/endpoints/migration.rb +1 -1
- data/lib/slack/web/api/endpoints/oauth_v2.rb +2 -2
- data/lib/slack/web/api/endpoints/openid_connect.rb +2 -2
- data/lib/slack/web/api/endpoints/reactions.rb +6 -6
- data/lib/slack/web/api/endpoints/reminders.rb +4 -4
- data/lib/slack/web/api/endpoints/rtm.rb +23 -0
- data/lib/slack/web/api/endpoints/search.rb +8 -8
- data/lib/slack/web/api/endpoints/slackLists.rb +52 -0
- data/lib/slack/web/api/endpoints/slackLists_access.rb +47 -0
- data/lib/slack/web/api/endpoints/slackLists_download.rb +40 -0
- data/lib/slack/web/api/endpoints/slackLists_items.rb +116 -0
- data/lib/slack/web/api/endpoints/team.rb +3 -3
- data/lib/slack/web/api/endpoints/team_externalTeams.rb +8 -8
- data/lib/slack/web/api/endpoints/usergroups.rb +18 -18
- data/lib/slack/web/api/endpoints/usergroups_users.rb +8 -8
- data/lib/slack/web/api/endpoints/users.rb +2 -2
- data/lib/slack/web/api/endpoints/users_discoverableContacts.rb +0 -1
- data/lib/slack/web/api/endpoints/views.rb +9 -9
- data/lib/slack/web/api/endpoints/workflows_featured.rb +69 -0
- data/lib/slack/web/api/endpoints/workflows_triggers_permissions.rb +15 -15
- data/lib/slack/web/api/endpoints.rb +10 -2
- data/lib/slack/web/api/errors.rb +88 -46
- data/lib/slack/web/faraday/response/raise_error.rb +20 -2
- data/lib/slack-ruby-client.rb +0 -12
- data/lib/tasks/update.rake +0 -1
- data/lib/tasks/web.rake +0 -4
- metadata +12 -35
- data/.github/workflows/integration_test.yml +0 -45
- data/bin/commands/workflows.rb +0 -44
- data/examples/hi_real_time_and_web/Gemfile +0 -6
- data/examples/hi_real_time_and_web/hi.gif +0 -0
- data/examples/hi_real_time_and_web/hi.rb +0 -28
- data/examples/hi_real_time_async_async/Gemfile +0 -7
- data/examples/hi_real_time_async_async/Procfile +0 -2
- data/examples/hi_real_time_async_async/hi.rb +0 -41
- data/lib/slack/real_time/api/message.rb +0 -23
- data/lib/slack/real_time/api/message_id.rb +0 -15
- data/lib/slack/real_time/api/ping.rb +0 -19
- data/lib/slack/real_time/api/schema/event.json +0 -23
- data/lib/slack/real_time/api/templates/event_handler.erb +0 -8
- data/lib/slack/real_time/api/typing.rb +0 -20
- data/lib/slack/real_time/client.rb +0 -271
- data/lib/slack/real_time/concurrency/async.rb +0 -142
- data/lib/slack/real_time/concurrency.rb +0 -8
- data/lib/slack/real_time/config.rb +0 -62
- data/lib/slack/real_time/models/base.rb +0 -11
- data/lib/slack/real_time/models/bot.rb +0 -9
- data/lib/slack/real_time/models/channel.rb +0 -13
- data/lib/slack/real_time/models/im.rb +0 -9
- data/lib/slack/real_time/models/mpim.rb +0 -9
- data/lib/slack/real_time/models/team.rb +0 -9
- data/lib/slack/real_time/models/user.rb +0 -9
- data/lib/slack/real_time/models.rb +0 -9
- data/lib/slack/real_time/socket.rb +0 -118
- data/lib/slack/real_time/stores/base.rb +0 -47
- data/lib/slack/real_time/stores/starter.rb +0 -449
- data/lib/slack/real_time/stores/store.rb +0 -624
- data/lib/slack/real_time/stores.rb +0 -5
- data/lib/slack/web/api/endpoints/workflows.rb +0 -63
- data/lib/tasks/real_time.rake +0 -81
data/bin/commands/admin_apps.rb
CHANGED
@@ -10,9 +10,9 @@ module Slack
|
|
10
10
|
g.long_desc %( Approve an app for installation on a workspace. )
|
11
11
|
g.command 'approve' do |c|
|
12
12
|
c.flag 'app_id', desc: 'The id of the app to approve.'
|
13
|
-
c.flag 'enterprise_id', desc: 'The ID of the enterprise to approve the app on.'
|
14
13
|
c.flag 'request_id', desc: 'The id of the request to approve.'
|
15
14
|
c.flag 'team_id', desc: 'The ID of the workspace to approve the app on.'
|
15
|
+
c.flag 'enterprise_id', desc: 'The ID of the enterprise to approve the app on.'
|
16
16
|
c.action do |_global_options, options, _args|
|
17
17
|
puts JSON.dump(@client.admin_apps_approve(options))
|
18
18
|
end
|
@@ -22,8 +22,8 @@ module Slack
|
|
22
22
|
g.long_desc %( Clear an app resolution )
|
23
23
|
g.command 'clearResolution' do |c|
|
24
24
|
c.flag 'app_id', desc: 'The id of the app whose resolution you want to clear/undo.'
|
25
|
-
c.flag 'enterprise_id', desc: 'The enterprise to clear the app resolution from.'
|
26
25
|
c.flag 'team_id', desc: 'The workspace to clear the app resolution from.'
|
26
|
+
c.flag 'enterprise_id', desc: 'The enterprise to clear the app resolution from.'
|
27
27
|
c.action do |_global_options, options, _args|
|
28
28
|
puts JSON.dump(@client.admin_apps_clearResolution(options))
|
29
29
|
end
|
@@ -33,9 +33,9 @@ module Slack
|
|
33
33
|
g.long_desc %( Restrict an app for installation on a workspace. )
|
34
34
|
g.command 'restrict' do |c|
|
35
35
|
c.flag 'app_id', desc: 'The id of the app to restrict.'
|
36
|
-
c.flag 'enterprise_id', desc: 'The ID of the enterprise to approve the app on.'
|
37
36
|
c.flag 'request_id', desc: 'The id of the request to restrict.'
|
38
37
|
c.flag 'team_id', desc: 'The ID of the workspace to approve the app on.'
|
38
|
+
c.flag 'enterprise_id', desc: 'The ID of the enterprise to approve the app on.'
|
39
39
|
c.action do |_global_options, options, _args|
|
40
40
|
puts JSON.dump(@client.admin_apps_restrict(options))
|
41
41
|
end
|
@@ -45,8 +45,8 @@ module Slack
|
|
45
45
|
g.long_desc %( Uninstall an app from one or many workspaces, or an entire enterprise organization. )
|
46
46
|
g.command 'uninstall' do |c|
|
47
47
|
c.flag 'app_id', desc: 'The ID of the app to uninstall.'
|
48
|
-
c.flag 'enterprise_id', desc: 'The enterprise to completely uninstall the application from (across all workspaces). With an org-level token, this or team_ids is required.'
|
49
48
|
c.flag 'team_ids', desc: 'IDs of the teams to uninstall from (max 100). With an org-level token, this or enterprise_id is required.'
|
49
|
+
c.flag 'enterprise_id', desc: 'The enterprise to completely uninstall the application from (across all workspaces). With an org-level token, this or team_ids is required.'
|
50
50
|
c.action do |_global_options, options, _args|
|
51
51
|
puts JSON.dump(@client.admin_apps_uninstall(options))
|
52
52
|
end
|
@@ -10,18 +10,18 @@ module Slack
|
|
10
10
|
g.long_desc %( Get logs for a specified team/org )
|
11
11
|
g.command 'list' do |c|
|
12
12
|
c.flag 'app_id', desc: 'The ID of the app to get activities from.'
|
13
|
-
c.flag '
|
14
|
-
c.flag 'component_type', desc: 'The component type of log events to be returned. Acceptable values are events_api, workflows, functions and tables.'
|
13
|
+
c.flag 'team_id', desc: 'The team who owns this log.'
|
15
14
|
c.flag 'cursor', desc: "Paginate through collections of data by setting the cursor parameter to a next_cursor attribute returned by a previous request's response_metadata. See pagination for more detail."
|
16
15
|
c.flag 'limit', desc: 'The maximum number of items to return.'
|
17
|
-
c.flag 'log_event_type', desc: 'The event type of log events to be returned.'
|
18
|
-
c.flag 'max_date_created', desc: 'The latest timestamp of the log to retrieve (epoch microseconds).'
|
19
|
-
c.flag 'min_date_created', desc: 'The earliest timestamp of the log to retrieve (epoch microseconds).'
|
20
16
|
c.flag 'min_log_level', desc: 'The minimum log level of the log events to be returned. Defaults to info. Acceptable values (in order of relative importance from smallest to largest) are trace, debug, info, warn, error and fatal.'
|
21
|
-
c.flag '
|
17
|
+
c.flag 'log_event_type', desc: 'The event type of log events to be returned.'
|
22
18
|
c.flag 'source', desc: 'The source of log events to be returned. Acceptable values are slack and developer.'
|
23
|
-
c.flag '
|
19
|
+
c.flag 'component_type', desc: 'The component type of log events to be returned. Acceptable values are events_api, workflows, functions and tables.'
|
20
|
+
c.flag 'component_id', desc: 'The component ID of log events to be returned. Will be FnXXXXXX for functions, and WfXXXXXX for workflows.'
|
24
21
|
c.flag 'trace_id', desc: 'The trace ID of log events to be returned.'
|
22
|
+
c.flag 'min_date_created', desc: 'The earliest timestamp of the log to retrieve (epoch microseconds).'
|
23
|
+
c.flag 'max_date_created', desc: 'The latest timestamp of the log to retrieve (epoch microseconds).'
|
24
|
+
c.flag 'sort_direction', desc: 'The direction you want the data sorted by (always by timestamp).'
|
25
25
|
c.action do |_global_options, options, _args|
|
26
26
|
puts JSON.dump(@client.admin_apps_activities_list(options))
|
27
27
|
end
|
@@ -9,11 +9,11 @@ module Slack
|
|
9
9
|
g.desc 'List approved apps for an org or workspace.'
|
10
10
|
g.long_desc %( List approved apps for an org or workspace. )
|
11
11
|
g.command 'list' do |c|
|
12
|
-
c.flag 'certified', desc: 'Limit the results to only include certified apps. When false, no certified apps will appear in the result.'
|
13
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
-
c.flag 'enterprise_id', desc: '.'
|
15
12
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
16
|
-
c.flag '
|
13
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
+
c.flag 'team_id', desc: ''
|
15
|
+
c.flag 'enterprise_id', desc: ''
|
16
|
+
c.flag 'certified', desc: 'Limit the results to only include certified apps. When false, no certified apps will appear in the result.'
|
17
17
|
c.action do |_global_options, options, _args|
|
18
18
|
puts JSON.dump(@client.admin_apps_approved_list(options))
|
19
19
|
end
|
@@ -10,6 +10,7 @@ module Slack
|
|
10
10
|
g.long_desc %( Look up the app config for connectors by their IDs )
|
11
11
|
g.command 'lookup' do |c|
|
12
12
|
c.flag 'app_ids', desc: 'An array of app IDs to get app configs for.'
|
13
|
+
c.flag 'rich_link_preview_types', desc: 'return apps with the corresponding rich link preview layouts.'
|
13
14
|
c.action do |_global_options, options, _args|
|
14
15
|
puts JSON.dump(@client.admin_apps_config_lookup(options))
|
15
16
|
end
|
@@ -19,8 +20,9 @@ module Slack
|
|
19
20
|
g.long_desc %( Set the app config for a connector )
|
20
21
|
g.command 'set' do |c|
|
21
22
|
c.flag 'app_id', desc: 'The encoded app ID to set the app config for.'
|
22
|
-
c.flag 'domain_restrictions', desc: 'Domain restrictions for the app. Should be an object with two properties: urls and emails. Each is an array of strings, and each sets the allowed URLs and emails for connector authorization, respectively.'
|
23
23
|
c.flag 'workflow_auth_strategy', desc: 'The workflow auth permission. Can be one of builder_choice or end_user_only.'
|
24
|
+
c.flag 'rich_link_preview_type', desc: 'Indicates the app-level override for rich link preview. Unsupported for free teams.'
|
25
|
+
c.flag 'domain_restrictions', desc: 'Domain restrictions for the app. Should be an object with two properties: urls and emails. Each is an array of strings, and each sets the allowed URLs and emails for connector authorization, respectively.'
|
24
26
|
c.action do |_global_options, options, _args|
|
25
27
|
puts JSON.dump(@client.admin_apps_config_set(options))
|
26
28
|
end
|
@@ -10,8 +10,8 @@ module Slack
|
|
10
10
|
g.long_desc %( Cancel app request for team )
|
11
11
|
g.command 'cancel' do |c|
|
12
12
|
c.flag 'request_id', desc: 'The id of the request to cancel.'
|
13
|
-
c.flag 'enterprise_id', desc: 'The ID of the enterprise where this request belongs.'
|
14
13
|
c.flag 'team_id', desc: 'The ID of the workspace where this request belongs.'
|
14
|
+
c.flag 'enterprise_id', desc: 'The ID of the enterprise where this request belongs.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_apps_requests_cancel(options))
|
17
17
|
end
|
@@ -20,11 +20,11 @@ module Slack
|
|
20
20
|
g.desc 'List app requests for a team/workspace.'
|
21
21
|
g.long_desc %( List app requests for a team/workspace. )
|
22
22
|
g.command 'list' do |c|
|
23
|
-
c.flag 'certified', desc: 'Include requests for certified apps.'
|
24
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
25
|
-
c.flag 'enterprise_id', desc: '.'
|
26
23
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
27
|
-
c.flag '
|
24
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
25
|
+
c.flag 'team_id', desc: ''
|
26
|
+
c.flag 'enterprise_id', desc: ''
|
27
|
+
c.flag 'certified', desc: 'Include requests for certified apps.'
|
28
28
|
c.action do |_global_options, options, _args|
|
29
29
|
puts JSON.dump(@client.admin_apps_requests_list(options))
|
30
30
|
end
|
@@ -9,11 +9,11 @@ module Slack
|
|
9
9
|
g.desc 'List restricted apps for an org or workspace.'
|
10
10
|
g.long_desc %( List restricted apps for an org or workspace. )
|
11
11
|
g.command 'list' do |c|
|
12
|
-
c.flag 'certified', desc: 'Limit the results to only include certified apps. When false, no certified apps will appear in the result.'
|
13
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
-
c.flag 'enterprise_id', desc: '.'
|
15
12
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
16
|
-
c.flag '
|
13
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
+
c.flag 'team_id', desc: ''
|
15
|
+
c.flag 'enterprise_id', desc: ''
|
16
|
+
c.flag 'certified', desc: 'Limit the results to only include certified apps. When false, no certified apps will appear in the result.'
|
17
17
|
c.action do |_global_options, options, _args|
|
18
18
|
puts JSON.dump(@client.admin_apps_restricted_list(options))
|
19
19
|
end
|
@@ -6,19 +6,19 @@ module Slack
|
|
6
6
|
class App
|
7
7
|
desc 'AdminAuditAnomalyAllow methods.'
|
8
8
|
command 'admin_audit_anomaly_allow' do |g|
|
9
|
-
g.desc 'API to allow
|
10
|
-
g.long_desc %( API to allow
|
9
|
+
g.desc 'API to allow Enterprise org admins to read the allow list of IP blocks and ASNs from the enterprise configuration.'
|
10
|
+
g.long_desc %( API to allow Enterprise org admins to read the allow list of IP blocks and ASNs from the enterprise configuration. )
|
11
11
|
g.command 'getItem' do |c|
|
12
12
|
c.action do |_global_options, options, _args|
|
13
13
|
puts JSON.dump(@client.admin_audit_anomaly_allow_getItem(options))
|
14
14
|
end
|
15
15
|
end
|
16
16
|
|
17
|
-
g.desc 'API to allow
|
18
|
-
g.long_desc %( API to allow
|
17
|
+
g.desc 'API to allow Enterprise org admins to write/overwrite the allow list of IP blocks and ASNs from the enterprise configuration.'
|
18
|
+
g.long_desc %( API to allow Enterprise org admins to write/overwrite the allow list of IP blocks and ASNs from the enterprise configuration. )
|
19
19
|
g.command 'updateItem' do |c|
|
20
|
-
c.flag '
|
21
|
-
c.flag '
|
20
|
+
c.flag 'trusted_cidr', desc: 'allow list of IPv4 addresses using cidr notation in the Enterprise organization configuration.'
|
21
|
+
c.flag 'trusted_asns', desc: 'allow list of Autonomous System Numbers (ASN) in the Enterprise organization configuration.'
|
22
22
|
c.action do |_global_options, options, _args|
|
23
23
|
puts JSON.dump(@client.admin_audit_anomaly_allow_updateItem(options))
|
24
24
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'Assign entities to a particular authentication policy.'
|
10
10
|
g.long_desc %( Assign entities to a particular authentication policy. )
|
11
11
|
g.command 'assignEntities' do |c|
|
12
|
-
c.flag 'entity_ids', desc: 'Array of IDs to assign to the policy.'
|
13
|
-
c.flag 'entity_type', desc: 'The type of entity to assign to the policy. Currently, USER is supported.'
|
14
12
|
c.flag 'policy_name', desc: 'The name of the authentication policy to assign the entities to. Currently, email_password is the only policy that may be used with this method.'
|
13
|
+
c.flag 'entity_type', desc: 'The type of entity to assign to the policy. Currently, USER is supported.'
|
14
|
+
c.flag 'entity_ids', desc: 'Array of IDs to assign to the policy.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_auth_policy_assignEntities(options))
|
17
17
|
end
|
@@ -21,9 +21,9 @@ module Slack
|
|
21
21
|
g.long_desc %( Fetch all the entities assigned to a particular authentication policy by name. )
|
22
22
|
g.command 'getEntities' do |c|
|
23
23
|
c.flag 'policy_name', desc: 'The name of the policy to fetch entities for. Currently, email_password is the only policy that may be used with this method.'
|
24
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
25
24
|
c.flag 'entity_type', desc: 'The type of entity to assign to the policy. Currently, USER is supported.'
|
26
25
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 and 1000, both inclusive.'
|
26
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
27
27
|
c.action do |_global_options, options, _args|
|
28
28
|
puts JSON.dump(@client.admin_auth_policy_getEntities(options))
|
29
29
|
end
|
@@ -32,9 +32,9 @@ module Slack
|
|
32
32
|
g.desc 'Remove specified entities from a specified authentication policy.'
|
33
33
|
g.long_desc %( Remove specified entities from a specified authentication policy. )
|
34
34
|
g.command 'removeEntities' do |c|
|
35
|
-
c.flag 'entity_ids', desc: "Encoded IDs of the entities you'd like to remove from the policy."
|
36
|
-
c.flag 'entity_type', desc: 'The type of entity to assign to the policy. Currently, USER is supported.'
|
37
35
|
c.flag 'policy_name', desc: 'The name of the policy to remove entities from. Currently, email_password is the only policy that may be used with this method.'
|
36
|
+
c.flag 'entity_type', desc: 'The type of entity to assign to the policy. Currently, USER is supported.'
|
37
|
+
c.flag 'entity_ids', desc: "Encoded IDs of the entities you'd like to remove from the policy."
|
38
38
|
c.action do |_global_options, options, _args|
|
39
39
|
puts JSON.dump(@client.admin_auth_policy_removeEntities(options))
|
40
40
|
end
|
@@ -9,8 +9,8 @@ module Slack
|
|
9
9
|
g.desc 'Create an Information Barrier'
|
10
10
|
g.long_desc %( Create an Information Barrier )
|
11
11
|
g.command 'create' do |c|
|
12
|
-
c.flag 'barriered_from_usergroup_ids', desc: 'A list of IDP Groups ids that the primary usergroup is to be barriered from.'
|
13
12
|
c.flag 'primary_usergroup_id', desc: 'The id of the primary IDP Group.'
|
13
|
+
c.flag 'barriered_from_usergroup_ids', desc: 'A list of IDP Groups ids that the primary usergroup is to be barriered from.'
|
14
14
|
c.flag 'restricted_subjects', desc: 'What kind of interactions are blocked by this barrier? For v1, we only support a list of all 3, eg im, mpim, call.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_barriers_create(options))
|
@@ -29,8 +29,8 @@ module Slack
|
|
29
29
|
g.desc 'Get all Information Barriers for your organization'
|
30
30
|
g.long_desc %( Get all Information Barriers for your organization )
|
31
31
|
g.command 'list' do |c|
|
32
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
33
32
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
33
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
34
34
|
c.action do |_global_options, options, _args|
|
35
35
|
puts JSON.dump(@client.admin_barriers_list(options))
|
36
36
|
end
|
@@ -40,8 +40,8 @@ module Slack
|
|
40
40
|
g.long_desc %( Update an existing Information Barrier )
|
41
41
|
g.command 'update' do |c|
|
42
42
|
c.flag 'barrier_id', desc: "The ID of the barrier you're trying to modify."
|
43
|
-
c.flag 'barriered_from_usergroup_ids', desc: 'A list of IDP Groups ids that the primary usergroup is to be barriered from.'
|
44
43
|
c.flag 'primary_usergroup_id', desc: 'The id of the primary IDP Group.'
|
44
|
+
c.flag 'barriered_from_usergroup_ids', desc: 'A list of IDP Groups ids that the primary usergroup is to be barriered from.'
|
45
45
|
c.flag 'restricted_subjects', desc: 'What kind of interactions are blocked by this barrier? For v1, we only support a list of all 3, eg im, mpim, call.'
|
46
46
|
c.action do |_global_options, options, _args|
|
47
47
|
puts JSON.dump(@client.admin_barriers_update(options))
|
@@ -36,8 +36,8 @@ module Slack
|
|
36
36
|
g.desc 'Move public or private channels in bulk.'
|
37
37
|
g.long_desc %( Move public or private channels in bulk. )
|
38
38
|
g.command 'bulkMove' do |c|
|
39
|
-
c.flag 'channel_ids', desc: 'An array of channel IDs.'
|
40
39
|
c.flag 'target_team_id', desc: 'Target team ID.'
|
40
|
+
c.flag 'channel_ids', desc: 'An array of channel IDs.'
|
41
41
|
c.action do |_global_options, options, _args|
|
42
42
|
puts JSON.dump(@client.admin_conversations_bulkMove(options))
|
43
43
|
end
|
@@ -65,9 +65,9 @@ module Slack
|
|
65
65
|
g.desc 'Create a public or private channel-based conversation.'
|
66
66
|
g.long_desc %( Create a public or private channel-based conversation. )
|
67
67
|
g.command 'create' do |c|
|
68
|
-
c.flag 'is_private', desc: 'When true, creates a private channel instead of a public channel.'
|
69
68
|
c.flag 'name', desc: 'Name of the public or private channel to create.'
|
70
69
|
c.flag 'description', desc: 'Description of the public or private channel to create.'
|
70
|
+
c.flag 'is_private', desc: 'When true, creates a private channel instead of a public channel.'
|
71
71
|
c.flag 'org_wide', desc: 'When true, the channel will be available org-wide. Note: if the channel is not org_wide=true, you must specify a team_id for this channel.'
|
72
72
|
c.flag 'team_id', desc: 'The workspace to create the channel in. Note: this argument is required unless you set org_wide=true.'
|
73
73
|
c.action do |_global_options, options, _args|
|
@@ -99,7 +99,7 @@ module Slack
|
|
99
99
|
g.long_desc %( Disconnect a connected channel from one or more workspaces. )
|
100
100
|
g.command 'disconnectShared' do |c|
|
101
101
|
c.flag 'channel_id', desc: 'The channel to be disconnected from some workspaces.'
|
102
|
-
c.flag 'leaving_team_ids', desc: '
|
102
|
+
c.flag 'leaving_team_ids', desc: 'Used for disconnecting a team from a shared channel. Only one team ID may be passed at a time.'
|
103
103
|
c.action do |_global_options, options, _args|
|
104
104
|
puts JSON.dump(@client.admin_conversations_disconnectShared(options))
|
105
105
|
end
|
@@ -137,8 +137,8 @@ module Slack
|
|
137
137
|
g.desc 'Invite a user to a public or private channel.'
|
138
138
|
g.long_desc %( Invite a user to a public or private channel. )
|
139
139
|
g.command 'invite' do |c|
|
140
|
-
c.flag 'channel_id', desc: 'The channel that the users will be invited to.'
|
141
140
|
c.flag 'user_ids', desc: 'The users to invite.'
|
141
|
+
c.flag 'channel_id', desc: 'The channel that the users will be invited to.'
|
142
142
|
c.action do |_global_options, options, _args|
|
143
143
|
puts JSON.dump(@client.admin_conversations_invite(options))
|
144
144
|
end
|
@@ -158,11 +158,11 @@ module Slack
|
|
158
158
|
g.desc 'Returns channels on the given team using the filters.'
|
159
159
|
g.long_desc %( Returns channels on the given team using the filters. )
|
160
160
|
g.command 'lookup' do |c|
|
161
|
-
c.flag 'last_message_activity_before', desc: 'Filter by public channels where the most recent message was sent before last_message_activity.'
|
162
161
|
c.flag 'team_ids', desc: 'Array of team IDs to filter by.'
|
162
|
+
c.flag 'max_member_count', desc: 'Filter by public channels with member count equal to or less than the specified number.'
|
163
|
+
c.flag 'last_message_activity_before', desc: 'Filter by public channels where the most recent message was sent before last_message_activity.'
|
163
164
|
c.flag 'cursor', desc: 'Set cursor to next_cursor returned in the previous call, to fetch the next page.'
|
164
165
|
c.flag 'limit', desc: 'Maximum number of results.'
|
165
|
-
c.flag 'max_member_count', desc: 'Filter by public channels with member count equal to or less than the specified number.'
|
166
166
|
c.action do |_global_options, options, _args|
|
167
167
|
puts JSON.dump(@client.admin_conversations_lookup(options))
|
168
168
|
end
|
@@ -181,7 +181,7 @@ module Slack
|
|
181
181
|
g.long_desc %( Rename a public or private channel. )
|
182
182
|
g.command 'rename' do |c|
|
183
183
|
c.flag 'channel_id', desc: 'The channel to rename.'
|
184
|
-
c.flag 'name', desc: '
|
184
|
+
c.flag 'name', desc: ''
|
185
185
|
c.action do |_global_options, options, _args|
|
186
186
|
puts JSON.dump(@client.admin_conversations_rename(options))
|
187
187
|
end
|
@@ -190,14 +190,14 @@ module Slack
|
|
190
190
|
g.desc 'Search for public or private channels in an Enterprise organization.'
|
191
191
|
g.long_desc %( Search for public or private channels in an Enterprise organization. )
|
192
192
|
g.command 'search' do |c|
|
193
|
+
c.flag 'team_ids', desc: 'Comma separated string of team IDs, signifying the internal workspaces to search through.'
|
193
194
|
c.flag 'connected_team_ids', desc: 'Array of encoded team IDs, signifying the external orgs to search through.'
|
194
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
195
|
-
c.flag 'limit', desc: 'Maximum number of items to be returned. Must be between 1 - 20 both inclusive. Default is 10.'
|
196
195
|
c.flag 'query', desc: 'Name of the the channel to query by.'
|
196
|
+
c.flag 'limit', desc: 'Maximum number of items to be returned. Must be between 1 - 20 both inclusive. Default is 10.'
|
197
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
197
198
|
c.flag 'search_channel_types', desc: 'The type of channel to include or exclude in the search. For example private will search private channels, while private_exclude will exclude them. For a full list of types, check the Types section.'
|
198
|
-
c.flag 'sort', desc: 'Possible values are relevant (search ranking based on what we think is closest), name (alphabetical), member_count (number of users in the channel), and created (date channel was created). You can optionally pair this with the sort_dir arg to change how it is sorted.'
|
199
|
+
c.flag 'sort', desc: 'Possible values are relevant (search ranking based on what we think is closest), name (alphabetical), member_count (number of users in the channel), and created (date channel was created). You can optionally pair this with the sort_dir arg to change how it is sorted .'
|
199
200
|
c.flag 'sort_dir', desc: 'Sort direction. Possible values are asc for ascending order like (1, 2, 3) or (a, b, c), and desc for descending order like (3, 2, 1) or (c, b, a).'
|
200
|
-
c.flag 'team_ids', desc: 'Comma separated string of team IDs, signifying the internal workspaces to search through.'
|
201
201
|
c.flag 'total_count_only', desc: 'Only return the total_count of channels. Omits channel data and allows access for admins without channel manager permissions.'
|
202
202
|
c.action do |_global_options, options, _args|
|
203
203
|
puts JSON.dump(@client.admin_conversations_search(options))
|
@@ -224,13 +224,13 @@ module Slack
|
|
224
224
|
end
|
225
225
|
end
|
226
226
|
|
227
|
-
g.desc 'Set the workspaces in an Enterprise
|
228
|
-
g.long_desc %( Set the workspaces in an Enterprise
|
227
|
+
g.desc 'Set the workspaces in an Enterprise org that connect to a public or private channel.'
|
228
|
+
g.long_desc %( Set the workspaces in an Enterprise org that connect to a public or private channel. )
|
229
229
|
g.command 'setTeams' do |c|
|
230
230
|
c.flag 'channel_id', desc: 'The encoded channel_id to add or remove to workspaces.'
|
231
|
-
c.flag 'org_channel', desc: 'True if channel has to be converted to an org channel.'
|
232
|
-
c.flag 'target_team_ids', desc: 'A comma-separated list of workspaces to which the channel should be shared. Not required if the channel is being shared org-wide.'
|
233
231
|
c.flag 'team_id', desc: 'The workspace to which the channel belongs if the channel is a local workspace channel. Omit this argument if the channel is a cross-workspace or org-wide shared channel.'
|
232
|
+
c.flag 'target_team_ids', desc: 'A comma-separated list of workspaces to which the channel should be shared. Not required if the channel is being shared org-wide.'
|
233
|
+
c.flag 'org_channel', desc: 'True if channel has to be converted to an org channel.'
|
234
234
|
c.action do |_global_options, options, _args|
|
235
235
|
puts JSON.dump(@client.admin_conversations_setTeams(options))
|
236
236
|
end
|
@@ -10,9 +10,9 @@ module Slack
|
|
10
10
|
g.long_desc %( List all disconnected channels—i.e., channels that were once connected to other workspaces and then disconnected—and the corresponding original channel IDs for key revocation with EKM. )
|
11
11
|
g.command 'listOriginalConnectedChannelInfo' do |c|
|
12
12
|
c.flag 'channel_ids', desc: 'A comma-separated list of channels to filter to.'
|
13
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
-
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
15
13
|
c.flag 'team_ids', desc: 'A comma-separated list of the workspaces to which the channels you would like returned belong.'
|
14
|
+
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
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.action do |_global_options, options, _args|
|
17
17
|
puts JSON.dump(@client.admin_conversations_ekm_listOriginalConnectedChannelInfo(options))
|
18
18
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'Add an allowlist of IDP groups for accessing a channel'
|
10
10
|
g.long_desc %( Add an allowlist of IDP groups for accessing a channel )
|
11
11
|
g.command 'addGroup' do |c|
|
12
|
-
c.flag 'channel_id', desc: 'The channel to link this group to.'
|
13
|
-
c.flag 'group_id', desc: 'The IDP Group ID to be an allowlist for the private channel.'
|
14
12
|
c.flag 'team_id', desc: 'The workspace where the channel exists. This argument is required for channels only tied to one workspace, and optional for channels that are shared across an organization.'
|
13
|
+
c.flag 'group_id', desc: 'The IDP Group ID to be an allowlist for the private channel.'
|
14
|
+
c.flag 'channel_id', desc: 'The channel to link this group to.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_conversations_restrictAccess_addGroup(options))
|
17
17
|
end
|
@@ -20,7 +20,7 @@ module Slack
|
|
20
20
|
g.desc 'List all IDP Groups linked to a channel'
|
21
21
|
g.long_desc %( List all IDP Groups linked to a channel )
|
22
22
|
g.command 'listGroups' do |c|
|
23
|
-
c.flag 'channel_id', desc: '
|
23
|
+
c.flag 'channel_id', desc: ''
|
24
24
|
c.flag 'team_id', desc: 'The workspace where the channel exists. This argument is required for channels only tied to one workspace, and optional for channels that are shared across an organization.'
|
25
25
|
c.action do |_global_options, options, _args|
|
26
26
|
puts JSON.dump(@client.admin_conversations_restrictAccess_listGroups(options))
|
@@ -30,9 +30,9 @@ module Slack
|
|
30
30
|
g.desc 'Remove a linked IDP group linked from a private channel'
|
31
31
|
g.long_desc %( Remove a linked IDP group linked from a private channel )
|
32
32
|
g.command 'removeGroup' do |c|
|
33
|
-
c.flag 'channel_id', desc: 'The channel to remove the linked group from.'
|
34
|
-
c.flag 'group_id', desc: 'The IDP Group ID to remove from the private channel.'
|
35
33
|
c.flag 'team_id', desc: 'The workspace where the channel exists. This argument is required for channels only tied to one workspace, and optional for channels that are shared across an organization.'
|
34
|
+
c.flag 'group_id', desc: 'The IDP Group ID to remove from the private channel.'
|
35
|
+
c.flag 'channel_id', desc: 'The channel to remove the linked group from.'
|
36
36
|
c.action do |_global_options, options, _args|
|
37
37
|
puts JSON.dump(@client.admin_conversations_restrictAccess_removeGroup(options))
|
38
38
|
end
|
data/bin/commands/admin_emoji.rb
CHANGED
@@ -19,15 +19,15 @@ module Slack
|
|
19
19
|
g.desc 'Add an emoji alias.'
|
20
20
|
g.long_desc %( Add an emoji alias. )
|
21
21
|
g.command 'addAlias' do |c|
|
22
|
-
c.flag 'alias_for', desc: 'Name of the emoji for which the alias is being made. Any wrapping whitespace or colons will be automatically trimmed.'
|
23
22
|
c.flag 'name', desc: 'The new alias for the specified emoji. Any wrapping whitespace or colons will be automatically trimmed.'
|
23
|
+
c.flag 'alias_for', desc: 'Name of the emoji for which the alias is being made. Any wrapping whitespace or colons will be automatically trimmed.'
|
24
24
|
c.action do |_global_options, options, _args|
|
25
25
|
puts JSON.dump(@client.admin_emoji_addAlias(options))
|
26
26
|
end
|
27
27
|
end
|
28
28
|
|
29
|
-
g.desc 'List emoji for an Enterprise
|
30
|
-
g.long_desc %( List emoji for an Enterprise
|
29
|
+
g.desc 'List emoji for an Enterprise organization.'
|
30
|
+
g.long_desc %( List emoji for an Enterprise organization. )
|
31
31
|
g.command 'list' do |c|
|
32
32
|
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
33
33
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
@@ -36,8 +36,8 @@ module Slack
|
|
36
36
|
end
|
37
37
|
end
|
38
38
|
|
39
|
-
g.desc 'Remove an emoji across an Enterprise
|
40
|
-
g.long_desc %( Remove an emoji across an Enterprise
|
39
|
+
g.desc 'Remove an emoji across an Enterprise organization'
|
40
|
+
g.long_desc %( Remove an emoji across an Enterprise organization )
|
41
41
|
g.command 'remove' do |c|
|
42
42
|
c.flag 'name', desc: 'The name of the emoji to be removed. Colons (:myemoji:) around the value are not required, although they may be included.'
|
43
43
|
c.action do |_global_options, options, _args|
|
@@ -9,10 +9,10 @@ module Slack
|
|
9
9
|
g.desc 'Look up functions by a set of apps'
|
10
10
|
g.long_desc %( Look up functions by a set of apps )
|
11
11
|
g.command 'list' do |c|
|
12
|
+
c.flag 'team_id', desc: 'The team context to retrieve functions from.'
|
12
13
|
c.flag 'app_ids', desc: 'Comma-separated array of app IDs to get functions for; max 50.'
|
13
14
|
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
15
|
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.'
|
15
|
-
c.flag 'team_id', desc: 'The team context to retrieve functions from.'
|
16
16
|
c.action do |_global_options, options, _args|
|
17
17
|
puts JSON.dump(@client.admin_functions_list(options))
|
18
18
|
end
|
@@ -9,8 +9,8 @@ module Slack
|
|
9
9
|
g.desc 'Approve a workspace invite request.'
|
10
10
|
g.long_desc %( Approve a workspace invite request. )
|
11
11
|
g.command 'approve' do |c|
|
12
|
-
c.flag 'invite_request_id', desc: 'ID of the request to invite.'
|
13
12
|
c.flag 'team_id', desc: 'ID for the workspace where the invite request was made.'
|
13
|
+
c.flag 'invite_request_id', desc: 'ID of the request to invite.'
|
14
14
|
c.action do |_global_options, options, _args|
|
15
15
|
puts JSON.dump(@client.admin_inviteRequests_approve(options))
|
16
16
|
end
|
@@ -19,8 +19,8 @@ module Slack
|
|
19
19
|
g.desc 'Deny a workspace invite request.'
|
20
20
|
g.long_desc %( Deny a workspace invite request. )
|
21
21
|
g.command 'deny' do |c|
|
22
|
-
c.flag 'invite_request_id', desc: 'ID of the request to invite.'
|
23
22
|
c.flag 'team_id', desc: 'ID for the workspace where the invite request was made.'
|
23
|
+
c.flag 'invite_request_id', desc: 'ID of the request to invite.'
|
24
24
|
c.action do |_global_options, options, _args|
|
25
25
|
puts JSON.dump(@client.admin_inviteRequests_deny(options))
|
26
26
|
end
|
@@ -29,9 +29,9 @@ module Slack
|
|
29
29
|
g.desc 'List all pending workspace invite requests.'
|
30
30
|
g.long_desc %( List all pending workspace invite requests. )
|
31
31
|
g.command 'list' do |c|
|
32
|
+
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
32
33
|
c.flag 'cursor', desc: 'Value of the next_cursor field sent as part of the previous API response.'
|
33
34
|
c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation. Must be between 1 - 1000, both inclusive.'
|
34
|
-
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
35
35
|
c.action do |_global_options, options, _args|
|
36
36
|
puts JSON.dump(@client.admin_inviteRequests_list(options))
|
37
37
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'List all approved workspace invite requests.'
|
10
10
|
g.long_desc %( List all approved workspace invite requests. )
|
11
11
|
g.command 'list' do |c|
|
12
|
+
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
12
13
|
c.flag 'cursor', desc: 'Value of the next_cursor field sent as part of the previous API response.'
|
13
14
|
c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation. Must be between 1 - 1000, both inclusive.'
|
14
|
-
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_inviteRequests_approved_list(options))
|
17
17
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'List all denied workspace invite requests.'
|
10
10
|
g.long_desc %( List all denied workspace invite requests. )
|
11
11
|
g.command 'list' do |c|
|
12
|
+
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
12
13
|
c.flag 'cursor', desc: 'Value of the next_cursor field sent as part of the previous api response.'
|
13
14
|
c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation. Must be between 1 - 1000 both inclusive.'
|
14
|
-
c.flag 'team_id', desc: 'ID for the workspace where the invite requests were made.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_inviteRequests_denied_list(options))
|
17
17
|
end
|
data/bin/commands/admin_roles.rb
CHANGED
@@ -9,8 +9,8 @@ module Slack
|
|
9
9
|
g.desc 'Adds members to the specified role with the specified scopes'
|
10
10
|
g.long_desc %( Adds members to the specified role with the specified scopes )
|
11
11
|
g.command 'addAssignments' do |c|
|
12
|
-
c.flag 'entity_ids', desc: 'List of the entity IDs for which roles will be assigned. These can be Org IDs, Team IDs or Channel IDs.'
|
13
12
|
c.flag 'role_id', desc: 'ID of the role to which users will be assigned.'
|
13
|
+
c.flag 'entity_ids', desc: 'List of the entity IDs for which roles will be assigned. These can be Org IDs, Team IDs or Channel IDs.'
|
14
14
|
c.flag 'user_ids', desc: 'List of IDs from the users to be added to the given role.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_roles_addAssignments(options))
|
@@ -21,9 +21,9 @@ module Slack
|
|
21
21
|
g.long_desc %( Lists assignments for all roles across entities. Options to scope results by any combination of roles or entities )
|
22
22
|
g.command 'listAssignments' do |c|
|
23
23
|
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
24
|
-
c.flag 'entity_ids', desc: 'The entities for which the roles apply.'
|
25
24
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 200 both inclusive.'
|
26
25
|
c.flag 'role_ids', desc: 'collection of role ids to scope results by.'
|
26
|
+
c.flag 'entity_ids', desc: 'The entities for which the roles apply.'
|
27
27
|
c.flag 'sort_dir', desc: 'Sort direction. Default is descending on date_create, can be either ASC or DESC.'
|
28
28
|
c.action do |_global_options, options, _args|
|
29
29
|
puts JSON.dump(@client.admin_roles_listAssignments(options))
|
@@ -33,8 +33,8 @@ module Slack
|
|
33
33
|
g.desc 'Removes a set of users from a role for the given scopes and entities'
|
34
34
|
g.long_desc %( Removes a set of users from a role for the given scopes and entities )
|
35
35
|
g.command 'removeAssignments' do |c|
|
36
|
-
c.flag 'entity_ids', desc: 'List of the entity IDs for which roles will be revoked. These can be Org IDs, Team IDs or Channel IDs.'
|
37
36
|
c.flag 'role_id', desc: 'ID of the role to which users will be assigned.'
|
37
|
+
c.flag 'entity_ids', desc: 'List of the entity IDs for which roles will be revoked. These can be Org IDs, Team IDs or Channel IDs.'
|
38
38
|
c.flag 'user_ids', desc: 'List of IDs of the users whose roles will be revoked.'
|
39
39
|
c.action do |_global_options, options, _args|
|
40
40
|
puts JSON.dump(@client.admin_roles_removeAssignments(options))
|
data/bin/commands/admin_teams.rb
CHANGED
@@ -18,11 +18,11 @@ module Slack
|
|
18
18
|
end
|
19
19
|
end
|
20
20
|
|
21
|
-
g.desc 'List all teams
|
22
|
-
g.long_desc %( List all teams
|
21
|
+
g.desc 'List all teams in an Enterprise organization'
|
22
|
+
g.long_desc %( List all teams in an Enterprise organization )
|
23
23
|
g.command 'list' do |c|
|
24
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
25
24
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be a positive integer no larger than 1000.'
|
25
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
26
26
|
c.action do |_global_options, options, _args|
|
27
27
|
puts JSON.dump(@client.admin_teams_list(options))
|
28
28
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'List all of the admins on a given workspace.'
|
10
10
|
g.long_desc %( List all of the admins on a given workspace. )
|
11
11
|
g.command 'list' do |c|
|
12
|
-
c.flag 'team_id', desc: '.'
|
13
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
12
|
c.flag 'limit', desc: 'The maximum number of items to return.'
|
13
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
14
|
+
c.flag 'team_id', desc: ''
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_teams_admins_list(options))
|
17
17
|
end
|
@@ -9,9 +9,9 @@ module Slack
|
|
9
9
|
g.desc 'List all of the owners on a given workspace.'
|
10
10
|
g.long_desc %( List all of the owners on a given workspace. )
|
11
11
|
g.command 'list' do |c|
|
12
|
-
c.flag 'team_id', desc: '
|
13
|
-
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
12
|
+
c.flag 'team_id', desc: ''
|
14
13
|
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
14
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
15
15
|
c.action do |_global_options, options, _args|
|
16
16
|
puts JSON.dump(@client.admin_teams_owners_list(options))
|
17
17
|
end
|