Group
Extension

Matches 3

YellowBot-API ( A/AB/ABH/YellowBot-API-0.96.tar.gz, ABH, 2012; MetaCPAN )
YellowBot-API/lib/YellowBot/API/Request/JSON.pm ( view source; MetaCPAN )
package YellowBot::API::Request::JSON;
{
  $YellowBot::API::Request::JSON::VERSION = '0.96';
}

use Moose;

use HTTP::Request;
use JSON qw(encode_json);

use namespace::clean -except => 'meta';

exten
lf->_more_args;

    # JSON POST request
    my $req = HTTP::Request->new('POST', $uri, ['Content-Type' => 'application/json; charset=utf-8']);
    my $req_content = encode_json(\%extra);
    $req->co
ing utf8

=head1 NAME

YellowBot::API::Request::Json - Request object for YellowBot::API (JSON POST)

=head1 SYNOPSIS

This class manages setting up JSON POST requests for the YellowBot::API.

No user
YellowBot-API ( A/AB/ABH/YellowBot-API-0.96.tar.gz, ABH, 2012; MetaCPAN )
YellowBot-API/lib/YellowBot/API/Response.pm ( view source; MetaCPAN )
ellowBot::API::Response;
{
  $YellowBot::API::Response::VERSION = '0.96';
}
use Moose;
use JSON qw(decode_json);
use namespace::clean -except => 'meta';

has http => (
   is  => 'ro',
   isa => 'HTTP:
ine,
                };
    }
    my $data = decode_json($self->http->content);
    if ($ENV{API_DEBUG} and $ENV{API_DEBUG} > 2) {
        warn "JSON response:\n" . $self->http->content . "\n";
    }
YellowBot-API ( A/AB/ABH/YellowBot-API-0.96.tar.gz, ABH, 2012; MetaCPAN )
YellowBot-API/lib/YellowBot/API.pm ( view source; MetaCPAN )
%REQ_CLASS = (
    'post' => 'YellowBot::API::Request',
    'j-post' => 'YellowBot::API::Request::JSON',
);

sub _request {
    my ($self, $method, %args) = @_;

    my $request_class = $REQ_CLASS{$se

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