lib/slack/web/api/endpoints/admin_apps.rb
# frozen_string_literal: true
# This file was auto-generated by lib/tasks/web.rake
module Slack
module Web
module Api
module Endpoints
module AdminApps
#
# Approve an app for installation on a workspace.
#
# @option options [string] :app_id
# The id of the app to approve.
# @option options [Object] :enterprise_id
# The ID of the enterprise to approve the app on.
# @option options [string] :request_id
# The id of the request to approve.
# @option options [Object] :team_id
# The ID of the workspace to approve the app on.
# @see https://api.slack.com/methods/admin.apps.approve
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps/admin.apps.approve.json
def admin_apps_approve(options = {})
post('admin.apps.approve', options)
end
#
# Clear an app resolution
#
# @option options [string] :app_id
# The id of the app whose resolution you want to clear/undo.
# @option options [Object] :enterprise_id
# The enterprise to clear the app resolution from.
# @option options [Object] :team_id
# The workspace to clear the app resolution from.
# @see https://api.slack.com/methods/admin.apps.clearResolution
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps/admin.apps.clearResolution.json
def admin_apps_clearResolution(options = {})
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
post('admin.apps.clearResolution', options)
end
#
# Restrict an app for installation on a workspace.
#
# @option options [string] :app_id
# The id of the app to restrict.
# @option options [Object] :enterprise_id
# The ID of the enterprise to approve the app on.
# @option options [string] :request_id
# The id of the request to restrict.
# @option options [Object] :team_id
# The ID of the workspace to approve the app on.
# @see https://api.slack.com/methods/admin.apps.restrict
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps/admin.apps.restrict.json
def admin_apps_restrict(options = {})
post('admin.apps.restrict', options)
end
#
# Uninstall an app from one or many workspaces, or an entire enterprise organization.
#
# @option options [string] :app_id
# The ID of the app to uninstall.
# @option options [string] :enterprise_id
# The enterprise to completely uninstall the application from (across all workspaces). With an org-level token, this or team_ids is required.
# @option options [string] :team_ids
# IDs of the teams to uninstall from (max 100). With an org-level token, this or enterprise_id is required.
# @see https://api.slack.com/methods/admin.apps.uninstall
# @see https://github.com/slack-ruby/slack-api-ref/blob/master/methods/admin.apps/admin.apps.uninstall.json
def admin_apps_uninstall(options = {})
raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
post('admin.apps.uninstall', options)
end
end
end
end
end
end