Module: Slack::Web::Search
- Included in:
- Slack::Web
- Defined in:
- lib/slack/web/search.rb
Constant Summary collapse
- SCOPE =
"search"
Instance Method Summary collapse
-
#search_all(params = {}) ⇒ Object
Searches for messages and files matching a query.
-
#search_files(params = {}) ⇒ Object
Searches for files matching a query.
-
#search_messages(params = {}) ⇒ Object
Searches for messages matching a query.
Instance Method Details
#search_all(params = {}) ⇒ Object
Searches for messages and files matching a query.
7 8 9 10 11 |
# File 'lib/slack/web/search.rb', line 7 def search_all(params={}) throw ArgumentError.new("Required arguments :query missing") if params['query'].nil? response = @session.do_get "#{SCOPE}.all", params Slack::parse_response(response) end |
#search_files(params = {}) ⇒ Object
Searches for files matching a query.
14 15 16 17 18 |
# File 'lib/slack/web/search.rb', line 14 def search_files(params={}) throw ArgumentError.new("Required arguments :query missing") if params['query'].nil? response = @session.do_get "#{SCOPE}.files", params Slack::parse_response(response) end |
#search_messages(params = {}) ⇒ Object
Searches for messages matching a query.
21 22 23 24 25 |
# File 'lib/slack/web/search.rb', line 21 def (params={}) throw ArgumentError.new("Required arguments :query missing") if params['query'].nil? response = @session.do_get "#{SCOPE}.messages", params Slack::parse_response(response) end |