Class: Spotify::MeResource

Inherits:
Resource show all
Defined in:
lib/spotify/resources/me.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 Spotify::Resource

Instance Method Details

#meObject



3
4
5
6
# File 'lib/spotify/resources/me.rb', line 3

def me
  response = get_request("me")
  User.new response.body
end

#playlists(**params) ⇒ Object



8
9
10
11
# File 'lib/spotify/resources/me.rb', line 8

def playlists(**params)
  response = get_request("me/playlists", params: params)
  Collection.from_response(response, type: Playlist, key: "items")
end