slack-ruby-client 2.0.0 → 2.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/FUNDING.yml +1 -0
- data/.github/workflows/integration_test.yml +19 -0
- data/.github/workflows/pr_lint.yml +1 -1
- data/.github/workflows/test.yml +1 -0
- data/CHANGELOG.md +9 -0
- data/README.md +18 -14
- data/SECURITY.md +9 -0
- data/bin/commands/admin_analytics.rb +16 -10
- data/bin/commands/admin_apps.rb +48 -42
- data/bin/commands/admin_apps_approved.rb +17 -11
- data/bin/commands/admin_apps_requests.rb +27 -21
- data/bin/commands/admin_apps_restricted.rb +17 -11
- data/bin/commands/admin_audit_anomaly_allow.rb +22 -16
- data/bin/commands/admin_auth_policy.rb +37 -31
- data/bin/commands/admin_barriers.rb +44 -38
- data/bin/commands/admin_conversations.rb +221 -165
- data/bin/commands/admin_conversations_ekm.rb +17 -11
- data/bin/commands/admin_conversations_restrictAccess.rb +35 -29
- data/bin/commands/admin_emoji.rb +50 -44
- data/bin/commands/admin_inviteRequests.rb +34 -28
- data/bin/commands/admin_inviteRequests_approved.rb +16 -10
- data/bin/commands/admin_inviteRequests_denied.rb +16 -10
- data/bin/commands/admin_roles.rb +46 -0
- data/bin/commands/admin_teams.rb +26 -20
- data/bin/commands/admin_teams_admins.rb +16 -10
- data/bin/commands/admin_teams_owners.rb +16 -10
- data/bin/commands/admin_teams_settings.rb +59 -53
- data/bin/commands/admin_usergroups.rb +45 -39
- data/bin/commands/admin_users.rb +91 -85
- data/bin/commands/admin_users_session.rb +72 -66
- data/bin/commands/admin_users_unsupportedVersions.rb +15 -9
- data/bin/commands/api.rb +14 -8
- data/bin/commands/apps.rb +15 -9
- data/bin/commands/apps_connections.rb +13 -7
- data/bin/commands/apps_event_authorizations.rb +16 -10
- data/bin/commands/apps_manifest.rb +48 -42
- data/bin/commands/auth.rb +21 -15
- data/bin/commands/auth_teams.rb +16 -10
- data/bin/commands/bookmarks.rb +50 -44
- data/bin/commands/bots.rb +15 -9
- data/bin/commands/calls.rb +49 -43
- data/bin/commands/calls_participants.rb +24 -18
- data/bin/commands/chat.rb +150 -144
- data/bin/commands/chat_scheduledMessages.rb +19 -13
- data/bin/commands/conversations.rb +233 -227
- data/bin/commands/dialog.rb +15 -9
- data/bin/commands/dnd.rb +46 -40
- data/bin/commands/emoji.rb +14 -7
- data/bin/commands/files.rb +110 -105
- data/bin/commands/files_comments.rb +15 -9
- data/bin/commands/files_remote.rb +73 -67
- data/bin/commands/functions_workflows_steps.rb +22 -0
- data/bin/commands/functions_workflows_steps_responses.rb +22 -0
- data/bin/commands/migration.rb +16 -10
- data/bin/commands/oauth.rb +18 -12
- data/bin/commands/oauth_v2.rb +28 -22
- data/bin/commands/openid_connect.rb +26 -20
- data/bin/commands/pins.rb +33 -26
- data/bin/commands/reactions.rb +52 -46
- data/bin/commands/reminders.rb +53 -47
- data/bin/commands/rtm.rb +15 -9
- data/bin/commands/search.rb +43 -37
- data/bin/commands/stars.rb +38 -32
- data/bin/commands/team.rb +47 -39
- data/bin/commands/team_billing.rb +13 -7
- data/bin/commands/team_preferences.rb +13 -7
- data/bin/commands/team_profile.rb +14 -8
- data/bin/commands/tooling_tokens.rb +14 -8
- data/bin/commands/usergroups.rb +64 -58
- data/bin/commands/usergroups_users.rb +27 -21
- data/bin/commands/users.rb +111 -105
- data/bin/commands/users_admin.rb +28 -22
- data/bin/commands/users_prefs.rb +13 -7
- data/bin/commands/users_profile.rb +26 -20
- data/bin/commands/views.rb +47 -41
- data/bin/commands/workflows.rb +36 -30
- data/bin/slack +48 -43
- data/lib/slack/version.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_analytics.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_apps_requests.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_conversations.rb +78 -0
- data/lib/slack/web/api/endpoints/admin_roles.rb +73 -0
- data/lib/slack/web/api/endpoints/chat.rb +2 -2
- data/lib/slack/web/api/endpoints/conversations.rb +1 -1
- data/lib/slack/web/api/endpoints/emoji.rb +2 -0
- data/lib/slack/web/api/endpoints/files.rb +0 -2
- data/lib/slack/web/api/endpoints/functions_workflows_steps.rb +28 -0
- data/lib/slack/web/api/endpoints/functions_workflows_steps_responses.rb +28 -0
- data/lib/slack/web/api/endpoints/pins.rb +2 -0
- data/lib/slack/web/api/endpoints/team.rb +11 -1
- data/lib/slack/web/api/endpoints/usergroups.rb +1 -1
- data/lib/slack/web/api/endpoints/users_profile.rb +1 -1
- data/lib/slack/web/api/endpoints.rb +6 -0
- data/lib/slack/web/api/errors.rb +62 -0
- data/lib/slack/web/api/templates/command.erb +18 -12
- data/lib/tasks/web.rake +0 -6
- data/slack-ruby-client.gemspec +0 -1
- data/spec/slack/web/api/endpoints/admin_conversations_spec.rb +31 -0
- data/spec/slack/web/api/endpoints/admin_roles_spec.rb +30 -0
- data/spec/slack/web/api/endpoints/functions_workflows_steps_responses_spec.rb +13 -0
- data/spec/slack/web/api/endpoints/functions_workflows_steps_spec.rb +13 -0
- metadata +13 -19
- data/bin/commands.rb +0 -69
- data/lib/slack/web/api/templates/commands.erb +0 -6
@@ -1,48 +1,54 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AdminUsergroups methods.'
|
8
|
+
command 'admin_usergroups' do |g|
|
9
|
+
g.desc 'Add up to one hundred default channels to an IDP group.'
|
10
|
+
g.long_desc %( Add up to one hundred default channels to an IDP group. )
|
11
|
+
g.command 'addChannels' do |c|
|
12
|
+
c.flag 'channel_ids', desc: 'Comma separated string of channel IDs.'
|
13
|
+
c.flag 'usergroup_id', desc: 'ID of the IDP group to add default channels for.'
|
14
|
+
c.flag 'team_id', desc: 'The workspace to add default channels in.'
|
15
|
+
c.action do |_global_options, options, _args|
|
16
|
+
puts JSON.dump(@client.admin_usergroups_addChannels(options))
|
17
|
+
end
|
18
|
+
end
|
16
19
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
20
|
+
g.desc 'Associate one or more default workspaces with an organization-wide IDP group.'
|
21
|
+
g.long_desc %( Associate one or more default workspaces with an organization-wide IDP group. )
|
22
|
+
g.command 'addTeams' do |c|
|
23
|
+
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.'
|
24
|
+
c.flag 'usergroup_id', desc: 'An encoded usergroup (IDP Group) ID.'
|
25
|
+
c.flag 'auto_provision', desc: 'When true, this method automatically creates new workspace accounts for the IDP group members.'
|
26
|
+
c.action do |_global_options, options, _args|
|
27
|
+
puts JSON.dump(@client.admin_usergroups_addTeams(options))
|
28
|
+
end
|
29
|
+
end
|
27
30
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
31
|
+
g.desc 'List the channels linked to an org-level IDP group (user group).'
|
32
|
+
g.long_desc %( List the channels linked to an org-level IDP group (user group). )
|
33
|
+
g.command 'listChannels' do |c|
|
34
|
+
c.flag 'usergroup_id', desc: 'ID of the IDP group to list default channels for.'
|
35
|
+
c.flag 'include_num_members', desc: 'Flag to include or exclude the count of members per channel.'
|
36
|
+
c.flag 'team_id', desc: 'ID of the the workspace.'
|
37
|
+
c.action do |_global_options, options, _args|
|
38
|
+
puts JSON.dump(@client.admin_usergroups_listChannels(options))
|
39
|
+
end
|
40
|
+
end
|
38
41
|
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
42
|
+
g.desc 'Remove one or more default channels from an org-level IDP group (user group).'
|
43
|
+
g.long_desc %( Remove one or more default channels from an org-level IDP group (user group). )
|
44
|
+
g.command 'removeChannels' do |c|
|
45
|
+
c.flag 'channel_ids', desc: 'Comma-separated string of channel IDs.'
|
46
|
+
c.flag 'usergroup_id', desc: 'ID of the IDP Group.'
|
47
|
+
c.action do |_global_options, options, _args|
|
48
|
+
puts JSON.dump(@client.admin_usergroups_removeChannels(options))
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
46
52
|
end
|
47
53
|
end
|
48
54
|
end
|
data/bin/commands/admin_users.rb
CHANGED
@@ -1,98 +1,104 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AdminUsers methods.'
|
8
|
+
command 'admin_users' do |g|
|
9
|
+
g.desc 'Add an Enterprise user to a workspace.'
|
10
|
+
g.long_desc %( Add an Enterprise user to a workspace. )
|
11
|
+
g.command 'assign' do |c|
|
12
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
13
|
+
c.flag 'user_id', desc: 'The ID of the user to add to the workspace.'
|
14
|
+
c.flag 'channel_ids', desc: 'Comma separated values of channel IDs to add user in the new workspace.'
|
15
|
+
c.flag 'is_restricted', desc: 'True if user should be added to the workspace as a guest.'
|
16
|
+
c.flag 'is_ultra_restricted', desc: 'True if user should be added to the workspace as a single-channel guest.'
|
17
|
+
c.action do |_global_options, options, _args|
|
18
|
+
puts JSON.dump(@client.admin_users_assign(options))
|
19
|
+
end
|
20
|
+
end
|
18
21
|
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
22
|
+
g.desc 'Invite a user to a workspace.'
|
23
|
+
g.long_desc %( Invite a user to a workspace. )
|
24
|
+
g.command 'invite' do |c|
|
25
|
+
c.flag 'channel_ids', desc: 'A comma-separated list of channel_ids for this user to join. At least one channel is required.'
|
26
|
+
c.flag 'email', desc: 'The email address of the person to invite.'
|
27
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
28
|
+
c.flag 'custom_message', desc: 'An optional message to send to the user in the invite email.'
|
29
|
+
c.flag 'email_password_policy_enabled', desc: 'Allow invited user to sign in via email and password. Only available for Enterprise Grid teams via admin invite.'
|
30
|
+
c.flag 'guest_expiration_ts', desc: 'Timestamp when guest account should be disabled. Only include this timestamp if you are inviting a guest user and you want their account to expire on a certain date.'
|
31
|
+
c.flag 'is_restricted', desc: 'Is this user a multi-channel guest user? (default: false).'
|
32
|
+
c.flag 'is_ultra_restricted', desc: 'Is this user a single channel guest user? (default: false).'
|
33
|
+
c.flag 'real_name', desc: 'Full name of the user.'
|
34
|
+
c.flag 'resend', desc: 'Allow this invite to be resent in the future if a user has not signed up yet. (default: false).'
|
35
|
+
c.action do |_global_options, options, _args|
|
36
|
+
puts JSON.dump(@client.admin_users_invite(options))
|
37
|
+
end
|
38
|
+
end
|
36
39
|
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
40
|
+
g.desc 'List users on a workspace'
|
41
|
+
g.long_desc %( List users on a workspace )
|
42
|
+
g.command 'list' do |c|
|
43
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
44
|
+
c.flag 'limit', desc: 'Limit for how many users to be retrieved per page.'
|
45
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace. The team_id is required if you use an org-level token.'
|
46
|
+
c.action do |_global_options, options, _args|
|
47
|
+
puts JSON.dump(@client.admin_users_list(options))
|
48
|
+
end
|
49
|
+
end
|
47
50
|
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
51
|
+
g.desc 'Remove a user from a workspace.'
|
52
|
+
g.long_desc %( Remove a user from a workspace. )
|
53
|
+
g.command 'remove' do |c|
|
54
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
55
|
+
c.flag 'user_id', desc: 'The ID of the user to remove.'
|
56
|
+
c.action do |_global_options, options, _args|
|
57
|
+
puts JSON.dump(@client.admin_users_remove(options))
|
58
|
+
end
|
59
|
+
end
|
57
60
|
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
61
|
+
g.desc 'Set an existing guest, regular user, or owner to be an admin user.'
|
62
|
+
g.long_desc %( Set an existing guest, regular user, or owner to be an admin user. )
|
63
|
+
g.command 'setAdmin' do |c|
|
64
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
65
|
+
c.flag 'user_id', desc: 'The ID of the user to designate as an admin.'
|
66
|
+
c.action do |_global_options, options, _args|
|
67
|
+
puts JSON.dump(@client.admin_users_setAdmin(options))
|
68
|
+
end
|
69
|
+
end
|
67
70
|
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
71
|
+
g.desc 'Set an expiration for a guest user'
|
72
|
+
g.long_desc %( Set an expiration for a guest user )
|
73
|
+
g.command 'setExpiration' do |c|
|
74
|
+
c.flag 'expiration_ts', desc: 'Timestamp when guest account should be disabled.'
|
75
|
+
c.flag 'user_id', desc: 'The ID of the user to set an expiration for.'
|
76
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
77
|
+
c.action do |_global_options, options, _args|
|
78
|
+
puts JSON.dump(@client.admin_users_setExpiration(options))
|
79
|
+
end
|
80
|
+
end
|
78
81
|
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
82
|
+
g.desc 'Set an existing guest, regular user, or admin user to be a workspace owner.'
|
83
|
+
g.long_desc %( Set an existing guest, regular user, or admin user to be a workspace owner. )
|
84
|
+
g.command 'setOwner' do |c|
|
85
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
86
|
+
c.flag 'user_id', desc: 'Id of the user to promote to owner.'
|
87
|
+
c.action do |_global_options, options, _args|
|
88
|
+
puts JSON.dump(@client.admin_users_setOwner(options))
|
89
|
+
end
|
90
|
+
end
|
88
91
|
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
92
|
+
g.desc 'Set an existing guest user, admin user, or owner to be a regular user.'
|
93
|
+
g.long_desc %( Set an existing guest user, admin user, or owner to be a regular user. )
|
94
|
+
g.command 'setRegular' do |c|
|
95
|
+
c.flag 'team_id', desc: 'The ID (T1234) of the workspace.'
|
96
|
+
c.flag 'user_id', desc: 'The ID of the user to designate as a regular user.'
|
97
|
+
c.action do |_global_options, options, _args|
|
98
|
+
puts JSON.dump(@client.admin_users_setRegular(options))
|
99
|
+
end
|
100
|
+
end
|
101
|
+
end
|
96
102
|
end
|
97
103
|
end
|
98
104
|
end
|
@@ -1,78 +1,84 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AdminUsersSession methods.'
|
8
|
+
command 'admin_users_session' do |g|
|
9
|
+
g.desc 'Clear user-specific session settings—the session duration and what happens when the client closes—for a list of users.'
|
10
|
+
g.long_desc %( Clear user-specific session settings—the session duration and what happens when the client closes—for a list of users. )
|
11
|
+
g.command 'clearSettings' do |c|
|
12
|
+
c.flag 'user_ids', desc: "The IDs of users you'd like to clear session settings for."
|
13
|
+
c.action do |_global_options, options, _args|
|
14
|
+
puts JSON.dump(@client.admin_users_session_clearSettings(options))
|
15
|
+
end
|
16
|
+
end
|
14
17
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
18
|
+
g.desc 'Get user-specific session settings—the session duration and what happens when the client closes—given a list of users.'
|
19
|
+
g.long_desc %( Get user-specific session settings—the session duration and what happens when the client closes—given a list of users. )
|
20
|
+
g.command 'getSettings' do |c|
|
21
|
+
c.flag 'user_ids', desc: "The IDs of users you'd like to fetch session settings for. Note: if a user does not have any active sessions, they will not be returned in the response."
|
22
|
+
c.action do |_global_options, options, _args|
|
23
|
+
puts JSON.dump(@client.admin_users_session_getSettings(options))
|
24
|
+
end
|
25
|
+
end
|
23
26
|
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
27
|
+
g.desc 'Revoke a single session for a user. The user will be forced to login to Slack.'
|
28
|
+
g.long_desc %( Revoke a single session for a user. The user will be forced to login to Slack. )
|
29
|
+
g.command 'invalidate' do |c|
|
30
|
+
c.flag 'session_id', desc: 'ID of the session to invalidate.'
|
31
|
+
c.flag 'team_id', desc: 'ID of the workspace that the session belongs to.'
|
32
|
+
c.action do |_global_options, options, _args|
|
33
|
+
puts JSON.dump(@client.admin_users_session_invalidate(options))
|
34
|
+
end
|
35
|
+
end
|
33
36
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
37
|
+
g.desc 'List active user sessions for an organization'
|
38
|
+
g.long_desc %( List active user sessions for an organization )
|
39
|
+
g.command 'list' do |c|
|
40
|
+
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.'
|
41
|
+
c.flag 'limit', desc: 'The maximum number of items to return. Must be between 1 - 1000 both inclusive.'
|
42
|
+
c.flag 'team_id', desc: "The ID of the workspace you'd like active sessions for. If you pass a team_id, you'll need to pass a user_id as well."
|
43
|
+
c.flag 'user_id', desc: "The ID of user you'd like active sessions for. If you pass a user_id, you'll need to pass a team_id as well."
|
44
|
+
c.action do |_global_options, options, _args|
|
45
|
+
puts JSON.dump(@client.admin_users_session_list(options))
|
46
|
+
end
|
47
|
+
end
|
45
48
|
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
49
|
+
g.desc 'Wipes all valid sessions on all devices for a given user'
|
50
|
+
g.long_desc %( Wipes all valid sessions on all devices for a given user )
|
51
|
+
g.command 'reset' do |c|
|
52
|
+
c.flag 'user_id', desc: 'The ID of the user to wipe sessions for.'
|
53
|
+
c.flag 'mobile_only', desc: 'Only expire mobile sessions (default: false).'
|
54
|
+
c.flag 'web_only', desc: 'Only expire web sessions (default: false).'
|
55
|
+
c.action do |_global_options, options, _args|
|
56
|
+
puts JSON.dump(@client.admin_users_session_reset(options))
|
57
|
+
end
|
58
|
+
end
|
56
59
|
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
60
|
+
g.desc 'Enqueues an asynchronous job to wipe all valid sessions on all devices for a given list of users'
|
61
|
+
g.long_desc %( Enqueues an asynchronous job to wipe all valid sessions on all devices for a given list of users )
|
62
|
+
g.command 'resetBulk' do |c|
|
63
|
+
c.flag 'user_ids', desc: 'The ID of the user to wipe sessions for.'
|
64
|
+
c.flag 'mobile_only', desc: 'Only expire mobile sessions (default: false).'
|
65
|
+
c.flag 'web_only', desc: 'Only expire web sessions (default: false).'
|
66
|
+
c.action do |_global_options, options, _args|
|
67
|
+
puts JSON.dump(@client.admin_users_session_resetBulk(options))
|
68
|
+
end
|
69
|
+
end
|
67
70
|
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
71
|
+
g.desc 'Configure the user-level session settings—the session duration and what happens when the client closes—for one or more users.'
|
72
|
+
g.long_desc %( Configure the user-level session settings—the session duration and what happens when the client closes—for one or more users. )
|
73
|
+
g.command 'setSettings' do |c|
|
74
|
+
c.flag 'user_ids', desc: 'The list of up to 1,000 user IDs to apply the session settings for.'
|
75
|
+
c.flag 'desktop_app_browser_quit', desc: 'Terminate the session when the client—either the desktop app or a browser window—is closed.'
|
76
|
+
c.flag 'duration', desc: "The session duration, in seconds. The minimum value is 28800, which represents 8 hours; the max value is 315569520 or 10 years (that's a long Slack session)."
|
77
|
+
c.action do |_global_options, options, _args|
|
78
|
+
puts JSON.dump(@client.admin_users_session_setSettings(options))
|
79
|
+
end
|
80
|
+
end
|
81
|
+
end
|
76
82
|
end
|
77
83
|
end
|
78
84
|
end
|
@@ -1,15 +1,21 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AdminUsersUnsupportedversions methods.'
|
8
|
+
command 'admin_users_unsupportedVersions' do |g|
|
9
|
+
g.desc 'Ask Slackbot to send you an export listing all workspace members using unsupported software, presented as a zipped CSV file.'
|
10
|
+
g.long_desc %( Ask Slackbot to send you an export listing all workspace members using unsupported software, presented as a zipped CSV file. )
|
11
|
+
g.command 'export' do |c|
|
12
|
+
c.flag 'date_end_of_support', desc: 'Unix timestamp of the date of past or upcoming end of support cycles. If not provided will include all announced end of support cycles.'
|
13
|
+
c.flag 'date_sessions_started', desc: 'Unix timestamp of a date to start looking for user sessions. If not provided will start six months ago.'
|
14
|
+
c.action do |_global_options, options, _args|
|
15
|
+
puts JSON.dump(@client.admin_users_unsupportedVersions_export(options))
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
13
19
|
end
|
14
20
|
end
|
15
21
|
end
|
data/bin/commands/api.rb
CHANGED
@@ -1,14 +1,20 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'Api methods.'
|
8
|
+
command 'api' do |g|
|
9
|
+
g.desc 'Checks API calling code.'
|
10
|
+
g.long_desc %( Checks API calling code. )
|
11
|
+
g.command 'test' do |c|
|
12
|
+
c.flag 'error', desc: 'Error response to return.'
|
13
|
+
c.action do |_global_options, options, _args|
|
14
|
+
puts JSON.dump(@client.api_test(options))
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
12
18
|
end
|
13
19
|
end
|
14
20
|
end
|
data/bin/commands/apps.rb
CHANGED
@@ -1,15 +1,21 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'Apps methods.'
|
8
|
+
command 'apps' do |g|
|
9
|
+
g.desc 'Uninstalls your app from a workspace.'
|
10
|
+
g.long_desc %( Uninstalls your app from a workspace. )
|
11
|
+
g.command 'uninstall' do |c|
|
12
|
+
c.flag 'client_id', desc: 'Issued when you created your application.'
|
13
|
+
c.flag 'client_secret', desc: 'Issued when you created your application.'
|
14
|
+
c.action do |_global_options, options, _args|
|
15
|
+
puts JSON.dump(@client.apps_uninstall(options))
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
13
19
|
end
|
14
20
|
end
|
15
21
|
end
|
@@ -1,13 +1,19 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AppsConnections methods.'
|
8
|
+
command 'apps_connections' do |g|
|
9
|
+
g.desc 'Generate a temporary Socket Mode WebSocket URL that your app can connect to in order to receive events and interactive payloads over.'
|
10
|
+
g.long_desc %( Generate a temporary Socket Mode WebSocket URL that your app can connect to in order to receive events and interactive payloads over. )
|
11
|
+
g.command 'open' do |c|
|
12
|
+
c.action do |_global_options, options, _args|
|
13
|
+
puts JSON.dump(@client.apps_connections_open(options))
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
11
17
|
end
|
12
18
|
end
|
13
19
|
end
|
@@ -1,16 +1,22 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
4
|
+
module Slack
|
5
|
+
module Cli
|
6
|
+
class App
|
7
|
+
desc 'AppsEventAuthorizations methods.'
|
8
|
+
command 'apps_event_authorizations' do |g|
|
9
|
+
g.desc 'Get a list of authorizations for the given event context. Each authorization represents an app installation that the event is visible to.'
|
10
|
+
g.long_desc %( Get a list of authorizations for the given event context. Each authorization represents an app installation that the event is visible to. )
|
11
|
+
g.command 'list' do |c|
|
12
|
+
c.flag 'event_context', desc: '.'
|
13
|
+
c.flag 'cursor', desc: '.'
|
14
|
+
c.flag 'limit', desc: '.'
|
15
|
+
c.action do |_global_options, options, _args|
|
16
|
+
puts JSON.dump(@client.apps_event_authorizations_list(options))
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
14
20
|
end
|
15
21
|
end
|
16
22
|
end
|