Group
Extension

Matches 35358

App-MatrixTool ( P/PE/PEVANS/App-MatrixTool-0.08.tar.gz, PEVANS, 2016; MetaCPAN )
App-MatrixTool/lib/App/MatrixTool/HTTPClient.pm ( view source; MetaCPAN )
DNS 0.06 qw( ERR_NO_HOST ERR_NO_ADDRESS ); # Future return with failure details
use JSON qw( encode_json decode_json );
use URI;

use Socket qw( getnameinfo NI_NUMERICHOST SOCK_RAW );

use constant DE
ef $params{content} ) {
         $req->content( encode_json( delete $params{content} ) );
         $req->header( Content_type => "application/json" );
      }
      else {
         $req->content( dele
);
}

=head2 request_json

   ( $body, $response ) = $client->request_json( ... )

A small wrapper around C<request> that decodes the returned body as JSON.

=cut

sub request_json
{
   my $self = shi
HTTP-ClickHouse ( M/MM/MMV/HTTP-ClickHouse-0.061.tar.gz, MMV, 2016; MetaCPAN )
HTTP-ClickHouse/lib/HTTP/ClickHouse.pm ( view source; MetaCPAN )
>

=back

=head1 AUTHOR

Maxim Motylkov

=head1 TODO

The closest plans are

=over 4

=item * Add json data format.

=back

=head1 MODIFICATION HISTORY

See the Changes file.

=head1 COPYRIGHT AND LIC
QBit-Application-Model-Authorization ( M/MA/MADSKILL/QBit-Application-Model-Authorization-0.007.tar.gz, MADSKILL, 2016; MetaCPAN )
QBit-Application-Model-Authorization/lib/QBit/Application/Model/Authorization.pm ( view source; MetaCPAN )

        -key     => $SALT,
        -cipher  => 'Blowfish'
    );

    return $cipher->encrypt(to_json($session));
}

