Class: GooPR::Base

Inherits:
Object
  • Object
show all
Includes:
HTTParty
Defined in:
lib/goopr/base.rb

Instance Method Summary collapse

Constructor Details

#initialize(domain, email, password) ⇒ Base

Returns a new instance of Base.



8
9
10
11
12
13
14
15
# File 'lib/goopr/base.rb', line 8

def initialize(domain,email,password)
  auth_params = {:accountType => 'HOSTED',
    :service => 'apps',
    :Email => CGI.escape(email),
    :Passwd => CGI.escape(password)}
    
  authenticate(auth_params)
end

Instance Method Details

#run(action) ⇒ Object



17
18
19
20
# File 'lib/goopr/base.rb', line 17

def run(action) 
    action.goopr = self
    action.run
end