Class: XingApi::Group::Post::Comment

Inherits:
Base
  • Object
show all
Defined in:
lib/xing_api/group/post/comment.rb,
lib/xing_api/group/post/comment/like.rb

Defined Under Namespace

Classes: Like

Class Method Summary collapse

Methods inherited from Base

request, request_with_body

Class Method Details

.create(post_id, content, options = {}) ⇒ Object



9
10
11
# File 'lib/xing_api/group/post/comment.rb', line 9

def self.create(post_id, content, options = {})
  request(:post, "/v1/groups/forums/posts/#{post_id}/comments", { content: content }.merge(options))
end

.delete(comment_id, options = {}) ⇒ Object



13
14
15
# File 'lib/xing_api/group/post/comment.rb', line 13

def self.delete(comment_id, options = {})
  request(:delete, "/v1/groups/forums/posts/comments/#{comment_id}", options)
end

.list(post_id, options = {}) ⇒ Object



5
6
7
# File 'lib/xing_api/group/post/comment.rb', line 5

def self.list(post_id, options = {})
  request(:get, "/v1/groups/forums/posts/#{post_id}/comments", options)
end