Class: Fourcast

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

Instance Method Summary collapse

Constructor Details

#initialize(auth) ⇒ Fourcast

Returns a new instance of Fourcast.



8
9
10
# File 'lib/fourcast.rb', line 8

def initialize(auth)
  @api_key = auth[:api_key]
end

Instance Method Details

#venue(vid, options = {}) ⇒ Object

fourcast = Fourcast.new(:api_key => ‘195070f46e2e787e’) puts fourcast.venue(11761).inspect



14
15
16
17
# File 'lib/fourcast.rb', line 14

def venue(vid, options = {})
  options.merge!({ :query => { :key => @api_key } })
  self.class.get("/venues/#{vid}", options)
end