itunes.base module

This module contains base data models for the rest of the iTunes store API

itunes.base.TS_FORMAT = '%Y-%m-%dT%H:%M:%S'

iTunes API Timestamp format

itunes.base.SESSION = <requests.sessions.Session object>

Globally accessible cache-enabled requests session

exception itunes.base.ITunesException(message)[source]

Bases: exceptions.Exception

Base iTunes request exception

class itunes.base.BaseObject(**kwargs)[source]

Bases: object

Base object for representing an iTunes request

get()[source]

Execute an HTTP GET against the iTunes API and construct an appropriate assortment of Resource‘s based on the response

resource = None
url

The url pointing at the resource defined by the implementing object

class itunes.base.Resource(id)[source]

Bases: object

Base class for the various types of Resources returned by the iTunes Store API

get_album()[source]

Returns the first album associated with this Resource

get_albums(limit=200)[source]

Returns the albums associated with this Resource

get_tracks(limit=500)[source]

Returns the tracks associated with this Resource

release_date

Accessor for a datetime.datetime representation of the release date for this Resource

exception itunes.base.NoResultsFoundException[source]

Bases: itunes.base.ITunesException

iTunes error for when no results are returned from a Lookup

class itunes.base.Lookup(id, entity=None, limit=50)[source]

Bases: itunes.base.BaseObject

A data model for an individual resource look up against iTunes

resource = 'lookup'
class itunes.base.Artist(id)[source]

Bases: itunes.base.Resource

The Artist Resource represents an iTunes artist

class itunes.base.Album(id)[source]

Bases: itunes.base.Resource

The Album Resource represents an Album (or collection of single resources) of other resource types

class itunes.base.Track(id)[source]

Bases: itunes.base.Resource

The Track Resource represents a single track from the iTunes store

class itunes.base.Audiobook(id)[source]

Bases: itunes.base.Album

The Audiobook Resource represents an iTunes Audiobook

class itunes.base.Software(*args, **kwargs)[source]

Bases: itunes.base.Track

The Software Resource represents an iTunes App resource

class itunes.base.TVEpisode(id)[source]

Bases: itunes.base.Track

The TVEpisode Resource represents a track type that represents a single TV Episode.

itunes.base.lookup(id)[source]

Perform an individual Lookup on a single resource in the iTunes Store API