NAME

Net::Dopplr - interface with Dopplr.com's web service

SYNOPSIS

my $dopplr = Net::Dopplr->new($token);

my $fellows = $dopplr->fellows('muttley');

print "I share my trips with ".scalar(@{$fellows->{show_trips_to}})." people\n"; 
print "I can see ".scalar(@{$fellows->{can_see_trips_of}})." people's trips\n"; 

GETTING A DEVELOPER TOKEN

This is a bit involved because Dopplr is still in beta.

First visit this URL

https://www.dopplr.com/api/AuthSubRequest?next=http%3A%2F%2Fwww.example.com%2Fdopplrapi&scope=http%3A%2F%2Fwww.dopplr.com%2F&session=1

(Or you can replace next with you own web app). That will give you a developer token.

You can then upgrade this to a permanent session token.

I use this script.

use strict;
use Net::Dopplr;
use Net::Google::AuthSub;
use LWP::UserAgent;

my $ua = LWP::UserAgent->new;
my $token = shift;
my $sess;
if (!defined $sess) {
            my $auth = Net::Google::AuthSub->new( url => 'https://www.dopplr.com/api', _bug_compat => 'dopplr');
            $auth->auth('null', $token);
            $sess    = $auth->session_token();
            print "Session token = $sess\n";
}

my $dopplr = Net::Dopplr->new($sess);

You can then use the session token from that point forward.

METHODS

More information here

http://dopplr.pbwiki.com/API+Resource+URLs

new <token>

Requires a developer token or a session token.

TRAVELLER METHODS

fellows <traveller>

Get people <traveller> shares information with.

traveller_info <traveller>

Get information about a traveller

trips_info <traveller>

Gte info about the trips of a traveller.

fellows_travellingtoday <traveller>

Get which of <traveller>'s fellows are travelling today.

tag <traveller>

Tag a traveller.

TRIP METHODS

trip_info <trip id>

Get info about a specific trip.

trip_tag <trip id>

Add tags to a trip

CITY METHODS

city_info <city>

Get info about a City.

city_search <city>

Find a city.

AUTHOR

Simon Wistow <simon@thegestalt.org>

COPYRIGHT

Copyright 2007, Simon Wistow

Distributed under the same terms as Perl itself.