Class: ChessApi::DailyPuzzleResource

Inherits:
Resource
  • Object
show all
Defined in:
lib/chess_api/resources/daily_puzzles.rb

Instance Attribute Summary

Attributes inherited from Resource

#client

Instance Method Summary collapse

Methods inherited from Resource

#initialize

Constructor Details

This class inherits a constructor from ChessApi::Resource

Instance Method Details

#randomObject



9
10
11
12
13
# File 'lib/chess_api/resources/daily_puzzles.rb', line 9

def random
  ChessApi::DailyPuzzle.new(
    get_request("puzzle/random").body
  )
end

#retrieveObject



3
4
5
6
7
# File 'lib/chess_api/resources/daily_puzzles.rb', line 3

def retrieve
  ChessApi::DailyPuzzle.new(
    get_request("puzzle").body
  )
end