Module: SimpleSpotify::Actions::Player
- Defined in:
- lib/simplespotify/actions/player.rb
Instance Method Summary collapse
Instance Method Details
#recently_played(limit = 50, after = nil, before = nil) ⇒ Object
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/simplespotify/actions/player.rb', line 5 def recently_played limit=50, after=nil, before=nil query = { limit: limit, } query[:after] = after if after query[:before] = before if before response = get "me/player/recently-played", query: query Model::Collection.of(SimpleSpotify::Model::PlayEvent, response.body) end |