Class: SinglePlatform::Request
- Inherits:
-
Object
- Object
- SinglePlatform::Request
- Defined in:
- lib/single_platform/request.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.get(path, params = {}) ⇒ Object
6 7 8 |
# File 'lib/single_platform/request.rb', line 6 def self.get(path, params={}) new.get(path, params) end |
Instance Method Details
#get(path, params = {}) ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/single_platform/request.rb', line 10 def get(path, params={}) client.get do |req| req.url path req.headers['Accept'] = 'application/json' params.each do |key, value| req.params[key] = value end req.params['client'] = SinglePlatform.config.client_id req.params['sig'] = signature(path, params) end end |