BandsInTownPy released

doug
Sun, 28 Feb 2010 14:00:07 +0000

A Python module on the API at bandsintown.com released and is available for download at http://github.com/kay/BandsInTownPy

Sample usage:

from bandsintown import *
site = BandsInTownRequest()

print "Getting Flyleaf information by name"
artist = site.GetArtistByName("Flyleaf")
print artist.get_as_string().encode('utf-8')
print

print "Getting events for Flyleaf by Artist object"
events = artist.GetEvents()

print len(events), "events"

for event in events:
    print (event)
print

print "Getting todays events"
events = site.GetEventsToday()

print len(events), "events today"

for event in events:
    print event.get_as_string().encode('utf-8')
print

print "Getting events for Exilia by name"
events = site.GetEventsByArtistName("Exilia")

print len(events), "events"

for event in events:
    print event.get_as_string().encode('utf-8')
print