App-MtAws
view release on metacpan or search on metacpan
lib/App/MtAws/GlacierRequest.pm view on Meta::CPAN
return $resp ? 1 : undef;
}
sub retrieve_archive
{
my ($self, $archive_id) = @_;
$archive_id||confess;
$self->add_header('Content-Type', 'application/x-www-form-urlencoded; charset=utf-8');
$self->{url} = "/$self->{account_id}/vaults/$self->{vault}/jobs";
$self->{method} = 'POST';
# add "SNSTopic": "sometopic"
# no Test::Tabs
my $body = <<"END";
{
"Type": "archive-retrieval",
"ArchiveId": "$archive_id"
}
lib/App/MtAws/GlacierRequest.pm view on Meta::CPAN
$format or confess;
if ($format eq 'json') {
$format = 'JSON';
} elsif ($format eq 'csv') {
$format = 'CSV';
} else {
confess "unknown inventory format $format";
}
$self->add_header('Content-Type', 'application/x-www-form-urlencoded; charset=utf-8');
$self->{url} = "/$self->{account_id}/vaults/$self->{vault}/jobs";
$self->{method} = 'POST';
my $job_meta = App::MtAws::MetaData::meta_job_encode(META_JOB_TYPE_FULL);
# add "SNSTopic": "sometopic"
# no Test::Tabs
my $body = <<"END";
{
"Type": "inventory-retrieval",
( run in 0.282 second using v1.01-cache-2.11-cpan-4d50c553e7e )