NAME

PAGI::App::WrapPSGI - PSGI-to-PAGI adapter

SYNOPSIS

use PAGI::App::WrapPSGI;

my $psgi_app = sub {
    my ($env) = @_;
    return [200, ['Content-Type' => 'text/plain'], ['Hello']];
};

my $wrapper = PAGI::App::WrapPSGI->new(psgi_app => $psgi_app);
my $pagi_app = $wrapper->to_app;

DESCRIPTION

PAGI::App::WrapPSGI wraps a PSGI application to make it work with PAGI servers. It converts PAGI scope to PSGI %env and converts PSGI responses to PAGI events.

SEE ALSO

PAGI::Server, PSGI

AUTHOR

John Napiorkowski <jjnapiork@cpan.org>

LICENSE

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