Skip to content
This repository has been archived by the owner on Mar 19, 2024. It is now read-only.

oleander/webhallon_wrapper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Webhallon Client

Used internally at Radiofy.se.

How to use

Initialize

socket = Webhallon::Client.new("http://server:8181")

Playlist

Create

Create a non collaborative playlist.

socket.playlists.create({
  name: "My playlist",
  collaborative: false
})

Wipe

socket.tracks.wipe("spotify:user:username:playlist:47JbGTR8wxJw0SX0G1CJcS")

Information

socket.playlists.information("spotify:user:username:playlist:47JbGTR8wxJw0SX0G1CJcS")

Update

socket.playlists.update({
  playlist: "spotify:user:username:playlist:47JbGTR8wxJw0SX0G1CJcS",
  name: "New name",
  collaborative: false
})

Tracks

Add

socket.tracks.add({
  playlist: "spotify:user:username:playlist:47JbGTR8wxJw0SX0G1CJcS",
  tracks: ["spotify:track:2Huqz13a9lalQkSPeSk7Sy"],
  index: 0
})

Range

socket.tracks.keep({
  playlist: "spotify:user:username:playlist:47JbGTR8wxJw0SX0G1CJcS",
  range: 30..50
})

Webhallon::Playlist

  • name (String) The name of the playlist.
  • link (String) The spotify playlist url.
  • length (Integer) The amount of tracks in the playlist.
  • tracks (Array< String >) A list of spotify tracks.
  • collaborative? (Boolean) Is the playlist collaborative?

Requirements

Webhallon is tested in OS X 10.7.4 using Ruby 1.9.2.

License

Webhallon is released under the MIT license.

About

The bridge between Webhallon and Ruby

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages