Plack::App::JSONRPC - (DEPRECATED) Yet another JSON-RPC 2.0 psgi application
# app.psgi use Plack::App::JSONRPC; use Plack::Builder; my $jsonrpc = Plack::App::JSONRPC->new( methods => { echo => sub { $_[0] }, empty => sub {''} } ); my $app = sub { [204, [], []] }; builder { mount '/jsonrpc', $jsonrpc->to_app; mount '/' => $app; }; # run $ plackup app.psgi # POST http://localhost:5000/jsonrpc # {"jsonrpc":"2.0","method":"echo","params":"Hello","id":1} # return content # {"jsonrpc":"2.0","result":"Hello","id":1}
Plack::App::JSONRPC is Yet another JSON-RPC 2.0 psgi application
Copyright (C) nqounet.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
nqounet <mail@nqou.net>
To install Plack::App::JSONRPC, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Plack::App::JSONRPC
CPAN shell
perl -MCPAN -e shell install Plack::App::JSONRPC
For more information on module installation, please visit the detailed CPAN module installation guide.