Class: MetaNexus::Wow::Auction
- Inherits:
-
MetaNexus::Wow
- Object
- Api
- MetaNexus::Wow
- MetaNexus::Wow::Auction
- Defined in:
- lib/meta_nexus/wow/auction.rb
Class Method Summary collapse
-
.find(realm) ⇒ Object
Find Auction in Battle.net WoW Api Required arguments: realm - realm name.
Methods inherited from MetaNexus::Wow
Methods inherited from Api
Class Method Details
.find(realm) ⇒ Object
Find Auction in Battle.net WoW Api Required arguments: realm - realm name
Example:
auction = MetaNexus::Wow::Auction
auction.find('eversong')
Response in Hash:
{"id"=>200, "title"=>"Persistent Defender", "points"=>10, "description"=>"Return 50 flags as a defender in Warsong Gulch.", "rewardItems"=>[], "icon"=>"Auction_bg_interruptx_flagcapture_attempts", "criteria"=>[{"id"=>440, "description"=>"Return the flag 50 times", "orderIndex"=>1, "max"=>50}], "accountWide"=>false, "factionId"=>2}
14 15 16 17 18 |
# File 'lib/meta_nexus/wow/auction.rb', line 14 def self.find(realm) client = MetaNexus::Wow.new call_url = "#{client.url}/auction/data/#{realm}?locale=#{MetaNexus.config.locale}&apikey=#{MetaNexus.config.api_key}" MetaNexus::Api.call_api(call_url) end |