VM-HetznerCloud
view release on metacpan - search on metacpan
view release on metacpan or search on metacpan
lib/VM/HetznerCloud/API/Certificates.pm view on Meta::CPAN
},
};
return $self->_request( '/:id/actions/:action_id', \%params, $request_params, { type => 'get', oid => '/certificates/{id}/actions/{action_id}#get' } );
}
1;
__END__
=pod
=encoding UTF-8
=head1 NAME
VM::HetznerCloud::API::Certificates - Certificates
=head1 VERSION
version 0.0.3
=head1 SYNOPSIS
use VM::HetznerCloud;
my $api_key = '1234abc';
my $cloud = VM::HetznerCloud->new(
token => $api_key,
);
$cloud->records->create(
);
=head1 ATTRIBUTES
=over 4
=item * endpoint
=back
=head1 METHODS
=head2 list
Returns all Certificate objects.
$cloud->certificates->list(
label_selector => 'test',
name => 'test',
sort => 'test',
type => 'test',
);
=head2 create
Creates a new Certificate.
The default type **uploaded** allows for uploading your existing `certificate` and `private_key` in PEM format. You have to monitor its expiration date and handle renewal yourself.
In contrast, type **managed** requests a new Certificate from *Let's Encrypt* for the specified `domain_names`. Only domains managed by *Hetzner DNS* are supported. We handle renewal and timely alert the project owner via email if problems occur.
For type `managed` Certificates the `action` key of the response contains the Action that allows for tracking the issuance process. For type `uploaded` Certificates the `action` is always null.
$cloud->certificates->create();
=head2 delete
Deletes a Certificate.
$cloud->certificates->delete(
id => 'test',
);
=head2 get
Gets a specific Certificate object.
$cloud->certificates->get(
id => 'test',
);
=head2 put
Updates the Certificate properties.
Note that when updating labels, the Certificateâs current set of labels will be replaced with the labels provided in the request body. So, for example, if you want to add a new label, you have to provide all existing labels plus the new label in th...
Note: if the Certificate object changes during the request, the response will be a âconflictâ error.
$cloud->certificates->put(
id => 'test',
);
=head2 list_actions
Returns all Action objects for a Certificate. You can sort the results by using the `sort` URI parameter, and filter them with the `status` parameter.
Only type `managed` Certificates can have Actions. For type `uploaded` Certificates the `actions` key will always contain an empty array.
$cloud->certificates->list_actions(
id => 'test',
sort => 'test',
status => 'test',
);
=head2 retry
Retry a failed Certificate issuance or renewal.
Only applicable if the type of the Certificate is `managed` and the issuance or renewal status is `failed`.
#### Call specific error codes
| Code | Description |
|---------------------------------------------------------|---------------------------------------------------------------------------|
| `caa_record_does_not_allow_ca` | CAA record does not allow certificate authority |
| `ca_dns_validation_failed` | Certificate Authority: DNS validation failed |
| `ca_too_many_authorizations_failed_recently` | Certificate Authority: Too many authorizations failed recently |
view all matches for this distributionview release on metacpan - search on metacpan
( run in 1.616 second using v1.00-cache-2.02-grep-82fe00e-cpan-f73e49a70403 )