Digital Ocean icon

Digital Ocean

Digital Ocean

Actions14

Overview

This node integrates with DigitalOcean's API to manage Droplets, which are virtual private servers. Specifically, the "Droplet" resource with the "Action" operation allows users to perform various control actions on a selected Droplet such as powering it on/off, rebooting, enabling/disabling backups or IPv6, resetting its password, renaming it, shutting it down, or creating snapshots.

Common scenarios include automating server lifecycle management tasks like scheduled reboots, snapshot creation before deployments, or dynamically enabling IPv6 for new droplets. For example, a user could automate taking a snapshot of a droplet before applying updates, or power cycle a droplet if it becomes unresponsive.

Properties

Name Meaning
Authentication Method to authenticate API requests: either using an Access Token or OAuth2 authentication.
Droplet Name or ID The identifier (name or ID) of the droplet to perform the action on.
Action to Perform The specific action to execute on the droplet. Options include:
- Disable Backups
- Enable Backups
- Enable IPv6
- Password Reset
- Power Cycle
- Power Off
- Power On
- Reboot
- Rename
- Shutdown
- Snapshot
Snapshot Name (Required if action is "Snapshot") The name to assign to the created snapshot.
Droplet Name (Required if action is "Rename") The new name to assign to the droplet.

Output

The output JSON contains the result of the performed action on the droplet. It typically includes an action object describing the status and details of the requested operation as returned by the DigitalOcean API.

No binary data output is produced by this node.

Example output structure:

{
  "action": {
    "id": 123456,
    "status": "in-progress",
    "type": "power_cycle",
    "started_at": "2023-01-01T12:00:00Z",
    ...
  }
}

Dependencies

  • Requires a valid DigitalOcean API credential configured in n8n, either via an API access token or OAuth2.
  • Uses DigitalOcean's REST API endpoints for droplets and their actions.
  • No additional external dependencies beyond the DigitalOcean API and n8n environment.

Troubleshooting

  • Error: Both Tag Name and Name provided when listing droplets
    The DigitalOcean API does not allow filtering droplets by both tag name and droplet name simultaneously. Remove one filter option to resolve.

  • Invalid Droplet ID or Name
    Ensure the droplet identifier exists and is correctly specified. Use the dropdown list or expressions carefully.

  • Authentication Errors
    Verify that the API key or OAuth2 credentials are valid and have sufficient permissions to perform droplet actions.

  • Action-specific errors
    Some actions require additional parameters (e.g., snapshot name for snapshot action, new name for rename). Make sure these fields are filled when required.

  • Rate Limits
    If many requests are made rapidly, DigitalOcean may throttle API calls. Implement retries or reduce request frequency.

Links and References

Discussion