Class: SlackChatter::Api::Chat
- Inherits:
-
Base
- Object
- Base
- SlackChatter::Api::Chat
show all
- Defined in:
- lib/slack_chatter/api/chat.rb
Instance Attribute Summary
Attributes inherited from Base
#client
Instance Method Summary
collapse
Methods inherited from Base
#bool_as_i, #call_method, #initialize
Instance Method Details
#delete(timestamp, channel_id) ⇒ Object
9
10
11
|
# File 'lib/slack_chatter/api/chat.rb', line 9
def delete timestamp, channel_id
call_method("chat", "delete", {"channel" => channel_id, "ts" => timestamp})
end
|
#post_message(channel_id, text, opts = {}) ⇒ Object
5
6
7
|
# File 'lib/slack_chatter/api/chat.rb', line 5
def post_message channel_id, text, opts={}
call_method("chat", "postMessage", {"channel" => channel_id, "text" => text}.merge(opts))
end
|
#update(timestamp, channel_id, text) ⇒ Object
13
14
15
|
# File 'lib/slack_chatter/api/chat.rb', line 13
def update timestamp, channel_id, text
call_method("chat", "update", {"channel" => channel_id, "ts" => timestamp, "text" => text})
end
|