Dancer2-Plugin-Auth-OAuth

 view release on metacpan or  search on metacpan

lib/Dancer2/Plugin/Auth/OAuth/Provider/VKontakte.pm  view on Meta::CPAN

        user_info        => 'https://api.vk.com/method/users.get',
    },
    query_params => {
        authorize => {
            response_type => 'code',
			# VKontakte sends user's email if exists with access token reply.
			# Because of this I had to modify 'Provider.pm' slightly.
			# If you want the email to be sent you must use 'email' scope.
			# Other user data should be requested with 'fields' configuration option.
            scope         => 'email',
	    display       => 'popup',
        }
    }
} }

sub post_process {
    my ($self, $session) = @_;

    my $fields = '';
    if ( exists $self->provider_settings->{fields} ) {
        $fields = "&fields=".$self->provider_settings->{fields};

lib/Dancer2/Plugin/Auth/OAuth/Provider/Yandex.pm  view on Meta::CPAN

    version => 2,
    urls => {
        authorize_url    => 'https://oauth.yandex.ru/authorize',
        access_token_url => 'https://oauth.yandex.ru/token',
        user_info        => 'https://login.yandex.ru/info',
    },
    query_params => {
        authorize => {
            response_type => 'code',
            scope         => 'login:birthday login:email login:info login:avatar',
            display       => 'popup',
        }
    }
} }

sub post_process {
    my ($self, $session) = @_;

    my $session_data = $session->read('oauth');

    my $ua = LWP::UserAgent->new;



( run in 1.985 second using v1.01-cache-2.11-cpan-364913b4093 )