Module: Slack::Web::Api::Endpoints::AdminApps

Included in:
Slack::Web::Api::Endpoints
Defined in:
lib/slack/web/api/endpoints/admin_apps.rb

Instance Method Summary collapse

Instance Method Details

#admin_apps_approve(options = {}) ⇒ Object

Approve an app for installation on a workspace.

Parameters:

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • :app_id (string)

    The id of the app to approve.

  • :enterprise_id (Object)

    The ID of the enterprise to approve the app on.

  • :request_id (string)

    The id of the request to approve.

  • :team_id (Object)

    The ID of the workspace to approve the app on.

See Also:



22
23
24
# File 'lib/slack/web/api/endpoints/admin_apps.rb', line 22

def admin_apps_approve(options = {})
  post('admin.apps.approve', options)
end

#admin_apps_clearResolution(options = {}) ⇒ Object

Clear an app resolution

Parameters:

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • :app_id (string)

    The id of the app whose resolution you want to clear/undo.

  • :enterprise_id (Object)

    The enterprise to clear the app resolution from.

  • :team_id (Object)

    The workspace to clear the app resolution from.

Raises:

  • (ArgumentError)

See Also:



37
38
39
40
# File 'lib/slack/web/api/endpoints/admin_apps.rb', line 37

def admin_apps_clearResolution(options = {})
  raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
  post('admin.apps.clearResolution', options)
end

#admin_apps_restrict(options = {}) ⇒ Object

Restrict an app for installation on a workspace.

Parameters:

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • :app_id (string)

    The id of the app to restrict.

  • :enterprise_id (Object)

    The ID of the enterprise to approve the app on.

  • :request_id (string)

    The id of the request to restrict.

  • :team_id (Object)

    The ID of the workspace to approve the app on.

See Also:



55
56
57
# File 'lib/slack/web/api/endpoints/admin_apps.rb', line 55

def admin_apps_restrict(options = {})
  post('admin.apps.restrict', options)
end

#admin_apps_uninstall(options = {}) ⇒ Object

Uninstall an app from one or many workspaces, or an entire enterprise organization.

Parameters:

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • :app_id (string)

    The ID of the app to uninstall.

  • :enterprise_id (string)

    The enterprise to completely uninstall the application from (across all workspaces). With an org-level token, this or team_ids is required.

  • :team_ids (string)

    IDs of the teams to uninstall from (max 100). With an org-level token, this or enterprise_id is required.

Raises:

  • (ArgumentError)

See Also:



70
71
72
73
# File 'lib/slack/web/api/endpoints/admin_apps.rb', line 70

def admin_apps_uninstall(options = {})
  raise ArgumentError, 'Required arguments :app_id missing' if options[:app_id].nil?
  post('admin.apps.uninstall', options)
end