-
-
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@f2e768a (2023-09-13)
- Loading branch information
Showing
30 changed files
with
567 additions
and
13 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,31 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminAppsConfig methods.' | ||
command 'admin_apps_config' do |g| | ||
g.desc 'Look up the app config for connectors by their IDs' | ||
g.long_desc %( Look up the app config for connectors by their IDs ) | ||
g.command 'lookup' do |c| | ||
c.flag 'app_ids', desc: 'An array of app IDs to get app configs for.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_apps_config_lookup(options)) | ||
end | ||
end | ||
|
||
g.desc 'Set the app config for a connector' | ||
g.long_desc %( Set the app config for a connector ) | ||
g.command 'set' do |c| | ||
c.flag 'app_id', desc: 'The encoded app ID to set the app config for.' | ||
c.flag 'domain_restrictions', desc: 'Domain restrictions for the app.' | ||
c.flag 'workflow_auth_strategy', desc: 'The workflow auth permission.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_apps_config_set(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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminFunctions methods.' | ||
command 'admin_functions' do |g| | ||
g.desc 'Look up functions by a set of apps' | ||
g.long_desc %( Look up functions by a set of apps ) | ||
g.command 'list' do |c| | ||
c.flag 'app_ids', desc: 'Comma-separated array of app IDs to get functions for; max 50.' | ||
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.' | ||
c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation. Must be between 1 and 1000, both inclusive.' | ||
c.flag 'team_id', desc: 'The team context to retrieve functions from.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_functions_list(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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminFunctionsPermissions methods.' | ||
command 'admin_functions_permissions' do |g| | ||
g.desc 'Lookup the visibility of multiple Slack functions and include the users if it is limited to particular named entities.' | ||
g.long_desc %( Lookup the visibility of multiple Slack functions and include the users if it is limited to particular named entities. ) | ||
g.command 'lookup' do |c| | ||
c.flag 'function_ids', desc: 'An array of function IDs to get permissions for.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_functions_permissions_lookup(options)) | ||
end | ||
end | ||
|
||
g.desc 'Set the visibility of a Slack function and define the users or workspaces if it is set to named_entities' | ||
g.long_desc %( Set the visibility of a Slack function and define the users or workspaces if it is set to named_entities ) | ||
g.command 'set' do |c| | ||
c.flag 'function_id', desc: 'The function ID to set permissions for.' | ||
c.flag 'visibility', desc: 'The function visibility.' | ||
c.flag 'user_ids', desc: 'List of user IDs to allow for named_entities visibility.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_functions_permissions_set(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,38 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminWorkflows methods.' | ||
command 'admin_workflows' do |g| | ||
g.desc 'Search workflows within the team or enterprise' | ||
g.long_desc %( Search workflows within the team or enterprise ) | ||
g.command 'search' do |c| | ||
c.flag 'app_id', desc: 'The parent app ID for which to return workflows.' | ||
c.flag 'collaborator_ids', desc: 'Only include workflows by the collaborators inputted.' | ||
c.flag 'cursor', desc: 'Set cursor to next_cursor returned by the previous call to list items in the next page.' | ||
c.flag 'limit', desc: 'The number of results that will be returned by the API on each invocation.' | ||
c.flag 'no_collaborators', desc: 'Only include workflows with no collaborators in the result; default is false.' | ||
c.flag 'num_trigger_ids', desc: 'Number of trigger IDs to fetch for each workflow; default is 0.' | ||
c.flag 'query', desc: 'A search query to filter for workflow name or description.' | ||
c.flag 'sort', desc: 'The field used to sort the returned workflows.' | ||
c.flag 'sort_dir', desc: 'Sort direction. Possible values are asc for ascending order like (1, 2, 3) or (a, b, c), and desc for descending order like (3, 2, 1) or (c, b, a).' | ||
c.flag 'source', desc: 'Source of workflow creation, either from code or workflow builder.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_workflows_search(options)) | ||
end | ||
end | ||
|
||
g.desc 'Unpublish workflows within the team or enterprise' | ||
g.long_desc %( Unpublish workflows within the team or enterprise ) | ||
g.command 'unpublish' do |c| | ||
c.flag 'workflow_ids', desc: 'Array of workflow IDs to unpublish.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_workflows_unpublish(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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminWorkflowsCollaborators methods.' | ||
command 'admin_workflows_collaborators' do |g| | ||
g.desc 'Add collaborators to workflows within the team or enterprise' | ||
g.long_desc %( Add collaborators to workflows within the team or enterprise ) | ||
g.command 'add' do |c| | ||
c.flag 'collaborator_ids', desc: 'Array of collaborators (encoded user IDs) to add; max 50.' | ||
c.flag 'workflow_ids', desc: 'Array of workflow IDs to edit; max 50.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_workflows_collaborators_add(options)) | ||
end | ||
end | ||
|
||
g.desc 'Remove collaborators from workflows within the team or enterprise' | ||
g.long_desc %( Remove collaborators from workflows within the team or enterprise ) | ||
g.command 'remove' do |c| | ||
c.flag 'collaborator_ids', desc: 'Array of collaborators (encoded user IDs) to remove; max 50.' | ||
c.flag 'workflow_ids', desc: 'Array of workflow IDs to edit; max 50.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_workflows_collaborators_remove(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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Cli | ||
class App | ||
desc 'AdminWorkflowsPermissions methods.' | ||
command 'admin_workflows_permissions' do |g| | ||
g.desc 'Look up the permissions for a set of workflows' | ||
g.long_desc %( Look up the permissions for a set of workflows ) | ||
g.command 'lookup' do |c| | ||
c.flag 'workflow_ids', desc: 'An array of workflow IDs to look up permissions for.' | ||
c.flag 'max_workflow_triggers', desc: 'Maximum number of triggers to fetch for each workflow when determining overall run permissions; max 1000.' | ||
c.action do |_global_options, options, _args| | ||
puts JSON.dump(@client.admin_workflows_permissions_lookup(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,40 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Web | ||
module Api | ||
module Endpoints | ||
module AdminAppsConfig | ||
# | ||
# Look up the app config for connectors by their IDs | ||
# | ||
# @option options [array] :app_ids | ||
# An array of app IDs to get app configs for. | ||
# @see https://api.slack.com/methods/admin.apps.config.lookup | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.config/admin.apps.config.lookup.json | ||
def admin_apps_config_lookup(options = {}) | ||
raise ArgumentError, 'Required arguments :app_ids missing' if options[:app_ids].nil? | ||
post('admin.apps.config.lookup', options) | ||
end | ||
|
||
# | ||
# Set the app config for a connector | ||
# | ||
# @option options [Object] :app_id | ||
# The encoded app ID to set the app config for. | ||
# @option options [object] :domain_restrictions | ||
# Domain restrictions for the app. | ||
# @option options [string] :workflow_auth_strategy | ||
# The workflow auth permission. | ||
# @see https://api.slack.com/methods/admin.apps.config.set | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps.config/admin.apps.config.set.json | ||
def admin_apps_config_set(options = {}) | ||
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil? | ||
post('admin.apps.config.set', 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# frozen_string_literal: true | ||
# This file was auto-generated by lib/tasks/web.rake | ||
|
||
module Slack | ||
module Web | ||
module Api | ||
module Endpoints | ||
module AdminFunctions | ||
# | ||
# Look up functions by a set of apps | ||
# | ||
# @option options [array] :app_ids | ||
# Comma-separated array of app IDs to get functions for; max 50. | ||
# @option options [string] :cursor | ||
# Set cursor to next_cursor returned by the previous call to list items in the next page. | ||
# @option options [integer] :limit | ||
# The number of results that will be returned by the API on each invocation. Must be between 1 and 1000, both inclusive. | ||
# @option options [Object] :team_id | ||
# The team context to retrieve functions from. | ||
# @see https://api.slack.com/methods/admin.functions.list | ||
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.functions/admin.functions.list.json | ||
def admin_functions_list(options = {}) | ||
raise ArgumentError, 'Required arguments :app_ids missing' if options[:app_ids].nil? | ||
if block_given? | ||
Pagination::Cursor.new(self, :admin_functions_list, options).each do |page| | ||
yield page | ||
end | ||
else | ||
post('admin.functions.list', options) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end |
Oops, something went wrong.