Module: Echowrap::API::Artist

Includes:
Utils
Included in:
Client
Defined in:
lib/echowrap/api/artist.rb

Constant Summary

Constants included from Utils

Utils::API_KEY_CANNOT_CALL_THIS_METHOD, Utils::INVALID_PARAMETER, Utils::MISSING_OR_INVALID_KEY, Utils::MISSING_PARAMETER, Utils::RATE_LIMIT_EXCEEDED, Utils::SUCCESS

Instance Method Summary collapse

Instance Method Details

#artist_biographies(options = {}) ⇒ Array<Echowrap::Biography>

Get a list of artist biographies.

Examples:

Biographies via id

Echowrap.artist_biographies(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :license (String)

    The desired license of the returned images. Not required, can send multiple, must be one of [‘echo-source’, ‘all-rights-reserved’, ‘cc-by-sa’, ‘cc-by-nc’, ‘cc-by-nc-nd’, ‘cc-by-nc-sa’, ‘cc-by-nd’, ‘cc-by’, ‘public-domain’, ‘unknown’].

Returns:

Raises:

  • (Echowrap::Error::Unauthorized)

    Error raised when supplied api key is not valid. # @raise [Echowrap::Error::Unauthorized] Error raised when supplied user credentials are not valid.

See Also:



22
23
24
# File 'lib/echowrap/api/artist.rb', line 22

def artist_biographies(options={})
  objects_from_response(Echowrap::Biography, :get, '/api/v4/artist/biographies', :biographies, options)
end

#artist_blogs(options = {}) ⇒ Array<Echowrap::Blog>

Get a list of artist blogs.

Examples:

blogs via id

Echowrap.artist_blogs(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :high_relevance (String)

    If true only items that are highly relevant for this artist will be returned. Not require, must be one of [‘true’, ‘false’].

Returns:

Raises:

  • (Echowrap::Error::Unauthorized)

    Error raised when supplied api key is not valid. # @raise [Echowrap::Error::Unauthorized] Error raised when supplied user credentials are not valid.

See Also:



40
41
42
# File 'lib/echowrap/api/artist.rb', line 40

def artist_blogs(options={})
  objects_from_response(Echowrap::Blog, :get, '/api/v4/artist/blogs', :blogs, options)
end

#artist_extract(options = {}) ⇒ Array<Echowrap::artist>

Extract artist names from text.

Examples:

Return an array of artists with artist ‘Daft Punk’

Echowrap.artist_search(:artist => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :bucket (String)

    Indicates what data should be returned with each artist. Not required, may send multiple, must be one of [‘biographies’, ‘blogs’, ‘doc_counts’, ‘familiarity’, ‘hotttnesss’, ‘images’, ‘artist_location’, ‘news’, ‘reviews’, ‘songs’, ‘terms’, ‘urls’, ‘video’, ‘years_active’, ‘id:Rosetta-space’]. Example: ‘songs’.

  • :limit (String)

    If ‘true’ limit the results to any of the given idspaces or catalogs. Not required, defaults to ‘false’.

  • :text (String)

    Text that contains artist names. Not required. Example: ‘Siriusmo is my favorite, but I also like hrvatski’.

  • :max_familiarity (Float)

    The maximum familiarity for the artist, the valid range for max_familiairty is 0.0 to 1.0, with 1.0 as default.

  • :min_familiarity (Float)

    The minimum famliiarity for the artist, the valid range for min_familiarity is 1.0 to 0.0, with 0.0 as default.

  • :max_hotttnesss (Float)

    The maximum hotttnesss of any artist’s artist, the valid range for artist_max_hotttnesss is 0.0 to 1.0, with 1.0 as default.

  • :min_hotttnesss (Float)

    The minimum hotttnesss of any artist’s artist, the valid range for the artist_min_hotttnesss is 0.0 to 1.0, with 0.0 as default.

  • :sort (String)

    Indicates how the artists results should be ordered. Must be one of [‘familiarity-asc’, ‘hotttnesss-asc’, ‘familiarity-desc’, ‘hotttnesss-desc’, ‘artist_start_year-asc’, ‘artist_start_year-desc’, ‘artist_end_year-asc’, ‘artist_end_year-desc’, ‘artist_start_year-asc’, ‘artist_start_year-desc’, ‘artist_end_year-asc’, ‘artist_end_year-desc’].

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

Returns:

  • (Array<Echowrap::artist>)

Raises:

See Also:



62
63
64
# File 'lib/echowrap/api/artist.rb', line 62

def artist_extract(options={})
  objects_from_response(Echowrap::Artist, :get, '/api/v4/artist/extract', :artists, options)
end

#artist_familiarity(options = {}) ⇒ Echowrap::Familiarity

Get numerical estimation of how familiar an artist currently is to the world.

Examples:

familiarity via id

Echowrap.artist_familiarity(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

Returns:

Raises:

  • (Echowrap::Error::Unauthorized)

    Error raised when supplied api key is not valid. # @raise [Echowrap::Error::Unauthorized] Error raised when supplied user credentials are not valid.

See Also:



76
77
78
# File 'lib/echowrap/api/artist.rb', line 76

def artist_familiarity(options={})
  object_from_response(Echowrap::Familiarity, :get, '/api/v4/artist/familiarity', :artist, options)
end

#artist_hotttnesss(options = {}) ⇒ Echowrap::Hotttnesss

Get numerical description of how hottt an artist currently is.

Examples:

hotttnesss via id

Echowrap.artist_hotttnesss(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

Returns:

Raises:

  • (Echowrap::Error::Unauthorized)

    Error raised when supplied api key is not valid. # @raise [Echowrap::Error::Unauthorized] Error raised when supplied user credentials are not valid.

See Also:



91
92
93
# File 'lib/echowrap/api/artist.rb', line 91

def artist_hotttnesss(options={})
  object_from_response(Echowrap::Hotttnesss, :get, '/api/v4/artist/hotttnesss', :artist, options)
end

#artist_images(options = {}) ⇒ Array<Echowrap::Image>

Get a list of artist images.

Examples:

images via id

Echowrap.artist_images(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :license (String)

    The desired license of the returned images. Not required, can send multiple, must be one of [‘echo-source’, ‘all-rights-reserved’, ‘cc-by-sa’, ‘cc-by-nc’, ‘cc-by-nc-nd’, ‘cc-by-nc-sa’, ‘cc-by-nd’, ‘cc-by’, ‘public-domain’, ‘unknown’].

Returns:

Raises:

See Also:



110
111
112
# File 'lib/echowrap/api/artist.rb', line 110

def artist_images(options={})
  objects_from_response(Echowrap::Image, :get, '/api/v4/artist/images', :images, options)
end

#artist_list_genres(options = {}) ⇒ Array<Echowrap::Genre>

Get a list of the available genres for use with search and playlisting. This method returns a list of genres suitable for use in the artist/search call when searching by description and for the creation of genre-radio playlists. The returned list of genres is inclusive of all supported genres.

Examples:

artist_list_genres

Echowrap.artist_list_genres

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

  • options (Hash) (defaults to: {})

    A customizable set of options.

Returns:

Raises:

See Also:



125
126
127
# File 'lib/echowrap/api/artist.rb', line 125

def artist_list_genres(options={})
  objects_from_response(Echowrap::Genre, :get, '/api/v4/artist/list_genres', :genres, options)
end

#artist_list_terms(options = {}) ⇒ Array<Echowrap::term>

Get a list of the available terms for use with search and playlisting. This method returns a list of genres suitable for use in the artist/search call when searching by description and for the creation of genre-radio playlists. The returned list of genres is inclusive of all supported genres.

Examples:

artist_list_terms

Echowrap.artist_list_terms

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :type (String)

    The type of term that is of interest. Not required, must be one of [‘style’, ‘mood’].

Returns:

  • (Array<Echowrap::term>)

Raises:

See Also:



141
142
143
# File 'lib/echowrap/api/artist.rb', line 141

def artist_list_terms(options={})
  objects_from_response(Echowrap::Term, :get, '/api/v4/artist/list_terms', :terms, options)
end

#artist_news(options = {}) ⇒ Array<Echowrap::NewsArticle>

Get a list of news articles found on the web related to an artist.

Examples:

news via id

Echowrap.artist_news(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :high_relevance (String)

    If true only items that are highly relevant for this artist will be returned. Not require, must be one of [‘true’, ‘false’].

Returns:

Raises:

  • (Echowrap::Error::Unauthorized)

    Error raised when supplied api key is not valid. # @raise [Echowrap::Error::Unauthorized] Error raised when supplied user credentials are not valid.

See Also:



159
160
161
# File 'lib/echowrap/api/artist.rb', line 159

def artist_news(options={})
  objects_from_response(Echowrap::NewsArticle, :get, '/api/v4/artist/news', :news, options)
end

#artist_profile(options = {}) ⇒ Echowrap::artist

Get basic information about an artist.

Examples:

Profile via id

Echowrap.artist_profile(:id => 'SOCZMFK12AC468668F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘SOCZMFK12AC468668F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :bucket (String)

    The type of track data that should be returned. Not required, can send multiple, may be any of [‘biographies’, ‘blogs’, ‘doc_counts’, ‘familiarity’, ‘hotttnesss’, ‘images’, ‘artist_location’, ‘news’, ‘reviews’, ‘songs’, ‘terms’, ‘urls’, ‘video’, ‘years_active’, ‘id:rosetta-stone’].

Returns:

  • (Echowrap::artist)

    The artist.

Raises:

See Also:



176
177
178
# File 'lib/echowrap/api/artist.rb', line 176

def artist_profile(options={})
  object_from_response(Echowrap::Artist, :get, '/api/v4/artist/profile', :artist, options)
end

#artist_reviews(options = {}) ⇒ Array<Echowrap::Review>

Examples:

reviews via id

Echowrap.artist_reviews(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

Returns:

Raises:

See Also:



226
227
228
# File 'lib/echowrap/api/artist.rb', line 226

def artist_reviews(options={})
  objects_from_response(Echowrap::Review, :get, '/api/v4/artist/reviews', :reviews, options)
end

#artist_search(options = {}) ⇒ Array<Echowrap::artist>

Search for artists given different query types

Examples:

Return an array of artists with artist ‘Daft Punk’

Echowrap.artist_search(:artist => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :bucket (String)

    Indicates what data should be returned with each artist. Not required, may send multiple, must be one of [‘biographies’, ‘blogs’, ‘doc_counts’, ‘familiarity’, ‘hotttnesss’, ‘images’, ‘artist_location’, ‘news’, ‘reviews’, ‘songs’, ‘terms’, ‘urls’, ‘video’, ‘years_active’, ‘id:Rosetta-space’]. Example: ‘songs’.

  • :limit (String)

    If ‘true’ limit the results to any of the given idspaces or catalogs. Not required, defaults to ‘false’.

  • :artist_location (String)

    The name of the location of interest. Not required, location names can optionally be qualified with a type specifier of ‘city’, ‘region’, ‘city’. Example: ‘boston’, ‘boston+ma+us’, ‘city:washington’, ‘region:washington’, ‘country:united+states’.

  • :name (String)

    The name of the artist to search for. Not required. Example: ‘radiohead’.

  • :description (String)

    A description of the artist, Warning Description cannot be used in conjunction with title, artist, combined, or artist_id. Not required, cannot be combined with ‘name’. Examples: ‘alt-rock’,‘-emo’, ‘harp^2’. See developer.echonest.com/docs/v4/artist.html#search for more examples.

  • :genre (String)

    A musical genre like rock, jazz, or funky. Not required, may send multiple. Examples are: ‘jazz’, ‘metal’.

  • :style (String)

    A musical style like rock, jazz, or funky. Not required, may send multiple. Examples are: ‘jazz’, ‘metal^2’.

  • :mood (String)

    A mood like happy or sad, some examples are: ‘happy’, ‘sad^.5’.

  • :rank_type (String)

    For search by description, style or mood indicates whether results should be ranked by query relevance or by artist familiarity, must be one of [‘relevance’, ‘familiarity’], with ‘relevance’ as default

  • :fuzzy_match (String)

    If ‘true’, a fuzzy match is performed. Not required, must be one of [‘true’, ‘false’].

  • :max_familiarity (Float)

    The maximum familiarity for the artist, the valid range for max_familiairty is 0.0 to 1.0, with 1.0 as default.

  • :min_familiarity (Float)

    The minimum famliiarity for the artist, the valid range for min_familiarity is 1.0 to 0.0, with 0.0 as default.

  • :max_hotttnesss (Float)

    The maximum hotttnesss of any artist’s artist, the valid range for artist_max_hotttnesss is 0.0 to 1.0, with 1.0 as default.

  • :min_hotttnesss (Float)

    The minimum hotttnesss of any artist’s artist, the valid range for the artist_min_hotttnesss is 0.0 to 1.0, with 0.0 as default.

  • :artist_start_year_before (String)

    Matches artists that have an earliest start year before the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_start_year_after (String)

    Matches artists that have an earliest start year after the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_end_year_before (String)

    Matches artists that have an latest start year before the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_end_year_after (String)

    Matches artists that have an latest start year after the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :sort (String)

    Indicates how the artists results should be ordered. Must be one of [‘familiarity-asc’, ‘hotttnesss-asc’, ‘familiarity-desc’, ‘hotttnesss-desc’, ‘artist_start_year-asc’, ‘artist_start_year-desc’, ‘artist_end_year-asc’, ‘artist_end_year-desc’, ‘artist_start_year-asc’, ‘artist_start_year-desc’, ‘artist_end_year-asc’, ‘artist_end_year-desc’].

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

Returns:

  • (Array<Echowrap::artist>)

Raises:

See Also:



210
211
212
# File 'lib/echowrap/api/artist.rb', line 210

def artist_search(options={})
  objects_from_response(Echowrap::Artist, :get, '/api/v4/artist/search', :artists, options)
end

#artist_similar(options = {}) ⇒ Array<Echowrap::artist>

Return similar artists given one or more artists for comparison. The Echo Nest provides up-to-the-minute artist similarity and recommendations from their real-time musical and cultural analysis of what people are saying across the Internet and what the music sounds like.

Examples:

Return an array of artists with artist ‘Daft Punk’

Echowrap.artist_similar(:name => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :name (String)

    The name of the artist to search for. Not required. Example: ‘radiohead’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :min_results (Integer)

    Indicates the minimum number of results to be returned regardless of constraints, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :bucket (String)

    Indicates what data should be returned with each artist. Not required, may send multiple, must be one of [‘biographies’, ‘blogs’, ‘doc_counts’, ‘familiarity’, ‘hotttnesss’, ‘images’, ‘artist_location’, ‘news’, ‘reviews’, ‘songs’, ‘terms’, ‘urls’, ‘video’, ‘years_active’, ‘id:Rosetta-space’]. Example: ‘songs’.

  • :max_familiarity (Float)

    The maximum familiarity for the artist, the valid range for max_familiairty is 0.0 to 1.0, with 1.0 as default.

  • :min_familiarity (Float)

    The minimum famliiarity for the artist, the valid range for min_familiarity is 1.0 to 0.0, with 0.0 as default.

  • :max_hotttnesss (Float)

    The maximum hotttnesss of any artist’s artist, the valid range for artist_max_hotttnesss is 0.0 to 1.0, with 1.0 as default.

  • :min_hotttnesss (Float)

    The minimum hotttnesss of any artist’s artist, the valid range for the artist_min_hotttnesss is 0.0 to 1.0, with 0.0 as default.

  • :artist_start_year_before (String)

    Matches artists that have an earliest start year before the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_start_year_after (String)

    Matches artists that have an earliest start year after the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_end_year_before (String)

    Matches artists that have an latest start year before the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :artist_end_year_after (String)

    Matches artists that have an latest start year after the given value, some examples are ‘1970’, ‘2011’, ‘present’.

  • :limit (String)

    If ‘true’ limit the results to any of the given idspaces or catalogs. Not required, defaults to ‘false’.

  • :seed_catalog (String)

    Only give similars to those in a catalog or catalogs, An Echo Nest artist catalog identifier. Muliple are allowed, up to 5, example: ‘CAKSMUX1321A708AA4’.

Returns:

  • (Array<Echowrap::artist>)

Raises:

See Also:



254
255
256
# File 'lib/echowrap/api/artist.rb', line 254

def artist_similar(options={})
  objects_from_response(Echowrap::Artist, :get, '/api/v4/artist/similar', :artists, options)
end

#artist_songs(options = {}) ⇒ Array<Echowrap::Song>

Examples:

songs via id

Echowrap.artist_songs(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

Returns:

Raises:

See Also:



270
271
272
# File 'lib/echowrap/api/artist.rb', line 270

def artist_songs(options={})
  objects_from_response(Echowrap::Song, :get, '/api/v4/artist/songs', :songs, options)
end

#artist_suggest(options = {}) ⇒ Array<Echowrap::artist>

Suggest artists based upon partial names. This method will return a list of potential artist matches based upon a query string. The method returns the most familiar best matching artist for the query.

Examples:

Return an array of artists with artist ‘Daft Pu’

Echowrap.artist_suggest(:name => "Daft Pu")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :name (String)

    A partial artist name. Not required. Examples: [“r”, “rad”, “radioh”].

  • :q (String)

    A partial artist name (an alias for ‘name’, to be jQuery friendly). Not required. Examples: [“r”, “rad”, “radioh”].

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

Returns:

  • (Array<Echowrap::artist>)

Raises:

See Also:



286
287
288
# File 'lib/echowrap/api/artist.rb', line 286

def artist_suggest(options={})
  objects_from_response(Echowrap::Artist, :get, '/api/v4/artist/suggest', :artists, options)
end

#artist_terms(options = {}) ⇒ Array<Echowrap::Term>

Get a list of most descriptive terms for an artist

Examples:

Return an array of terms with name ‘Daft Punk’

Echowrap.artist_terms(:name => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :sort (String)

    Sort terms based upon weight or frequency. Not required, must be one of [‘weight’, ‘frequency’], with ‘frequency’ as default.

Returns:

Raises:

See Also:



302
303
304
# File 'lib/echowrap/api/artist.rb', line 302

def artist_terms(options={})
  objects_from_response(Echowrap::Term, :get, '/api/v4/artist/terms', :terms, options)
end

#artist_top_hottt(options = {}) ⇒ Array<Echowrap::Artist>

Return a list of the top hottt artists.

Examples:

Return an array of artists with top genre ‘dance’

Echowrap.artist_top_hottt(:genre => "dance")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

  • :genre (String)

    A musical genre like rock, jazz, or funky. Not required, may send multiple. Examples are: ‘jazz’, ‘metal’.

  • :bucket (String)

    Indicates what data should be returned with each artist. Not required, may send multiple, must be one of [‘biographies’, ‘blogs’, ‘doc_counts’, ‘familiarity’, ‘hotttnesss’, ‘images’, ‘artist_location’, ‘news’, ‘reviews’, ‘songs’, ‘terms’, ‘urls’, ‘video’, ‘years_active’, ‘id:Rosetta-space’]. Example: ‘songs’.

  • :limit (String)

    If ‘true’ limit the results to any of the given idspaces or catalogs. Not required, defaults to ‘false’.

Returns:

Raises:

See Also:



320
321
322
# File 'lib/echowrap/api/artist.rb', line 320

def artist_top_hottt(options={})
  objects_from_response(Echowrap::Artist, :get, '/api/v4/artist/top_hottt', :artists, options)
end

#artist_top_terms(options = {}) ⇒ Array<Echowrap::Term>

Returns a list of the overall top terms.

Examples:

Return an array of terms

Echowrap.artist_top_terms

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

Returns:

Raises:

See Also:



334
335
336
# File 'lib/echowrap/api/artist.rb', line 334

def artist_top_terms(options={})
  objects_from_response(Echowrap::Term, :get, '/api/v4/artist/top_terms', :terms, options)
end

#artist_twitter(options = {}) ⇒ Array<Echowrap::Term>

Gets the twitter handle for an artist

Examples:

Return an artist with name of ‘Daft Punk’

Echowrap.artist_twitter(:name => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

Returns:

Raises:

See Also:



349
350
351
# File 'lib/echowrap/api/artist.rb', line 349

def artist_twitter(options={})
  object_from_response(Echowrap::Artist, :get, '/api/v4/artist/twitter', :artist, options)
end

#artist_urls(options = {}) ⇒ Array<Echowrap::Urls>

Get links to the artist’s official site, MusicBrainz site, MySpace site, Wikipedia article, Amazon list, and iTunes page.

Examples:

Return urls for artist with name of ‘Daft Punk’

Echowrap.artist_urls(:name => "Daft Punk")

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

Returns:

Raises:

See Also:



364
365
366
# File 'lib/echowrap/api/artist.rb', line 364

def artist_urls(options={})
  object_from_response(Echowrap::Urls, :get, '/api/v4/artist/urls', :urls, options)
end

#artist_video(options = {}) ⇒ Array<Echowrap::Video>

Get a list of video documents found on the web related to an artist.

Examples:

video via id

Echowrap.artist_video(:id => 'ARH6W4X1187B99274F')

Parameters:

  • options (Hash) (defaults to: {})

    A customizable set of options.

Options Hash (options):

  • :id (String)

    The ID of the artist. Required if name is not provided. Example: ‘ARH6W4X1187B99274F’.

  • :name (String)

    The name of the artist. Required if id is not provided. Example: ‘Weezer’.

  • :results (Integer)

    The desired number of results to return, the valid range is 0 to 100, with 15 as the default

  • :start (Integer)

    The desired index of the first result returned, must be on of [0, 15, 30] with 0 as the default

Returns:

Raises:

See Also:



381
382
383
# File 'lib/echowrap/api/artist.rb', line 381

def artist_video(options={})
  objects_from_response(Echowrap::Video, :get, '/api/v4/artist/video', :video, options)
end