Sha256: 4279a5be0d9e7cb1528daa26d52d57d6dd49b5ae1a18e69f90ab1b295991ee01
Contents?: true
Size: 786 Bytes
Versions: 2
Compression:
Stored size: 786 Bytes
Contents
def get_channels(bot_is_in: false) if config.simulate and config.key?(:client) if bot_is_in client.web_client.conversations_members.reject {|r,v| !v.members.include?(config.nick_id)}.values else client.web_client.conversations_members.values end else if bot_is_in client.web_client.users_conversations(exclude_archived: true, limit: 100, types: "im, public_channel,private_channel").channels else #todo: add pagination for case more than 1000 channels on the workspace client.web_client.conversations_list( types: "private_channel,public_channel", limit: "1000", exclude_archived: "true", ).channels end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
slack-smart-bot-1.9.2 | lib/slack/smart-bot/comm/get_channels.rb |
slack-smart-bot-1.9.1 | lib/slack/smart-bot/comm/get_channels.rb |