Class: PistonApi::Client
- Inherits:
-
MonsterMash::Base
- Object
- MonsterMash::Base
- PistonApi::Client
- Defined in:
- lib/piston_api/client.rb
Class Method Summary collapse
Class Method Details
.default_params ⇒ Object
24 25 26 27 28 29 30 |
# File 'lib/piston_api/client.rb', line 24 def default_params default_params = { :api_key => PistonApi.api_key } default_params[:sandbox] = '1' if PistonApi.sandbox? default_params end |
.escape_params(params) ⇒ Object
32 33 34 35 |
# File 'lib/piston_api/client.rb', line 32 def escape_params(params) params.each { |k, v| params[k] = CGI.escape(v) } params end |
.uri_for(path) ⇒ Object
20 21 22 |
# File 'lib/piston_api/client.rb', line 20 def uri_for(path) "https://www.mediapiston.com#{path}" end |