Class: Filespot::Request
- Inherits:
-
Object
- Object
- Filespot::Request
- Defined in:
- lib/filespot/request.rb
Class Method Summary collapse
- .delete(api_method = '', uri_params = {}) ⇒ Object
- .get(api_method = '', uri_params = {}) ⇒ Object
- .post(api_method = '', uri_params = {}, post_params = {}) ⇒ Object
Class Method Details
.delete(api_method = '', uri_params = {}) ⇒ Object
17 18 19 20 |
# File 'lib/filespot/request.rb', line 17 def self.delete(api_method = '', uri_params = {}) uri = api_uri('DELETE', api_method, uri_params) connection(uri).delete(uri.query) end |
.get(api_method = '', uri_params = {}) ⇒ Object
7 8 9 10 |
# File 'lib/filespot/request.rb', line 7 def self.get(api_method = '', uri_params = {}) uri = api_uri('GET', api_method, uri_params) connection(uri).get(uri.query) end |
.post(api_method = '', uri_params = {}, post_params = {}) ⇒ Object
12 13 14 15 |
# File 'lib/filespot/request.rb', line 12 def self.post(api_method = '', uri_params = {}, post_params = {}) uri = api_uri('POST', api_method, uri_params) connection(uri).post(uri.query, post_params) end |