Commit Graph

40 Commits

Author SHA1 Message Date
akutz 8ed9e9ea6c Portable Go Context Usage
This patch updates the godo package to use a portable Go context -- a
Context that works with Go versions prior to Go 1.7 as well as Go 1.7
and onwards.
2017-04-07 15:32:33 -05:00
Viola Holownia 24ddd97cc2 Fix typos in PublicIPv6() 2017-02-27 19:06:08 -05:00
Antoine Grondin dc14e4b04d add context.Context to all calls 2017-02-23 14:25:29 -05:00
Marko Mudrinic 792d5cee77 Added missing fields in Droplet struct 2017-02-13 14:04:32 +01:00
Maurício Linhares 3ab73e7c31 Merge pull request #119 from term1nal/refactor/make-linters-happy
make linters happy
2016-12-22 14:56:20 -03:00
Carlos Villela 7c9bf15691 Adds support for creating droplets with monitoring (#117) 2016-12-21 23:05:53 -05:00
Term1nal b814e84f48 make linters happy 2016-12-20 16:00:17 -08:00
Phillip Baker bec8984b6b Merge pull request #108 from digitalocean/feature/snapshots
Add snapshots endpoints.
2016-11-29 22:58:31 -05:00
Phillip Baker e715166fe5 Add snapshots endpoints, unify code with storage snapshots. 2016-11-18 11:26:43 -05:00
Vivian Fang 8d4c97f7f2 Fix JSON typo in Droplet 2016-11-14 23:33:25 -08:00
Vivian Fang d9494d316f Fix droplet JSON to support VolumeIDs
Before this patch, the Droplet struct had the wrong JSON key for
VolumeIDs, so volumes would not be reflected in a Droplet query.
2016-11-14 23:30:41 -08:00
Mike Chittenden 82ae4350ef Add Tags attribute to droplet create 2016-11-09 10:57:33 -05:00
Chase Adams eaefd48803 organizes dropletCreateImage MarshalJSON declaration 2016-09-09 09:56:11 -07:00
Antoine Grondin 979e3b310f storage: support for storage API 2016-06-27 13:45:59 -04:00
bryanl 3bd6277a85 Add tags to droplets 2016-04-19 12:32:42 +02:00
Nan Zhong a294b449f7 Fix incorrect query param 2016-03-17 02:18:20 -04:00
Nan Zhong 1eaf6161c0 Update droplet and actions endpoints with tagging support 2016-03-17 01:45:16 -04:00
bryanl 145e3fbd9b Remove ActionIDs from Droplets
ActionIDs for Droplets were removed a while go. This removes support the API client.
2016-02-29 19:44:37 -05:00
bryanl 0155e46933 Expose convenience methods to expose droplet IPs
Introduces new functions for `github.com/digitalocean/droplet` to make fetching IP address easier.

* PublicIPv4
* PublicIPv6
* PrivateIPv4
2016-01-30 09:56:51 -05:00
Mike Chittenden 3978e9d3ba Multiple droplet create support 2015-12-14 16:11:51 -05:00
Francisco Demartino 7b30f84482 make current kernel available in a Droplet
it was already available in the fetched JSON
2015-12-02 09:18:32 -03:00
bryanl af5057f05f Add checks for arguments
Adds checks to determine if the request will actually be valid by prefiltering invalid defaults (less than 0, empty strings, nils). The goal of this change is eliminate unnecceary API calls.
2015-09-25 14:44:20 -05:00
bryanl 32ac48f00c It's DigitalOcean 2015-09-18 09:10:59 -04:00
bryanl 62b1f69e1a remove unexported items from interfaces 2015-06-03 00:22:08 -04:00
bryanl de59235b17 updating documentation for godo 2015-06-01 13:34:27 -04:00
Phillip Baker 1df42b98f6 Standardize on returning objects, not the json roots.
Let's be nice to our consumers - they don't care about the root, they care about the object. Even when the user needs access to the Links, that's accessible via the resp variable returned.
2015-06-01 10:47:19 -04:00
bryanl 5d38c50b0a Add size slug to droplet
Adds missing size slug to droplets. This should take care of the
issue raised in #21.
2015-05-11 14:26:52 -04:00
Raphael Simon 2a6cda7911 Rename Droplets.ListKernels() and co. to Droplets.Kernels()
so that the naming convention is consistent with the Images service where "ListFoo()" means "list images of type foo" rather than "list foos of the image".
2015-04-20 18:32:49 -07:00
Raphael Simon df0702b9e2 Add Droplet service Listing requests.
Includes ListKernels, ListSnapshots, ListBackups, ListActions and ListNeighbors corresponding to
the GET "/v2/droplets/:id/kernels" etc. APIs.
2015-04-20 15:27:41 -07:00
Bryce Reitano 107613d25b Omit an empty value for user data to serialize properly. 2015-04-12 18:44:47 -06:00
bryanl 14a4b3f281 Remove testing Implements
Make adherenence to interface a compile type rather than a test time check.
2015-03-21 15:42:48 -04:00
Phillip Baker f1ccbcd46f Add image/ssh key structs for explicit type on droplet create.
Closes #22
2015-03-21 14:52:14 -04:00
Phillip Baker 1323a431a4 Update doc links for v2 documentation. 2015-03-07 15:47:46 -05:00
Nick Saika 483a68e37a New struct NetworkV6, rename struct Network -> NetworkV4.
This is due to there being a different in the type of the Netmask value,
when it is returned from the API server. For IPv4 networks, the netmask
is returned as a string. However, the netmask is returned as an int for
IPv6 networks.

Add tests for the new NetworkV6 type.
2015-02-20 14:14:47 -05:00
Gianluca Arbezzano 90e430af72 Add creation date field 2014-11-02 23:38:31 +01:00
bryanl 6fc81f4c7a Add all options to droplet create request
Added:

backups, ipv6, private_networking, user_data
2014-10-16 09:36:50 -04:00
bryanl 09b1d317c4 Links aren't added to droplet create response
Links returned by the API were not added to the Droplet create response, so you couldn't inspect the URL to determine when a Droplet was created.
2014-09-10 17:28:44 -04:00
bryanl 96accbf5e9 Update to current API spec
* Allow requesting pages in lists by number
* Add tooling to allow examination of page links if they exist
* Add domain management CRUD
2014-09-08 20:36:11 -04:00
bryanl 4b5588d885 Services are interfaces
* Converted services to interfaces to make testing with them
in downstream projects easier to do.
* Removed testify dependency.
2014-09-04 16:22:37 -04:00
bryanl b4bec8f557 initial commit 2014-09-03 10:20:10 -04:00