NAME
WebService::DigitalOcean - Access the DigitalOcean RESTful API (v2)
VERSION
version 0.002
SYNOPSIS
use WebService::DigitalOcean;
my $do = WebService::DigitalOcean->new(
token => $TOKEN,
);
my $res = $do->domain_create(
name => 'example.com',
ip_address => '127.0.0.1',
);
if ($res->{is_success}) {
say $res->{content}{domain}{name};
}
else {
say "Could not create domain";
}
DESCRIPTION
This module implements DigitalOceans new RESTful API.
It's on a very early stage of development, so expect new features, better docs and tests very soon.
Patches welcome: https://github.com/andrewalker/p5-webservice-digitalocean
ATTRIBUTES
api_base_url
A string prepended to all API endpoints. By default, it's https://api.digitalocean.com/v2. This can be adjusted to facilitate tests.
token
The authorization token. It can be retrieved by logging into one's DigitalOcean account, and generating a personal token here: https://cloud.digitalocean.com/settings/applications.
SEE ALSO
DigitalOcean: original DigitalOcean module, for v1 API.
https://developers.digitalocean.com: Documentation for API v2, in DigitalOcean's website.
Droplets role: Manage droplets with this module.
Domains role: Manage domains with this module.
Domain Records role: Manage domain records with this module.
CAVEATS
This is alpha software. The interface is unstable, and may change without notice.
Also, there are no real unit tests. We currently only test compilation and instantiation of the module.
AUTHOR
André Walker <andre@cpan.org>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2014 by André Walker.
This is free software, licensed under:
The GNU General Public License, Version 2, June 1991