.008001;
use strict;
use warnings;
use utf8;
use LWP::UserAgent;
use HTTP::Request;
use URI;
use JSON::XS;
use Carp qw/carp croak/;
sub new {
my ($class, %opt) = @_;
my $self = {};
$self
getTokenInfo about token: $access_token. Code: $response_code";
}
my $response = decode_json($request->content);
return $response;
}
sub refreshToken {
my ($self, %opt) = @_;
de != 200) {
croak "Can't get token. Code: $response_code";
}
my $token = decode_json($response->content);
return $token;
}
sub __getOpenIdServices {
my ($self) = @_;
m
Digest::MD5 qw(md5_hex);
use JSON qw(to_json);
sub operate {
my ($self, $hash, $operand, @arguments) = @_;
$operand = '' unless defined $operand;
return md5_hex(to_json($operand, { canonical => 1 }
else {
$final->{$key} = undef;
}
}
$final->{$key} = ($item->$key ? $item->$key->to_json() : undef) if ($fields->{$key}->is_one() && $fields->{$key}->is_own());
} elsif (ref($fields->{
n_job rerun_problem take_job finish_job open_problem/;
our @EXPORT_OK = @EXPORT;
use JSON::MaybeXS qw/decode_json/;
use HTTP::Tiny;
use PerlX::Maybe qw/maybe/;
use DBI;
use DBIx::Simple;
use List::U
job_entry {
my $ret = _add_names _query(job_entry_sth => $_[0])->hash;
$ret->{results} = decode_json $ret->{results} if $ret->{results};
$ret
}
sub create_job {
my (%args) = @_;
$db->update('use
$c->tx->remote_port();
$self->clients->{ $client_id } = $c;
$c->tx->on( json => sub {
my( $c, $data ) = @_;
#warn Dumper $data ;
warn "Cli
};
output.onclick = function(evt) {
console.log(evt);
exampleSocket.send(JSON.stringify( { action:"click", x: evt.offsetX, y: evt.offsetY }));
}
status.innerHTML = "Co
2. Visit L<https://secure.meetup.com/de-DE/meetup_api/key/>
to get the API key
=item 4. Create a JSON file named C<meetup.credentials>
This file should live in your
home directory
with the API key:
compile'
or 'watch'.
files The list of files and folders to check.
--json Takes in either a file name, or a JSON
string. If filename, will also check
for changes to this file before re
ut
=head1 EXAMPLES
shopify-liquid-compile.pl *.liquid
=cut
my @ARGS;
GetOptions(
'json=s' => \my $json,
'help' => \my $help,
'fullhelp' => \my $fullhelp,
'base=s' => \my @bases,
'class=s'
user_id' );
my $user = Models::User->retrieve( $id )
->serialize();
return $self->render( json => $user );
}
=head2 Custom ids
package Models::User {
use Moose;
extends 'Mongol::Model
ce::autoclean;
# VERSION
our $VERSION = '0.02';
# IMPORTS
use Carp;
use HTTP::Tiny ();
use JSON::XS ();
use URI ();
use URI::Encode qw(uri_encode);
use URI::QueryParam ();
=
_create_uri( $name, %args );
my $response = $self->_client->$method($uri);
return JSON::XS::decode_json $response->{content};
}
sub _create_uri {
my ( $self, $name, %args ) = @_;
my
return HTTP::Tiny->new(
default_headers => {
'Accept' => 'application/json',
'User-Agent' => sprintf( 'Perl-%s::%s', __PACKAGE__, $VERSION ),
@args,
package Kubectl::CLIWrapper {
use Moo;
use IPC::Open3;
use JSON::MaybeXS;
use Kubectl::CLIWrapper::Result;
use Type::Tiny::Union;
use Types::Standard qw/Str CodeRef Bool/;
our $VERSION
undef, @command);
}
sub json {
my ($self, @command) = @_;
push @command, '-o=json';
my $result = $self->run(@command);
my $struct = eval {
JSON->new->decode($result->outpu
Kubectl::CLIWrapper::Result->new(
rc => $result->rc,
output => $result->output,
json => $struct
);
}
sub input {
my ($self, $input, @params) = @_;
my @final_command
VERSION = '0.03';
use Carp;
use Cwd;
use File::Basename qw(basename dirname);
use File::Spec;
use JSON ();
use LWP::Simple qw(get);
use Path::Tiny;
#use Data::Dump qw(dd pp);
=head1 NAME
CPAN::Cpano
ns_json>
String holding the basename of a file to be created (or regenerated) on server
holding metadata in JSON format about all releases of F<perl>. Optional;
defaults to C<perl_version_all.json>.
q 'HASH';
my @required_args = ( qw| path | );
my @optional_args = ( qw| verbose versions_json search_api_url | );
my %valid_args = map {$_ => 1} (@required_args, @optional_args);
my @
{%{$self->args}};
my $api_tmpl_file = $self->_template_path('api.json.ep');
my $api_file = path($args->{api_dir}, 'api.json');
$args->{api_title} = ref($self->app) . ' OpenAPI';
$args->{
ile, $args);
# Prettify generated JSON. With this step we also make sure the generated
# JSON is syntactically correct.
my $decoded = JSON::PP::decode_json(path($api_file)->slurp());
$decode
d->{definitions} = {%{$decoded->{definitions}}, %$api_defs};
path($api_file)->spurt(JSON::PP->new->utf8->pretty->encode($decoded));
return;
}
sub generate_path_api ($self, $t, $object_api_def, $
: I<< Linux version 4.8.0-53-generic >>.
Benchmark with C<< bencher -m ColorRGBUtil --env-hashes-json '[{"PERL5OPT":"-Iarchive/Color-RGB-Util-0.58/lib"},{"PERL5OPT":"-Iarchive/Color-RGB-Util-0.590/li
package Struct::Path::JsonPointer;
use 5.006;
use strict;
use warnings FATAL => 'all';
use parent 'Exporter';
use Carp 'croak';
use Scalar::Util 'looks_like_number';
our @EXPORT_OK = qw(
path2s
h::JsonPointer - JsonPointer (L<rfc6901|https://tools.ietf.org/html/rfc6901>)
syntax frontend for L<Struct::Path|Struct::Path>
=begin html
<a href="https://travis-ci.org/mr-mixas/Struct-Path-JsonPoi
ttps://travis-ci.org/mr-mixas/Struct-Path-JsonPointer.pm.svg?branch=master" alt="Travis CI"></a>
<a href='https://coveralls.io/github/mr-mixas/Struct-Path-JsonPointer.pm?branch=master'><img src='https
y $perl_dist_url = "http://search.cpan.org/api/dist/perl";
my $cpan_json = get($perl_dist_url);
my $filename = 'perl_version_all.json';
my $cwd = cwd();
{
my $tdir = tempdir(CLEANUP => 1);
my
$tdir or croak "Unable to change to $tdir for testing";
my $rv = print_file( $filename, $cpan_json );
ok($rv, "print_file() returned true value");
ok(-f $file_expected, "$file_expected was
e to change to $tdir for testing";
local $@;
eval { my $rv = print_file( $filename, $cpan_json ); };
like($@, qr/data\/$filename/s,
"Got expected exception: absence of 'data/' subd
as rc => (is => 'ro', isa => Int, required => 1);
has output => (is => 'ro', isa => Str);
has json => (is => 'ro', isa => HashRef);
has success => (is => 'ro', isa => Bool, lazy => 1, default =
{ module => "Wallflower" },
{ module => "JSON" },
{ module => "JSON::Types" },
],
summary => "Modules mentioned in Perl A
Set>
=item * L<App::Wallflower>
=item * L<File::Find>
=item * L<Wallflower>
=item * L<JSON>
=item * L<JSON::Types>
=back
=head1 HOMEPAGE
Please visit the project's homepage at L<https://metacp
ict;
use warnings;
use 5.010001;
use Pandoc::Elements;
use Scalar::Util qw(blessed reftype);
use JSON::PP;
use Carp;
# # For Pandoc::Metadata::Error
# use Carp qw(shortmess longmess);
# packages and
Document::Metadata;
{
no warnings 'once';
*to_json = \&Pandoc::Document::Element::to_json;
}
sub TO_JSON {
return { %{ $_[0] } }
}
sub value {
my
'FALSE' ? 1 : 0;
}
sub Pandoc::Document::MetaBool::TO_JSON {
return {
t => 'MetaBool',
c => $_[0]->{c} ? JSON::true() : JSON::false(),
};
}
sub Pandoc::Document::MetaBool::va
on 2016-11-06). Visit the URL for the full contents.",
entries => [{ module => "JSON" }, { module => "JSON::Types" }],
summary => "Modules mentioned in Perl Advent Calendar 2012 (day 23)"
6-11-06). Visit the URL for the full contents.
=head1 INCLUDED MODULES
=over
=item * L<JSON>
=item * L<JSON::Types>
=back
=head1 HOMEPAGE
Please visit the project's homepage at L<https://metacp
r/2014/12/day-1-slicing-and-dicing-your-json-appjpath.html] (retrieved on 2016-11-07). Visit the URL for the full contents.",
entries => [{ module => "JSON::Path" }],
summary => "Modules m
4/12/day-1-slicing-and-dicing-your-json-appjpath.html] (retrieved on 2016-11-07). Visit the URL for the full contents.
=head1 INCLUDED MODULES
=over
=item * L<JSON::Path>
=back
=head1 HOMEPAGE
P