Module: Songkick::User
- Included in:
- Client
- Defined in:
- lib/songkick/client/user.rb
Instance Method Summary collapse
-
#attendance(username, event_id) ⇒ Object
Attendance.
-
#gigography(username, page = 1) ⇒ Object
Find past events that a user attended For upcoming events use user_calendar method Important: Only public profiles are considered.
-
#muted_artists(page = 1) ⇒ Object
Paginated list of muted artists.
-
#track_artist(username, artist_id) ⇒ Object
Track an artist.
-
#track_location(usersame, location_id) ⇒ Object
Track a location.
-
#tracked_artists(username, page = 1) ⇒ Object
Get tracked artists for a user Example: sg = Songkick.new(“myapikey”) artists = sg.tracked_artists(“saleandro”).
-
#tracked_locations(username, page = 1) ⇒ Object
Get tracked locations for a user Example: sg = Songkick.new(“myapikey”) locations = sg.tracked_locations(“saleandro”).
Instance Method Details
#attendance(username, event_id) ⇒ Object
Attendance
43 44 45 |
# File 'lib/songkick/client/user.rb', line 43 def attendance(username, event_id) get "users/#{username}/trackings/event:#{event_id}.#{format}" end |
#gigography(username, page = 1) ⇒ Object
Find past events that a user attended For upcoming events use user_calendar method Important: Only public profiles are considered
Example: sg = Songkick.new(“myapikey”) gigs = song.gigography(“saleandro”)
12 13 14 |
# File 'lib/songkick/client/user.rb', line 12 def gigography(username, page = 1) get "users/#{username}/gigography.#{format}", page end |
#muted_artists(page = 1) ⇒ Object
Paginated list of muted artists.
48 49 50 |
# File 'lib/songkick/client/user.rb', line 48 def muted_artists(page = 1) get "users/#{username}/artists/muted.#{format}", page end |
#track_artist(username, artist_id) ⇒ Object
Track an artist
33 34 35 |
# File 'lib/songkick/client/user.rb', line 33 def track_artist(username, artist_id) get "users/#{username}/trackings/artist:#{artist_id}.#{format}" end |
#track_location(usersame, location_id) ⇒ Object
Track a location
38 39 40 |
# File 'lib/songkick/client/user.rb', line 38 def track_location(usersame, location_id) get "users/#{username}/trackings/metro_area:#{location_id}.#{format}" end |
#tracked_artists(username, page = 1) ⇒ Object
Get tracked artists for a user Example: sg = Songkick.new(“myapikey”) artists = sg.tracked_artists(“saleandro”)
28 29 30 |
# File 'lib/songkick/client/user.rb', line 28 def tracked_artists(username, page = 1) get "users/#{username}/artists/tracked.#{format}", page end |
#tracked_locations(username, page = 1) ⇒ Object
Get tracked locations for a user Example: sg = Songkick.new(“myapikey”) locations = sg.tracked_locations(“saleandro”)
20 21 22 |
# File 'lib/songkick/client/user.rb', line 20 def tracked_locations(username, page = 1) get "users/#{username}/metro_areas/tracked.#{format}", page end |