Group
Extension

Matches 35359

Brightcove-MAPI ( B/BA/BARTENDER/Brightcove-MAPI-0.1.tar.gz, BARTENDER, 2011; MetaCPAN )
Brightcove-MAPI/lib/Brightcove/MAPI.pm ( view source; MetaCPAN )
 Brightcove::MAPI;

# ABSTRACT: Brightcove Media API Wrapper

our $VERSION = '0.1';

use URI;
use JSON;
use Any::Moose;
use LWP::UserAgent;

has read_api_url => (
	is	=> 'rw',
	required=> 1,
	default	
s);
	my $res = $self->user_agent->get($url->as_string);

	if ($res->is_success) {
		return decode_json($res->decoded_content);
	} else {
		confess $res->status_line;
	}
}


sub post {
	my $self = shif
t;
	my $params = shift || {};
	my $file = shift;

	$params->{token} = $self->token;

	my $jsonrpc = encode_json({
		method => $method,
		params => $params,
	});

	my $res;
	if (defined($file) and -f $
PGXN-Site ( D/DW/DWHEELER/PGXN-Site-v0.7.2.tar.gz, DWHEELER, 2011; MetaCPAN )
PGXN-Site/lib/PGXN/Site.pm ( view source; MetaCPAN )
ks for distributing any kind of release distributions and for
providing a lightweight static file JSON REST API.

This module provides a simple PGXN web site. All it needs is a
L<PGXN::API>-powered AP
WWW-3Taps-API ( E/ED/EDENC/WWW-3Taps-API-0.06.tar.gz, EDENC, 2011; MetaCPAN )
WWW-3Taps-API/lib/WWW/3Taps/API.pm ( view source; MetaCPAN )
eX::Params::Validate;
use URI;
use LWP::UserAgent;
use JSON::Any;
use WWW::3Taps::API::Types qw( Source Category Location Timestamp JSONMap
  JSONBoolean Retvals List Dimension ReferenceType Notificat
}
);

has _json_handler => (
  is      => 'rw',
  default => sub { JSON::Any->new( utf8 => 1, allow_nonref => 1 ) },
  handles => {
    _from_json => 'from_json',
    _to_json   => 'to_json'
  },
);

   execTimeMs => 325,
  #   numResults => 141087,
  #   success => bless( do { \( my $o = 1 ) }, 'JSON::XS::Boolean' )
  #   results    => [
  #     {
  #       category => "VAUT",
  #       externalU
WWW-GitHub-PostReceiveHook ( M/MA/MATTP/WWW-GitHub-PostReceiveHook-0.002.tar.gz, MATTP, 2011; MetaCPAN )
WWW-GitHub-PostReceiveHook/lib/WWW/GitHub/PostReceiveHook.pm ( view source; MetaCPAN )
RSION = '0.002';
}
# ABSTRACT: A simple means of receiving GitHub's web hooks

use Try::Tiny;
use JSON;

has routes => (
    is        => 'rw',
    predicate => 'has_routes',
    required  => 1,
    i
       my $json = decode_json $payload;

                # callback
                $self->routes->{ "/$path" }->( $json );
            }
            catch {
                # malformed JSON string, n
ect, number, string or atom, at character offset 0 ?
                # you are trying to POST non JSON data. don't do that.
                warn "Caught exception: /$path: attempted to trigger callbac
WWW-3Taps-API ( E/ED/EDENC/WWW-3Taps-API-0.06.tar.gz, EDENC, 2011; MetaCPAN )
WWW-3Taps-API/lib/WWW/3Taps/API/Types.pm ( view source; MetaCPAN )
n Timestamp JSONMap
     JSONBoolean Retvals List Dimension ReferenceType
  NotificationFormat )
];
use MooseX::Types::Moose qw(Int Str ArrayRef HashRef Any);
use DateTimeX::Easy;
use JSON::Any;

subt
'must be a valid date' };

subtype JSONMap,
  as Str,
  where { eval { ref( JSON::Any->new(utf8 => 1)->from_json($_) ) eq 'HASH'} },
  message { 'must be a valid JSON map of key/value pairs' };

subty
{ 'Must be "source", "category", or "location"'};

