slack-ruby-client 3.3.0 → 3.4.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/danger-comment.yml +11 -2
- data/.github/workflows/danger.yml +10 -2
- data/.github/workflows/lint.yml +21 -8
- data/.github/workflows/release.yml +27 -0
- data/.gitignore +1 -0
- data/.rubocop.yml +93 -1
- data/.spellcheck.txt +256 -0
- data/AGENTS.md +1 -1
- data/CHANGELOG.md +17 -0
- data/CONTRIBUTING.md +53 -62
- data/Gemfile +20 -4
- data/LICENSE.md +1 -1
- data/README.md +94 -104
- data/RELEASING.md +20 -58
- data/Rakefile +22 -0
- data/SECURITY.md +1 -1
- data/UPGRADING.md +39 -43
- data/benchmarks/events.rb +26 -0
- data/benchmarks/formatting.rb +17 -0
- data/benchmarks/support.rb +67 -0
- data/benchmarks/web_client.rb +28 -0
- data/bin/commands/admin_analytics_members.rb +39 -0
- data/bin/commands/admin_analytics_messages.rb +2 -2
- data/bin/commands/admin_analytics_slackbot.rb +33 -0
- data/bin/commands/admin_apps_permissions.rb +1 -1
- data/bin/commands/admin_conversations.rb +11 -1
- data/bin/commands/admin_slackbot_skills.rb +56 -0
- data/bin/commands/admin_users.rb +11 -2
- data/bin/commands/admin_users_access.rb +31 -0
- data/bin/commands/agents_conversations.rb +122 -0
- data/bin/commands/apps_managed_permissions.rb +2 -2
- data/bin/commands/chat.rb +1 -1
- data/bin/commands/pins.rb +1 -1
- data/bin/commands/slackLists_download.rb +1 -0
- data/bin/commands/slackLists_items.rb +1 -1
- data/bin/commands/slackbot_skills.rb +71 -0
- data/bin/commands/slackbot_skills_library.rb +29 -0
- data/bin/commands/team.rb +1 -0
- data/bin/commands/team_externalTeams.rb +1 -1
- data/examples/files_upload_v2/README.md +4 -3
- data/examples/oauth_v2/README.md +5 -4
- data/lib/slack/messages/formatting.rb +29 -20
- data/lib/slack/version.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_analytics_members.rb +66 -0
- data/lib/slack/web/api/endpoints/admin_analytics_messages.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_analytics_slackbot.rb +54 -0
- data/lib/slack/web/api/endpoints/admin_apps_permissions.rb +1 -1
- data/lib/slack/web/api/endpoints/admin_conversations.rb +16 -1
- data/lib/slack/web/api/endpoints/admin_slackbot_skills.rb +84 -0
- data/lib/slack/web/api/endpoints/admin_users.rb +13 -1
- data/lib/slack/web/api/endpoints/admin_users_access.rb +40 -0
- data/lib/slack/web/api/endpoints/agents_conversations.rb +186 -0
- data/lib/slack/web/api/endpoints/apps_managed_permissions.rb +1 -1
- data/lib/slack/web/api/endpoints/chat.rb +1 -1
- data/lib/slack/web/api/endpoints/pins.rb +1 -1
- data/lib/slack/web/api/endpoints/slackLists_download.rb +2 -0
- data/lib/slack/web/api/endpoints/slackLists_items.rb +1 -1
- data/lib/slack/web/api/endpoints/slackbot_skills.rb +107 -0
- data/lib/slack/web/api/endpoints/slackbot_skills_library.rb +36 -0
- data/lib/slack/web/api/endpoints/team.rb +2 -0
- data/lib/slack/web/api/endpoints/team_externalTeams.rb +1 -1
- data/lib/slack/web/api/endpoints.rb +14 -0
- data/lib/slack/web/api/errors.rb +258 -2
- data/lib/slack/web/api/mixins/ids.id.rb +2 -1
- data/script/release.rb +33 -0
- data/slack-ruby-client.gemspec +1 -2
- metadata +24 -3
|
@@ -0,0 +1,84 @@
|
|
|
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 AdminSlackbotSkills
|
|
9
|
+
#
|
|
10
|
+
# Lists metadata for skills owned by the organization, including invite-only skills.
|
|
11
|
+
#
|
|
12
|
+
# @option options [enum] :category
|
|
13
|
+
# Only return skills in this category.
|
|
14
|
+
# @option options [string] :cursor
|
|
15
|
+
# Continuation from the previous page. Keep all filters and sorting unchanged. Pages can be empty while a continuation remains; continue until next_cursor is empty. Changes during traversal may move results; pagination is not a snapshot.
|
|
16
|
+
# @option options [integer] :limit
|
|
17
|
+
# The maximum number of skills to return. Fewer may be returned even when more remain.
|
|
18
|
+
# @option options [array] :creator_ids
|
|
19
|
+
# Only return skills created by these users. Accepts U or W user IDs.
|
|
20
|
+
# @option options [enum] :publish_status
|
|
21
|
+
# Filter by publication to the org catalog.
|
|
22
|
+
# @option options [enum] :auto_enabled_status
|
|
23
|
+
# Filter by org deployment, independently of publication.
|
|
24
|
+
# @option options [enum] :sort
|
|
25
|
+
# Sort across the inventory. Name uses case-insensitive ordering. Unedited skills use their creation date for date_updated sorting.
|
|
26
|
+
# @option options [enum] :sort_dir
|
|
27
|
+
# Sort direction; file ID breaks ties.
|
|
28
|
+
# @see https://api.slack.com/methods/admin.slackbot.skills.list
|
|
29
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.slackbot.skills/admin.slackbot.skills.list.json
|
|
30
|
+
def admin_slackbot_skills_list(options = {})
|
|
31
|
+
if block_given?
|
|
32
|
+
Pagination::Cursor.new(self, :admin_slackbot_skills_list, options).each do |page|
|
|
33
|
+
yield page
|
|
34
|
+
end
|
|
35
|
+
else
|
|
36
|
+
post('admin.slackbot.skills.list', options)
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
#
|
|
41
|
+
# Publishes Slackbot skills to an organization's catalog.
|
|
42
|
+
#
|
|
43
|
+
# @option options [array] :skill_ids
|
|
44
|
+
# One to 50 skill IDs. Successful items are not rolled back if other items fail.
|
|
45
|
+
# @see https://api.slack.com/methods/admin.slackbot.skills.publish
|
|
46
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.slackbot.skills/admin.slackbot.skills.publish.json
|
|
47
|
+
def admin_slackbot_skills_publish(options = {})
|
|
48
|
+
raise ArgumentError, 'Required arguments :skill_ids missing' if options[:skill_ids].nil?
|
|
49
|
+
post('admin.slackbot.skills.publish', options)
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
#
|
|
53
|
+
# Sets who a Slackbot skill is automatically turned on for.
|
|
54
|
+
#
|
|
55
|
+
# @option options [string] :skill_id
|
|
56
|
+
# Canvas skill to deploy.
|
|
57
|
+
# @option options [enum] :permission_type
|
|
58
|
+
# Deployment audience.
|
|
59
|
+
# @option options [array] :usergroup_ids
|
|
60
|
+
# One to 100 user groups for named_entities. Duplicates count toward the input limit and are stored once. Omit for other permission types.
|
|
61
|
+
# @see https://api.slack.com/methods/admin.slackbot.skills.setAutoEnabled
|
|
62
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.slackbot.skills/admin.slackbot.skills.setAutoEnabled.json
|
|
63
|
+
def admin_slackbot_skills_setAutoEnabled(options = {})
|
|
64
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
65
|
+
raise ArgumentError, 'Required arguments :permission_type missing' if options[:permission_type].nil?
|
|
66
|
+
post('admin.slackbot.skills.setAutoEnabled', options)
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
#
|
|
70
|
+
# Removes Slackbot skills from the org catalog, preserving access, libraries, and deployments.
|
|
71
|
+
#
|
|
72
|
+
# @option options [array] :skill_ids
|
|
73
|
+
# One to 50 skill IDs. Successful items are not rolled back if other items fail.
|
|
74
|
+
# @see https://api.slack.com/methods/admin.slackbot.skills.unpublish
|
|
75
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.slackbot.skills/admin.slackbot.skills.unpublish.json
|
|
76
|
+
def admin_slackbot_skills_unpublish(options = {})
|
|
77
|
+
raise ArgumentError, 'Required arguments :skill_ids missing' if options[:skill_ids].nil?
|
|
78
|
+
post('admin.slackbot.skills.unpublish', options)
|
|
79
|
+
end
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
end
|
|
@@ -27,6 +27,18 @@ module Slack
|
|
|
27
27
|
post('admin.users.assign', options)
|
|
28
28
|
end
|
|
29
29
|
|
|
30
|
+
#
|
|
31
|
+
# Deactivate a user from an enterprise organization and all its workspaces.
|
|
32
|
+
#
|
|
33
|
+
# @option options [string] :user_id
|
|
34
|
+
# The ID of the user to deactivate.
|
|
35
|
+
# @see https://api.slack.com/methods/admin.users.deactivate
|
|
36
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.users/admin.users.deactivate.json
|
|
37
|
+
def admin_users_deactivate(options = {})
|
|
38
|
+
raise ArgumentError, 'Required arguments :user_id missing' if options[:user_id].nil?
|
|
39
|
+
post('admin.users.deactivate', options)
|
|
40
|
+
end
|
|
41
|
+
|
|
30
42
|
#
|
|
31
43
|
# Fetches the expiration timestamp for a guest
|
|
32
44
|
#
|
|
@@ -167,7 +179,7 @@ module Slack
|
|
|
167
179
|
end
|
|
168
180
|
|
|
169
181
|
#
|
|
170
|
-
# Set an existing guest user, admin user, or owner to be a regular user.
|
|
182
|
+
# Set an existing guest user, admin user, or owner to be a regular user. When team_id is an organization, the user is also set to a regular user on every workspace where they are a workspace owner, including workspaces where they were an owner before becoming an org admin or owner.
|
|
171
183
|
#
|
|
172
184
|
# @option options [Object] :team_id
|
|
173
185
|
# The ID of the workspace or organization.
|
|
@@ -0,0 +1,40 @@
|
|
|
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 AdminUsersAccess
|
|
9
|
+
#
|
|
10
|
+
# Pause access across the organization for up to 1,000 frontline members. Success means the request was queued, not that all updates have completed.
|
|
11
|
+
#
|
|
12
|
+
# @option options [array] :user_ids
|
|
13
|
+
# IDs of frontline members in the authenticated organization. Valid users are queued; rejected IDs are returned in invalid_users.
|
|
14
|
+
# @option options [string] :reason
|
|
15
|
+
# Optional explanation for the access change.
|
|
16
|
+
# @see https://api.slack.com/methods/admin.users.access.pause
|
|
17
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.users.access/admin.users.access.pause.json
|
|
18
|
+
def admin_users_access_pause(options = {})
|
|
19
|
+
raise ArgumentError, 'Required arguments :user_ids missing' if options[:user_ids].nil?
|
|
20
|
+
post('admin.users.access.pause', options)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
#
|
|
24
|
+
# Resume access across the organization for up to 1,000 frontline members. Success means the request was queued, not that all updates have completed.
|
|
25
|
+
#
|
|
26
|
+
# @option options [array] :user_ids
|
|
27
|
+
# IDs of frontline members in the authenticated organization. Valid users are queued; rejected IDs are returned in invalid_users.
|
|
28
|
+
# @option options [string] :reason
|
|
29
|
+
# Optional explanation for the access change.
|
|
30
|
+
# @see https://api.slack.com/methods/admin.users.access.resume
|
|
31
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.users.access/admin.users.access.resume.json
|
|
32
|
+
def admin_users_access_resume(options = {})
|
|
33
|
+
raise ArgumentError, 'Required arguments :user_ids missing' if options[:user_ids].nil?
|
|
34
|
+
post('admin.users.access.resume', options)
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,186 @@
|
|
|
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 AgentsConversations
|
|
9
|
+
#
|
|
10
|
+
# Archive a code channel.
|
|
11
|
+
#
|
|
12
|
+
# @option options [string] :channel_id
|
|
13
|
+
# ID of the code channel to archive.
|
|
14
|
+
# @option options [string] :summary_message_ts
|
|
15
|
+
# Timestamp of a message in the code channel to share back as a thread reply on the origin message. Requires the channel to have an origin_link set.
|
|
16
|
+
# @see https://api.slack.com/methods/agents.conversations.archive
|
|
17
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.archive.json
|
|
18
|
+
def agents_conversations_archive(options = {})
|
|
19
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
20
|
+
post('agents.conversations.archive', options)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
#
|
|
24
|
+
# Create a dedicated code channel for an agent session.
|
|
25
|
+
#
|
|
26
|
+
# @option options [string] :team_id
|
|
27
|
+
# Encoded team id to create the channel in. Required for org tokens when origin_channel_id is not provided. When omitted, the workspace is derived from the origin channel.
|
|
28
|
+
# @option options [string] :session_id
|
|
29
|
+
# An opaque identifier for the agent session. When provided, the call is idempotent: if a channel already exists for this session_id, it is returned instead of creating a new one.
|
|
30
|
+
# @option options [string] :name
|
|
31
|
+
# A friendly display name for the code channel. Optional when origin_channel_id and origin_message_ts are provided — in that case the channel is named from the origin message and re-titled automatically. Required when no origin link is given.
|
|
32
|
+
# @option options [boolean] :is_private
|
|
33
|
+
# Whether the code channel is private. When omitted, the channel matches the privacy of origin_channel_id, or is public if no origin is given. An explicit value is always honored, even if it differs from the origin channel's privacy: passing false creates a public channel from a private origin.
|
|
34
|
+
# @option options [string] :origin_channel_id
|
|
35
|
+
# The channel ID where the agent session was initiated from. Must be provided together with origin_message_ts. The channel must be accessible to the calling user and must not be externally shared (Slack Connect). When team_id is omitted with an org token, the channel is created in the same workspace as this origin channel.
|
|
36
|
+
# @option options [string] :origin_message_ts
|
|
37
|
+
# The message timestamp in the origin channel that started the agent session. Must be provided together with origin_channel_id. The author of this message is automatically invited to the newly created code channel.
|
|
38
|
+
# @see https://api.slack.com/methods/agents.conversations.create
|
|
39
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.create.json
|
|
40
|
+
def agents_conversations_create(options = {})
|
|
41
|
+
raise ArgumentError, 'Required arguments :name missing' if options[:name].nil?
|
|
42
|
+
post('agents.conversations.create', options)
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
#
|
|
46
|
+
# Fetch a canvas attached to a code channel.
|
|
47
|
+
#
|
|
48
|
+
# @option options [channel] :channel
|
|
49
|
+
# ID of the agent session channel the canvas belongs to.
|
|
50
|
+
# @option options [Object] :canvas_id
|
|
51
|
+
# Encoded ID of the canvas to fetch.
|
|
52
|
+
# @option options [enum] :content_format
|
|
53
|
+
# Format to render the canvas content in. Defaults to markdown.
|
|
54
|
+
# @option options [boolean] :include_resolved
|
|
55
|
+
# Whether to include resolved comment threads in the response. Defaults to false.
|
|
56
|
+
# @see https://api.slack.com/methods/agents.conversations.getCanvas
|
|
57
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.getCanvas.json
|
|
58
|
+
def agents_conversations_getCanvas(options = {})
|
|
59
|
+
raise ArgumentError, 'Required arguments :channel missing' if options[:channel].nil?
|
|
60
|
+
raise ArgumentError, 'Required arguments :canvas_id missing' if options[:canvas_id].nil?
|
|
61
|
+
options = options.merge(channel: conversations_id(options)['channel']['id']) if options[:channel]
|
|
62
|
+
post('agents.conversations.getCanvas', options)
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
#
|
|
66
|
+
# List the views currently attached to a code channel.
|
|
67
|
+
#
|
|
68
|
+
# @option options [string] :channel_id
|
|
69
|
+
# ID of the code channel to list views for.
|
|
70
|
+
# @see https://api.slack.com/methods/agents.conversations.listViews
|
|
71
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.listViews.json
|
|
72
|
+
def agents_conversations_listViews(options = {})
|
|
73
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
74
|
+
post('agents.conversations.listViews', options)
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
#
|
|
78
|
+
# Remove a view from a code channel.
|
|
79
|
+
#
|
|
80
|
+
# @option options [string] :channel_id
|
|
81
|
+
# ID of the code channel to remove the view from.
|
|
82
|
+
# @option options [string] :view_key
|
|
83
|
+
# Agent-assigned key of the view to remove. Provide exactly one of view_key or view_id.
|
|
84
|
+
# @option options [string] :view_id
|
|
85
|
+
# Encoded channel tab ID of the view to remove. Provide exactly one of view_key or view_id.
|
|
86
|
+
# @see https://api.slack.com/methods/agents.conversations.removeView
|
|
87
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.removeView.json
|
|
88
|
+
def agents_conversations_removeView(options = {})
|
|
89
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
90
|
+
post('agents.conversations.removeView', options)
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
#
|
|
94
|
+
# Replace the full markdown content of a plan canvas attached to a code channel.
|
|
95
|
+
#
|
|
96
|
+
# @option options [channel] :channel
|
|
97
|
+
# ID of the agent session channel the canvas is attached to.
|
|
98
|
+
# @option options [Object] :canvas_id
|
|
99
|
+
# Encoded ID of the canvas whose content to replace.
|
|
100
|
+
# @option options [string] :content
|
|
101
|
+
# The full new canvas content as markdown. The server diffs this against the current content and applies only the changed sections.
|
|
102
|
+
# @see https://api.slack.com/methods/agents.conversations.setCanvasContent
|
|
103
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.setCanvasContent.json
|
|
104
|
+
def agents_conversations_setCanvasContent(options = {})
|
|
105
|
+
raise ArgumentError, 'Required arguments :channel missing' if options[:channel].nil?
|
|
106
|
+
raise ArgumentError, 'Required arguments :canvas_id missing' if options[:canvas_id].nil?
|
|
107
|
+
raise ArgumentError, 'Required arguments :content missing' if options[:content].nil?
|
|
108
|
+
options = options.merge(channel: conversations_id(options)['channel']['id']) if options[:channel]
|
|
109
|
+
post('agents.conversations.setCanvasContent', options)
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
#
|
|
113
|
+
# Register the set of agent-defined slash commands for the calling agent in a code channel.
|
|
114
|
+
#
|
|
115
|
+
# @option options [string] :channel_id
|
|
116
|
+
# ID of the code channel to register commands for.
|
|
117
|
+
# @option options [array] :commands
|
|
118
|
+
# Full set of commands to register for the calling agent in this channel, replacing that agent's previously registered set. Pass an empty array to clear the agent's commands. At most 10 commands may exist across all agents in the channel; names must be unique within the set and must not collide with builtin Slack commands.
|
|
119
|
+
# @see https://api.slack.com/methods/agents.conversations.setCommands
|
|
120
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.setCommands.json
|
|
121
|
+
def agents_conversations_setCommands(options = {})
|
|
122
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
123
|
+
raise ArgumentError, 'Required arguments :commands missing' if options[:commands].nil?
|
|
124
|
+
post('agents.conversations.setCommands', options)
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
#
|
|
128
|
+
# Set properties on a code channel.
|
|
129
|
+
#
|
|
130
|
+
# @option options [string] :channel_id
|
|
131
|
+
# ID of the code channel to update.
|
|
132
|
+
# @option options [string] :title
|
|
133
|
+
# New display title for the agent session.
|
|
134
|
+
# @option options [enum] :status
|
|
135
|
+
# New status for the agent session.
|
|
136
|
+
# @option options [object] :code_channel
|
|
137
|
+
# Code channel properties to set. Only provided fields are updated.
|
|
138
|
+
# @option options [object] :agent_resource
|
|
139
|
+
# Agent resource properties to set. Only provided fields are updated.
|
|
140
|
+
# @see https://api.slack.com/methods/agents.conversations.setProperties
|
|
141
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.setProperties.json
|
|
142
|
+
def agents_conversations_setProperties(options = {})
|
|
143
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
144
|
+
post('agents.conversations.setProperties', options)
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
#
|
|
148
|
+
# Create or update a view in a code channel.
|
|
149
|
+
#
|
|
150
|
+
# @option options [string] :channel_id
|
|
151
|
+
# ID of the code channel to render the view in.
|
|
152
|
+
# @option options [Object] :type
|
|
153
|
+
# The kind of view to create or update. Defaults to html. Determines which other arguments are required: html and diff require content, block_kit requires blocks, and canvas requires canvas_id.
|
|
154
|
+
# @option options [string] :view_key
|
|
155
|
+
# Agent-assigned stable identity for the view (e.g. the source file path on the agent's machine). Used as the upsert key: calls with the same view_key update the same view. Required for html, block_kit, and canvas views; ignored for diff (a diff view is a per-channel singleton).
|
|
156
|
+
# @option options [string] :content
|
|
157
|
+
# View content. For html, a full self-contained HTML document; for diff, raw unified diff text. Capped at 1,000,000 bytes; larger content returns content_too_large. The cap is enforced by the handler (not schema maxLength) so the documented error code actually surfaces instead of a generic argument-validation failure. Required when type is html or diff.
|
|
158
|
+
# @option options [Object] :blocks
|
|
159
|
+
# Block Kit blocks to render in the view tab. Required when type is block_kit; ignored otherwise.
|
|
160
|
+
# @option options [Object] :canvas_id
|
|
161
|
+
# Encoded ID of the canvas to attach as the view. Required when type is canvas; ignored otherwise.
|
|
162
|
+
# @option options [enum] :access_level
|
|
163
|
+
# For canvas views: access level granted to the channel for the canvas tab. Defaults to write. Use comment to grant channel members comment access (read and comment, no editing) so the agent remains the sole author of the canvas text.
|
|
164
|
+
# @option options [string] :agent_content_hash
|
|
165
|
+
# For canvas views: hash of the canvas-derived markdown the agent last wrote, recorded so the agent can later detect human edits to the canvas. Opaque to the server.
|
|
166
|
+
# @option options [string] :base_branch
|
|
167
|
+
# For diff views: base branch name for display purposes.
|
|
168
|
+
# @option options [string] :head_branch
|
|
169
|
+
# For diff views: head branch name for display purposes.
|
|
170
|
+
# @option options [string] :name
|
|
171
|
+
# Display label for the view tab. Preferred over the legacy label argument (name wins if both are supplied). Defaults to the last path segment of view_key, stripped of any .html or .htm extension.
|
|
172
|
+
# @option options [string] :label
|
|
173
|
+
# Deprecated alias for name. Display label for the view tab. Defaults to the last path segment of view_key, stripped of any .html or .htm extension.
|
|
174
|
+
# @option options [object] :csp
|
|
175
|
+
# Content-Security-Policy domain declarations for the view. Domains are validated server-side (https:// only, no private or internal hosts) and persisted.
|
|
176
|
+
# @see https://api.slack.com/methods/agents.conversations.setView
|
|
177
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/agents.conversations/agents.conversations.setView.json
|
|
178
|
+
def agents_conversations_setView(options = {})
|
|
179
|
+
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil?
|
|
180
|
+
post('agents.conversations.setView', options)
|
|
181
|
+
end
|
|
182
|
+
end
|
|
183
|
+
end
|
|
184
|
+
end
|
|
185
|
+
end
|
|
186
|
+
end
|
|
@@ -7,7 +7,7 @@ module Slack
|
|
|
7
7
|
module Endpoints
|
|
8
8
|
module AppsManagedPermissions
|
|
9
9
|
#
|
|
10
|
-
# Set who can interact with a managed app. Lets the builder who created a managed app on a partner platform configure the app's permissions
|
|
10
|
+
# Set who can interact with a managed app. Lets the builder who created a managed app on a partner platform configure the app's permissions, using a user token or bot token from the manager app. Permissions can only be set before the app is installed: if the app is already installed, this method makes no change and returns the app's current permissions.
|
|
11
11
|
#
|
|
12
12
|
# @option options [Object] :app_id
|
|
13
13
|
# Encoded ID of the managed app to configure.
|
|
@@ -12,7 +12,7 @@ module Slack
|
|
|
12
12
|
# @option options [channel] :channel
|
|
13
13
|
# An encoded ID that represents a channel, private group, or DM.
|
|
14
14
|
# @option options [array] :chunks
|
|
15
|
-
# Array of streaming chunks.
|
|
15
|
+
# Array of streaming chunks that can contain either markdown text or task updates.
|
|
16
16
|
# @option options [timestamp] :ts
|
|
17
17
|
# The timestamp of the streaming message.
|
|
18
18
|
# @option options [string] :markdown_text
|
|
@@ -10,7 +10,7 @@ module Slack
|
|
|
10
10
|
# Pins an item to a channel.
|
|
11
11
|
#
|
|
12
12
|
# @option options [channel] :channel
|
|
13
|
-
# Channel to pin the
|
|
13
|
+
# Channel to pin the message to. You must also include a timestamp when pinning messages.
|
|
14
14
|
# @option options [string] :timestamp
|
|
15
15
|
# Timestamp of the message to pin. You must also include the channel.
|
|
16
16
|
# @see https://api.slack.com/methods/pins.add
|
|
@@ -19,6 +19,8 @@ module Slack
|
|
|
19
19
|
# 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.
|
|
20
20
|
# @option options [boolean] :include_attachments
|
|
21
21
|
# 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.
|
|
22
|
+
# @option options [boolean] :include_archived
|
|
23
|
+
# Must match the include_archived passed to slackLists.download.start. The returned download_url carries this through so the served export includes archived items when they were requested.
|
|
22
24
|
# @see https://api.slack.com/methods/slackLists.download.get
|
|
23
25
|
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackLists.download/slackLists.download.get.json
|
|
24
26
|
def slackLists_download_get(options = {})
|
|
@@ -77,7 +77,7 @@ module Slack
|
|
|
77
77
|
# @option options [string] :list_id
|
|
78
78
|
# ID of the List.
|
|
79
79
|
# @option options [integer] :limit
|
|
80
|
-
# The maximum number of records to return.
|
|
80
|
+
# The maximum number of records to return, up to the list row limit of 5000.
|
|
81
81
|
# @option options [string] :cursor
|
|
82
82
|
# Next cursor for pagination.
|
|
83
83
|
# @option options [boolean] :archived
|
|
@@ -0,0 +1,107 @@
|
|
|
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 SlackbotSkills
|
|
9
|
+
#
|
|
10
|
+
# Creates a skill from markdown instructions, or turns an existing canvas the caller owns into a skill.
|
|
11
|
+
#
|
|
12
|
+
# @option options [string] :display_name
|
|
13
|
+
# Human-readable label. Max 255 characters; not unique.
|
|
14
|
+
# @option options [string] :instructions
|
|
15
|
+
# Markdown body of the skill. Send exactly one of instructions or canvas_id.
|
|
16
|
+
# @option options [Object] :canvas_id
|
|
17
|
+
# Canvas the caller owns to turn into a skill. Send exactly one of instructions or canvas_id.
|
|
18
|
+
# @option options [string] :description
|
|
19
|
+
# When Slackbot should use the skill. Max 400 characters.
|
|
20
|
+
# @option options [enum] :category
|
|
21
|
+
# One of the skill categories.
|
|
22
|
+
# @option options [string] :example_prompt
|
|
23
|
+
# Max 200 characters. May contain {skill}, which becomes the skill mention.
|
|
24
|
+
# @option options [array] :mcp_servers
|
|
25
|
+
# Apps the skill needs, capped at the caller's MCP server limit. Declaring an app doesn't grant access to it.
|
|
26
|
+
# @see https://api.slack.com/methods/slackbot.skills.create
|
|
27
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills/slackbot.skills.create.json
|
|
28
|
+
def slackbot_skills_create(options = {})
|
|
29
|
+
raise ArgumentError, 'Required arguments :display_name missing' if options[:display_name].nil?
|
|
30
|
+
post('slackbot.skills.create', options)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
#
|
|
34
|
+
# Deletes a Slackbot skill and its canvas, and removes it from every library, skill set, and the org catalog.
|
|
35
|
+
#
|
|
36
|
+
# @option options [string] :skill_id
|
|
37
|
+
# Skill to delete.
|
|
38
|
+
# @see https://api.slack.com/methods/slackbot.skills.delete
|
|
39
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills/slackbot.skills.delete.json
|
|
40
|
+
def slackbot_skills_delete(options = {})
|
|
41
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
42
|
+
post('slackbot.skills.delete', options)
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
#
|
|
46
|
+
# Returns one Slackbot skill, including its instructions.
|
|
47
|
+
#
|
|
48
|
+
# @option options [string] :skill_id
|
|
49
|
+
# Skill to fetch: a canvas file ID or a builtin: reference.
|
|
50
|
+
# @see https://api.slack.com/methods/slackbot.skills.info
|
|
51
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills/slackbot.skills.info.json
|
|
52
|
+
def slackbot_skills_info(options = {})
|
|
53
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
54
|
+
post('slackbot.skills.info', options)
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
#
|
|
58
|
+
# Lists Slackbot skills from the caller's point of view. Instructions are not included.
|
|
59
|
+
#
|
|
60
|
+
# @option options [enum] :filter
|
|
61
|
+
# library: skills enabled for the caller, including auto-enabled skills and skills from skill sets. owned: skills the caller created. catalog: the organization's official skills.
|
|
62
|
+
# @option options [string] :category
|
|
63
|
+
# Only return skills in this category.
|
|
64
|
+
# @option options [string] :cursor
|
|
65
|
+
# Paginate through collections of data by setting the cursor parameter to a next_cursor attribute returned by a previous request's response_metadata. Must be used with the same filter and category.
|
|
66
|
+
# @option options [integer] :limit
|
|
67
|
+
# The maximum number of skills to return. Fewer may be returned even when more remain.
|
|
68
|
+
# @see https://api.slack.com/methods/slackbot.skills.list
|
|
69
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills/slackbot.skills.list.json
|
|
70
|
+
def slackbot_skills_list(options = {})
|
|
71
|
+
if block_given?
|
|
72
|
+
Pagination::Cursor.new(self, :slackbot_skills_list, options).each do |page|
|
|
73
|
+
yield page
|
|
74
|
+
end
|
|
75
|
+
else
|
|
76
|
+
post('slackbot.skills.list', options)
|
|
77
|
+
end
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
#
|
|
81
|
+
# Changes a Slackbot skill's instructions or metadata. Only the inputs you send are changed; a call that changes nothing succeeds without writing.
|
|
82
|
+
#
|
|
83
|
+
# @option options [string] :skill_id
|
|
84
|
+
# Skill to change.
|
|
85
|
+
# @option options [string] :display_name
|
|
86
|
+
# Human-readable label. Max 255 characters.
|
|
87
|
+
# @option options [string] :instructions
|
|
88
|
+
# Markdown that replaces the whole document.
|
|
89
|
+
# @option options [string] :description
|
|
90
|
+
# When Slackbot should use the skill. Max 400 characters. Send an empty string to clear.
|
|
91
|
+
# @option options [enum] :category
|
|
92
|
+
# One of the skill categories. Send an empty string to clear.
|
|
93
|
+
# @option options [string] :example_prompt
|
|
94
|
+
# Max 200 characters. May contain {skill}. Send an empty string to clear.
|
|
95
|
+
# @option options [array] :mcp_servers
|
|
96
|
+
# Apps the skill needs. Replaces the whole list; send [] to clear.
|
|
97
|
+
# @see https://api.slack.com/methods/slackbot.skills.update
|
|
98
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills/slackbot.skills.update.json
|
|
99
|
+
def slackbot_skills_update(options = {})
|
|
100
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
101
|
+
post('slackbot.skills.update', options)
|
|
102
|
+
end
|
|
103
|
+
end
|
|
104
|
+
end
|
|
105
|
+
end
|
|
106
|
+
end
|
|
107
|
+
end
|
|
@@ -0,0 +1,36 @@
|
|
|
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 SlackbotSkillsLibrary
|
|
9
|
+
#
|
|
10
|
+
# Turns a skill on in the caller's personal library.
|
|
11
|
+
#
|
|
12
|
+
# @option options [string] :skill_id
|
|
13
|
+
# Skill to turn on for the caller.
|
|
14
|
+
# @see https://api.slack.com/methods/slackbot.skills.library.add
|
|
15
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills.library/slackbot.skills.library.add.json
|
|
16
|
+
def slackbot_skills_library_add(options = {})
|
|
17
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
18
|
+
post('slackbot.skills.library.add', options)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
#
|
|
22
|
+
# Turns a skill off in the caller's personal library.
|
|
23
|
+
#
|
|
24
|
+
# @option options [string] :skill_id
|
|
25
|
+
# Skill to turn off for the caller.
|
|
26
|
+
# @see https://api.slack.com/methods/slackbot.skills.library.remove
|
|
27
|
+
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/slackbot.skills.library/slackbot.skills.library.remove.json
|
|
28
|
+
def slackbot_skills_library_remove(options = {})
|
|
29
|
+
raise ArgumentError, 'Required arguments :skill_id missing' if options[:skill_id].nil?
|
|
30
|
+
post('slackbot.skills.library.remove', options)
|
|
31
|
+
end
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
@@ -60,6 +60,8 @@ module Slack
|
|
|
60
60
|
# Query by domain instead of team (only when team is null). This only works for domains in the same enterprise as the querying team token. This also expects the domain to belong to a team and not the enterprise itself. This is the value set up for the 'Joining This Workspace' workspace setting. If it contains more than one domain, the field will contain multiple comma-separated domain values. If no domain is set, the field is empty.
|
|
61
61
|
# @option options [string] :team
|
|
62
62
|
# Team to get info about; if omitted, will return information about the current team.
|
|
63
|
+
# @option options [boolean] :include_slackbot_availability
|
|
64
|
+
# Include advisory Slackbot availability for the returned workspace or organization. Only applies to a single team in the caller's own workspace or organization; omitted for external teams. Does not guarantee individual eligibility, remaining usage, or access to a particular app.
|
|
63
65
|
# @see https://api.slack.com/methods/team.info
|
|
64
66
|
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/team/team.info.json
|
|
65
67
|
def team_info(options = {})
|
|
@@ -30,7 +30,7 @@ module Slack
|
|
|
30
30
|
# @option options [enum] :sort_direction
|
|
31
31
|
# Direction to sort in asc or desc.
|
|
32
32
|
# @option options [array] :slack_connect_pref_filter
|
|
33
|
-
# Filters connected orgs by Slack Connect pref override(s). Value can be: approved_orgs_only allow_sc_file_uploads profile_visibility away_team_sc_invite_permissions accept_sc_invites sc_mpdm_to_private
|
|
33
|
+
# Filters connected orgs by Slack Connect pref override(s). Value can be: approved_orgs_only allow_sc_file_uploads profile_visibility away_team_sc_invite_permissions accept_sc_invites sc_mpdm_to_private external_awareness_context_bar.
|
|
34
34
|
# @option options [array] :workspace_filter
|
|
35
35
|
# Shows connected orgs which are connected on a specified encoded workspace ID.
|
|
36
36
|
# @option options [enum] :connection_status_filter
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
# This file was auto-generated by lib/tasks/web.rake
|
|
3
3
|
|
|
4
4
|
require_relative 'endpoints/admin_analytics'
|
|
5
|
+
require_relative 'endpoints/admin_analytics_members'
|
|
5
6
|
require_relative 'endpoints/admin_analytics_messages'
|
|
7
|
+
require_relative 'endpoints/admin_analytics_slackbot'
|
|
6
8
|
require_relative 'endpoints/admin_apps'
|
|
7
9
|
require_relative 'endpoints/admin_apps_activities'
|
|
8
10
|
require_relative 'endpoints/admin_apps_approved'
|
|
@@ -25,18 +27,21 @@ require_relative 'endpoints/admin_inviteRequests'
|
|
|
25
27
|
require_relative 'endpoints/admin_inviteRequests_approved'
|
|
26
28
|
require_relative 'endpoints/admin_inviteRequests_denied'
|
|
27
29
|
require_relative 'endpoints/admin_roles'
|
|
30
|
+
require_relative 'endpoints/admin_slackbot_skills'
|
|
28
31
|
require_relative 'endpoints/admin_teams'
|
|
29
32
|
require_relative 'endpoints/admin_teams_admins'
|
|
30
33
|
require_relative 'endpoints/admin_teams_owners'
|
|
31
34
|
require_relative 'endpoints/admin_teams_settings'
|
|
32
35
|
require_relative 'endpoints/admin_usergroups'
|
|
33
36
|
require_relative 'endpoints/admin_users'
|
|
37
|
+
require_relative 'endpoints/admin_users_access'
|
|
34
38
|
require_relative 'endpoints/admin_users_session'
|
|
35
39
|
require_relative 'endpoints/admin_users_unsupportedVersions'
|
|
36
40
|
require_relative 'endpoints/admin_workflows'
|
|
37
41
|
require_relative 'endpoints/admin_workflows_collaborators'
|
|
38
42
|
require_relative 'endpoints/admin_workflows_permissions'
|
|
39
43
|
require_relative 'endpoints/admin_workflows_triggers_types_permissions'
|
|
44
|
+
require_relative 'endpoints/agents_conversations'
|
|
40
45
|
require_relative 'endpoints/agents_sessions'
|
|
41
46
|
require_relative 'endpoints/api'
|
|
42
47
|
require_relative 'endpoints/apps'
|
|
@@ -92,6 +97,8 @@ require_relative 'endpoints/slackLists'
|
|
|
92
97
|
require_relative 'endpoints/slackLists_access'
|
|
93
98
|
require_relative 'endpoints/slackLists_download'
|
|
94
99
|
require_relative 'endpoints/slackLists_items'
|
|
100
|
+
require_relative 'endpoints/slackbot_skills'
|
|
101
|
+
require_relative 'endpoints/slackbot_skills_library'
|
|
95
102
|
require_relative 'endpoints/stars'
|
|
96
103
|
require_relative 'endpoints/team'
|
|
97
104
|
require_relative 'endpoints/team_billing'
|
|
@@ -118,7 +125,9 @@ module Slack
|
|
|
118
125
|
include Slack::Web::Api::Mixins::Users
|
|
119
126
|
|
|
120
127
|
include AdminAnalytics
|
|
128
|
+
include AdminAnalyticsMembers
|
|
121
129
|
include AdminAnalyticsMessages
|
|
130
|
+
include AdminAnalyticsSlackbot
|
|
122
131
|
include AdminApps
|
|
123
132
|
include AdminAppsActivities
|
|
124
133
|
include AdminAppsApproved
|
|
@@ -141,18 +150,21 @@ module Slack
|
|
|
141
150
|
include AdminInviterequestsApproved
|
|
142
151
|
include AdminInviterequestsDenied
|
|
143
152
|
include AdminRoles
|
|
153
|
+
include AdminSlackbotSkills
|
|
144
154
|
include AdminTeams
|
|
145
155
|
include AdminTeamsAdmins
|
|
146
156
|
include AdminTeamsOwners
|
|
147
157
|
include AdminTeamsSettings
|
|
148
158
|
include AdminUsergroups
|
|
149
159
|
include AdminUsers
|
|
160
|
+
include AdminUsersAccess
|
|
150
161
|
include AdminUsersSession
|
|
151
162
|
include AdminUsersUnsupportedversions
|
|
152
163
|
include AdminWorkflows
|
|
153
164
|
include AdminWorkflowsCollaborators
|
|
154
165
|
include AdminWorkflowsPermissions
|
|
155
166
|
include AdminWorkflowsTriggersTypesPermissions
|
|
167
|
+
include AgentsConversations
|
|
156
168
|
include AgentsSessions
|
|
157
169
|
include Api
|
|
158
170
|
include Apps
|
|
@@ -208,6 +220,8 @@ module Slack
|
|
|
208
220
|
include SlackListsAccess
|
|
209
221
|
include SlackListsDownload
|
|
210
222
|
include SlackListsItems
|
|
223
|
+
include SlackbotSkills
|
|
224
|
+
include SlackbotSkillsLibrary
|
|
211
225
|
include Stars
|
|
212
226
|
include Team
|
|
213
227
|
include TeamBilling
|