Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/claudiob/openstrands
Rails plugin to retrieve knowledge about musical objects from Openstrands web service
https://github.com/claudiob/openstrands
Last synced: about 6 hours ago
JSON representation
Rails plugin to retrieve knowledge about musical objects from Openstrands web service
- Host: GitHub
- URL: https://github.com/claudiob/openstrands
- Owner: claudiob
- License: mit
- Created: 2009-03-13T16:20:33.000Z (almost 16 years ago)
- Default Branch: master
- Last Pushed: 2009-03-13T16:32:51.000Z (almost 16 years ago)
- Last Synced: 2024-12-05T13:26:55.423Z (17 days ago)
- Language: Ruby
- Homepage: http://open.strands.com
- Size: 82 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README
- License: MIT-LICENSE
Awesome Lists containing this project
README
Openstrands
===========Provides functions to retrieve knowledge about musical objects through the
OpenStrands Web Service (http://open.strands.com)* Make sure to put your Openstrands key config/openstrands.yml.
State
=======In development
To do
=======* Update authentication to the new models using OAuth
* Include both match and lookup functions
* Extend from tracks to artists, albums, genres, etc.Example
=======# // songs_controller.rb
class SongsController < ApplicationController
openstrandsdef show
@song = Song.find(params[:id])
@track = openstrands_lookup_track(params[:id])
end
end# // songs/show.html.erb
Track: <%= @track[:track_name] %>
Album: <%= @track[:album_name] %>
<%= image_tag(@track[:cover_uri]) %>Methods
=======def openstrands_lookup_track(id)
Given an Openstrands track ID returns a hash of metadata.
Example: @track = openstrands_lookup_track(2704707) returns
@track[:track_name] => 'She will be loved'
@track[:artist_name] => 'Maroon 5', etc.Credits
=======The structure of this plugin resembles the Last.fm plugin developed by
Gordon B. Isnor and available at http://github.com/gordonbisnor/lastfm/
hoping these plugins will be merged someday.. :-)Copyright (c) 2009 Claudio Baccigalupo, released under the MIT license