subtype JSONBoolean,
  as Str,
  where {/^true|false$/ },
  message { 'Must contain a json boolean: "true" or "false"' };

subtype NotificationFormat
WWW-Geni ( E/ER/ERINSPICE/WWW-Geni-0.3.0a.tgz, ERINSPICE, 2011; MetaCPAN )
WWW-Geni/lib/WWW/Geni.pm ( view source; MetaCPAN )
e 5.001;
use strict;
use warnings;
use HTTP::Cookies;
use HTTP::Response;
use LWP::UserAgent;
use JSON;
use utf8;
use vars qw($VERSION $errstr);

binmode STDOUT, ":utf8";
binmode STDERR, ":utf8";

###
ass = shift;
	my $self = { @_ };
	($self->{user}, $self->{pass}) = (shift, shift);
	$self->{json} = new JSON;
	if (!$self->{user} || !$self->{pass}){
		$WWW::Geni::errstr = "Username and password are 
rl) = (shift, shift);
	my $res = $self->{ua}->get($url);
	if ($res->is_success){
		return $self->{json}->allow_nonref->relaxed->decode($res->decoded_content);
	} else {
		$WWW::Geni::errstr = $res->st
Catalyst-Authentication-Store-CouchDB ( C/CB/CBRADFORD/Catalyst-Authentication-Store-CouchDB-0.001.tar.gz, CBRADFORD, 2011; MetaCPAN )
Catalyst-Authentication-Store-CouchDB/lib/Catalyst/Authentication/Store/CouchDB/User.pm ( view source; MetaCPAN )
:NonMoose 0.20;
use CouchDB::Client 0.09 qw ();
use Catalyst::Exception;
use Catalyst::Utils;
use JSON 2.17 qw ();
use Try::Tiny 0.09;


use namespace::autoclean;
extends 'Catalyst::Authentication::Us
for_session {
    my ($self) = @_;

    my $data = $self->_user->contentForSubmit();
    # Return JSON here, because it's fast, it's human readable so we can
    # see what's going on in the session. 
 is mangling it.
    return JSON::encode_json($data);
}

sub from_session {
    my ($self, $frozen_user) = @_;

    $self->_user($self->_user_doc_from_hash(JSON::decode_json($frozen_user)));
    retur
Perl-Meta ( C/CH/CHORNY/Perl-Meta-0.02.tar.gz, CHORNY, 2011; MetaCPAN )
Perl-Meta/lib/Perl/Meta.pm ( view source; MetaCPAN )
 ...

=head1 SUBROUTINES/METHODS

=head2 extract_license

Returns license code for META.yml/json from perl/pod text by matching several patterns.

=head2 extract_perl_version

Returns perl v
IO-Multiplex-Intermediary ( J/JA/JASONMAY/IO-Multiplex-Intermediary-0.06.tar.gz, JASONMAY, 2011; MetaCPAN )
IO-Multiplex-Intermediary/lib/IO/Multiplex/Intermediary/Client.pm ( view source; MetaCPAN )

use namespace::autoclean;

use IO::Socket;
use IO::Select;
use Time::HiRes qw(gettimeofday);
use JSON;

local $| = 1;

has socket => (
    is         => 'rw',
    isa        => 'IO::Socket::INET',
  
 @inputs = grep { $_ } split /\e/m, $input;
    for (@inputs) {
        my $output = $self->parse_json($_);
        $self->socket->send("$output\n\e");
    }
};

sub build_response {
    my $self     
ift;
    my $data   = shift;

    return to_json({param => 'null'});
}

sub input_hook {
    my $self   = shift;
    my $data   = shift;

    return to_json(
        {
            param => 'output',
 
Net-Disqus ( M/MA/MADCAT/Net-Disqus-1.19.tar.gz, MADCAT, 2011; MetaCPAN )
Net-Disqus/lib/Net/Disqus/UserAgent.pm ( view source; MetaCPAN )
$Net::Disqus::VERSION";
    if(!$args{'forcelwp'}) {
        eval 'use Mojo::UserAgent; use Mojo::JSON; use Mojo::URL';
        unless($@) {
            $args{'ua_class'} = 'Mojo::UserAgent';
        
gent; use JSON::PP; use URI; use URI::Escape;';
            die Net::Disqus::Exception->new({code => 500, text => 'Something really funny is going on, cannot find one of LWP::UserAgent, JSON::PP, URI,
rAgent; use JSON::PP; use URI; use URI::Escape;';
        die Net::Disqus::Exception->new({code => 500, text => 'Something really funny is going on, cannot find one of LWP::UserAgent, JSON::PP, URI, U
Net-Disqus ( M/MA/MADCAT/Net-Disqus-1.19.tar.gz, MADCAT, 2011; MetaCPAN )
Net-Disqus/lib/Net/Disqus.pm ( view source; MetaCPAN )
= $self->fragment;
    my %args = (@_);

    $self->fragment(undef);

    my $url = sprintf('%s%s.json', $self->api_url, $self->path);
    my $method = lc($fragment->{method});
    my $required = $fra

    my ($json, $rate) = $self->ua->request($method, $url, %args);
    die Net::Disqus::Exception->new({ code => $json->{code}, text => $json->{response}}) if(!$self->pass_api_errors && $json->{code} 
'X-Ratelimit-Remaining'});
    $self->rate_limit_reset($rate->{'X-Ratelimit-Reset'});
    return $json;
}

sub AUTOLOAD {
    my $self = shift;
    my $fragment = ((($_ = $AUTOLOAD) =~ s/.*://) ? $_ :
Mojolicious-Plugin-Disqus ( M/MA/MADCAT/Mojolicious-Plugin-Disqus-1.22.tar.gz, MADCAT, 2011; MetaCPAN )
Mojolicious-Plugin-Disqus/lib/Mojolicious/Plugin/Disqus.pm ( view source; MetaCPAN )
te with the Disqus API
    pass_api_errors (optional)  When set, any API errors are returned as a JSON object instead of
                                throwing an exception.

=head1 METHODS/HELPERS
Net-Disqus ( M/MA/MADCAT/Net-Disqus-1.19.tar.gz, MADCAT, 2011; MetaCPAN )
Net-Disqus/lib/Net/Disqus/Interfaces.pm ( view source; MetaCPAN )
  $Net::Disqus::Interfaces::VERSION = '1.19';
}

# this got turned into a module since bundling a json file is often
# a pain in the you-know-whatsit - plus I forgot to add it to the Dist::Zilla
# dis
['json','jsonp'],'required' => ['group'],'method' => 'GET'},'list' => {'formats' => ['json','jsonp'],'required' => ['forum'],'method' => 'GET'}},'applications' => {'listUsage' => {'formats' => ['json'
jsonp'],'required' => [],'method' => 'GET'}},'categories' => {'listPosts' => {'formats' => ['json','jsonp','rss'],'required' => ['category'],'method' => 'GET'},'details' => {'formats' => ['json','json
Mojolicious-Plugin-Wolowitz ( G/GU/GUGOD/Mojolicious-Plugin-Wolowitz-1.0.1.tar.gz, GUGOD, 2011; MetaCPAN )
Mojolicious-Plugin-Wolowitz/lib/Mojolicious/Plugin/Wolowitz.pm ( view source; MetaCPAN )
n('wolowitz');
        ...
    }

=head1 DESCRIPTION

L<Locale::Wolowitz> is a i18n tool that use JSON as its lexicon
storage.  This Mojolicious plugin is an alternative choice to do i18n
in Mojolicio
ome, and then put translation files into there. See
L<Locale::Wolowitz> for the content format of JSON files.

=head1 METHODS

=head2 loc($message, @args)

Return the localized C<$message>. The target
WWW-MediaTemple ( C/CV/CVEGA/WWW-MediaTemple-0.02.tar.gz, CVEGA, 2011; MetaCPAN )
WWW-MediaTemple/lib/WWW/MediaTemple.pm ( view source; MetaCPAN )
package WWW::MediaTemple;

use Carp qw(croak);
use JSON;
use XML::Simple;

use base qw(REST::Client);

our $VERSION = 0.02;

sub new {
    my ( $class, %args ) = @_;

    if ( !$args{api_key} ) { croa
api/v1',
        pretty_print => 'true',
        wrap_root    => 'true',
        format       => 'json',
        raw_data     => '',
        key          => ''
    );

    # we prefer the following ve

}

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

    my $b_content = undef;

    # prepare xml/json
    if ( $self->{format} eq 'xml' ) {
        $b_content = "<service><serviceType>$args{serviceTy
IO-Multiplex-Intermediary ( J/JA/JASONMAY/IO-Multiplex-Intermediary-0.06.tar.gz, JASONMAY, 2011; MetaCPAN )
IO-Multiplex-Intermediary/lib/IO/Multiplex/Intermediary.pm ( view source; MetaCPAN )
/bin/env perl
package IO::Multiplex::Intermediary;

our $VERSION = "0.06";

use MooseX::POE;

use JSON;
use List::MoreUtils qw(any);
use Scalar::Util qw(reftype);

use POE qw(
    Wheel::SocketFactory
   my $json = eval { from_json($input) };

    {
        if ($@ || !$json) {
            warn "JSON error: $@";
        }
        elsif (!exists $json->{param}) {
            warn "Invalid JSON struct
          last unless $json->{data}->{id};
            last unless reftype($self->rw_set);
            last unless $self->rw_set->{ $json->{data}->{id} };

            if ($json->{param} eq 'output') 
Net-Disqus ( M/MA/MADCAT/Net-Disqus-1.19.tar.gz, MADCAT, 2011; MetaCPAN )
Net-Disqus/extra/build.pl ( view source; MetaCPAN )
 IO::File;
use JSON::XS;
use Data::Dumper;

my $interfaces;
my $fh = IO::File->new('./interfaces.json');
{ 
    local $/;
    $interfaces = <$fh>;
}
$fh->close();

my $json = decode_json($interfaces);

my $out = IO::File->new('>../lib/Net/Disqus/Interfaces.pm');
while(<$fh>) {
    $out->print($_);
}
$fh->close();
$out->print('sub INTERFACES { return ', Dumper($json), "; }\n\n1;\n");
$out->close();
Squatting ( B/BE/BEPPU/Squatting-0.81.tar.gz, BEPPU, 2011; MetaCPAN )
Squatting/lib/Squatting.pm ( view source; MetaCPAN )
&bar=2"
  R('Profile', 'larry')                 # "/~larry"
  R('Profile', 'larry', 'json')         # "/~larry.json"
                                                             
As you can see, C<@ar
Giddy ( I/ID/IDOPEREL/Giddy-0.013_001.tar.gz, IDOPEREL, 2011; MetaCPAN )
Giddy/lib/Giddy/Manual.pod ( view source; MetaCPAN )
chosen as the serialization
format since YAML is well suited as a human editable format; however, JSON
support is planned). This module provides an API for usage by Perl applications.

Main database f
 of the document. Quite frankly, Giddy will not care if the files
are in fact binary. They can be JSON or plain text files for all it cares, but as
long as they are separate from attributes.yaml, they
 A document file (implies '_body' attribute holds HTML data)
		data.json				<-- A document file (implies '_body' attribute holds JSON text)
		about/					<-- A document directory
			attributes.yaml				
Plack-Handler-Mongrel2 ( D/DM/DMAKI/Plack-Handler-Mongrel2-0.01000_04.tar.gz, DMAKI, 2011; MetaCPAN )
Plack-Handler-Mongrel2/lib/Plack/Handler/Mongrel2.pm ( view source; MetaCPAN )
ZMQ_POLLIN
    ZMQ_PULL
    ZMQ_PUB
    ZMQ_IDENTITY
    ZMQ_RCVMORE
    ZMQ_LINGER
);
use JSON qw(decode_json);
use HTTP::Status qw(status_message);
use Plack::Util ();
use Plack::Util::Accessor
    
 my %hdrs;

    if (DEBUG()) {
        print STDERR "[Mongrel2.pm] Decoding JSON '$headers'\n";
    }
    return decode_json $headers;
}

sub _parse_pattern {
    my $pattern = shift;
    if (DEBUG())
y) = _parse_netstring($rest);

    if ( $env{REQUEST_METHOD} eq 'JSON' ) {
        my $json_body = decode_json $body;
        if ($json_body->{type} eq 'disconnect') {
            # noop 
        } el

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