NAME

AnyEvent::Plackup - Easily establish an HTTP server inside a program

SYNOPSIS

use AnyEvent::Plackup;

my $server = plackup(); # port is automatically chosen
my $req = $server->recv; # isa Plack::Request

my $value = $req->parameters->{foo};

$req->respond([ 200, [], [ 'OK' ] ]);

# or specify PSGI app:

my $server = plackup(app => \&app);

DESCRIPTION

AnyEvent::Plackup provides functionality of establishing an HTTP server inside a program using Twiggy. If not specified, open port is automatically chosen.

FUNCTIONS

AUTHOR

motemen motemen@gmail.com

SEE ALSO

Twiggy

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.