Class: Spotted::Resources::Users
- Inherits:
-
Object
- Object
- Spotted::Resources::Users
- Defined in:
- lib/spotted/resources/users.rb,
lib/spotted/resources/users/playlists.rb
Defined Under Namespace
Classes: Playlists
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(client:) ⇒ Users
constructor
private
A new instance of Users.
-
#retrieve_profile(user_id, request_options: {}) ⇒ Spotted::Models::UserRetrieveProfileResponse
Some parameter documentations has been truncated, see Models::UserRetrieveProfileParams for more details.
Constructor Details
#initialize(client:) ⇒ Users
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Users.
35 36 37 38 |
# File 'lib/spotted/resources/users.rb', line 35 def initialize(client:) @client = client @playlists = Spotted::Resources::Users::Playlists.new(client: client) end |
Instance Attribute Details
#playlists ⇒ Spotted::Resources::Users::Playlists (readonly)
7 8 9 |
# File 'lib/spotted/resources/users.rb', line 7 def playlists @playlists end |
Instance Method Details
#retrieve_profile(user_id, request_options: {}) ⇒ Spotted::Models::UserRetrieveProfileResponse
Some parameter documentations has been truncated, see Models::UserRetrieveProfileParams for more details.
Get public profile information about a Spotify user.
23 24 25 26 27 28 29 30 |
# File 'lib/spotted/resources/users.rb', line 23 def retrieve_profile(user_id, params = {}) @client.request( method: :get, path: ["users/%1$s", user_id], model: Spotted::Models::UserRetrieveProfileResponse, options: params[:request_options] ) end |