lib/slack/web/api/endpoints/files.rb in slack-ruby-client-0.5.1 vs lib/slack/web/api/endpoints/files.rb in slack-ruby-client-0.5.2
- old
+ new
@@ -4,9 +4,27 @@
module Web
module Api
module Endpoints
module Files
#
+ # Edit an existing comment on a file. Only the user who created a comment may make edits. Teams may configure a limited time window during which file comment edits are allowed.
+ #
+ # @option options [file] :file
+ # File containing the comment to edit.
+ # @option options [Object] :id
+ # The comment to edit.
+ # @option options [Object] :comment
+ # Text of the comment to edit.
+ # @see https://api.slack.com/methods/files.comments
+ # @see https://github.com/dblock/slack-api-ref/blob/master/methods/files.comments.json
+ def files_comments(options = {})
+ throw ArgumentError.new('Required arguments :file missing') if options[:file].nil?
+ throw ArgumentError.new('Required arguments :id missing') if options[:id].nil?
+ throw ArgumentError.new('Required arguments :comment missing') if options[:comment].nil?
+ post('files.comments', options)
+ end
+
+ #
# This method deletes a file from your team.
#
# @option options [file] :file
# ID of file to delete.
# @see https://api.slack.com/methods/files.delete