module Slack::Web::Api::Endpoints::Im
def im_close(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.close.json -
See: https://api.slack.com/methods/im.close -
Options Hash:
(**options)-
:channel(im) --
def im_close(options = {}) throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil? options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] post('im.close', options) end
def im_history(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.history.json -
See: https://api.slack.com/methods/im.history -
Options Hash:
(**options)-
:unreads(Object) -- -
:oldest(timestamp) -- -
:latest(timestamp) -- -
:inclusive(Object) -- -
:channel(im) --
def im_history(options = {}) throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil? options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] post('im.history', options) end
def im_list(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.list.json -
See: https://api.slack.com/methods/im.list -
Options Hash:
(**options)-
:limit(Object) -- -
:cursor(Object) --
def im_list(options = {}) if block_given? Pagination::Cursor.new(self, :im_list, options).each do |page| yield page end else post('im.list', options) end end
def im_mark(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.mark.json -
See: https://api.slack.com/methods/im.mark -
Options Hash:
(**options)-
:ts(timestamp) -- -
:channel(im) --
def im_mark(options = {}) throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil? throw ArgumentError.new('Required arguments :ts missing') if options[:ts].nil? options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] post('im.mark', options) end
def im_open(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.open.json -
See: https://api.slack.com/methods/im.open -
Options Hash:
(**options)-
:return_im(Object) -- -
:include_locale(Object) -- -
:user(user) --
def im_open(options = {}) throw ArgumentError.new('Required arguments :user missing') if options[:user].nil? options = options.merge(user: users_id(options)['user']['id']) if options[:user] post('im.open', options) end
def im_replies(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/im/im.replies.json -
See: https://api.slack.com/methods/im.replies -
Options Hash:
(**options)-
:thread_ts(Object) -- -
:channel(im) --
def im_replies(options = {}) throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil? throw ArgumentError.new('Required arguments :thread_ts missing') if options[:thread_ts].nil? options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] post('im.replies', options) end