Facebook-Graph

 view release on metacpan or  search on metacpan

author.t/authenticate.t  view on Meta::CPAN


use Test::More;
use lib '../lib';

die "You need to set an environment variable for FB_APP_ID && FB_SECRET to test this" unless $ENV{FB_APP_ID} && $ENV{FB_SECRET};

use_ok('Facebook::Graph');
my $fb = Facebook::Graph->new(
    secret      => $ENV{FB_SECRET},
    app_id      => $ENV{FB_APP_ID},
    postback    => 'https://www.facebook.com/connect/login_success.html',   # this is used for desktop apps, so we're cheating a bit for this test
    );
isa_ok($fb, 'Facebook::Graph');

my $uri = $fb->authorize->extend_permissions(qw(read_stream manage_pages))->uri_as_string;

print "Point your browser here: $uri

After authenticating paste the response URL here:

";



( run in 0.491 second using v1.01-cache-2.11-cpan-299005ec8e3 )