Module: Slack::Web::Api::Endpoints::TeamExternalteams

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

Instance Method Summary collapse

Instance Method Details

#team_externalTeams_disconnect(options = {}) ⇒ Object

Disconnect an external organization.

Parameters:

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

    a customizable set of options

Options Hash (options):

  • :target_team (Object)

    The team ID of the target team.

Raises:

  • (ArgumentError)

See Also:



16
17
18
19
# File 'lib/slack/web/api/endpoints/team_externalTeams.rb', line 16

def team_externalTeams_disconnect(options = {})
  raise ArgumentError, 'Required arguments :target_team missing' if options[:target_team].nil?
  post('team.externalTeams.disconnect', options)
end

#team_externalTeams_list(options = {}) ⇒ Object

Returns a list of all the external teams connected and details about the connection.

Parameters:

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

    a customizable set of options

Options Hash (options):

  • :connection_status_filter (enum)

    Status of the connected team.

  • :cursor (string)

    Paginate through collections of data by setting parameter to the team_id attribute returned by a previous request’s response_metadata. If not provided, the first page of the collection is returned. See pagination for more detail.

  • :limit (integer)

    The maximum number of items to return per page.

  • :slack_connect_pref_filter (array)

    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 require_sc_channel_for_sc_dm external_awareness_context_bar.

  • :sort_direction (enum)

    Direction to sort in asc or desc.

  • :sort_field (enum)

    Name of the parameter that we are sorting by.

  • :workspace_filter (array)

    Shows connected orgs which are connected on a specified encoded workspace ID.

See Also:



40
41
42
43
44
45
46
47
48
# File 'lib/slack/web/api/endpoints/team_externalTeams.rb', line 40

def team_externalTeams_list(options = {})
  if block_given?
    Pagination::Cursor.new(self, :team_externalTeams_list, options).each do |page|
      yield page
    end
  else
    post('team.externalTeams.list', options)
  end
end