class Octaccord::Command::GetTeamMembers
Public Class Methods
new(client, teams, **options)
click to toggle source
# File lib/octaccord/command/get_team_members.rb, line 6 def initialize(client, teams, **options) teams.split(',').each do |team| org, team_name = team.split('/') response = client.organization_teams(org) team_id = response.select{|t| t.name == team_name}.first.id response = client.team_members(team_id) members = response.map(&:login) puts members.join(', ') end end