KosmoKrator

cloud

DigitalOcean CLI for AI Agents

Use the DigitalOcean CLI from KosmoKrator to call DigitalOcean tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

10 functions 7 read 3 write Bearer token auth

DigitalOcean CLI Setup

DigitalOcean can be configured headlessly with `kosmokrator integrations:configure digitalocean`.

# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure digitalocean --set access_token="$DIGITALOCEAN_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmokrator integrations:doctor digitalocean --json
kosmokrator integrations:status --json

Credentials

Authentication type: Bearer token bearer_token. Configure credentials once, then use the same stored profile from scripts, coding CLIs, Lua code mode, and the MCP gateway.

KeyEnv varTypeRequiredLabel
access_token DIGITALOCEAN_ACCESS_TOKEN Secret secret yes Access Token
url DIGITALOCEAN_URL URL url no API Base URL

Call DigitalOcean Headlessly

Use the generic call form when another coding CLI or script needs a stable universal interface.

kosmo integrations:call digitalocean.digitalocean_list_droplets '{
  "page": 1,
  "per_page": 1
}' --json

Use the provider shortcut form for shorter human-facing commands.

kosmo integrations:digitalocean digitalocean_list_droplets '{
  "page": 1,
  "per_page": 1
}' --json

Agent Discovery Commands

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

kosmo integrations:docs digitalocean --json
kosmo integrations:docs digitalocean.digitalocean_list_droplets --json
kosmo integrations:schema digitalocean.digitalocean_list_droplets --json
kosmo integrations:search "DigitalOcean" --json
kosmo integrations:list --json

All CLI Functions

Every function below can be called headlessly. The generic form is stable across all integrations; the provider shortcut is shorter but specific to DigitalOcean.

digitalocean.digitalocean_list_droplets

Read read

List all droplets (virtual machines) in the DigitalOcean account. Returns IDs, names, status, size, region, and IP addresses.

Parameters
page, per_page

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_list_droplets '{"page":1,"per_page":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_list_droplets '{"page":1,"per_page":1}' --json

digitalocean.digitalocean_get_droplet

Read read

Get details for a specific DigitalOcean droplet by ID. Returns full droplet information including networks, image, and region.

Parameters
id

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_get_droplet '{"id":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_get_droplet '{"id":1}' --json

digitalocean.digitalocean_create_droplet

Write write

Create a new DigitalOcean droplet (virtual machine). Requires a name, region, size, and image.

Parameters
name, region, size, image, ssh_keys, backups, ipv6, user_data, tags

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_create_droplet '{"name":"example_name","region":"example_region","size":"example_size","image":"example_image","ssh_keys":"example_ssh_keys","backups":true,"ipv6":true,"user_data":"example_user_data"}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_create_droplet '{"name":"example_name","region":"example_region","size":"example_size","image":"example_image","ssh_keys":"example_ssh_keys","backups":true,"ipv6":true,"user_data":"example_user_data"}' --json

digitalocean.digitalocean_delete_droplet

Write write

Permanently delete a DigitalOcean droplet. This action is irreversible and will destroy all data on the droplet.

Parameters
id

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_delete_droplet '{"id":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_delete_droplet '{"id":1}' --json

digitalocean.digitalocean_reboot_droplet

Write write

Reboot a DigitalOcean droplet. The droplet will be power-cycled and will be temporarily unavailable.

Parameters
id

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_reboot_droplet '{"id":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_reboot_droplet '{"id":1}' --json

digitalocean.digitalocean_list_domains

Read read

List all DNS domains managed in the DigitalOcean account.

Parameters
page, per_page

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_list_domains '{"page":1,"per_page":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_list_domains '{"page":1,"per_page":1}' --json

digitalocean.digitalocean_get_domain

Read read

Get details for a specific DNS domain in DigitalOcean, including zone file and TTL information.

Parameters
name

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_get_domain '{"name":"example_name"}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_get_domain '{"name":"example_name"}' --json

digitalocean.digitalocean_list_spaces

Read read

