EVDB::API - Perl interface to EVDB public API
use EVDB::API; my $evdb = EVDB::API->new(app_key => $app_key); $evdb->login(user => 'harry', password => 'H0gwart$') or die "Can't log in: $EVDB::API::errstr"; # call() accepts either an array ref or a hash ref. my $event = $evdb->call('events/get', {id => 'E0-001-000218163-6'}) or die "Can't retrieve event: $EVDB::API::errstr"; print "Title: $event->{title}\n"; my $venue = $evdb->call('venues/get', [id => $event->{venue_id}]) or die "Can't retrieve venue: $EVDB::API::errstr"; print "Venue: $venue->{name}\n";
The EVDB API allows you to build tools and applications that interact with EVDB, the Events & Venues Database. This module provides a Perl interface to that API, including the digest-based authentication infrastructure.
See http://api.evdb.com/ for details.
Copyright 2006 Eventful, Inc. All rights reserved.
You may distribute under the terms of either the GNU General Public License or the Artistic License, as specified in the Perl README file.
Special thanks to Daniel Westermann-Clark for adding support for "flavors" of plug-in parsers. Visit Podbop.org to see other cool things made by Daniel.
0.99 - August 2006
$evdb = EVDB::API->new(app_key => $app_key);
Creates a new API object. Requires a valid app_key as provided by EVDB.
You can also specify an API "flavor", such as yaml, to use a different format.
yaml
$evdb = EVDB::API->new(app_key => $app_key, flavor => 'yaml');
Valid flavors are rest, yaml, and json.
rest
json
$evdb->login(user => $username, password => $password); $evdb->login(user => $username, password_md5 => $password_md5);
Retrieves an authentication token from the EVDB API server.
$data = $evdb->call($method, \%arguments, [$force_array]);
Calls the specified method with the given arguments and any previous authentication information (including app_key). Returns a hash reference containing the results.
app_key
1 POD Error
The following errors were encountered while parsing the POD:
=cut found outside a pod block. Skipping to next block.
To install EVDB::API, copy and paste the appropriate command in to your terminal.
cpanm
cpanm EVDB::API
CPAN shell
perl -MCPAN -e shell install EVDB::API
For more information on module installation, please visit the detailed CPAN module installation guide.