module Shopkit
Constants
- VERSION
Public Class Methods
method_missing(method, *args, &block)
click to toggle source
Delegate to Shopkit::Client.new
Calls superclass method
# File lib/shopkit.rb, line 20 def method_missing(method, *args, &block) return super unless new.respond_to?(method) new.send(method, *args, &block) end
new(options={})
click to toggle source
@return [Shopkit::Client]
# File lib/shopkit.rb, line 10 def new(options={}) options['url'] = self.url options['access_token'] = self.access_token options['login'] = self.login options['password'] = self.password Shopkit::Client.new(options) end
setup(options)
click to toggle source
# File lib/shopkit.rb, line 25 def setup(options) self.url = options[:url] self.url = "http://#{self.url}" unless self.url.start_with?('http://', 'https://') self.access_token = options[:access_token] self.login = options[:login] # or basic auth self.password = options[:password] options end