List Spaces (S3-compatible object storage buckets) in the DigitalOcean account.

Parameters
page, per_page

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_list_spaces '{"page":1,"per_page":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_list_spaces '{"page":1,"per_page":1}' --json

digitalocean.digitalocean_list_kubernetes

Read read

List Kubernetes (DOKS) clusters in the DigitalOcean account.

Parameters
page, per_page

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_list_kubernetes '{"page":1,"per_page":1}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_list_kubernetes '{"page":1,"per_page":1}' --json

digitalocean.digitalocean_get_current_user

Read read

Get information about the current authenticated DigitalOcean account, including email, UUID, and status.

Parameters
none

Generic CLI call

kosmo integrations:call digitalocean.digitalocean_get_current_user '{}' --json

Provider shortcut

kosmo integrations:digitalocean digitalocean_get_current_user '{}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

digitalocean.digitalocean_list_droplets

List all droplets (virtual machines) in the DigitalOcean account. Returns IDs, names, status, size, region, and IP addresses.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_list_droplets --json
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
per_page integer no Number of droplets per page (default: 20, max: 200).

digitalocean.digitalocean_get_droplet

Get details for a specific DigitalOcean droplet by ID. Returns full droplet information including networks, image, and region.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_get_droplet --json
ParameterTypeRequiredDescription
id integer yes The droplet ID.

digitalocean.digitalocean_create_droplet

Create a new DigitalOcean droplet (virtual machine). Requires a name, region, size, and image.

Operation
Write write
Schema command
kosmo integrations:schema digitalocean.digitalocean_create_droplet --json
ParameterTypeRequiredDescription
name string yes The hostname for the droplet (e.g., "web-01").
region string yes The region slug (e.g., "nyc3", "ams3", "sgp1").
size string yes The size slug (e.g., "s-1vcpu-1gb", "s-2vcpu-4gb").
image string yes The image slug or ID (e.g., "ubuntu-24-04-x64", "debian-12-x64").
ssh_keys array no Array of SSH key IDs or fingerprints to embed.
backups boolean no Enable automated backups (default: false).
ipv6 boolean no Enable IPv6 (default: false).
user_data string no Cloud-init user data script.
tags array no Array of tag names to apply.

digitalocean.digitalocean_delete_droplet

Permanently delete a DigitalOcean droplet. This action is irreversible and will destroy all data on the droplet.

Operation
Write write
Schema command
kosmo integrations:schema digitalocean.digitalocean_delete_droplet --json
ParameterTypeRequiredDescription
id integer yes The droplet ID to delete.

digitalocean.digitalocean_reboot_droplet

Reboot a DigitalOcean droplet. The droplet will be power-cycled and will be temporarily unavailable.

Operation
Write write
Schema command
kosmo integrations:schema digitalocean.digitalocean_reboot_droplet --json
ParameterTypeRequiredDescription
id integer yes The droplet ID to reboot.

digitalocean.digitalocean_list_domains

List all DNS domains managed in the DigitalOcean account.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_list_domains --json
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
per_page integer no Number of domains per page (default: 20).

digitalocean.digitalocean_get_domain

Get details for a specific DNS domain in DigitalOcean, including zone file and TTL information.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_get_domain --json
ParameterTypeRequiredDescription
name string yes The domain name (e.g., "example.com").

digitalocean.digitalocean_list_spaces

List Spaces (S3-compatible object storage buckets) in the DigitalOcean account.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_list_spaces --json
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
per_page integer no Number of items per page (default: 20).

digitalocean.digitalocean_list_kubernetes

List Kubernetes (DOKS) clusters in the DigitalOcean account.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_list_kubernetes --json
ParameterTypeRequiredDescription
page integer no Page number for pagination (default: 1).
per_page integer no Number of items per page (default: 20).

digitalocean.digitalocean_get_current_user

Get information about the current authenticated DigitalOcean account, including email, UUID, and status.

Operation
Read read
Schema command
kosmo integrations:schema digitalocean.digitalocean_get_current_user --json
ParameterTypeRequiredDescription
No parameters.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.