Module: Wallhaven
- Includes:
- HTTParty
- Defined in:
- lib/wallhaven/version.rb,
lib/wallhaven/wallhaven.rb
Constant Summary collapse
- VERSION =
"1.0.2"
Class Attribute Summary collapse
-
.apikey ⇒ Object
Returns the value of attribute apikey.
Class Method Summary collapse
Class Attribute Details
.apikey ⇒ Object
Returns the value of attribute apikey.
8 9 10 |
# File 'lib/wallhaven/wallhaven.rb', line 8 def apikey @apikey end |
Class Method Details
.search(params = {}) ⇒ Object
15 16 17 |
# File 'lib/wallhaven/wallhaven.rb', line 15 def self.search(params = {}) parse get('/search', query(params )) end |
.settings ⇒ Object
23 24 25 |
# File 'lib/wallhaven/wallhaven.rb', line 23 def self.settings parse get("/settings", query) end |
.tag(id) ⇒ Object
19 20 21 |
# File 'lib/wallhaven/wallhaven.rb', line 19 def self.tag(id) parse get("/tag/#{id}", query) end |
.wallpaper(id) ⇒ Object
11 12 13 |
# File 'lib/wallhaven/wallhaven.rb', line 11 def self.wallpaper(id) parse get("/w/#{id}", query) end |