To list the versions of Kubernetes available for use, the regions that support Kubernetes, and the available node sizes, send a GET request to /v2/kubernetes/options
.
import os
from pydo import Client
client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))
resp = client.kubernetes.list_options()
See the API spec for this endpoint to view additional detail on responses, headers, parameters, and more.
The response will be a JSON object with a key called options
which contains
regions
, versions
, and sizes
objects listing the available options and
the matching slugs for use when creating a new cluster.
Unauthorized
The resource was not found.
API Rate limit exceeded
Server error.
Unexpected error