sub _password_hash {
    my ($self, $key, $password) = @_;

    utf8::encode($key)
      -key     => $SALT,
        -cipher  => 'Blowfish'
    );

    try {
        $session = from_json($cipher->decrypt($session));
    }
    catch {
        throw Exception::Authorization::BadSession
Log-Log4perl-Appender-Lumberjack ( B/BE/BENNING/Log-Log4perl-Appender-Lumberjack-1.00.tar.gz, BENNING, 2016; MetaCPAN )
Log-Log4perl-Appender-Lumberjack/lib/Log/Log4perl/Appender/Lumberjack.pm ( view source; MetaCPAN )


  $msg = $msg->[0] if ref $msg eq 'ARRAY' && @$msg == 1;

  if (eval { $msg->isa('Log::Message::JSON') }) {
    $msg = { %$msg };
  } elsif (eval { $msg->DOES("Log::Message::Structured") }) {
    $m
ort = 5044
    log4perl.appender.Remote.keepalive = 0
    log4perl.appender.Remote.frame_format = json
    #log4perl.appender.Remote.use_ssl = 1
    #log4perl.appender.Remote.ssl_verify = 1
    # thes
f frames per connection.

=head2 frame_formt (default: 'json')

The following frame formats are supported:

=over

=item 'json', 'v2'

Uses json formatted data frames as defined in lumberjack protocol
XML-Lenient ( D/DA/DAVIES/XML-Lenient-1.0.1.tar.gz, DAVIES, 2016; MetaCPAN )
XML-Lenient/lib/XML/Lenient.pm ( view source; MetaCPAN )
ge returns and line feeds to spaces before passing the
string to the parser.

Neither YAML nor JSON can be handled.

Internally, XML::Lenient uses lots of regexes (and other things as
well. I kn
AnyEvent-Mattermost ( J/JS/JSIME/AnyEvent-Mattermost-0.002.tar.gz, JSIME, 2016; MetaCPAN )
AnyEvent-Mattermost/lib/AnyEvent/Mattermost.pm ( view source; MetaCPAN )
attermost APIs

=cut

use AnyEvent;
use AnyEvent::WebSocket::Client 0.37;
use Carp;
use Furl;
use JSON;
use Time::HiRes qw( time );
use Try::Tiny;

=head1 SYNOPSIS

    use AnyEvent;
    use AnyEvent:
}
}

sub _handle_incoming {
    my ($self, $conn, $raw) = @_;

    my $msg = try {
        decode_json($raw->body);
    }
    catch {
        my $message = $raw->body;
        croak "unable to decode 
$res = $furl->get($self->{'host'} . $path, $self->_headers);

    my $data = try {
        decode_json($res->content);
    } catch {
        my $status = $res->status;
        my $message = $res->cont
Eixo-Rest ( A/AL/ALAMBIKE/Eixo-Rest-1.207.tar.gz, ALAMBIKE, 2016; MetaCPAN )
Eixo-Rest/lib/Eixo/Rest/Request.pm ( view source; MetaCPAN )
> undef,
    onSuccess =>  undef,
    onError => undef,
    onStart => undef,
    
    __format=>'json',

    buffer=>'',

);

sub start{
    my ($self) = @_;

    $self->{buffer} = ''; # truncate the
n/json
    if($response->content_type eq 'application/json'){
        use Encode;
        $content = Encode::decode('UTF-8', $content);
    }

    if($self->__format eq 'json'){

        return JSON->
Eixo-Rest ( A/AL/ALAMBIKE/Eixo-Rest-1.207.tar.gz, ALAMBIKE, 2016; MetaCPAN )
Eixo-Rest/lib/Eixo/Rest/Client.pm ( view source; MetaCPAN )
;
use strict;

use Eixo::Base::Clase;

use URI;
use LWP::UserAgent;
use LWP::Protocol::https;
use JSON -convert_blessed_universally;
use Carp;
use Data::Dumper;

use Config;
use Eixo::Rest::RequestSyn
my $USER_AGENT_VERSION = 'EixoAgent/0.1';

has(

    ua=>undef,
    endpoint=>undef,
    format=>'json',
    error_callback => undef,
    current_method => undef,
);

sub initialize{
    my ($self, $e
tent-Type') 
        || 'application/json';
        #|| 'application/x-www-form-urlencoded';

    if($content_type eq "application/json"){

        $content = JSON->new->allow_blessed(1)
             
Test-RestAPI ( J/JA/JASEI/Test-RestAPI-0.1.6.tar.gz, JASEI, 2016; MetaCPAN )
Test-RestAPI/lib/Test/RestAPI.pm ( view source; MetaCPAN )
filename);
use Test::RestAPI::MojoGenerator;
use Port::Selector;
use Path::Tiny;
use Mojo::JSON qw(decode_json);
use Mojo::UserAgent;

use constant WINDOWS => ($^O eq 'MSWin32');

BEGIN {
    if (WIND


    my @lines;
    while (my $line = <$fh>) {
        chomp $line;

        push @lines, decode_json($line);
    }

    return \@lines;
}


sub DESTROY {
    my ($self) = @_;

    if ($^O eq 'MSWin3
Test-RestAPI ( J/JA/JASEI/Test-RestAPI-0.1.6.tar.gz, JASEI, 2016; MetaCPAN )
Test-RestAPI/lib/Test/RestAPI/MojoGenerator.pm ( view source; MetaCPAN )
F', $endpoints));
% my ($endpoints) = @_;
use Mojolicious::Lite;
use Path::Tiny;
use Mojo::JSON qw(encode_json);

% foreach my $endpoint (@$endpoints) {
<%= $endpoint->method %> '<%= $endpoint->path %
b {
    my ($c) = @_;

    path(app->home(), "<%= $endpoint->path_as_filename %>")->append(encode_json($c->req->body)."\n");

    $c->render(%{<%= $endpoint->render_as_string %>});
};
% }

any '/app_m
Eixo-Rest ( A/AL/ALAMBIKE/Eixo-Rest-1.207.tar.gz, ALAMBIKE, 2016; MetaCPAN )
Eixo-Rest/lib/Eixo/Rest/RequestAsync.pm ( view source; MetaCPAN )
package Eixo::Rest::RequestAsync;

use strict;

use threads;
use Thread::Queue;

use JSON -convert_blessed_universally;

# use Eixo::Base::Clase;
use Eixo::Base::Clase 'Eixo::Rest::Request';

use Attr
Eixo-Rest ( A/AL/ALAMBIKE/Eixo-Rest-1.207.tar.gz, ALAMBIKE, 2016; MetaCPAN )
Eixo-Rest/lib/Eixo/Rest.pm ( view source; MetaCPAN )
package Eixo::Rest;

use 5.008;
use strict;
use warnings;

use parent qw(Eixo::Base::Clase);
use JSON;
use LWP::UserAgent;

our $VERSION = '1.207';

1;
Eixo-Rest ( A/AL/ALAMBIKE/Eixo-Rest-1.207.tar.gz, ALAMBIKE, 2016; MetaCPAN )
Eixo-Rest/lib/Eixo/Rest/Product.pm ( view source; MetaCPAN )
ute) = @_;

	return undef if(grep {$attribute eq $_} $self->NOT_SERIALIZE);

	return 1;
}

sub TO_JSON {
	my $self = $_[0];

	return {map {$_ => $self->$_} grep {$self->is_serializable($_)} keys(%$sel
Plack-App-GitHub-WebHook ( V/VO/VOJ/Plack-App-GitHub-WebHook-0.9.tar.gz, VOJ, 2016; MetaCPAN )
Plack-App-GitHub-WebHook/lib/Plack/App/GitHub/WebHook.pm ( view source; MetaCPAN )
 Plack::Middleware::HTTPExceptions;
use Plack::Middleware::Access;
use Carp qw(croak);
use JSON qw(decode_json);
use Scalar::Util qw(blessed);

our $VERSION = '0.9';

our @GITHUB_IPS = (
    allow => 
 ) {
        $payload = $req->param('payload') || $req->content;
        $payload = eval { decode_json $payload };
    }

    if (!$payload) {
        return [400,['Content-Type'=>'text/plain','Conten
ION

This L<PSGI> application receives HTTP POST requests with body parameter
C<payload> set to a JSON object. The default use case is to receive 
L<GitHub WebHooks|http://developer.github.com/webhook
WebService-Spotify ( N/NI/NICKL/WebService-Spotify-1.003.tar.gz, NICKL, 2016; MetaCPAN )
WebService-Spotify/lib/WebService/Spotify/OAuth2.pm ( view source; MetaCPAN )
uth2;
use Moo;
use Method::Signatures;
use IO::File;
use LWP::UserAgent;
use URI::QueryParam;
use JSON;
use MIME::Base64;
use Data::Dumper;

our $VERSION = '1.002';

has 'client_id'     => ( is => 'rw
 if (my $fh = IO::File->new('< ' . $self->cache_path)) {
      local $/;
      $token_info = from_json( <$fh> );
      $fh->close;
    }

    $token_info = $self->refresh_access_token($token_info->{re
IO::File->new('> ' . $self->cache_path) || die "Could not create cache file $@";
    print $fh to_json($token_info);
    $fh->close;
  }
}

method is_token_expired ($token_info) {
  return ($token_inf
WebService-Spotify ( N/NI/NICKL/WebService-Spotify-1.003.tar.gz, NICKL, 2016; MetaCPAN )
WebService-Spotify/lib/WebService/Spotify.pm ( view source; MetaCPAN )
ebService::Spotify;
use Moo;
use Method::Signatures;
use LWP::UserAgent;
use URI::QueryParam;
use JSON;
use Data::Dumper;

our $VERSION = '1.003';

has 'prefix' => ( is => 'rw', default => 'https://ap
 $uri->as_string);
  $self->_log("RESP", $response->content);

  return $response->content ? from_json($response->content) : undef;
}

method post ($method, $payload, %args) {
  my $uri      = $self->
headers;
  $headers->{'Content-Type'} = 'application/json';
  my $response = $self->user_agent->post( $uri->as_string, %$headers, Content => to_json($payload) );
  
  $self->_log("POST", $uri->as_stri
WebService-Slack-IncomingWebHook ( M/MA/MASASUZU/WebService-Slack-IncomingWebHook-0.02.tar.gz, MASASUZU, 2016; MetaCPAN )
WebService-Slack-IncomingWebHook/lib/WebService/Slack/IncomingWebHook.pm ( view source; MetaCPAN )
ackage WebService::Slack::IncomingWebHook;
use 5.008001;
use strict;
use warnings;
use utf8;

use JSON;
use Furl;
use Carp ();

our $VERSION = "0.02";

sub new {
    my ($class, %args) = @_;
    Carp:
{$_} ) } qw( webhook_url channel icon_emoji icon_url username )
    } => $class;

    $self->{json} = JSON->new->utf8;
    $self->{furl} = Furl->new(agent => "$class.$VERSION");

    return $self;
}

->{furl}->post(
        $self->{webhook_url},
        ['Content-Type' => 'application/json'],
        $self->{json}->encode($post_data),
    );
    if (! $res->is_success) {
        Carp::carp('post f
FAIR-Data ( M/MA/MARKW/FAIR-Data-1.001.tar.gz, MARKW, 2016; MetaCPAN )
FAIR-Data/lib/FAIR/Accessor.pm ( view source; MetaCPAN )
led?
 use lib "$FindBin::Bin";      # use that dir for libs, too
 use strict;
 use warnings;
 use JSON;
 use FAIR::Accessor::Distribution;
 use FAIR::Accessor::Container;
 use FAIR::Accessor::MetaReco
Plift ( C/CA/CAFEGRATZ/Plift-0.15.tar.gz, CAFEGRATZ, 2016; MetaCPAN )
Plift/lib/Plift/Context.pm ( view source; MetaCPAN )
package Plift::Context;

use Moo;
use Carp;
use XML::LibXML::jQuery;
use JSON 'to_json';
use Encode 'encode';
use namespace::clean;
use Ref::Util qw/ is_hashref is_blessed_ref /;


has 'helper', is =>
ion);

            $target_element->remove unless defined $value;

            # to_json
            $value = to_json($value, { convert_blessed => 1 }) if ref $value eq 'HASH';

            # encode
 
FAIR-Data ( M/MA/MARKW/FAIR-Data-1.001.tar.gz, MARKW, 2016; MetaCPAN )
FAIR-Data/lib/FAIR/AccessorBase.pm ( view source; MetaCPAN )
:VERSION = '1.001';




# ABSTRACT: The core Accessor functions


use Moose;
use URI::Escape;
use JSON;
use FAIR::AccessorConfig;
use RDF::Trine::Parser 0.135;
use RDF::Trine::Model 0.135;
use RDF::Tr

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