Skip to content

Instantly share code, notes, and snippets.

@gslin
Created April 3, 2011 08:09
Show Gist options
  • Save gslin/900277 to your computer and use it in GitHub Desktop.
Save gslin/900277 to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
use strict;
use warnings;
use 5.010;
use OAuth::Lite::Consumer;
INIT {
my $c = OAuth::Lite::Consumer->new(
consumer_key => 'key',
consumer_secret => 'secret',
site => 'http://term.ie',
request_token_path => '/oauth/example/request_token.php',
access_token_path => '/oauth/example/access_token.php',
authorize_path => 'http://example.org/authorized',
);
my $rt = $c->get_request_token(callback => 'http://example.org/callback');
say $c->url_to_authorize(token => $rt);
}
__END__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment