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.
- checksums.yaml +4 -4
- data/.coveralls.yml +0 -0
- data/.github/FUNDING.yml +0 -0
- data/.github/dependabot.yml +0 -0
- data/.github/prompts/changelog-entries.prompt.yml +32 -0
- data/.github/workflows/danger-comment.yml +0 -0
- data/.github/workflows/danger.yml +0 -0
- data/.github/workflows/lint.yml +2 -0
- data/.github/workflows/test.yml +0 -0
- data/.github/workflows/update_api.yml +86 -6
- data/.gitignore +0 -0
- data/.gitmodules +0 -0
- data/.rspec +0 -0
- data/.rubocop.yml +2 -1
- data/.rubocop_todo.yml +13 -2
- data/.ruby-version +0 -0
- data/AGENTS.md +12 -0
- data/CHANGELOG.md +33 -0
- data/CONTRIBUTING.md +10 -1
- data/Dangerfile +0 -0
- data/Gemfile +17 -5
- data/LICENSE.md +0 -0
- data/README.md +47 -2
- data/RELEASING.md +2 -2
- data/Rakefile +7 -3
- data/SECURITY.md +0 -0
- data/UPGRADING.md +12 -0
- data/bin/commands/admin_analytics.rb +0 -0
- data/bin/commands/admin_analytics_messages.rb +2 -2
- data/bin/commands/admin_apps.rb +0 -0
- data/bin/commands/admin_apps_activities.rb +0 -0
- data/bin/commands/admin_apps_approved.rb +0 -0
- data/bin/commands/admin_apps_config.rb +0 -0
- data/bin/commands/admin_apps_mcp_servers.rb +21 -0
- data/bin/commands/admin_apps_mcp_servers_permissions.rb +33 -0
- data/bin/commands/admin_apps_permissions.rb +58 -0
- data/bin/commands/admin_apps_requests.rb +0 -0
- data/bin/commands/admin_apps_restricted.rb +0 -0
- data/bin/commands/admin_audit_anomaly_allow.rb +0 -0
- data/bin/commands/admin_auth_policy.rb +0 -0
- data/bin/commands/admin_barriers.rb +0 -0
- data/bin/commands/admin_conversations.rb +12 -2
- data/bin/commands/admin_conversations_ekm.rb +0 -0
- data/bin/commands/admin_conversations_restrictAccess.rb +0 -0
- data/bin/commands/admin_emoji.rb +0 -0
- data/bin/commands/admin_functions.rb +1 -1
- data/bin/commands/admin_functions_permissions.rb +0 -0
- data/bin/commands/admin_inviteRequests.rb +0 -0
- data/bin/commands/admin_inviteRequests_approved.rb +0 -0
- data/bin/commands/admin_inviteRequests_denied.rb +0 -0
- data/bin/commands/admin_roles.rb +0 -0
- data/bin/commands/admin_teams.rb +0 -0
- data/bin/commands/admin_teams_admins.rb +0 -0
- data/bin/commands/admin_teams_owners.rb +0 -0
- data/bin/commands/admin_teams_settings.rb +0 -0
- data/bin/commands/admin_usergroups.rb +74 -0
- data/bin/commands/admin_users.rb +0 -0
- data/bin/commands/admin_users_session.rb +0 -1
- data/bin/commands/admin_users_unsupportedVersions.rb +0 -0
- data/bin/commands/admin_workflows.rb +0 -0
- data/bin/commands/admin_workflows_collaborators.rb +0 -0
- data/bin/commands/admin_workflows_permissions.rb +0 -0
- data/bin/commands/admin_workflows_triggers_types_permissions.rb +0 -0
- data/bin/commands/agents_sessions.rb +38 -0
- data/bin/commands/api.rb +0 -0
- data/bin/commands/apps.rb +0 -0
- data/bin/commands/apps_activities.rb +0 -0
- data/bin/commands/apps_auth_external.rb +0 -0
- data/bin/commands/apps_connections.rb +0 -0
- data/bin/commands/apps_datastore.rb +0 -0
- data/bin/commands/apps_event_authorizations.rb +0 -0
- data/bin/commands/apps_icon.rb +0 -0
- data/bin/commands/apps_managed_permissions.rb +21 -0
- data/bin/commands/apps_manifest.rb +0 -0
- data/bin/commands/apps_user_connection.rb +0 -0
- data/bin/commands/assistant_search.rb +0 -0
- data/bin/commands/assistant_threads.rb +1 -1
- data/bin/commands/auth.rb +0 -0
- data/bin/commands/auth_teams.rb +0 -0
- data/bin/commands/blocks.rb +0 -0
- data/bin/commands/bookmarks.rb +0 -0
- data/bin/commands/bots.rb +0 -0
- data/bin/commands/calls.rb +0 -0
- data/bin/commands/calls_participants.rb +0 -0
- data/bin/commands/canvases.rb +12 -2
- data/bin/commands/canvases_access.rb +0 -0
- data/bin/commands/canvases_sections.rb +0 -0
- data/bin/commands/chat.rb +9 -6
- data/bin/commands/chat_scheduledMessages.rb +0 -0
- data/bin/commands/conversations.rb +1 -1
- data/bin/commands/conversations_canvases.rb +1 -1
- data/bin/commands/conversations_externalInvitePermissions.rb +0 -0
- data/bin/commands/conversations_requestSharedInvite.rb +0 -0
- data/bin/commands/dialog.rb +0 -0
- data/bin/commands/dnd.rb +0 -0
- data/bin/commands/emoji.rb +0 -0
- data/bin/commands/entity.rb +27 -0
- data/bin/commands/files.rb +3 -0
- data/bin/commands/files_comments.rb +0 -0
- data/bin/commands/files_remote.rb +0 -0
- data/bin/commands/functions.rb +0 -0
- data/bin/commands/functions_distributions_permissions.rb +0 -0
- data/bin/commands/functions_workflows_steps.rb +0 -0
- data/bin/commands/functions_workflows_steps_responses.rb +0 -0
- data/bin/commands/migration.rb +0 -0
- data/bin/commands/oauth.rb +0 -0
- data/bin/commands/oauth_v2.rb +21 -0
- data/bin/commands/oauth_v2_user.rb +0 -0
- data/bin/commands/openid_connect.rb +0 -0
- data/bin/commands/pins.rb +0 -0
- data/bin/commands/reactions.rb +0 -0
- data/bin/commands/reminders.rb +0 -0
- data/bin/commands/rtm.rb +0 -0
- data/bin/commands/search.rb +0 -0
- data/bin/commands/slackLists.rb +0 -0
- data/bin/commands/slackLists_access.rb +0 -0
- data/bin/commands/slackLists_download.rb +6 -0
- data/bin/commands/slackLists_items.rb +1 -0
- data/bin/commands/stars.rb +0 -0
- data/bin/commands/team.rb +0 -0
- data/bin/commands/team_billing.rb +0 -0
- data/bin/commands/team_externalTeams.rb +0 -0
- data/bin/commands/team_preferences.rb +0 -0
- data/bin/commands/team_profile.rb +0 -0
- data/bin/commands/tooling_tokens.rb +0 -0
- data/bin/commands/usergroups.rb +0 -0
- data/bin/commands/usergroups_users.rb +0 -0
- data/bin/commands/users.rb +1 -0
- data/bin/commands/users_admin.rb +0 -0
- data/bin/commands/users_discoverableContacts.rb +0 -0
- data/bin/commands/users_prefs.rb +0 -0
- data/bin/commands/users_profile.rb +0 -0
- data/bin/commands/views.rb +0 -0
- data/bin/commands/workflows_featured.rb +0 -0
- data/bin/commands/workflows_triggers_permissions.rb +0 -0
- data/bin/slack +5 -1
- data/examples/files_upload_v2/.env.example +0 -0
- data/examples/files_upload_v2/Gemfile +0 -0
- data/examples/files_upload_v2/README.md +0 -0
- data/examples/files_upload_v2/files_upload_v2.rb +1 -1
- data/examples/hi_web/Gemfile +0 -0
- data/examples/hi_web/hi.gif +0 -0
- data/examples/hi_web/hi.rb +1 -1
- data/examples/new_ticket/Gemfile +0 -0
- data/examples/new_ticket/new_ticket.rb +1 -1
- data/examples/oauth_v2/.env.example +0 -0
- data/examples/oauth_v2/Gemfile +0 -0
- data/examples/oauth_v2/README.md +0 -0
- data/examples/oauth_v2/oauth_v2.rb +6 -6
- data/lib/slack/config.rb +0 -0
- data/lib/slack/events/config.rb +1 -1
- data/lib/slack/events/request.rb +2 -2
- data/lib/slack/logger.rb +0 -0
- data/lib/slack/messages/formatting.rb +0 -0
- data/lib/slack/messages/message.rb +0 -0
- data/lib/slack/utils/security.rb +0 -0
- data/lib/slack/version.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_analytics.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_analytics_messages.rb +2 -2
- data/lib/slack/web/api/endpoints/admin_apps.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_apps_activities.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_apps_approved.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_apps_config.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_apps_mcp_servers.rb +31 -0
- data/lib/slack/web/api/endpoints/admin_apps_mcp_servers_permissions.rb +46 -0
- data/lib/slack/web/api/endpoints/admin_apps_permissions.rb +83 -0
- data/lib/slack/web/api/endpoints/admin_apps_requests.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_apps_restricted.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_audit_anomaly_allow.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_auth_policy.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_barriers.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_conversations.rb +16 -1
- data/lib/slack/web/api/endpoints/admin_conversations_ekm.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_conversations_restrictAccess.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_emoji.rb +0 -1
- data/lib/slack/web/api/endpoints/admin_functions.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_functions_permissions.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_inviteRequests.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_inviteRequests_approved.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_inviteRequests_denied.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_roles.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_teams.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_teams_admins.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_teams_owners.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_teams_settings.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_usergroups.rb +111 -0
- data/lib/slack/web/api/endpoints/admin_users.rb +1 -0
- data/lib/slack/web/api/endpoints/admin_users_session.rb +0 -2
- data/lib/slack/web/api/endpoints/admin_users_unsupportedVersions.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_workflows.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_workflows_collaborators.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_workflows_permissions.rb +0 -0
- data/lib/slack/web/api/endpoints/admin_workflows_triggers_types_permissions.rb +0 -0
- data/lib/slack/web/api/endpoints/agents_sessions.rb +54 -0
- data/lib/slack/web/api/endpoints/api.rb +0 -0
- data/lib/slack/web/api/endpoints/apps.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_activities.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_auth_external.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_connections.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_datastore.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_event_authorizations.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_icon.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_managed_permissions.rb +27 -0
- data/lib/slack/web/api/endpoints/apps_manifest.rb +0 -0
- data/lib/slack/web/api/endpoints/apps_user_connection.rb +0 -0
- data/lib/slack/web/api/endpoints/assistant_search.rb +0 -0
- data/lib/slack/web/api/endpoints/assistant_threads.rb +1 -1
- data/lib/slack/web/api/endpoints/auth.rb +0 -0
- data/lib/slack/web/api/endpoints/auth_teams.rb +0 -0
- data/lib/slack/web/api/endpoints/blocks.rb +0 -0
- data/lib/slack/web/api/endpoints/bookmarks.rb +0 -0
- data/lib/slack/web/api/endpoints/bots.rb +0 -0
- data/lib/slack/web/api/endpoints/calls.rb +0 -0
- data/lib/slack/web/api/endpoints/calls_participants.rb +0 -0
- data/lib/slack/web/api/endpoints/canvases.rb +16 -2
- data/lib/slack/web/api/endpoints/canvases_access.rb +0 -0
- data/lib/slack/web/api/endpoints/canvases_sections.rb +0 -0
- data/lib/slack/web/api/endpoints/chat.rb +13 -9
- data/lib/slack/web/api/endpoints/chat_scheduledMessages.rb +0 -0
- data/lib/slack/web/api/endpoints/conversations.rb +1 -1
- data/lib/slack/web/api/endpoints/conversations_canvases.rb +1 -1
- data/lib/slack/web/api/endpoints/conversations_externalInvitePermissions.rb +0 -0
- data/lib/slack/web/api/endpoints/conversations_requestSharedInvite.rb +0 -0
- data/lib/slack/web/api/endpoints/dialog.rb +0 -0
- data/lib/slack/web/api/endpoints/dnd.rb +0 -0
- data/lib/slack/web/api/endpoints/emoji.rb +0 -0
- data/lib/slack/web/api/endpoints/entity.rb +48 -0
- data/lib/slack/web/api/endpoints/files.rb +7 -0
- data/lib/slack/web/api/endpoints/files_comments.rb +0 -0
- data/lib/slack/web/api/endpoints/files_remote.rb +0 -0
- data/lib/slack/web/api/endpoints/functions.rb +0 -0
- data/lib/slack/web/api/endpoints/functions_distributions_permissions.rb +0 -0
- data/lib/slack/web/api/endpoints/functions_workflows_steps.rb +0 -0
- data/lib/slack/web/api/endpoints/functions_workflows_steps_responses.rb +0 -0
- data/lib/slack/web/api/endpoints/migration.rb +0 -0
- data/lib/slack/web/api/endpoints/oauth.rb +0 -0
- data/lib/slack/web/api/endpoints/oauth_v2.rb +33 -0
- data/lib/slack/web/api/endpoints/oauth_v2_user.rb +0 -0
- data/lib/slack/web/api/endpoints/openid_connect.rb +0 -0
- data/lib/slack/web/api/endpoints/pins.rb +0 -0
- data/lib/slack/web/api/endpoints/reactions.rb +0 -0
- data/lib/slack/web/api/endpoints/reminders.rb +0 -0
- data/lib/slack/web/api/endpoints/rtm.rb +0 -0
- data/lib/slack/web/api/endpoints/search.rb +0 -0
- data/lib/slack/web/api/endpoints/slackLists.rb +0 -0
- data/lib/slack/web/api/endpoints/slackLists_access.rb +0 -0
- data/lib/slack/web/api/endpoints/slackLists_download.rb +12 -0
- data/lib/slack/web/api/endpoints/slackLists_items.rb +2 -0
- data/lib/slack/web/api/endpoints/stars.rb +0 -0
- data/lib/slack/web/api/endpoints/team.rb +0 -0
- data/lib/slack/web/api/endpoints/team_billing.rb +0 -0
- data/lib/slack/web/api/endpoints/team_externalTeams.rb +0 -0
- data/lib/slack/web/api/endpoints/team_preferences.rb +0 -0
- data/lib/slack/web/api/endpoints/team_profile.rb +0 -0
- data/lib/slack/web/api/endpoints/tooling_tokens.rb +0 -0
- data/lib/slack/web/api/endpoints/usergroups.rb +0 -0
- data/lib/slack/web/api/endpoints/usergroups_users.rb +0 -0
- data/lib/slack/web/api/endpoints/users.rb +2 -1
- data/lib/slack/web/api/endpoints/users_admin.rb +0 -0
- data/lib/slack/web/api/endpoints/users_discoverableContacts.rb +0 -0
- data/lib/slack/web/api/endpoints/users_prefs.rb +0 -0
- data/lib/slack/web/api/endpoints/users_profile.rb +0 -0
- data/lib/slack/web/api/endpoints/views.rb +0 -0
- data/lib/slack/web/api/endpoints/workflows_featured.rb +0 -0
- data/lib/slack/web/api/endpoints/workflows_triggers_permissions.rb +0 -0
- data/lib/slack/web/api/endpoints.rb +10 -0
- data/lib/slack/web/api/error.rb +0 -0
- data/lib/slack/web/api/errors/server_error.rb +1 -1
- data/lib/slack/web/api/errors/slack_error.rb +1 -1
- data/lib/slack/web/api/errors/too_many_requests_error.rb +1 -1
- data/lib/slack/web/api/errors.rb +126 -8
- data/lib/slack/web/api/helpers/files.rb +2 -2
- data/lib/slack/web/api/helpers.rb +0 -0
- data/lib/slack/web/api/mixins/conversations.id.rb +2 -1
- data/lib/slack/web/api/mixins/ids.id.rb +0 -0
- data/lib/slack/web/api/mixins/users.id.json +0 -0
- data/lib/slack/web/api/mixins/users.id.rb +2 -1
- data/lib/slack/web/api/mixins/users.search.json +0 -0
- data/lib/slack/web/api/mixins/users.search.rb +1 -1
- data/lib/slack/web/api/mixins.rb +0 -0
- data/lib/slack/web/api/options.rb +0 -0
- data/lib/slack/web/api/patches/.gitkeep +0 -0
- data/lib/slack/web/api/patches/files.default-filename.patch +12 -0
- data/lib/slack/web/api/schema/group.json +0 -0
- data/lib/slack/web/api/schema/method.json +0 -0
- data/lib/slack/web/api/templates/command.erb +0 -0
- data/lib/slack/web/api/templates/endpoints.erb +0 -0
- data/lib/slack/web/api/templates/errors.erb +0 -0
- data/lib/slack/web/api/templates/method.erb +0 -0
- data/lib/slack/web/api/templates/method_spec.erb +0 -0
- data/lib/slack/web/client.rb +29 -0
- data/lib/slack/web/config.rb +0 -0
- data/lib/slack/web/faraday/connection.rb +0 -0
- data/lib/slack/web/faraday/options.rb +0 -0
- data/lib/slack/web/faraday/request.rb +22 -2
- data/lib/slack/web/faraday/response/raise_error.rb +0 -0
- data/lib/slack/web/faraday/response/wrap_error.rb +0 -0
- data/lib/slack/web/pagination/cursor.rb +0 -0
- data/lib/slack-ruby-client.rb +0 -0
- data/lib/slack.rb +0 -0
- data/lib/slack_ruby_client.rb +0 -0
- data/lib/tasks/git.rake +0 -0
- data/lib/tasks/update.rake +0 -0
- data/lib/tasks/web.rake +0 -0
- data/slack-ruby-client.gemspec +0 -1
- data/slack.png +0 -0
- metadata +20 -17
data/bin/commands/reactions.rb
CHANGED
|
File without changes
|
data/bin/commands/reminders.rb
CHANGED
|
File without changes
|
data/bin/commands/rtm.rb
CHANGED
|
File without changes
|
data/bin/commands/search.rb
CHANGED
|
File without changes
|
data/bin/commands/slackLists.rb
CHANGED
|
File without changes
|
|
File without changes
|
|
@@ -11,6 +11,9 @@ module Slack
|
|
|
11
11
|
g.command 'get' do |c|
|
|
12
12
|
c.flag 'list_id', desc: 'ID of the List to export.'
|
|
13
13
|
c.flag 'job_id', desc: 'The ID of the recently started job to export the List.'
|
|
14
|
+
c.flag 'format', desc: 'Format the export was started with. Must match the format passed to slackLists.download.start. Defaults to csv.'
|
|
15
|
+
c.flag 'include_threads', desc: 'Must match the include_threads passed to slackLists.download.start. The returned download_url carries this through so the served export matches what was generated. Only applies when format is json.'
|
|
16
|
+
c.flag 'include_attachments', desc: 'Must match the include_attachments passed to slackLists.download.start. The returned download_url carries this through so the served export matches what was generated. Only applies when format is json.'
|
|
14
17
|
c.action do |_global_options, options, _args|
|
|
15
18
|
puts JSON.dump(@client.slackLists_download_get(options))
|
|
16
19
|
end
|
|
@@ -21,6 +24,9 @@ module Slack
|
|
|
21
24
|
g.command 'start' do |c|
|
|
22
25
|
c.flag 'list_id', desc: 'ID of the List to export.'
|
|
23
26
|
c.flag 'include_archived', desc: ''
|
|
27
|
+
c.flag 'format', desc: 'Format of the export. Defaults to csv for backward compatibility. Use json for a complete, hierarchical export.'
|
|
28
|
+
c.flag 'include_threads', desc: "Include each item's conversation thread in the export. Only applies when format is json."
|
|
29
|
+
c.flag 'include_attachments', desc: 'Include file attachment metadata and access paths in the export. Only applies when format is json.'
|
|
24
30
|
c.action do |_global_options, options, _args|
|
|
25
31
|
puts JSON.dump(@client.slackLists_download_start(options))
|
|
26
32
|
end
|
|
@@ -56,6 +56,7 @@ module Slack
|
|
|
56
56
|
c.flag 'limit', desc: 'The maximum number of records to return.'
|
|
57
57
|
c.flag 'cursor', desc: 'Next cursor for pagination.'
|
|
58
58
|
c.flag 'archived', desc: 'Boolean indicating whether archived items or normal items should be returned.'
|
|
59
|
+
c.flag 'include_list', desc: 'Set to true to also return the parent list object, including its title, column schema, and total row count. Defaults to false to keep the response small.'
|
|
59
60
|
c.action do |_global_options, options, _args|
|
|
60
61
|
puts JSON.dump(@client.slackLists_items_list(options))
|
|
61
62
|
end
|
data/bin/commands/stars.rb
CHANGED
|
File without changes
|
data/bin/commands/team.rb
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
data/bin/commands/usergroups.rb
CHANGED
|
File without changes
|
|
File without changes
|
data/bin/commands/users.rb
CHANGED
|
@@ -11,6 +11,7 @@ module Slack
|
|
|
11
11
|
g.command 'conversations' do |c|
|
|
12
12
|
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. Default value fetches the first 'page' of the collection. See pagination for more detail."
|
|
13
13
|
c.flag 'exclude_archived', desc: 'Set to true to exclude archived channels from the list.'
|
|
14
|
+
c.flag 'exclude_muted', desc: 'Set to true to exclude muted channels from the list.'
|
|
14
15
|
c.flag 'limit', desc: "The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached. Must be an integer with a max value of 999."
|
|
15
16
|
c.flag 'team_id', desc: 'encoded team id to list conversations in, required if org token is used.'
|
|
16
17
|
c.flag 'types', desc: 'Mix and match channel types by providing a comma-separated list of any combination of public_channel, private_channel, mpim, im.'
|
data/bin/commands/users_admin.rb
CHANGED
|
File without changes
|
|
File without changes
|
data/bin/commands/users_prefs.rb
CHANGED
|
File without changes
|
|
File without changes
|
data/bin/commands/views.rb
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
data/bin/slack
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
data/examples/hi_web/Gemfile
CHANGED
|
File without changes
|
data/examples/hi_web/hi.gif
CHANGED
|
File without changes
|
data/examples/hi_web/hi.rb
CHANGED
data/examples/new_ticket/Gemfile
CHANGED
|
File without changes
|
|
File without changes
|
data/examples/oauth_v2/Gemfile
CHANGED
|
File without changes
|
data/examples/oauth_v2/README.md
CHANGED
|
File without changes
|
|
@@ -18,8 +18,8 @@ server.mount_proc '/' do |req, res|
|
|
|
18
18
|
|
|
19
19
|
response = client.oauth_v2_access(
|
|
20
20
|
req.query.merge(
|
|
21
|
-
client_id: ENV
|
|
22
|
-
client_secret: ENV
|
|
21
|
+
client_id: ENV.fetch('SLACK_CLIENT_ID', nil),
|
|
22
|
+
client_secret: ENV.fetch('SLACK_CLIENT_SECRET', nil),
|
|
23
23
|
grant_type: 'authorization_code'
|
|
24
24
|
)
|
|
25
25
|
)
|
|
@@ -47,10 +47,10 @@ server.mount_proc '/' do |req, res|
|
|
|
47
47
|
end
|
|
48
48
|
|
|
49
49
|
query = {
|
|
50
|
-
client_id: ENV
|
|
51
|
-
redirect_uri: ENV
|
|
52
|
-
scope: ENV
|
|
53
|
-
user_scope: ENV
|
|
50
|
+
client_id: ENV.fetch('SLACK_CLIENT_ID', nil),
|
|
51
|
+
redirect_uri: ENV.fetch('REDIRECT_URI', nil),
|
|
52
|
+
scope: ENV.fetch('SCOPE', nil),
|
|
53
|
+
user_scope: ENV.fetch('USER_SCOPE', nil)
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
url = "https://slack.com/oauth/v2/authorize?#{query.to_query}"
|
data/lib/slack/config.rb
CHANGED
|
File without changes
|
data/lib/slack/events/config.rb
CHANGED
data/lib/slack/events/request.rb
CHANGED
data/lib/slack/logger.rb
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
data/lib/slack/utils/security.rb
CHANGED
|
File without changes
|
data/lib/slack/version.rb
CHANGED
|
File without changes
|
|
@@ -18,7 +18,7 @@ module Slack
|
|
|
18
18
|
# @option options [string] :cursor
|
|
19
19
|
# Paginate through collections of data by setting the cursor parameter to a next_cursor attribute returned by a previous request's response_metadata. Default value fetches the first "page" of the collection.
|
|
20
20
|
# @option options [integer] :limit
|
|
21
|
-
# Maximum number of entries to return.
|
|
21
|
+
# Maximum number of entries to return. Defaults to 50 if not passed. Max allowed is 100.
|
|
22
22
|
# @see https://api.slack.com/methods/admin.analytics.messages.activity
|
|
23
23
|
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.analytics.messages/admin.analytics.messages.activity.json
|
|
24
24
|
def admin_analytics_messages_activity(options = {})
|
|
@@ -43,7 +43,7 @@ module Slack
|
|
|
43
43
|
# @option options [string] :latest_ts
|
|
44
44
|
# Most recent timestamp to include in the results. If not passed, defaults to current time.
|
|
45
45
|
# @option options [string] :cursor
|
|
46
|
-
# Paginate through collections of data by setting the cursor parameter to a next_cursor attribute returned by a previous request's response_metadata. Default value fetches the first "page" of the collection. See pagination for more
|
|
46
|
+
# Paginate through collections of data by setting the cursor parameter to a next_cursor attribute returned by a previous request's response_metadata. Default value fetches the first "page" of the collection. See pagination for more detail.
|
|
47
47
|
# @see https://api.slack.com/methods/admin.analytics.messages.metadata
|
|
48
48
|
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.analytics.messages/admin.analytics.messages.metadata.json
|
|
49
49
|
def admin_analytics_messages_metadata(options = {})
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
# This file was auto-generated by lib/tasks/web.rake
|
|
3
|
+
|
|
4
|
+
module Slack
|
|
5
|
+
module Web
|
|
6
|
+
module Api
|
|
7
|
+
module Endpoints
|
|
8
|
+
module AdminAppsMcpServers
|
|
9
|
+
#
|
|
10
|
+
# List third-party app MCP servers approved for an organization, derived from the org's MCP server allowlist. Entries reflect allowlist state, not install/scope liveness: servers of apps that are uninstalled (but not deleted) are still listed.
|
|
11
|
+
#
|
|
12
|
+
# @option options [integer] :limit
|
|
13
|
+
# The maximum number of items to return. Must be between 1 - 1000 both inclusive.
|
|
14
|
+
# @option options [string] :cursor
|
|
15
|
+
# Set cursor to next_cursor returned by the previous call to list items in the next page.
|
|
16
|
+
# @see https://api.slack.com/methods/admin.apps.mcp.servers.list
|
|
17
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.mcp.servers/admin.apps.mcp.servers.list.json
|
|
18
|
+
def admin_apps_mcp_servers_list(options = {})
|
|
19
|
+
if block_given?
|
|
20
|
+
Pagination::Cursor.new(self, :admin_apps_mcp_servers_list, options).each do |page|
|
|
21
|
+
yield page
|
|
22
|
+
end
|
|
23
|
+
else
|
|
24
|
+
post('admin.apps.mcp.servers.list', options)
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
# This file was auto-generated by lib/tasks/web.rake
|
|
3
|
+
|
|
4
|
+
module Slack
|
|
5
|
+
module Web
|
|
6
|
+
module Api
|
|
7
|
+
module Endpoints
|
|
8
|
+
module AdminAppsMcpServersPermissions
|
|
9
|
+
#
|
|
10
|
+
# List MCP servers for an app with their access control permissions
|
|
11
|
+
#
|
|
12
|
+
# @option options [string] :app_id
|
|
13
|
+
# Encoded ID of the app.
|
|
14
|
+
# @see https://api.slack.com/methods/admin.apps.mcp.servers.permissions.list
|
|
15
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.mcp.servers.permissions/admin.apps.mcp.servers.permissions.list.json
|
|
16
|
+
def admin_apps_mcp_servers_permissions_list(options = {})
|
|
17
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
18
|
+
post('admin.apps.mcp.servers.permissions.list', options)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
#
|
|
22
|
+
# Set the access control permission for who can use an MCP server
|
|
23
|
+
#
|
|
24
|
+
# @option options [string] :app_id
|
|
25
|
+
# Encoded ID of the app.
|
|
26
|
+
# @option options [string] :server_id
|
|
27
|
+
# Encoded ID of the MCP server.
|
|
28
|
+
# @option options [enum] :permission_type
|
|
29
|
+
# The type of permission that defines who can use this MCP server.
|
|
30
|
+
# @option options [array] :user_ids
|
|
31
|
+
# List of user IDs to set for named_entities or named_entities_exclude.
|
|
32
|
+
# @option options [array] :usergroup_ids
|
|
33
|
+
# List of encoded usergroup IDs.
|
|
34
|
+
# @see https://api.slack.com/methods/admin.apps.mcp.servers.permissions.set
|
|
35
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.mcp.servers.permissions/admin.apps.mcp.servers.permissions.set.json
|
|
36
|
+
def admin_apps_mcp_servers_permissions_set(options = {})
|
|
37
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
38
|
+
raise ArgumentError, 'Required arguments :server_id missing' if options[:server_id].nil?
|
|
39
|
+
raise ArgumentError, 'Required arguments :permission_type missing' if options[:permission_type].nil?
|
|
40
|
+
post('admin.apps.mcp.servers.permissions.set', options)
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
end
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
# This file was auto-generated by lib/tasks/web.rake
|
|
3
|
+
|
|
4
|
+
module Slack
|
|
5
|
+
module Web
|
|
6
|
+
module Api
|
|
7
|
+
module Endpoints
|
|
8
|
+
module AdminAppsPermissions
|
|
9
|
+
#
|
|
10
|
+
# Grant permission for entities to access an app that has its permission type set to named_entities
|
|
11
|
+
#
|
|
12
|
+
# @option options [string] :app_id
|
|
13
|
+
# Encoded ID of the app.
|
|
14
|
+
# @option options [array] :user_ids
|
|
15
|
+
# List of user IDs to allow for named_entities visibility.
|
|
16
|
+
# @option options [array] :usergroup_ids
|
|
17
|
+
# List of encoded usergroup IDs.
|
|
18
|
+
# @option options [array] :channel_ids
|
|
19
|
+
# 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.
|
|
20
|
+
# @see https://api.slack.com/methods/admin.apps.permissions.add
|
|
21
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.permissions/admin.apps.permissions.add.json
|
|
22
|
+
def admin_apps_permissions_add(options = {})
|
|
23
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
24
|
+
post('admin.apps.permissions.add', options)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
#
|
|
28
|
+
# Returns the permission type of an app and if applicable, includes the entities that have been granted access
|
|
29
|
+
#
|
|
30
|
+
# @option options [string] :app_id
|
|
31
|
+
# Encoded ID of the app.
|
|
32
|
+
# @see https://api.slack.com/methods/admin.apps.permissions.list
|
|
33
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.permissions/admin.apps.permissions.list.json
|
|
34
|
+
def admin_apps_permissions_list(options = {})
|
|
35
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
36
|
+
post('admin.apps.permissions.list', options)
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
#
|
|
40
|
+
# Revoke an entity's access to an app that has its permission type set to named_entities
|
|
41
|
+
#
|
|
42
|
+
# @option options [string] :app_id
|
|
43
|
+
# Encoded ID of the app.
|
|
44
|
+
# @option options [array] :user_ids
|
|
45
|
+
# List of user IDs whose named_entities access will be revoked.
|
|
46
|
+
# @option options [array] :usergroup_ids
|
|
47
|
+
# List of encoded usergroup IDs.
|
|
48
|
+
# @option options [array] :channel_ids
|
|
49
|
+
# 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.
|
|
50
|
+
# @see https://api.slack.com/methods/admin.apps.permissions.remove
|
|
51
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.permissions/admin.apps.permissions.remove.json
|
|
52
|
+
def admin_apps_permissions_remove(options = {})
|
|
53
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
54
|
+
post('admin.apps.permissions.remove', options)
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
#
|
|
58
|
+
# Set the permission type for who can access an app
|
|
59
|
+
#
|
|
60
|
+
# @option options [string] :app_id
|
|
61
|
+
# Encoded ID of the app.
|
|
62
|
+
# @option options [enum] :permission_type
|
|
63
|
+
# The type of permission that defines who can access the app.
|
|
64
|
+
# @option options [array] :user_ids
|
|
65
|
+
# List of user IDs to allow for named_entities visibility.
|
|
66
|
+
# @option options [array] :usergroup_ids
|
|
67
|
+
# List of encoded usergroup IDs.
|
|
68
|
+
# @option options [enum] :channel_restriction_mode
|
|
69
|
+
# The mode that defines where the app can be used in channels.
|
|
70
|
+
# @option options [array] :channel_ids
|
|
71
|
+
# List of encoded channel IDs for channel restrictions. Semantics depend on channel_restriction_mode: allowlist for specific_channels, exclusion list for all_channels_except.
|
|
72
|
+
# @see https://api.slack.com/methods/admin.apps.permissions.set
|
|
73
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.permissions/admin.apps.permissions.set.json
|
|
74
|
+
def admin_apps_permissions_set(options = {})
|
|
75
|
+
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
|
|
76
|
+
raise ArgumentError, 'Required arguments :permission_type missing' if options[:permission_type].nil?
|
|
77
|
+
post('admin.apps.permissions.set', options)
|
|
78
|
+
end
|
|
79
|
+
end
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
end
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -58,7 +58,7 @@ module Slack
|
|
|
58
58
|
end
|
|
59
59
|
|
|
60
60
|
#
|
|
61
|
-
# Exclude channels from Slack AI in bulk
|
|
61
|
+
# Exclude channels from Slack AI in bulk.
|
|
62
62
|
#
|
|
63
63
|
# @option options [array] :channel_ids
|
|
64
64
|
# An array of channel IDs to exclude from Slack AI.
|
|
@@ -72,6 +72,21 @@ module Slack
|
|
|
72
72
|
post('admin.conversations.bulkSetExcludeFromSlackAi', options)
|
|
73
73
|
end
|
|
74
74
|
|
|
75
|
+
#
|
|
76
|
+
# Set properties on channels in bulk.
|
|
77
|
+
#
|
|
78
|
+
# @option options [array] :channel_ids
|
|
79
|
+
# An array of channel IDs on which to set the property.
|
|
80
|
+
# @option options [string] :property
|
|
81
|
+
# The property for this channel in a key value format. Only one property can be updated at a time.
|
|
82
|
+
# @see https://api.slack.com/methods/admin.conversations.bulkSetProperties
|
|
83
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.conversations/admin.conversations.bulkSetProperties.json
|
|
84
|
+
def admin_conversations_bulkSetProperties(options = {})
|
|
85
|
+
raise ArgumentError, 'Required arguments :channel_ids missing' if options[:channel_ids].nil?
|
|
86
|
+
raise ArgumentError, 'Required arguments :property missing' if options[:property].nil?
|
|
87
|
+
post('admin.conversations.bulkSetProperties', options)
|
|
88
|
+
end
|
|
89
|
+
|
|
75
90
|
#
|
|
76
91
|
# Convert a public channel to a private channel.
|
|
77
92
|
#
|
|
File without changes
|
|
File without changes
|
|
@@ -17,7 +17,6 @@ module Slack
|
|
|
17
17
|
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.emoji/admin.emoji.add.json
|
|
18
18
|
def admin_emoji_add(options = {})
|
|
19
19
|
raise ArgumentError, 'Required arguments :name missing' if options[:name].nil?
|
|
20
|
-
raise ArgumentError, 'Required arguments :url missing' if options[:url].nil?
|
|
21
20
|
post('admin.emoji.add', options)
|
|
22
21
|
end
|
|
23
22
|
|
|
@@ -14,7 +14,7 @@ module Slack
|
|
|
14
14
|
# @option options [array] :app_ids
|
|
15
15
|
# Comma-separated array of app IDs to get functions for; max 50.
|
|
16
16
|
# @option options [boolean] :include_non_distributed_functions
|
|
17
|
-
# Whether to also include functions that are not yet distributed to any users in the function
|
|
17
|
+
# 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.
|
|
18
18
|
# @option options [string] :cursor
|
|
19
19
|
# Set cursor to next_cursor returned by the previous call to list items in the next page.
|
|
20
20
|
# @option options [integer] :limit
|
|
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
|