NAME
Uniform::Upload::PAGI - Explicit asynchronous multi-part file upload driver for PAGI
SYNOPSIS
use Future::AsyncAwait;
use Uniform::Upload::PAGI;
async sub handle_async_upload ($scope, $receive, $send) {
# Explicit instantiation with zero implicit guessing overhead
my $upload = Uniform::Upload::PAGI->new($scope);
if ($upload->has_file('document_payload')) {
# Execute your core, chainable validation profiles natively
$upload->file('document_payload')
->max_size('10M')
->allowed_types(['application/pdf'])
->save_to('/var/secure/storage/');
}
await $send->({
type => 'http.response.start',
status => 200,
headers => [['content-type', 'text/plain']],
});
}
DESCRIPTION
Uniform::Upload::PAGI provides an explicit integration bridge connecting the Uniform::Upload specification layer to asynchronous, non-blocking multi-part file upload environments built on the PAGI stream pipeline specification.
METHODS
new( $scope )
Validates and instantiates the asynchronous multi-part upload driver context. Requires a valid, active PAGI connection scope hash reference ($scope). Automatically maps and normalizes raw inbound stream payload keys into core file object mutators.
AUTHOR
Joshua S. Day <HAX@cpan.org>
LICENSE
MIT License. Copyright (c) 2026 Joshua S. Day.