Sha256: 0c638b3fcbfbf90361baa690d1a9f29433bb8e6ac50c04084b88c9a50980e294

Contents?: true

Size: 400 Bytes

Versions: 4

Compression:

Stored size: 400 Bytes

Contents

#!/usr/bin/env ruby

require 'rubygems'
require 'rest_client'
require 'json'
require 'pp'

puts "getting all playlists"
resp = RestClient.get 'http://localhost:3000/playlists'
playlists = JSON.parse(resp)
pp playlists

playlists['result']['playlists'].each do |p|
  puts "retrieving details for playlist #{p['name']}:"
  pp JSON.parse(RestClient.get "http://localhost:3000/playlists/#{p['id']}")
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
jberkel-spotify-api-0.0.1 examples/list_playlists.rb
jberkel-spotify-api-0.0.2 examples/list_playlists.rb
jberkel-spotify-api-0.0.3 examples/list_playlists.rb
jberkel-spotify-api-0.0.4 examples/list_playlists.rb