module Slack::Web::Api::Endpoints::Files
def files_delete(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.delete.json -
See: https://api.slack.com/methods/files.delete -
Options Hash:
(**options)-
:file(file) --
def files_delete(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? post('files.delete', options) end
def files_edit(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/undocumented/files/files.edit.json -
Options Hash:
(**options)-
:filetype(Object) -- -
:title(Object) -- -
:file(Object) --
def files_edit(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? throw ArgumentError.new('Required arguments :title missing') if options[:title].nil? logger.warn('The files.edit method is undocumented.') post('files.edit', options) end
def files_info(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.info.json -
See: https://api.slack.com/methods/files.info -
Options Hash:
(**options)-
:limit(Object) -- -
:cursor(Object) -- -
:file(file) --
def files_info(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? if block_given? Pagination::Cursor.new(self, :files_info, options).each do |page| yield page end else post('files.info', options) end end
def files_list(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.list.json -
See: https://api.slack.com/methods/files.list -
Options Hash:
(**options)-
:user(user) -- -
:types(Object) -- -
:ts_to(Object) -- -
:ts_from(Object) -- -
:channel(channel) --
def files_list(options = {}) options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] options = options.merge(user: users_id(options)['user']['id']) if options[:user] post('files.list', options) end
def files_revokePublicURL(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.revokePublicURL.json -
See: https://api.slack.com/methods/files.revokePublicURL -
Options Hash:
(**options)-
:file(file) --
def files_revokePublicURL(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? post('files.revokePublicURL', options) end
def files_share(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/undocumented/files/files.share.json -
Options Hash:
(**options)-
:channel(channel) -- -
:file(Object) --
def files_share(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? throw ArgumentError.new('Required arguments :channel missing') if options[:channel].nil? options = options.merge(channel: channels_id(options)['channel']['id']) if options[:channel] logger.warn('The files.share method is undocumented.') post('files.share', options) end
def files_sharedPublicURL(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.sharedPublicURL.json -
See: https://api.slack.com/methods/files.sharedPublicURL -
Options Hash:
(**options)-
:file(file) --
def files_sharedPublicURL(options = {}) throw ArgumentError.new('Required arguments :file missing') if options[:file].nil? post('files.sharedPublicURL', options) end
def files_upload(options = {})
- See: https://github.com/slack-ruby/slack-api-ref/blob/master/methods/files/files.upload.json -
See: https://api.slack.com/methods/files.upload -
Options Hash:
(**options)-
:title(Object) -- -
:thread_ts(Object) -- -
:initial_comment(Object) -- -
:filetype(Object) -- -
:filename(Object) -- -
:file(file) -- -
:content(Object) -- -
:channels(Object) --
def files_upload(options = {}) post('files.upload', options) end