GithubHelp home page GithubHelp logo

gracenote's Introduction

Gracenote Build Status

A simple ruby wrapper gem for the Gracenote Music API, which can retrieve Artist, Album and Track metadata with the most common options.

Inspired by pygn project.

Gracenote allows you to look up artists, albums, and tracks in the Gracenote database, and returns a number of metadata fields, including:

Basic metadata like Artist Name, Album Title, Track Title. Descriptors like Genre, Origin, Mood, Tempo. Related content like Album Art, Artist Image, Biographies.

Gracenote 1.2 supports TVShow queries

Installation

Add this line to your application's Gemfile:

gem 'gracenote'

And then execute:

$ bundle install

Or install it yourself as:

$ gem install gracenote

Rubygem

https://rubygems.org/gems/gracenote

Usage

You will need a Gracenote Client ID to use this module. Please visit https://developer.gracenote.com to get yours.

Each installed application also needs to have a User ID, which may be obtained by registering your Client ID with the Gracenote API. To do this, do:

spec = {:clientID => "your_client_id", :clientTag => "your_client_tag"}
obj = Gracenote.new(spec)
obj.registerUser

This registration should be done only once per application to avoid hitting your API quota (i.e. definitely do NOT do this before every query).

Once you have your Client ID and User ID, you can start making queries.

To search for the Kings of Convenience track "Homesick" from the album "Riot On An Empty Street",

p obj.findTrack("Kings Of Convenience", "Riot On An Empty Street", "Homesick", '0').inspect

p obj.findTVShow('saved by the bell').inspect

p obj.fetchTVShow('238078046-4B86F4187EE2D215784CE4266CB83EA9').inspect

p obj.fetchSeason('238050049-B36CFD6F8B6FC76E2174F2A6E22515CD').inspect

p obj.findContributor('vince vaughn').inspect

p obj.fetchContributor('238498181-193BE2BA655E1490A3B8DF3ACCACEF3A').inspect

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

gracenote's People

Contributors

christopherstyles avatar nobelium avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

gracenote's Issues

SSL error

I'm getting this error:

C:/Ruby21/lib/ruby/2.1.0/net/http.rb:920:in `connect': SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (OpenSSL::SSL::SSLError)

Any ideas?
Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.