Group
Extension

Matches 2

WWW-FCM-HTTP-V1 ( O/OM/OMOHAYUI/WWW-FCM-HTTP-V1-0.02.tar.gz, OMOHAYUI, 2019; MetaCPAN )
WWW-FCM-HTTP-V1/lib/WWW/FCM/HTTP/V1.pm ( view source; MetaCPAN )
"0.02";

use Class::Accessor::Lite (
    new => 0,
    rw  => [qw/sender api_url/],
);
use JSON qw(encode_json);
use Carp qw(croak);

use WWW::FCM::HTTP::V1::OAuth;

our $SCOPE_FIREBASE_MESSAGING = "h
pi_url => $api_url, api_key_json => $api_key_json })'
    unless (exists $args{api_url} && defined $args{api_url} && exists $args{api_key_json} && defined $args{api_key_json});

    $args{sender} ||= 
WWW::FCM::HTTP::V1::OAuth->new(
        api_key_json => $args{api_key_json},
        scopes       => [$SCOPE_FIREBASE_MESSAGING],
    );

    bless { %args }, $class;
}

sub send {
    my ($self, $con
WWW-FCM-HTTP-V1 ( O/OM/OMOHAYUI/WWW-FCM-HTTP-V1-0.02.tar.gz, OMOHAYUI, 2019; MetaCPAN )
WWW-FCM-HTTP-V1/lib/WWW/FCM/HTTP/V1/OAuth.pm ( view source; MetaCPAN )
opes grant_type timeout expires_in/],
    rw => [qw/token_url cache/],
);

use JSON qw(encode_json decode_json);
use JSON::WebToken;
use Furl;
use HTTP::Status qw(:constants);
use Carp qw(carp croak);
EFAULT_TIMEOUT;
    $args{scopes}     ||= [];
    $args{jwt_config} ||= _jwt_config_from_json($args{api_key_json}, $args{scopes});
    $args{token_url}  ||= $args{jwt_config}->{token_url};
    $args{u
args{uri},
        headers => [
            'Content-Type' => $args{content_type} || 'application/json; UTF-8',
            'Authorization' => sprintf("Bearer %s", $token->{access_token}),
        ],

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.