-
-
Notifications
You must be signed in to change notification settings - Fork 217
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update API from slack-api-ref@3ec3c10 (2024-09-19)
- Loading branch information
Showing
19 changed files
with
305 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AssistantThreads methods.' | ||
command 'assistant_threads' do |g| | ||
g.desc 'Set the status for an AI assistant thread.' | ||
g.long_desc %( Set the status for an AI assistant thread. ) | ||
g.command 'setStatus' do |c| | ||
c.flag 'channel_id', desc: 'Channel ID containing the assistant thread.' | ||
c.flag 'status', desc: "Status of the specified bot user, e.g. 'is thinking...'." | ||
c.flag 'thread_ts', desc: 'Message timestamp of the thread of where to set the status.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.assistant_threads_setStatus(options)) | ||
end | ||
end | ||
|
||
g.desc 'Set suggested prompts for the given assistant thread' | ||
g.long_desc %( Set suggested prompts for the given assistant thread ) | ||
g.command 'setSuggestedPrompts' do |c| | ||
c.flag 'channel_id', desc: 'Channel ID containing the assistant thread.' | ||
c.flag 'prompts', desc: '.' | ||
c.flag 'thread_ts', desc: 'Message timestamp of the thread to set suggested prompts for.' | ||
c.flag 'title', desc: 'Title for the prompts. Like Suggested Prompts, Related questions.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.assistant_threads_setSuggestedPrompts(options)) | ||
end | ||
end | ||
|
||
g.desc 'Set the title for the given assistant thread' | ||
g.long_desc %( Set the title for the given assistant thread ) | ||
g.command 'setTitle' do |c| | ||
c.flag 'channel_id', desc: 'Channel ID containing the assistant thread.' | ||
c.flag 'thread_ts', desc: 'Message timestamp of the thread to set suggested prompts for.' | ||
c.flag 'title', desc: 'The title to use for the thread.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.assistant_threads_setTitle(options)) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'ConversationsRequestsharedinvite methods.' | ||
command 'conversations_requestSharedInvite' do |g| | ||
g.desc 'Approves a request to add an external user to a channel and sends them a Slack Connect invite' | ||
g.long_desc %( Approves a request to add an external user to a channel and sends them a Slack Connect invite ) | ||
g.command 'approve' do |c| | ||
c.flag 'invite_id', desc: 'ID of the requested shared channel invite to approve.' | ||
c.flag 'channel_id', desc: 'Optional channel_id to which external user will be invited to. Will override the value on the requested invite.' | ||
c.flag 'is_external_limited', desc: 'Optional boolean on whether the invited team will have post-only permissions in the channel. Will override the value on the requested invite.' | ||
c.flag 'message', desc: 'Object describing the text to send along with the invite. If this object is specified, both text and is_override are required properties. If is_override is set to true, text will override the original invitation message. Otherwise, text will be appended to the original invitation message. The total length of the message cannot exceed 560 characters. If is_override is set to false, the length of text and the user specified message on the invite request in total must be less than 560 characters.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.conversations_requestSharedInvite_approve(options)) | ||
end | ||
end | ||
|
||
g.desc 'Denies a request to invite an external user to a channel' | ||
g.long_desc %( Denies a request to invite an external user to a channel ) | ||
g.command 'deny' do |c| | ||
c.flag 'invite_id', desc: 'ID of the requested shared channel invite to deny.' | ||
c.flag 'message', desc: 'Optional message explaining why the request to invite was denied.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.conversations_requestSharedInvite_deny(options)) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Web | ||
module Api | ||
module Endpoints | ||
module AssistantThreads | ||
# | ||
# Set the status for an AI assistant thread. | ||
# | ||
# @option options [Object] :channel_id | ||
# Channel ID containing the assistant thread. | ||
# @option options [string] :status | ||
# Status of the specified bot user, e.g. 'is thinking...'. | ||
# @option options [string] :thread_ts | ||
# Message timestamp of the thread of where to set the status. | ||
# @see https://api.slack.com/methods/assistant.threads.setStatus | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/assistant.threads/assistant.threads.setStatus.json | ||
def assistant_threads_setStatus(options = {}) | ||
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil? | ||
raise ArgumentError, 'Required arguments :status missing' if options[:status].nil? | ||
raise ArgumentError, 'Required arguments :thread_ts missing' if options[:thread_ts].nil? | ||
post('assistant.threads.setStatus', options) | ||
end | ||
|
||
# | ||
# Set suggested prompts for the given assistant thread | ||
# | ||
# @option options [Object] :channel_id | ||
# Channel ID containing the assistant thread. | ||
# @option options [Object] :prompts | ||
# . | ||
# @option options [string] :thread_ts | ||
# Message timestamp of the thread to set suggested prompts for. | ||
# @option options [string] :title | ||
# Title for the prompts. Like Suggested Prompts, Related questions. | ||
# @see https://api.slack.com/methods/assistant.threads.setSuggestedPrompts | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/assistant.threads/assistant.threads.setSuggestedPrompts.json | ||
def assistant_threads_setSuggestedPrompts(options = {}) | ||
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil? | ||
raise ArgumentError, 'Required arguments :prompts missing' if options[:prompts].nil? | ||
raise ArgumentError, 'Required arguments :thread_ts missing' if options[:thread_ts].nil? | ||
post('assistant.threads.setSuggestedPrompts', options) | ||
end | ||
|
||
# | ||
# Set the title for the given assistant thread | ||
# | ||
# @option options [Object] :channel_id | ||
# Channel ID containing the assistant thread. | ||
# @option options [string] :thread_ts | ||
# Message timestamp of the thread to set suggested prompts for. | ||
# @option options [string] :title | ||
# The title to use for the thread. | ||
# @see https://api.slack.com/methods/assistant.threads.setTitle | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/assistant.threads/assistant.threads.setTitle.json | ||
def assistant_threads_setTitle(options = {}) | ||
raise ArgumentError, 'Required arguments :channel_id missing' if options[:channel_id].nil? | ||
raise ArgumentError, 'Required arguments :thread_ts missing' if options[:thread_ts].nil? | ||
raise ArgumentError, 'Required arguments :title missing' if options[:title].nil? | ||
post('assistant.threads.setTitle', options) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
lib/slack/web/api/endpoints/conversations_requestSharedInvite.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Web | ||
module Api | ||
module Endpoints | ||
module ConversationsRequestsharedinvite | ||
# | ||
# Approves a request to add an external user to a channel and sends them a Slack Connect invite | ||
# | ||
# @option options [Object] :invite_id | ||
# ID of the requested shared channel invite to approve. | ||
# @option options [string] :channel_id | ||
# Optional channel_id to which external user will be invited to. Will override the value on the requested invite. | ||
# @option options [boolean] :is_external_limited | ||
# Optional boolean on whether the invited team will have post-only permissions in the channel. Will override the value on the requested invite. | ||
# @option options [object] :message | ||
# Object describing the text to send along with the invite. If this object is specified, both text and is_override are required properties. If is_override is set to true, text will override the original invitation message. Otherwise, text will be appended to the original invitation message. The total length of the message cannot exceed 560 characters. If is_override is set to false, the length of text and the user specified message on the invite request in total must be less than 560 characters. | ||
# @see https://api.slack.com/methods/conversations.requestSharedInvite.approve | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/conversations.requestSharedInvite/conversations.requestSharedInvite.approve.json | ||
def conversations_requestSharedInvite_approve(options = {}) | ||
raise ArgumentError, 'Required arguments :invite_id missing' if options[:invite_id].nil? | ||
post('conversations.requestSharedInvite.approve', options) | ||
end | ||
|
||
# | ||
# Denies a request to invite an external user to a channel | ||
# | ||
# @option options [Object] :invite_id | ||
# ID of the requested shared channel invite to deny. | ||
# @option options [string] :message | ||
# Optional message explaining why the request to invite was denied. | ||
# @see https://api.slack.com/methods/conversations.requestSharedInvite.deny | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/conversations.requestSharedInvite/conversations.requestSharedInvite.deny.json | ||
def conversations_requestSharedInvite_deny(options = {}) | ||
raise ArgumentError, 'Required arguments :invite_id missing' if options[:invite_id].nil? | ||
post('conversations.requestSharedInvite.deny', options) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
Oops, something went wrong.