{
  "openapi": "3.1.0",
  "info": {
    "title": "Cloud API",
    "version": "1.5.10",
    "description": "Servers, networking, storage, managed services and Kubernetes in one zone of Cloud. Every request goes to the zone the resource is in."
  },
  "servers": [
    {
      "url": "https://{availability_zone}.betterstackcloud.com",
      "variables": {
        "availability_zone": {
          "description": "Use the zone your resources are in, such as `us-west-2a`. Each zone is separate. Required: the API has no default, every caller must supply one.",
          "default": "us-west-2a",
          "x-required": true
        }
      }
    }
  ],
  "x-cli-token-env": "BETTERSTACK_CLOUD_API_TOKEN",
  "x-team-token": "Cloud",
  "x-cli-token-exchange": "cloud",
  "x-cli-helpers": [
    {
      "name": "ssh",
      "resource": "server",
      "kind": "server_ssh",
      "operations": {
        "get": "get_server"
      },
      "fields": {
        "id": "id",
        "addresses": "ip_addresses",
        "address": "ip",
        "address_type": "type",
        "ipv4_type": "ipv4",
        "ipv6_type": "ipv6"
      }
    }
  ],
  "x-cli-examples": [
    {
      "title": "Add your SSH key, then start a new server and wait until it is running",
      "commands": [
        "ssh-key create --availability-zone us-west-2a --team-id t123 --slug my-key --public-key @~/.ssh/id_ed25519.pub",
        "server create --availability-zone us-west-2a --team-id t123 --name web-1 --server-type AM4 --image ubuntu-26-04 --ssh-keys my-key --wait"
      ]
    }
  ],
  "security": [
    {
      "teamApiToken": []
    },
    {
      "globalApiToken": []
    }
  ],
  "tags": [
    {
      "name": "certificate",
      "description": "A TLS certificate for the `https` services of your load balancers. You either upload the certificate, or we issue and renew it with Let's Encrypt. A certificate works in every availability zone."
    },
    {
      "name": "clickhouse",
      "description": "A managed ClickHouse instance, an analytical database for large amounts of data."
    },
    {
      "name": "clickhouse_event",
      "description": "Something that happened to a ClickHouse instance, such as a rescale or a snapshot."
    },
    {
      "name": "clickhouse_scheduled_snapshot",
      "description": "A schedule that creates snapshots of a ClickHouse instance."
    },
    {
      "name": "clickhouse_snapshot",
      "description": "A backup of a ClickHouse instance at one point in time. A snapshot stays after its instance is deleted, and you can still get it by its ID."
    },
    {
      "name": "clickhouse_type",
      "description": "A size of ClickHouse instance you can order."
    },
    {
      "name": "clickhouse_version",
      "description": "A ClickHouse LTS version you can run a managed ClickHouse instance on."
    },
    {
      "name": "event",
      "description": "Something that happened to a server, with who did it and when."
    },
    {
      "name": "firewall",
      "description": "A named set of inbound and outbound rules that you can attach to servers. A firewall blocks all traffic that no rule allows."
    },
    {
      "name": "firewall_rule",
      "description": "A rule that allows traffic through a firewall. A rule matches traffic by direction, protocol, address and port range."
    },
    {
      "name": "image",
      "description": "An operating system image a server can be created from."
    },
    {
      "name": "ip",
      "description": "An IP in this zone, such as a public address on a server, a private address in a network or a reserved IP that isn't assigned to a server."
    },
    {
      "name": "kafka",
      "description": "A managed Kafka cluster with one or three brokers, running in KRaft mode."
    },
    {
      "name": "kafka_event",
      "description": "Something that happened to a Kafka cluster, such as a topic created, a broker down or an upgrade."
    },
    {
      "name": "kafka_topic",
      "description": "A topic on a managed Kafka cluster. Clients can't create topics on the cluster, so create them via [Create a Kafka topic](/docs/cloud/api/kafka-topics/create-kafka-topic/)."
    },
    {
      "name": "kafka_type",
      "description": "A size of Kafka cluster you can order."
    },
    {
      "name": "kafka_user",
      "description": "A user of a Kafka cluster. Clients sign in as a user with SCRAM, and can use only the topics the user's privileges allow."
    },
    {
      "name": "kafka_version",
      "description": "A Kafka version you can run a new cluster on or upgrade to."
    },
    {
      "name": "kubernetes_cluster",
      "description": "A managed Kubernetes cluster, with a control plane and groups of workers in `node_pools`. The control plane runs on a single server."
    },
    {
      "name": "kubernetes_event",
      "description": "Something that happened to a Kubernetes cluster, such as a node pool scaled, a worker replaced or a restore that failed."
    },
    {
      "name": "kubernetes_node_pool",
      "description": "A group of workers in a Kubernetes cluster, all of one server type. You add, scale and remove workers through the cluster's node pools."
    },
    {
      "name": "kubernetes_scheduled_snapshot",
      "description": "A schedule that creates snapshots of a Kubernetes cluster's control plane."
    },
    {
      "name": "kubernetes_snapshot",
      "description": "A snapshot of a Kubernetes cluster's control plane, without the workers or persistent volumes."
    },
    {
      "name": "kubernetes_version",
      "description": "A Kubernetes minor version you can run a cluster on, and the exact build we install for it."
    },
    {
      "name": "load_balancer",
      "description": "A managed load balancer that spreads TCP, UDP, HTTP and HTTPS traffic over your servers. A load balancer has services that listen for traffic and targets that receive it."
    },
    {
      "name": "load_balancer_event",
      "description": "Something that happened to a load balancer, such as a change of its type."
    },
    {
      "name": "load_balancer_service",
      "description": "A port a load balancer listens on, with how it forwards the traffic to the load balancer's targets. Each service checks the targets' health on its own."
    },
    {
      "name": "load_balancer_target",
      "description": "A server, or every server with a set of tags, that a load balancer sends traffic to."
    },
    {
      "name": "load_balancer_type",
      "description": "A size of load balancer you can order."
    },
    {
      "name": "mysql",
      "description": "A managed MySQL instance with a primary and up to two read replicas. Replicas copy the primary asynchronously."
    },
    {
      "name": "mysql_event",
      "description": "Something that happened to a MySQL instance, such as a rescale or an upgrade."
    },
    {
      "name": "mysql_scheduled_snapshot",
      "description": "A schedule that creates snapshots of a MySQL instance."
    },
    {
      "name": "mysql_snapshot",
      "description": "A snapshot of a MySQL instance at one point in time. You can get or delete a snapshot by its ID alone, even after its instance is deleted."
    },
    {
      "name": "mysql_type",
      "description": "A size of MySQL instance you can order, with its disk and connection limits."
    },
    {
      "name": "mysql_version",
      "description": "A MySQL LTS version you can create an instance with."
    },
    {
      "name": "network",
      "description": "A private network you can attach servers to. Servers on the network get private addresses from its IP range."
    },
    {
      "name": "object_cache",
      "description": "An S3-compatible cache in front of your buckets at another storage provider. The object cache serves reads from fast local disks and passes writes on to the original buckets."
    },
    {
      "name": "object_cache_bucket",
      "description": "A bucket an object cache serves. Each one maps to a bucket at your S3-compatible storage provider."
    },
    {
      "name": "object_cache_event",
      "description": "Something that happened to an object cache, such as a purge or a bucket added."
    },
    {
      "name": "object_cache_type",
      "description": "A size of object cache you can order."
    },
    {
      "name": "otlp",
      "description": "An export that sends the metrics of a team's servers in this zone to your OTLP receiver every minute."
    },
    {
      "name": "placement_group",
      "description": "A group of servers that we either spread across different hosts or pack onto as few hosts as we can, as long as there's room."
    },
    {
      "name": "postgres",
      "description": "A managed PostgreSQL instance with up to two read replicas. Clients connect straight to PostgreSQL, or through PgBouncer, which pools connections."
    },
    {
      "name": "postgres_database",
      "description": "A database inside a managed PostgreSQL instance."
    },
    {
      "name": "postgres_event",
      "description": "Something that happened to a PostgreSQL instance, such as a rescale or an upgrade."
    },
    {
      "name": "postgres_scheduled_snapshot",
      "description": "A schedule that creates snapshots of a PostgreSQL instance."
    },
    {
      "name": "postgres_snapshot",
      "description": "A snapshot of a PostgreSQL instance. You can get a snapshot by its ID alone, even after its instance is deleted."
    },
    {
      "name": "postgres_type",
      "description": "A size of PostgreSQL instance you can order, with its CPUs, memory, disk and connection limits."
    },
    {
      "name": "postgres_user",
      "description": "A user of a PostgreSQL instance, with its access level on each database."
    },
    {
      "name": "postgres_version",
      "description": "A PostgreSQL major version you can create an instance with."
    },
    {
      "name": "quota",
      "description": "The organization's resource limits in this zone."
    },
    {
      "name": "reserved_ip",
      "description": "A public IP address that belongs to your team instead of a server. You can move a reserved IP between servers, and you keep it when you delete a server."
    },
    {
      "name": "scheduled_snapshot",
      "description": "A schedule that creates snapshots of a server."
    },
    {
      "name": "scheduled_volume_snapshot",
      "description": "A schedule that creates snapshots of a volume."
    },
    {
      "name": "server",
      "description": "A virtual machine, with its size, image, networks, firewall, addresses and status."
    },
    {
      "name": "server_pool",
      "description": "A server pool keeps spare servers of one type running, so you can claim a running server from the pool in under a second."
    },
    {
      "name": "server_private_ip",
      "description": "A private IP of a server in one of its private networks."
    },
    {
      "name": "server_public_ip",
      "description": "A public IP address on a server, and its reverse DNS record."
    },
    {
      "name": "server_type",
      "description": "A server size, with its vCPUs, memory, disk and bandwidth, and whether you can order it."
    },
    {
      "name": "server_type_availability",
      "description": "Whether your organization can start a number of servers of a server type in this zone now."
    },
    {
      "name": "snapshot",
      "description": "A copy of a server's disk at one moment. You can restore it onto the same server or into a new server."
    },
    {
      "name": "ssh_key",
      "description": "An SSH key for the root user of your servers. We add it to a server when the server is created, or later when you attach it."
    },
    {
      "name": "valkey",
      "description": "A managed Valkey instance, with one primary and up to two replicas."
    },
    {
      "name": "valkey_event",
      "description": "Something that happened to a Valkey instance, such as a rescale or a failover."
    },
    {
      "name": "valkey_scheduled_snapshot",
      "description": "A schedule that creates a snapshot of a Valkey instance at a regular interval, always from the instance's current primary."
    },
    {
      "name": "valkey_snapshot",
      "description": "A backup of a Valkey instance at one point in time. A snapshot stays after its instance is deleted, and you can still get it by its ID."
    },
    {
      "name": "valkey_type",
      "description": "A size of Valkey instance you can order."
    },
    {
      "name": "valkey_version",
      "description": "A Valkey version you can run a Valkey instance on."
    },
    {
      "name": "volume",
      "description": "An NVMe disk that adds storage to a server. A volume is attached to one server at a time."
    },
    {
      "name": "volume_snapshot",
      "description": "A backup of a volume at one moment, kept in object storage."
    },
    {
      "name": "webhook",
      "description": "A URL we notify when your resources in this zone change."
    }
  ],
  "paths": {
    "/v1/certificates": {
      "get": {
        "operationId": "list_certificate",
        "summary": "List the certificates in this zone, with their type and status.",
        "tags": [
          "certificate"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/certificates",
        "parameters": [
          {
            "name": "certificate_type",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "uploaded",
                "managed"
              ]
            },
            "description": "Only certificates of this type."
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "pending",
                "issued",
                "failed"
              ]
            },
            "description": "Only certificates with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the certificate with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only certificates whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only certificates with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match certificates that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of certificate objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CertificateList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "domain_names",
          "not_valid_after"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "status_message",
          "domain_names",
          "certificate",
          "fingerprint",
          "not_valid_before",
          "not_valid_after",
          "last_issued_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.certificate.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_certificate",
        "summary": "Upload a certificate, or have us issue a managed one.",
        "description": "A managed certificate starts as `pending`. We issue it once it's attached to an `https` service of a load balancer and every domain points at that load balancer. Port 80 on the load balancer must be free or serve plain HTTP.",
        "tags": [
          "certificate"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/certificates",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single certificate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CertificateDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single certificate. (`certificate_type` is `managed`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CertificateDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of certificates, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CertificateCreate"
              },
              "examples": {
                "ask_us_to_issue_a_certificate": {
                  "summary": "Ask us to issue a certificate",
                  "value": {
                    "team_id": "t123",
                    "name": "example",
                    "certificate_type": "managed",
                    "domain_names": [
                      "example.com"
                    ]
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "domain_names",
          "not_valid_after"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "status_message",
          "domain_names",
          "certificate",
          "fingerprint",
          "not_valid_before",
          "not_valid_after",
          "last_issued_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.certificate.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/certificates/{id}": {
      "delete": {
        "operationId": "delete_certificate",
        "summary": "Remove a certificate.",
        "description": "Detach the certificate from every load balancer service first.",
        "tags": [
          "certificate"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/certificates/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A load balancer service in any zone uses the certificate, with the code `certificate_in_use`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_certificate",
        "summary": "Get a certificate, with the domains it covers, its status and when it expires.",
        "tags": [
          "certificate"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/certificates/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single certificate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CertificateDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "domain_names",
          "not_valid_after"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "status_message",
          "domain_names",
          "certificate",
          "fingerprint",
          "not_valid_before",
          "not_valid_after",
          "last_issued_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.certificate.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_certificate",
        "summary": "Update a certificate's name or tags.",
        "description": "To replace the certificate itself, create a new one and attach it to your load balancer services.",
        "tags": [
          "certificate"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/certificates/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single certificate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CertificateDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CertificateUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "domain_names",
          "not_valid_after"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "certificate_type",
          "status",
          "status_message",
          "domain_names",
          "certificate",
          "fingerprint",
          "not_valid_before",
          "not_valid_after",
          "last_issued_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.certificate.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse": {
      "get": {
        "operationId": "list_clickhouse",
        "summary": "List your ClickHouse instances in this zone.",
        "description": "The list includes `failed` and `destroyed` instances.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "upgrading",
                "restoring",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only instances with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the instance with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only instances whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only instances with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match instances that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of clickhouse objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_clickhouse",
        "summary": "Create a ClickHouse instance.",
        "description": "A new instance comes with the `admin` user and the `defaultdb` database.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the ClickHouse instance. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of ClickHouse instances, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, type, network or firewall doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another ClickHouse action is running in your organization at the same time, with the code `concurrent_create_limit`. Or we couldn't set up the instance, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickHouseCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created instance reports running; not client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse-snapshots": {
      "get": {
        "operationId": "list_flat_clickhouse_snapshot",
        "summary": "List the snapshots of all your ClickHouse instances.",
        "description": "The list includes snapshots of deleted instances.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse-snapshots",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the snapshots of the ClickHouse instance with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of clickhouse_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_flat_clickhouse_snapshot",
        "summary": "Create a snapshot of the ClickHouse instance in `clickhouse_id`.",
        "description": "The snapshot holds the data inserted before it, except rows still in Buffer tables.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse-snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance in `clickhouse_id` doesn't exist, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance can't be snapshotted in its current state, or a snapshot of it is already being created, with the code `clickhouse_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `clickhouse_id`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another snapshot is being created in your organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "clickhouse_id": {
                    "type": "string",
                    "description": "The ID of the ClickHouse instance to create a snapshot of.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_clickhouse",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `analytics-2026-11-24`.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
                  }
                },
                "required": [
                  "clickhouse_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_clickhouse_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse-snapshots/{id}": {
      "delete": {
        "operationId": "delete_flat_clickhouse_snapshot",
        "summary": "Delete an `available` or `failed` ClickHouse snapshot by its ID, also after its instance is deleted.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_clickhouse_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_flat_clickhouse_snapshot",
        "summary": "Get a ClickHouse snapshot by its ID, also after its instance is deleted.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse-snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_flat_clickhouse_snapshot",
        "summary": "Create a new ClickHouse instance from an `available` snapshot, by the snapshot's ID alone.",
        "description": "The original instance must still exist.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse-snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, was saved without its instance's settings, or its instance is deleted, with the code `snapshot_not_restorable`. The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse-types": {
      "get": {
        "operationId": "list_clickhouse_type",
        "summary": "List the ClickHouse types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "clickhouse_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of clickhouse_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_disk_gb",
          "max_concurrent_queries",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_disk_gb",
          "max_concurrent_queries",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/clickhouse-types/{name}": {
      "get": {
        "operationId": "get_clickhouse_type",
        "summary": "Get a ClickHouse type by its name.",
        "description": "You can also get a deprecated type that has a replacement.",
        "tags": [
          "clickhouse_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `CH2`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no `replacement`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_disk_gb",
          "max_concurrent_queries",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_disk_gb",
          "max_concurrent_queries",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/clickhouse-versions": {
      "get": {
        "operationId": "list_clickhouse_version",
        "summary": "List the ClickHouse versions you can create an instance on.",
        "description": "To upgrade an instance, pick a version from its `available_engine_versions`.",
        "tags": [
          "clickhouse_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of clickhouse_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_version.list"
        },
        "x-response-envelope": {
          "list_path": [
            "versions"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/events": {
      "get": {
        "operationId": "list_clickhouse_event",
        "summary": "List a ClickHouse instance's events.",
        "description": "You can still list them after the instance is deleted.",
        "tags": [
          "clickhouse_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:clickhouse_id/events",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of clickhouse_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/scheduled-snapshots": {
      "get": {
        "operationId": "list_clickhouse_scheduled_snapshot",
        "summary": "List a ClickHouse instance's snapshot schedules.",
        "tags": [
          "clickhouse_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:clickhouse_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of clickhouse_scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "clickhouse_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_clickhouse_scheduled_snapshot",
        "summary": "Create a snapshot schedule for a ClickHouse instance.",
        "description": "The instance must be `running` or `degraded`. The schedule counts toward your organization's limit of snapshot schedules.",
        "tags": [
          "clickhouse_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:clickhouse_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single clickhouse_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickHouseScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "clickhouse_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_clickhouse_scheduled_snapshot",
        "summary": "Delete a snapshot schedule.",
        "description": "The snapshots the schedule already created are kept.",
        "tags": [
          "clickhouse_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse/:clickhouse_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_clickhouse_scheduled_snapshot",
        "summary": "Get a snapshot schedule of a ClickHouse instance.",
        "tags": [
          "clickhouse_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:clickhouse_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "clickhouse_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_clickhouse_scheduled_snapshot",
        "summary": "Change how often a snapshot schedule creates snapshots.",
        "tags": [
          "clickhouse_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/clickhouse/:clickhouse_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickHouseScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "clickhouse_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/snapshots": {
      "get": {
        "operationId": "list_clickhouse_snapshot",
        "summary": "List a ClickHouse instance's snapshots, with their status and size.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:clickhouse_id/snapshots",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of clickhouse_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_clickhouse_snapshot",
        "summary": "Create a snapshot of a ClickHouse instance.",
        "description": "The snapshot holds the data inserted before it, except rows still in Buffer tables.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:clickhouse_id/snapshots",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickHouseSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "clickhouse_id": {
              "source": "params",
              "path": [
                "clickhouse_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/snapshots/{id}": {
      "delete": {
        "operationId": "delete_clickhouse_snapshot",
        "summary": "Delete an `available` or `failed` snapshot of a ClickHouse instance.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse/:clickhouse_id/snapshots/:id",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "clickhouse_id": {
              "source": "params",
              "path": [
                "clickhouse_id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_clickhouse_snapshot",
        "summary": "Get a snapshot of a ClickHouse instance.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:clickhouse_id/snapshots/:id",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "clickhouse_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "clickhouse_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "clickhouse_id": {
              "source": "params",
              "path": [
                "clickhouse_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{clickhouse_id}/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_clickhouse_snapshot",
        "summary": "Create a new ClickHouse instance from an `available` snapshot, in the same team and zone.",
        "description": "The new instance gets the snapshot's data, SQL users, type, time zone and networks. The new instance gets its own ID, hostname, certificate and `admin` password. The new instance's `public_access` is `false`.",
        "tags": [
          "clickhouse_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:clickhouse_id/snapshots/:id/restore",
        "parameters": [
          {
            "name": "clickhouse_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance. Get it via [List ClickHouse instances](/docs/cloud/api/clickhouses/list-clickhouses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}": {
      "delete": {
        "operationId": "delete_clickhouse",
        "summary": "Delete a ClickHouse instance.",
        "description": "The instance is `destroyed` at once. The instance's snapshots stay.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_clickhouse",
        "summary": "Get a ClickHouse instance.",
        "description": "Get the `admin` user's password via [Get a ClickHouse instance's credentials](/docs/cloud/api/clickhouses/credentials-clickhouse/).",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_clickhouse",
        "summary": "Update a ClickHouse instance's `name`, `metadata`, `timezone`, `public_access` or `term`.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/clickhouse/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single clickhouse. (`public_access` changes)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClickHouseUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}/credentials": {
      "get": {
        "operationId": "credentials_clickhouse",
        "summary": "Get what you need to connect to a ClickHouse instance as the `admin` user.",
        "description": "You can get the credentials again at any time while the instance exists.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the credentials as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The username, always `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The `admin` user's password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The default database, `defaultdb`."
                    },
                    "uri": {
                      "type": "string",
                      "description": "A `clickhouse://` URI for your private networks, with the password in it. The URI uses the native protocol with TLS.",
                      "x-sensitive": true
                    },
                    "https_url": {
                      "type": "string",
                      "description": "The HTTPS URL for your private networks, without the password."
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "A `clickhouse://` URI for clients on the internet, with the password in it, or `null` when `public_access` is `false`. The URI uses the native protocol with TLS.",
                      "x-sensitive": true
                    },
                    "public_https_url": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The HTTPS address for clients on the internet, without the password, or `null` when `public_access` is `false`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate to verify the instance's TLS certificate with, in PEM format. Save it to a file for your client."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous password stops working after a password change, or `null` when there's no change in progress."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "https_url",
          "public_uri",
          "public_https_url",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/clickhouse/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_clickhouse_credentials",
        "summary": "Change the `admin` user's password of a ClickHouse instance.",
        "description": "The old password keeps working for 24 hours, until `rotating_until`. The instance must be `running` or `degraded`.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance whose credentials to rotate.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the credentials with the new password as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The username, always `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The new `admin` password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The default database, `defaultdb`."
                    },
                    "uri": {
                      "type": "string",
                      "description": "A `clickhouse://` URI for your private networks, with the new password in it. The URI uses the native protocol with TLS.",
                      "x-sensitive": true
                    },
                    "https_url": {
                      "type": "string",
                      "description": "The HTTPS URL for your private networks, without the password."
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "A `clickhouse://` URI for clients on the internet, with the new password in it, or `null` when `public_access` is `false`. The URI uses the native protocol with TLS.",
                      "x-sensitive": true
                    },
                    "public_https_url": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The HTTPS address for clients on the internet, without the password, or `null` when `public_access` is `false`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate to verify the instance's TLS certificate with, in PEM format. Save it to a file for your client."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous password stops working, 24 hours from now."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "https_url",
          "public_uri",
          "public_https_url",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/clickhouse/{id}/firewalls": {
      "post": {
        "operationId": "attach_clickhouse_firewall",
        "summary": "Attach a firewall to a ClickHouse instance.",
        "description": "The firewall must be in the instance's team. An instance can have at most one firewall.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance to attach the firewall to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_clickhouse_firewall",
        "summary": "Detach a firewall from a ClickHouse instance.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance to detach the firewall from.",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/clickhouse/{id}/metrics": {
      "get": {
        "operationId": "metrics_clickhouse",
        "summary": "Get a ClickHouse instance's metrics over time, such as queries, inserts, connections, memory and disk.",
        "description": "Defaults to the last day. A range can be at most 366 days.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/clickhouse/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range. Defaults to now."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the metrics as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "clickhouse_id": {
                      "type": "string",
                      "description": "The instance's ID."
                    },
                    "clickhouse_name": {
                      "type": "string",
                      "description": "The instance's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range the metrics cover."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range the metrics cover."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the points are.",
                      "x-enum-descriptions": {
                        "raw": "One point a minute, for a range up to one day.",
                        "hourly": "One point an hour, for a longer range."
                      }
                    },
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "member_id": {
                            "type": "string",
                            "description": "The node's ID."
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "primary"
                            ],
                            "description": "The node's role, always `primary`."
                          },
                          "data": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "dt": {
                                  "type": "string",
                                  "format": "date-time",
                                  "description": "The start of the minute or hour the point covers."
                                },
                                "queries_per_second": {
                                  "type": "number",
                                  "description": "Queries per second."
                                },
                                "failed_queries_per_second": {
                                  "type": "number",
                                  "description": "Failed queries per second."
                                },
                                "inserted_rows_per_second": {
                                  "type": "number",
                                  "description": "Inserted rows per second."
                                },
                                "inserted_bytes_per_second": {
                                  "type": "number",
                                  "description": "Inserted bytes per second."
                                },
                                "selected_rows_per_second": {
                                  "type": "number",
                                  "description": "Rows read per second."
                                },
                                "connections": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number",
                                      "description": "The average number of open connections."
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most open connections."
                                    }
                                  },
                                  "description": "Open connections."
                                },
                                "concurrent_queries": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number",
                                      "description": "The average number of queries running at the same time."
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most queries running at the same time."
                                    },
                                    "limit": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The type's `max_concurrent_queries`."
                                    }
                                  },
                                  "description": "Queries running at the same time."
                                },
                                "memory": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The average memory used, in bytes."
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most memory used, in bytes."
                                    },
                                    "ram_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The node's memory, in bytes."
                                    }
                                  },
                                  "description": "Memory use."
                                },
                                "disk": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The average disk space used, in bytes."
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most disk space used, in bytes."
                                    },
                                    "usable_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The type's storage for your data, in bytes."
                                    }
                                  },
                                  "description": "Disk use."
                                }
                              }
                            },
                            "description": "The node's metrics, one entry per point."
                          }
                        }
                      },
                      "description": "The metrics of each node."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "clickhouse_id",
          "clickhouse_name",
          "from",
          "to",
          "resolution",
          "members"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/clickhouse/{id}/networks": {
      "post": {
        "operationId": "attach_clickhouse_network",
        "summary": "Attach a private network to a ClickHouse instance.",
        "description": "The network must be in the instance's team. The instance gets an address in the network shortly after the response.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance to attach the network to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_clickhouse_network",
        "summary": "Detach a private network from a ClickHouse instance.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/clickhouse/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the ClickHouse instance to detach the network from.",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/clickhouse/{id}/rescale": {
      "post": {
        "operationId": "rescale_clickhouse",
        "summary": "Change a ClickHouse instance's type.",
        "description": "The instance restarts once during the change. A smaller type is refused unless your data fits in 80% of its storage.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type. Must differ from the current one.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_clickhouse_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_disk_gb",
                        "max_concurrent_queries"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; the member may still be resizing — contact support if this persists"
                  }
                }
              },
              {
                "path": [
                  "type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "type"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; the member may still be resizing — contact support if this persists"
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The instance was resized to the requested plan and is running again without a rescale error. Client reconnection is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}/restore": {
      "post": {
        "operationId": "restore_clickhouse",
        "summary": "Restore a ClickHouse instance from one of its own snapshots.",
        "description": "Data written after the snapshot is lost. The instance keeps its hostname and password.",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClickHouseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of the snapshot to restore. Must be a snapshot of this instance.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_clickhouse_snapshot",
                      "bindings": {
                        "clickhouse_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "status",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.list"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance returned to running after accepted restore; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/clickhouse/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_clickhouse",
        "summary": "Upgrade a ClickHouse instance to the next LTS version.",
        "description": "We create a snapshot first and upgrade once the snapshot is done. The upgrade can't be undone. To go back, restore that snapshot onto the instance with [Restore a ClickHouse instance](/docs/cloud/api/clickhouses/restore-clickhouse/).",
        "tags": [
          "clickhouse"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/clickhouse/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single clickhouse.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ClickHouseDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "pre_upgrade_snapshot_id": {
                          "type": "string",
                          "description": "The ID of the snapshot we created before the upgrade."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "engine_version": {
                    "type": "string",
                    "description": "The version to upgrade to, one of `available_engine_versions`."
                  }
                },
                "required": [
                  "engine_version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_concurrent_queries",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "timezone",
          "public_access",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "pre_upgrade_snapshot_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.clickhouse.upgrade"
        },
        "x-cli-wait": {
          "observe": "get_clickhouse",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_clickhouse",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "engine_version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "engine_version"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "engine_version"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "engine_version"
                    ]
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance reports running on the requested engine line; not workload verification"
        },
        "x-cli-one-time-fields": [
          "pre_upgrade_snapshot_id"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/firewalls": {
      "get": {
        "operationId": "list_firewall",
        "summary": "List the firewalls in this zone, with their rules.",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/firewalls",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only firewalls whose `name` contains this text, ignoring case."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of firewall objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "rules",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_firewall",
        "summary": "Create a firewall.",
        "description": "A new firewall has one rule, which allows all outbound traffic. The firewall blocks all inbound traffic, SSH included, until you add a rule that allows it via [Create a firewall rule](/docs/cloud/api/firewall-rules/create-firewall-rule/).",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/firewalls",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of firewalls, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has no `team_id`, the `name` is empty, or another firewall in the organization has the same `name`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FirewallCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "rules",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/firewalls/{firewall_id}/rules": {
      "get": {
        "operationId": "list_firewall_rule",
        "summary": "List a firewall's rules.",
        "tags": [
          "firewall_rule"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/firewalls/:firewall_id/rules",
        "parameters": [
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall whose rules to list. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of firewall_rule objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallRuleList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "direction",
          "protocol",
          "ip_addresses",
          "port_from",
          "port_to"
        ],
        "x-cli-response-fields": [
          "id",
          "direction",
          "protocol",
          "ip_addresses",
          "port_from",
          "port_to"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall_rule.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_firewall_rule",
        "summary": "Add a rule to a firewall.",
        "description": "The rule applies to the firewall's servers shortly after.",
        "tags": [
          "firewall_rule"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/firewalls/:firewall_id/rules",
        "parameters": [
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "x-cli-input": {
                "order": 10,
                "lookup": "list_firewall",
                "value_field": "id",
                "label_fields": [
                  "name",
                  "team_id"
                ]
              }
            },
            "description": "The ID of the firewall to add the rule to. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single firewall_rule.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallRuleDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The firewall has reached its limit of rules, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A required field is missing or a value isn't valid, such as an empty `ip_addresses` list or a `port_to` lower than `port_from`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another rule is being added to this firewall at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FirewallRuleCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "direction",
          "protocol",
          "ip_addresses",
          "port_from",
          "port_to"
        ],
        "x-cli-response-fields": [
          "id",
          "direction",
          "protocol",
          "ip_addresses",
          "port_from",
          "port_to"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall_rule.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/firewalls/{firewall_id}/rules/{id}": {
      "delete": {
        "operationId": "delete_firewall_rule",
        "summary": "Remove a rule from a firewall.",
        "description": "The rule stops applying to the firewall's servers shortly after.",
        "tags": [
          "firewall_rule"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/firewalls/:firewall_id/rules/:id",
        "parameters": [
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall the rule belongs to. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the rule to remove. Get it via [List firewall rules](/docs/cloud/api/firewall-rules/list-firewall-rules/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the firewall or the rule.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/firewalls/{id}": {
      "delete": {
        "operationId": "delete_firewall",
        "summary": "Remove a firewall and its rules.",
        "description": "We remove the firewall from every server it's attached to shortly after.",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/firewalls/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_firewall",
        "summary": "Get a firewall, with every rule it applies.",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/firewalls/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "rules",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_firewall",
        "summary": "Rename a firewall.",
        "description": "Add a rule via [Create a firewall rule](/docs/cloud/api/firewall-rules/create-firewall-rule/) and remove one via [Remove a firewall rule](/docs/cloud/api/firewall-rules/delete-firewall-rule/).",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/firewalls/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FirewallUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "rules",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/firewalls/{id}/attach": {
      "post": {
        "operationId": "attach_firewall",
        "summary": "Attach a firewall to a server.",
        "description": "A server can have one firewall. The firewall's rules apply to the server shortly after.",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/firewalls/:id/attach",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single firewall.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FirewallDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The firewall is already attached to the server, with the code `already_attached`. Or another firewall is attached to the server, with the code `firewall_limit_reached`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to attach the firewall to. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status"
                      ]
                    }
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "rules",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.firewall.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/firewalls/{id}/attach/{server_id}": {
      "delete": {
        "operationId": "detach_firewall",
        "summary": "Detach a firewall from a server.",
        "description": "The firewall's rules stop applying to the server shortly after.",
        "tags": [
          "firewall"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/firewalls/:id/attach/:server_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server to detach the firewall from. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The firewall isn't attached to a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/images": {
      "get": {
        "operationId": "list_image",
        "summary": "List the images this zone offers.",
        "tags": [
          "image"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/images",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of image objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImageList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "slug"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.image.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/images/{slug}": {
      "get": {
        "operationId": "get_image",
        "summary": "Get an image this zone offers, by its `slug`, to check it exists before you create a server.",
        "tags": [
          "image"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/images/:slug",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The `slug` of the image to get, such as `ubuntu-26-04`. Get it via [List images](/docs/cloud/api/images/list-images/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single image.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImageDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "slug"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.image.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/ips": {
      "get": {
        "operationId": "list_ip",
        "summary": "List the IP addresses in this zone.",
        "description": "The list includes public addresses on servers, private addresses in networks and reserved IPs that aren't assigned to a server.",
        "tags": [
          "ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/ips",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only addresses whose IP, reverse DNS name, server name, network name or reserved IP name contains this text, ignoring case."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of ip objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/IpList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "ip",
          "type",
          "visibility",
          "available",
          "server",
          "network",
          "reservation"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "ip",
          "type",
          "visibility",
          "available",
          "ptr_record",
          "server",
          "network",
          "reservation",
          "created_at",
          "device_name",
          "server_id",
          "network_id",
          "ip_address",
          "name",
          "gateway",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka": {
      "get": {
        "operationId": "list_kafka",
        "summary": "List your Kafka clusters.",
        "description": "The list includes destroyed and failed clusters.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "upgrading",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only clusters in this state."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the cluster with exactly this name."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only clusters whose name contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only clusters with this tag, such as `metadata[env]=prod`. Repeat it to filter by several tags, and a cluster must have all of them."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kafka objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kafka",
        "summary": "Create a Kafka cluster, and optionally its first topics.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the Kafka cluster. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of Kafka clusters, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, type, network or firewall doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, such as a `broker_count` other than `1` or `3`, or a topic that doesn't fit, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another Kafka cluster is being created in the organization at the same time, with the code `concurrent_create_limit`. Or we couldn't start the brokers, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team to create the cluster in. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The cluster's name, at most 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`.",
                    "x-cli-input": {
                      "order": 40
                    }
                  },
                  "type": {
                    "type": "string",
                    "description": "The cluster's type, such as `KA1`. Get the types via [List Kafka types](/docs/cloud/api/kafka-types/list-kafka-types/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_kafka_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_storage_gb",
                        "max_partitions"
                      ]
                    }
                  },
                  "engine_version": {
                    "type": "string",
                    "description": "The Kafka version, such as `4.4`. Defaults to the latest version. Get the versions via [List Kafka versions](/docs/cloud/api/kafka-versions/list-kafka-versions/).",
                    "x-cli-input": {
                      "order": 30,
                      "lookup": "list_kafka_version",
                      "value_field": "engine_version",
                      "label_fields": [
                        "engine_version",
                        "latest"
                      ]
                    }
                  },
                  "broker_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The number of brokers, `1` or `3`. Defaults to `3`. Can't be changed later. With a single broker, your data has one copy, so a lost broker can't be rebuilt from another broker.",
                    "default": 3
                  },
                  "public_access": {
                    "type": "boolean",
                    "description": "Whether the cluster also gets public bootstrap and broker endpoints. The public endpoints use the same TLS and SCRAM credentials as the private ones.",
                    "default": false
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of your private networks to attach to every broker. The networks must be in the cluster's team. Get them via [List networks](/docs/cloud/api/networks/list-networks/).",
                    "x-cli-input": {
                      "order": 70,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ]
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The ID of a firewall to attach to every broker, at most one. The firewall must be in the cluster's team. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
                    "x-cli-input": {
                      "order": 80,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ]
                    }
                  },
                  "topics": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "description": "The topic's name, unique in the cluster, 1–249 letters, digits, dots, hyphens and underscores. Can't be `.` or `..` or start with `__`."
                        },
                        "partitions": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The number of partitions, at least 1. Defaults to `3`. All topics together must fit within the cluster type's `max_partitions`."
                        },
                        "retention_bytes": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The most data to keep in each partition, in bytes, at least 1048576. Defaults to `1073741824`, 1 GiB. All topics together, plus one segment for each partition, must fit in the cluster's storage budget."
                        },
                        "retention_ms": {
                          "type": "integer",
                          "format": "int64",
                          "description": "How long to keep messages, in milliseconds, at least 60000. Defaults to `604800000`, 7 days. `-1` keeps them with no time limit, and `retention_bytes` still limits their size."
                        },
                        "cleanup_policy": {
                          "type": "string",
                          "enum": [
                            "delete",
                            "compact",
                            "compact_delete"
                          ],
                          "description": "How Kafka removes old messages. Defaults to `delete`.\n\n- `delete`: Deletes messages older than the retention time or past the retention size.\n- `compact`: Keeps only the latest message for each key.\n- `compact_delete`: Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`.",
                          "x-enum-descriptions": {
                            "delete": "Deletes messages older than the retention time or past the retention size.",
                            "compact": "Keeps only the latest message for each key.",
                            "compact_delete": "Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`."
                          }
                        },
                        "max_message_bytes": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The largest message the topic accepts, in bytes, from 1024 to 8388608. Defaults to `1048576`, 1 MiB."
                        }
                      },
                      "required": [
                        "name"
                      ]
                    },
                    "description": "Topics to create with the cluster. All topics together must fit in the cluster's storage budget.",
                    "x-cli-input": {
                      "order": 60,
                      "group": "Advanced"
                    }
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term. Defaults to `monthly`.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "default": "monthly"
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name",
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-cli-wait": {
          "observe": "get_kafka",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created resource reports running; not replica or broker health, TLS issuance, or client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka-types": {
      "get": {
        "operationId": "list_kafka_type",
        "summary": "List the Kafka types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "kafka_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of kafka_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_storage_gb",
          "max_partitions",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_storage_gb",
          "max_partitions",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/kafka-types/{name}": {
      "get": {
        "operationId": "get_kafka_type",
        "summary": "Get a Kafka type by its name, including a deprecated type that has a replacement.",
        "tags": [
          "kafka_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `KA1`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kafka_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_storage_gb",
          "max_partitions",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_storage_gb",
          "max_partitions",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/kafka-versions": {
      "get": {
        "operationId": "list_kafka_version",
        "summary": "List the Kafka versions we offer.",
        "description": "A cluster's `available_engine_versions` holds only the next version it can upgrade to.",
        "tags": [
          "kafka_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of kafka_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_version.list"
        },
        "x-response-envelope": {
          "list_path": [
            "versions"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{id}": {
      "delete": {
        "operationId": "delete_kafka",
        "summary": "Delete a Kafka cluster and all its data.",
        "description": "A deleted cluster can't be restored. The cluster is `destroyed` right away, and we remove its brokers shortly after.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kafka/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster is already destroyed, with the code `kafka_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_kafka",
        "summary": "Get a Kafka cluster.",
        "description": "Get the `default` user's password via [Get a Kafka cluster's credentials](/docs/cloud/api/kafkas/credentials-kafka/).",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-cli-wait": {
          "observe": "get_kafka",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the resource currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_kafka",
        "summary": "Update a Kafka cluster's name, tags, `public_access` or billing term.",
        "description": "A change to `public_access` reaches the brokers shortly after the response. To change the cluster's type, use [Rescale a Kafka cluster](/docs/cloud/api/kafkas/rescale-kafka/).",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kafka/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single kafka. (the request changes `public_access`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The name is blank or too long, or another value isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KafkaUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{id}/consumer-groups": {
      "get": {
        "operationId": "consumer_groups_kafka",
        "summary": "List a Kafka cluster's consumer groups and how far behind each one is right now.",
        "description": "The list is empty when no broker responds, even if the cluster has groups.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:id/consumer-groups",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns every consumer group in one page.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "group_id": {
                            "type": "string",
                            "description": "The consumer group's ID."
                          },
                          "lag": {
                            "type": "integer",
                            "format": "int64",
                            "description": "How many messages the group is behind, summed over its partitions."
                          },
                          "topics": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "The names of the topics the group reads, sorted."
                          },
                          "members": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The number of active consumers in the group."
                          },
                          "partitions": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The number of partitions the group reads."
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't read the consumer groups from the broker, with the code `consumer_groups_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "group_id",
          "lag",
          "topics",
          "members",
          "partitions"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.consumer_groups"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{id}/credentials": {
      "get": {
        "operationId": "credentials_kafka",
        "summary": "Get the SCRAM credentials of the cluster's `default` user and the settings a client needs to connect.",
        "description": "You can get them again at any time.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the `default` user's credentials and the client settings as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "username": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The `default` user's username, or `null` when the cluster has no `default` user."
                    },
                    "password": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The `default` user's SCRAM password, or `null` when the cluster has no `default` user.",
                      "x-sensitive": true
                    },
                    "bootstrap_servers": {
                      "type": "string",
                      "description": "The private bootstrap address, as `host:port`."
                    },
                    "public_bootstrap_servers": {
                      "type": "string",
                      "description": "The public bootstrap address, as `host:port`. Present only when `public_access` is on."
                    },
                    "security_protocol": {
                      "type": "string",
                      "description": "The protocol clients connect with, always `SASL_SSL`."
                    },
                    "sasl_mechanism": {
                      "type": "string",
                      "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate bundle that signs the cluster's TLS certificate. Save it to a file for your client to verify the cluster."
                    },
                    "properties": {
                      "type": "object",
                      "properties": {
                        "bootstrap.servers": {
                          "type": "string"
                        },
                        "security.protocol": {
                          "type": "string"
                        },
                        "sasl.mechanism": {
                          "type": "string"
                        },
                        "sasl.username": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "sasl.password": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "ssl.ca.location": {
                          "type": "string"
                        }
                      },
                      "description": "The client settings to connect with, under the names librdkafka and kcat use. The settings include the password. Replace `/path/to/betterstack-ca.pem` in `ssl.ca.location` with the path of the saved `ca_certificate`.",
                      "x-sensitive": true
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster is destroyed, with the code `kafka_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "username",
          "password",
          "bootstrap_servers",
          "public_bootstrap_servers",
          "security_protocol",
          "sasl_mechanism",
          "ca_certificate",
          "properties"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_kafka_credentials",
        "summary": "Set a new password for the cluster's `default` user.",
        "description": "The old password stops working shortly after the response. Open connections stay open, and new connections need the new password.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster whose credentials to rotate. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the new credentials and the client settings as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "username": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The `default` user's username."
                    },
                    "password": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The new SCRAM password.",
                      "x-sensitive": true
                    },
                    "bootstrap_servers": {
                      "type": "string",
                      "description": "The private bootstrap address, as `host:port`."
                    },
                    "public_bootstrap_servers": {
                      "type": "string",
                      "description": "The public bootstrap address, as `host:port`. Present only when `public_access` is on."
                    },
                    "security_protocol": {
                      "type": "string",
                      "description": "The protocol clients connect with, always `SASL_SSL`."
                    },
                    "sasl_mechanism": {
                      "type": "string",
                      "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate bundle that signs the cluster's TLS certificate."
                    },
                    "properties": {
                      "type": "object",
                      "properties": {
                        "bootstrap.servers": {
                          "type": "string"
                        },
                        "security.protocol": {
                          "type": "string"
                        },
                        "sasl.mechanism": {
                          "type": "string"
                        },
                        "sasl.username": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "sasl.password": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "ssl.ca.location": {
                          "type": "string"
                        }
                      },
                      "description": "The client settings to connect with, including the new password. Replace `/path/to/betterstack-ca.pem` in `ssl.ca.location` with the path of the saved `ca_certificate`.",
                      "x-sensitive": true
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, with the code `kafka_busy`. Or it has no `default` user, with the code `kafka_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "username",
          "password",
          "bootstrap_servers",
          "public_bootstrap_servers",
          "security_protocol",
          "sasl_mechanism",
          "ca_certificate",
          "properties"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{id}/firewalls": {
      "post": {
        "operationId": "attach_kafka_firewall",
        "summary": "Attach a firewall to every broker of a cluster.",
        "description": "The firewall must be in the cluster's team. We apply its rules shortly after the response.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster to attach the firewall to. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The cluster's team has no firewall with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster already has a firewall, with the code `firewall_limit_reached`. Or it has no brokers, with the code `kafka_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach. A cluster can have one firewall. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/)."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_kafka_firewall",
        "summary": "Detach a firewall from every broker of a cluster.",
        "description": "We remove its rules shortly after the response.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kafka/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster to detach the firewall from. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/kafka/{id}/metrics": {
      "get": {
        "operationId": "metrics_kafka",
        "summary": "Get each broker's metrics over time.",
        "description": "Defaults to the last day, and the range can be up to 366 days. A range of up to one day returns a value for each minute, and a longer range a value for each hour.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range, included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range, not included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to now. Must be after `from`."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the history as one object, with a series for each broker.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "kafka_id": {
                      "type": "string",
                      "description": "The cluster's ID."
                    },
                    "kafka_name": {
                      "type": "string",
                      "description": "The cluster's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range returned, included."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range returned, not included."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the values are.",
                      "x-enum-descriptions": {
                        "raw": "A value for each minute.",
                        "hourly": "A value for each hour."
                      }
                    },
                    "brokers": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "broker_id": {
                            "type": "string"
                          },
                          "node_id": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "data": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "dt": {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                "partitions": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number"
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "limit": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "leader_partitions": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number"
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "under_replicated_partitions": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number"
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "live_brokers": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "number"
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "expected": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "disk": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "usable_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "max_consumer_group_lag": {
                                  "type": "object",
                                  "properties": {
                                    "avg": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "max": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      },
                      "description": "The history of each broker, with the broker's ID and its Kafka node ID."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A time isn't in ISO 8601, `from` isn't before `to`, or the range is longer than 366 days, with the code `invalid_range`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't read the metrics, with the code `metrics_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "kafka_id",
          "kafka_name",
          "from",
          "to",
          "resolution",
          "brokers"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{id}/networks": {
      "post": {
        "operationId": "attach_kafka_network",
        "summary": "Attach one of your private networks to every broker of a cluster.",
        "description": "The network must be in the cluster's team. The brokers join the network shortly after the response. Check that your clients can reach every broker.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster to attach the network to. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The cluster's team has no network with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The network is already attached, with the code `already_attached`. Or the cluster has no brokers, with the code `kafka_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach. Get it via [List networks](/docs/cloud/api/networks/list-networks/)."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_kafka_network",
        "summary": "Detach one of your private networks from every broker of a cluster.",
        "description": "The brokers leave the network shortly after the response.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kafka/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster to detach the network from. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/kafka/{id}/rescale": {
      "post": {
        "operationId": "rescale_kafka",
        "summary": "Change a Kafka cluster's type, one broker at a time.",
        "description": "The topics' storage budget and partitions must fit in the new type. A cluster with one broker is down while it's rescaled. The cluster shows the new `type` right away, and is `running` again even when a broker didn't finish. To see how the rescale went, check `status_message` and [List Kafka events](/docs/cloud/api/kafka-events/list-kafka-events/).",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, with the code `kafka_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The topics' storage budget or partitions don't fit in the new type, with the code `does_not_fit`. Or the cluster already has this type, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type, such as `KA2`. Get the types via [List Kafka types](/docs/cloud/api/kafka-types/list-kafka-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_kafka_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_storage_gb",
                        "max_partitions"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-cli-wait": {
          "observe": "get_kafka",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; a broker may still be resizing — contact support if this persists"
                  }
                }
              },
              {
                "path": [
                  "type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "type"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; a broker may still be resizing — contact support if this persists"
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Every broker was resized to the requested type and the cluster is running again without a rescale error. Client reconnection and partition leadership are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_kafka",
        "summary": "Upgrade a Kafka cluster to the next version, one broker at a time.",
        "description": "The upgrade is done when the cluster is `running` on the requested `engine_version`. When a broker fails its health check, the cluster goes back to the version it had.",
        "tags": [
          "kafka"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, or a broker of a three-broker cluster isn't running, with the code `kafka_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `engine_version` isn't one of the cluster's `available_engine_versions`, with the code `invalid_engine_version`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "engine_version": {
                    "type": "string",
                    "description": "The version to upgrade to, one of the cluster's `available_engine_versions`."
                  }
                },
                "required": [
                  "engine_version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "broker_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "broker_count",
          "replication_factor",
          "min_insync_replicas",
          "usable_storage_gb",
          "max_partitions",
          "storage_budget_bytes",
          "storage_budget_used_bytes",
          "partition_count",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "public_access",
          "endpoint",
          "brokers",
          "topics",
          "users",
          "network_ids",
          "firewall_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka.list"
        },
        "x-cli-wait": {
          "observe": "get_kafka",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_kafka",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "engine_version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "engine_version"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "engine_version"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "engine_version"
                    ]
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance reports running on the requested engine line; not workload verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/events": {
      "get": {
        "operationId": "list_kafka_event",
        "summary": "List a Kafka cluster's events.",
        "description": "You can still list them after the cluster is deleted.",
        "tags": [
          "kafka_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/events",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kafka_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "kafka_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/topics": {
      "get": {
        "operationId": "list_kafka_topic",
        "summary": "List a Kafka cluster's topics.",
        "tags": [
          "kafka_topic"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/topics",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kafka_topic objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTopicList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "budget_bytes"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "retention_ms",
          "cleanup_policy",
          "max_message_bytes",
          "budget_bytes",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_topic.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kafka_topic",
        "summary": "Create a Kafka topic.",
        "description": "The topic is ready on the brokers shortly after the response. Kafka Streams can't create its own topics, so create them with this endpoint first.",
        "tags": [
          "kafka_topic"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:kafka_id/topics",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka_topic.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTopicDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A broker's disk is 95% full or more. Lower a topic's `retention_bytes`, delete a topic or rescale the cluster, with the code `disk_usage_critical`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The topic doesn't fit in the cluster's storage budget, with the code `insufficient_storage_budget`. Or the name, a setting or the number of partitions isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "pattern": "^[a-zA-Z0-9._-]+$",
                    "description": "The topic's name, unique in the cluster, 1–249 letters, digits, dots, hyphens and underscores. Can't be `.` or `..` or start with `__`."
                  },
                  "partitions": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The number of partitions, at least 1. Defaults to `3`. All topics together must fit within the cluster type's `max_partitions`.",
                    "default": 3
                  },
                  "retention_bytes": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The most data to keep in each partition, in bytes, at least 1048576. Defaults to `1073741824`, 1 GiB. All topics together, plus one segment for each partition, must fit in the cluster's storage budget.",
                    "default": 1073741824
                  },
                  "retention_ms": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How long to keep messages, in milliseconds, at least 60000. Defaults to `604800000`, 7 days. `-1` keeps them with no time limit, and `retention_bytes` still limits their size.",
                    "default": 604800000
                  },
                  "cleanup_policy": {
                    "type": "string",
                    "enum": [
                      "delete",
                      "compact",
                      "compact_delete"
                    ],
                    "description": "How Kafka removes old messages. Defaults to `delete`.",
                    "x-enum-descriptions": {
                      "delete": "Deletes messages older than the retention time or past the retention size.",
                      "compact": "Keeps only the latest message for each key.",
                      "compact_delete": "Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`."
                    },
                    "default": "delete"
                  },
                  "max_message_bytes": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The largest message the topic accepts, in bytes, from 1024 to 8388608. Defaults to `1048576`, 1 MiB.",
                    "default": 1048576
                  }
                },
                "required": [
                  "name"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "budget_bytes"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "retention_ms",
          "cleanup_policy",
          "max_message_bytes",
          "budget_bytes",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_topic.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/topics/{id}": {
      "delete": {
        "operationId": "delete_kafka_topic",
        "summary": "Delete a Kafka topic and its data.",
        "description": "Clients that still use the topic get `UNKNOWN_TOPIC_OR_PARTITION`.",
        "tags": [
          "kafka_topic"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kafka/:kafka_id/topics/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_kafka_topic",
        "summary": "Get a Kafka topic by its ID, with its partitions and how long it keeps messages.",
        "tags": [
          "kafka_topic"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/topics/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kafka_topic.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTopicDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "budget_bytes"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "retention_ms",
          "cleanup_policy",
          "max_message_bytes",
          "budget_bytes",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_topic.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_kafka_topic",
        "summary": "Update a Kafka topic's settings.",
        "description": "The brokers get the change shortly after the response. When a broker's disk is nearly full, you can still lower `retention_bytes`.",
        "tags": [
          "kafka_topic"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kafka/:kafka_id/topics/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka_topic.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaTopicDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A broker's disk is 95% full or more, and the update increases `partitions` or `retention_bytes`, with the code `disk_usage_critical`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The topic doesn't fit in the cluster's storage budget, with the code `insufficient_storage_budget`. Or `partitions` decreases or goes over the type's `max_partitions`, or a setting isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KafkaTopicUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "budget_bytes"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "partitions",
          "replication_factor",
          "retention_bytes",
          "retention_ms",
          "cleanup_policy",
          "max_message_bytes",
          "budget_bytes",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_topic.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/users": {
      "get": {
        "operationId": "list_kafka_user",
        "summary": "List a Kafka cluster's users and their privileges.",
        "description": "Get a user's password via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/users",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kafka_user objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaUserList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user",
          "privileges"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kafka_user",
        "summary": "Create a Kafka user with a generated password.",
        "description": "We add the user to the cluster shortly after the response. The response includes the password. Get the password again later via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:kafka_id/users",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka_user.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/KafkaUserDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "password": {
                          "type": "string",
                          "description": "The generated password. Get it again later via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
                          "x-sensitive": true
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The cluster already has 25 users, counting the `default` user, with the code `user_limit_reached`. Or the `username` or `privileges` aren't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "username": {
                    "type": "string",
                    "pattern": "^[a-z0-9][a-z0-9_-]*$",
                    "description": "The name clients sign in with, unique in the cluster, up to 64 lowercase letters, digits, hyphens and underscores, starting with a letter or digit. Can't start with `betterstack`. Can't be changed later."
                  },
                  "privileges": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "object",
                      "properties": {
                        "topic_pattern": {
                          "type": "string",
                          "pattern": "^[a-zA-Z0-9._-]*\\*?$",
                          "description": "A topic name, or a prefix followed by a trailing `*`, made of letters, digits, dots, hyphens and underscores, up to 249 characters. `*` alone matches every topic."
                        },
                        "permission": {
                          "type": "string",
                          "enum": [
                            "consume",
                            "produce",
                            "produce_consume"
                          ],
                          "description": "What the user can do on the matching topics.\n\n- `consume`: Read and describe the matching topics, and join consumer groups.\n- `produce`: Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.\n- `produce_consume`: Both `consume` and `produce`.",
                          "x-enum-descriptions": {
                            "consume": "Read and describe the matching topics, and join consumer groups.",
                            "produce": "Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.",
                            "produce_consume": "Both `consume` and `produce`."
                          }
                        }
                      },
                      "required": [
                        "topic_pattern",
                        "permission"
                      ]
                    },
                    "description": "The topics the user can use and what it can do on them, up to 25 entries. Leave it out, or send `null` or an empty list, to create a user without privileges."
                  }
                },
                "required": [
                  "username"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user",
          "privileges"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at",
          "updated_at",
          "password"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.create"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/users/{id}": {
      "delete": {
        "operationId": "delete_kafka_user",
        "summary": "Delete a Kafka user and remove its password and permissions from the cluster.",
        "description": "When the cluster can't be reached, the delete still succeeds, and the cluster removes the user shortly after.",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kafka/:kafka_id/users/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `default` user can't be deleted, with the code `default_user_undeletable`. Change its privileges instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_kafka_user",
        "summary": "Get a Kafka user, with the privileges it has on each topic.",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/users/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kafka_user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaUserDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user",
          "privileges"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_kafka_user",
        "summary": "Replace a Kafka user's privileges.",
        "description": "We apply them to the cluster shortly after the response. To change the password, use [Reset a Kafka user's password](/docs/cloud/api/kafka-users/reset-kafka-user-password/).",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kafka/:kafka_id/users/:id",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kafka_user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KafkaUserDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has no `privileges`, or they aren't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "privileges": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "object",
                      "properties": {
                        "topic_pattern": {
                          "type": "string",
                          "pattern": "^[a-zA-Z0-9._-]*\\*?$",
                          "description": "A topic name, or a prefix followed by a trailing `*`, made of letters, digits, dots, hyphens and underscores, up to 249 characters. `*` alone matches every topic."
                        },
                        "permission": {
                          "type": "string",
                          "enum": [
                            "consume",
                            "produce",
                            "produce_consume"
                          ],
                          "description": "What the user can do on the matching topics.\n\n- `consume`: Read and describe the matching topics, and join consumer groups.\n- `produce`: Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.\n- `produce_consume`: Both `consume` and `produce`.",
                          "x-enum-descriptions": {
                            "consume": "Read and describe the matching topics, and join consumer groups.",
                            "produce": "Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.",
                            "produce_consume": "Both `consume` and `produce`."
                          }
                        }
                      },
                      "required": [
                        "topic_pattern",
                        "permission"
                      ]
                    },
                    "description": "The new privileges, up to 25 entries. Send `null` or an empty list to remove all of them."
                  }
                },
                "required": [
                  "privileges"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user",
          "privileges"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kafka/{kafka_id}/users/{id}/credentials": {
      "get": {
        "operationId": "credentials_kafka_user",
        "summary": "Get the user's password and the settings a client needs to connect.",
        "description": "You can get them again at any time.",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kafka/:kafka_id/users/:id/credentials",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the user's credentials and the client settings as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "username": {
                      "type": "string",
                      "description": "The user's username."
                    },
                    "password": {
                      "type": "string",
                      "description": "The user's password.",
                      "x-sensitive": true
                    },
                    "bootstrap_servers": {
                      "type": "string",
                      "description": "The private bootstrap address, as `host:port`."
                    },
                    "public_bootstrap_servers": {
                      "type": "string",
                      "description": "The public bootstrap address, as `host:port`. Only a cluster with public access has it."
                    },
                    "security_protocol": {
                      "type": "string",
                      "description": "The protocol clients connect with, always `SASL_SSL`."
                    },
                    "sasl_mechanism": {
                      "type": "string",
                      "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate to verify the cluster's TLS certificate with. Save it to a file for your client."
                    },
                    "properties": {
                      "type": "object",
                      "properties": {
                        "bootstrap.servers": {
                          "type": "string",
                          "description": "The private bootstrap address, as `host:port`."
                        },
                        "security.protocol": {
                          "type": "string",
                          "description": "The protocol clients connect with, always `SASL_SSL`."
                        },
                        "sasl.mechanism": {
                          "type": "string",
                          "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                        },
                        "sasl.username": {
                          "type": "string",
                          "description": "The user's username."
                        },
                        "sasl.password": {
                          "type": "string",
                          "description": "The user's password."
                        },
                        "ssl.ca.location": {
                          "type": "string",
                          "description": "The placeholder `/path/to/betterstack-ca.pem`. Replace it with the path where you saved `ca_certificate`."
                        }
                      },
                      "description": "The client settings to connect with, ready to use with librdkafka and kcat. Replace `/path/to/betterstack-ca.pem` with the path where you saved `ca_certificate`.",
                      "x-sensitive": true
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster is destroyed, with the code `kafka_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "username",
          "password",
          "bootstrap_servers",
          "public_bootstrap_servers",
          "security_protocol",
          "sasl_mechanism",
          "ca_certificate",
          "properties"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/kafka/{kafka_id}/users/{id}/reset-password": {
      "post": {
        "operationId": "reset_kafka_user_password",
        "summary": "Generate a new password for a Kafka user.",
        "description": "The old password stops working shortly after the response. Open connections stay open, and new connections need the new password.",
        "tags": [
          "kafka_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kafka/:kafka_id/users/:id/reset-password",
        "parameters": [
          {
            "name": "kafka_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kafka cluster. Get it via [List Kafka clusters](/docs/cloud/api/kafkas/list-kafkas/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the new credentials and the client settings as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "username": {
                      "type": "string",
                      "description": "The user's username."
                    },
                    "password": {
                      "type": "string",
                      "description": "The new password.",
                      "x-sensitive": true
                    },
                    "bootstrap_servers": {
                      "type": "string",
                      "description": "The private bootstrap address, as `host:port`."
                    },
                    "public_bootstrap_servers": {
                      "type": "string",
                      "description": "The public bootstrap address, as `host:port`. Only a cluster with public access has it."
                    },
                    "security_protocol": {
                      "type": "string",
                      "description": "The protocol clients connect with, always `SASL_SSL`."
                    },
                    "sasl_mechanism": {
                      "type": "string",
                      "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate to verify the cluster's TLS certificate with. Save it to a file for your client."
                    },
                    "properties": {
                      "type": "object",
                      "properties": {
                        "bootstrap.servers": {
                          "type": "string",
                          "description": "The private bootstrap address, as `host:port`."
                        },
                        "security.protocol": {
                          "type": "string",
                          "description": "The protocol clients connect with, always `SASL_SSL`."
                        },
                        "sasl.mechanism": {
                          "type": "string",
                          "description": "The authentication mechanism, always `SCRAM-SHA-512`."
                        },
                        "sasl.username": {
                          "type": "string",
                          "description": "The user's username."
                        },
                        "sasl.password": {
                          "type": "string",
                          "description": "The user's password."
                        },
                        "ssl.ca.location": {
                          "type": "string",
                          "description": "The placeholder `/path/to/betterstack-ca.pem`. Replace it with the path where you saved `ca_certificate`."
                        }
                      },
                      "description": "The client settings to connect with, including the new password, ready to use with librdkafka and kcat. Replace `/path/to/betterstack-ca.pem` with the path where you saved `ca_certificate`.",
                      "x-sensitive": true
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, with the code `kafka_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "username",
          "password",
          "bootstrap_servers",
          "public_bootstrap_servers",
          "security_protocol",
          "sasl_mechanism",
          "ca_certificate",
          "properties"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kafka_user.reset_password"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/kubernetes-clusters": {
      "get": {
        "operationId": "list_kubernetes_cluster",
        "summary": "List your Kubernetes clusters, except `failed` and `destroyed` ones.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only clusters with this status."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only clusters whose name contains this text, ignoring letter case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only clusters with this tag, such as `metadata[env]=prod`. Repeat it to filter by several tags, and a cluster must have all of them."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kubernetes_cluster objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kubernetes_cluster",
        "summary": "Create a Kubernetes cluster with its control plane and workers.",
        "description": "Leave out `node_pools`, or send an empty list, to create a cluster without workers.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of Kubernetes clusters, or the workers would need more servers than its limit allows, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, a network, a firewall or the server type doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id` or `name`, or the version, an IP range or a node pool isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another cluster is being created in the organization at the same time, with the code `concurrent_create_limit`. Or we couldn't create the cluster's servers, with the code `orchestration_failed`. List your clusters before you send the request again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team that owns the cluster. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The cluster's name, up to 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "version": {
                    "type": "string",
                    "description": "The Kubernetes version as major and minor number, such as `1.36`. Defaults to the newest version. Get the versions via [List Kubernetes versions](/docs/cloud/api/kubernetes-versions/list-kubernetes-versions/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_kubernetes_version",
                      "value_field": "version",
                      "label_fields": [
                        "version",
                        "build",
                        "latest"
                      ]
                    }
                  },
                  "pod_cidr": {
                    "type": "string",
                    "description": "The IPv4 range for pods. Can't overlap `service_cidr`, a network you attach, or `100.89.94.0/24`, which we use for the cluster. Can't be changed after the cluster is created.",
                    "default": "10.42.0.0/16"
                  },
                  "service_cidr": {
                    "type": "string",
                    "description": "The IPv4 range for Kubernetes services. Can't overlap `pod_cidr`, a network you attach, or `100.89.94.0/24`, which we use for the cluster. Can't be changed after the cluster is created.",
                    "default": "10.43.0.0/16"
                  },
                  "api_allowed_cidrs": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string"
                    },
                    "description": "The IP ranges allowed to reach the cluster's Kubernetes API, as 1 to 50 IPv4 or IPv6 CIDRs. Leave it out, or send `null`, to allow every address.",
                    "default": [
                      "0.0.0.0/0",
                      "::/0"
                    ]
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of your private networks to attach to the cluster. The networks must be in the cluster's team. Get them via [List networks](/docs/cloud/api/networks/list-networks/).",
                    "x-cli-input": {
                      "order": 70,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of the firewalls to attach to the workers. Get them via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
                    "x-cli-input": {
                      "order": 80,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "node_pools": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
                          "description": "The node pool's name, unique in the cluster, up to 30 lowercase letters, digits and hyphens, starting and ending with a letter or digit."
                        },
                        "server_type": {
                          "type": "string",
                          "description": "The server type of the workers. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/)."
                        },
                        "node_count": {
                          "type": "integer",
                          "format": "int64",
                          "description": "How many workers the node pool should have, from 0 to 100. A cluster can have 100 workers in total."
                        },
                        "labels": {
                          "type": [
                            "object",
                            "null"
                          ],
                          "additionalProperties": true,
                          "description": "The Kubernetes labels of the workers, up to 10 string pairs. Keys and values have up to 63 characters."
                        },
                        "taints": {
                          "type": [
                            "array",
                            "null"
                          ],
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string",
                                "description": "The taint's key, in the form of a Kubernetes label key."
                              },
                              "value": {
                                "type": [
                                  "string",
                                  "null"
                                ],
                                "description": "The taint's value, up to 63 characters."
                              },
                              "effect": {
                                "type": "string",
                                "enum": [
                                  "NoSchedule",
                                  "PreferNoSchedule",
                                  "NoExecute"
                                ],
                                "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                              }
                            },
                            "required": [
                              "key",
                              "effect"
                            ]
                          },
                          "description": "The Kubernetes taints of the workers, up to 10."
                        }
                      },
                      "required": [
                        "name",
                        "server_type"
                      ]
                    },
                    "description": "The cluster's node pools, up to 10, with up to 100 workers in total. Workers are servers, so server types and server quotas apply to them.",
                    "x-cli-input": {
                      "order": 40
                    },
                    "default": []
                  },
                  "metadata": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. The keys `kubernetes-cluster`, `kubernetes-node-pool` and `kubernetes-service-uid` are reserved for Better Stack and can't be set.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "node_pools"
                ],
                "matching": {
                  "source": "result",
                  "path": [
                    "node_pools"
                  ]
                },
                "match_by": "id",
                "every": {
                  "all": [
                    {
                      "path": [
                        "nodes"
                      ],
                      "count": true,
                      "expected": {
                        "source": "matched",
                        "path": [
                          "node_count"
                        ]
                      }
                    },
                    {
                      "path": [
                        "nodes"
                      ],
                      "every": {
                        "path": [
                          "status"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": "ready"
                        }
                      }
                    }
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the control plane reports running and every accepted pool has its desired live count with all nodes ready; not workload health"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}": {
      "delete": {
        "operationId": "delete_kubernetes_cluster",
        "summary": "Delete a Kubernetes cluster.",
        "description": "The cluster is returned as `destroyed`. We remove the cluster's servers and networks shortly after. The cluster's snapshots are deleted too. Volumes the cluster used are kept, with their data.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kubernetes-clusters/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster is already destroyed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_kubernetes_cluster",
        "summary": "Get a Kubernetes cluster, including a `failed` or `destroyed` one.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "node_pools"
                ],
                "every": {
                  "all": [
                    {
                      "path": [
                        "nodes"
                      ],
                      "count": true,
                      "expected": {
                        "source": "item",
                        "path": [
                          "node_count"
                        ]
                      }
                    },
                    {
                      "path": [
                        "nodes"
                      ],
                      "every": {
                        "path": [
                          "status"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": "ready"
                        }
                      }
                    }
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the control plane reports running and every current pool has its desired live count with all nodes ready; not workload health"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_kubernetes_cluster",
        "summary": "Change a Kubernetes cluster's name, tags or the IP ranges allowed to reach its Kubernetes API.",
        "description": "New IP ranges apply shortly after the response. To change the version, use [Upgrade a Kubernetes cluster](/docs/cloud/api/kubernetes-clusters/upgrade-kubernetes-cluster/). To change the workers, use [Update a Kubernetes node pool](/docs/cloud/api/kubernetes-node-pools/update-kubernetes-node-pool/).",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kubernetes-clusters/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The cluster's name, up to 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`."
                  },
                  "api_allowed_cidrs": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string"
                    },
                    "description": "The IP ranges allowed to reach the cluster's Kubernetes API, as 1 to 50 IPv4 or IPv6 CIDRs. The new list replaces the current one."
                  },
                  "metadata": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/firewalls": {
      "post": {
        "operationId": "attach_kubernetes_cluster_firewall",
        "summary": "Attach a firewall to the cluster's workers.",
        "description": "We attach it shortly after the response.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster to attach the firewall to. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/)."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_kubernetes_cluster",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before_condition": {
            "path": [
              "nodes_ready"
            ],
            "at_least": {
              "source": "literal",
              "value": 1
            }
          },
          "success": {
            "not": {
              "path": [
                "firewall_ids"
              ],
              "every": {
                "not": {
                  "path": [],
                  "expected": {
                    "source": "request",
                    "path": [
                      "firewall_id"
                    ]
                  }
                }
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "description": "The cluster lists the firewall in firewall_ids, which Cloud reads from its first worker. Waiting needs a ready worker, and the other workers and the rules on each host are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_kubernetes_cluster_firewall",
        "summary": "Detach a firewall from the cluster's workers.",
        "description": "We detach it shortly after the response.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kubernetes-clusters/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster to detach the firewall from. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_kubernetes_cluster",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before_condition": {
            "not": {
              "path": [
                "firewall_ids"
              ],
              "every": {
                "not": {
                  "path": [],
                  "expected": {
                    "source": "params",
                    "path": [
                      "firewall_id"
                    ]
                  }
                }
              }
            }
          },
          "success": {
            "path": [
              "firewall_ids"
            ],
            "every": {
              "not": {
                "path": [],
                "expected": {
                  "source": "params",
                  "path": [
                    "firewall_id"
                  ]
                }
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "description": "The cluster no longer lists the firewall in firewall_ids, which Cloud reads from its first worker. Waiting needs the firewall attached now, and the other workers and the removal of the rules on each host are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/kubeconfig": {
      "get": {
        "operationId": "kubeconfig_kubernetes_cluster",
        "summary": "Get a kubeconfig with admin access to the cluster.",
        "description": "You can get it again at any time.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:id/kubeconfig",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a JSON object with the kubeconfig and the API URL.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "kubeconfig": {
                      "type": "string",
                      "description": "The kubeconfig, as YAML with the admin token. Save this value as your kubeconfig file.",
                      "x-sensitive": true
                    },
                    "server": {
                      "type": "string",
                      "description": "The HTTPS URL of the Kubernetes API, on port 6443."
                    },
                    "rotated_at": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the admin token was first issued or last rotated, or `null`."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The control plane hasn't issued the admin token yet. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-notes": [
          "The kubeconfig verifies the API's certificate with the cluster's CA. When the cluster's CA isn't available, the kubeconfig skips the certificate check."
        ],
        "x-cli-response-fields": [
          "kubeconfig",
          "server",
          "rotated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.kubeconfig"
        },
        "x-cli-wait": {
          "observe": "kubeconfig_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "pending_codes": [
            "kubeconfig_not_ready"
          ],
          "description": "the existing kubeconfig GET succeeds; not external API reachability or workload health"
        },
        "x-cli-export": {
          "format": "text",
          "field": "kubeconfig"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/kubeconfig/rotate": {
      "post": {
        "operationId": "rotate_kubernetes_cluster_kubeconfig",
        "summary": "Issue a new admin token and return a new kubeconfig.",
        "description": "Every kubeconfig you got before stops working.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:id/kubeconfig/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster whose kubeconfig to rotate. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns a JSON object with the new kubeconfig and the API URL.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "kubeconfig": {
                      "type": "string",
                      "description": "The new kubeconfig, as YAML with the new admin token.",
                      "x-sensitive": true
                    },
                    "server": {
                      "type": "string",
                      "description": "The HTTPS URL of the Kubernetes API, on port 6443."
                    },
                    "rotated_at": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the admin token was rotated."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The control plane hasn't issued the new token yet. Get the kubeconfig via [Get a Kubernetes cluster's kubeconfig](/docs/cloud/api/kubernetes-clusters/kubeconfig-kubernetes-cluster/) until it's ready, rather than rotating again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-notes": [
          "The old token can keep working for about 10 seconds after a rotation."
        ],
        "x-cli-response-fields": [
          "kubeconfig",
          "server",
          "rotated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.rotate_kubeconfig"
        },
        "x-cli-export": {
          "format": "text",
          "field": "kubeconfig"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/metrics": {
      "get": {
        "operationId": "metrics_kubernetes_cluster",
        "summary": "Get a Kubernetes cluster's metrics over time.",
        "description": "Defaults to the last hour. A range longer than one day returns hourly averages.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range, included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to one hour before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range, included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to now. Must be after `from`, and the range can be up to 366 days."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the data points, and the time range and resolution we used.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "at": {
                            "type": "string",
                            "format": "date-time",
                            "description": "The time of the data point, or the hour it averages."
                          },
                          "nodes_ready": {
                            "type": "integer",
                            "format": "int64",
                            "description": "How many workers were ready. Hourly averages are rounded."
                          },
                          "nodes_total": {
                            "type": "integer",
                            "format": "int64",
                            "description": "How many workers the cluster had. Hourly averages are rounded."
                          },
                          "pods_running": {
                            "type": "integer",
                            "format": "int64",
                            "description": "How many pods were running. Hourly averages are rounded."
                          },
                          "pods_capacity": {
                            "type": "integer",
                            "format": "int64",
                            "description": "How many pods the workers can run. Hourly averages are rounded."
                          },
                          "apiserver_up": {
                            "type": "number",
                            "description": "How available the Kubernetes API was, from `0` to `1`."
                          }
                        }
                      }
                    },
                    "meta": {
                      "type": "object",
                      "properties": {
                        "from": {
                          "type": "string",
                          "format": "date-time",
                          "description": "The start of the range we used."
                        },
                        "to": {
                          "type": "string",
                          "format": "date-time",
                          "description": "The end of the range we used."
                        },
                        "resolution": {
                          "type": "string",
                          "enum": [
                            "raw",
                            "hour"
                          ],
                          "description": "How far apart the data points are.",
                          "x-enum-descriptions": {
                            "raw": "Each data point is one measurement.",
                            "hour": "Each data point is the average of one hour."
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A time isn't valid, `from` isn't before `to`, or the range is longer than 366 days.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't read the metrics. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "at",
          "nodes_ready",
          "nodes_total",
          "pods_running",
          "pods_capacity",
          "apiserver_up"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/networks": {
      "post": {
        "operationId": "attach_kubernetes_cluster_network",
        "summary": "Attach a private network to the cluster.",
        "description": "We attach it shortly after the response.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster to attach the network to. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The network's range overlaps `pod_cidr` or `service_cidr`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach. Get it via [List networks](/docs/cloud/api/networks/list-networks/)."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_kubernetes_cluster",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before_condition": {
            "path": [
              "nodes_ready"
            ],
            "at_least": {
              "source": "literal",
              "value": 1
            }
          },
          "success": {
            "not": {
              "path": [
                "network_ids"
              ],
              "every": {
                "not": {
                  "path": [],
                  "expected": {
                    "source": "request",
                    "path": [
                      "network_id"
                    ]
                  }
                }
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "description": "The cluster lists the network in network_ids, which Cloud reads from its first worker. Waiting needs a ready worker, and the other workers and the private addresses on each server are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_kubernetes_cluster_network",
        "summary": "Detach a private network from the cluster.",
        "description": "We detach it shortly after the response.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kubernetes-clusters/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster to detach the network from. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_kubernetes_cluster",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before_condition": {
            "not": {
              "path": [
                "network_ids"
              ],
              "every": {
                "not": {
                  "path": [],
                  "expected": {
                    "source": "params",
                    "path": [
                      "network_id"
                    ]
                  }
                }
              }
            }
          },
          "success": {
            "path": [
              "network_ids"
            ],
            "every": {
              "not": {
                "path": [],
                "expected": {
                  "source": "params",
                  "path": [
                    "network_id"
                  ]
                }
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "description": "The cluster no longer lists the network in network_ids, which Cloud reads from its first worker. Waiting needs the network attached now, and the other workers and the removal of each server's network interface are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/restore": {
      "post": {
        "operationId": "restore_kubernetes_cluster",
        "summary": "Restore a Kubernetes cluster's control plane from one of its own `available` snapshots.",
        "description": "The cluster keeps its ID and is returned as `restoring`. The cluster must be `running` or `degraded`.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesClusterDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The snapshot doesn't belong to this cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, with the code `cluster_busy`. Or the snapshot isn't `available`, with the code `snapshot_not_restorable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of an `available` snapshot of this cluster.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_kubernetes_snapshot",
                      "bindings": {
                        "kubernetes_cluster_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "select": {
                        "status": {
                          "source": "literal",
                          "value": "available"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "status",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-notes": [
          "A restore can fail even when the cluster is `running` again afterwards. To see whether the restore worked, check the cluster's events via [List Kubernetes events](/docs/cloud/api/kubernetes-events/list-kubernetes-events/). Persistent volumes keep their current data."
        ],
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "degraded",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Control plane is running again after the restore. A failed restore can also end running, so the cluster's events say whether it worked, and worker and workload health are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_kubernetes_cluster",
        "summary": "Upgrade a Kubernetes cluster to the next minor version.",
        "description": "We create a snapshot of the control plane first. Then we upgrade the control plane, and then the workers. The cluster must be `running` or `degraded`.",
        "tags": [
          "kubernetes_cluster"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_cluster.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/KubernetesClusterDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "pre_upgrade_snapshot_id": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "The ID of the snapshot we create before the upgrade. Restore it to roll the upgrade back."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster isn't `running` or `degraded`, with the code `cluster_busy`. Or a snapshot of the cluster is being created, with the code `snapshot_in_progress`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The version isn't one of the cluster's `available_versions`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "version": {
                    "type": "string",
                    "description": "The version to upgrade to, one of the cluster's `available_versions`."
                  }
                },
                "required": [
                  "version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-notes": [
          "The cluster's `version` changes before we install the new version. The upgrade is done when every worker is `ready` and reports the version's `build` from [List Kubernetes versions](/docs/cloud/api/kubernetes-versions/list-kubernetes-versions/). When the snapshot before the upgrade fails, the upgrade doesn't start, and the cluster goes back to `running` on the old version with a `status_message`."
        ],
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "version",
          "nodes_ready",
          "nodes_total"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "version",
          "patch_version",
          "available_versions",
          "status",
          "status_message",
          "endpoint",
          "pod_cidr",
          "service_cidr",
          "nodes_ready",
          "nodes_total",
          "node_pools",
          "network_ids",
          "firewall_ids",
          "kubeconfig_rotated_at",
          "latest_snapshot_at",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "pre_upgrade_snapshot_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_cluster.upgrade"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "version"
                  ]
                }
              },
              {
                "path": [
                  "node_pools"
                ],
                "every": {
                  "any": [
                    {
                      "path": [
                        "status"
                      ],
                      "expected": {
                        "source": "literal",
                        "value": "deleting"
                      }
                    },
                    {
                      "all": [
                        {
                          "path": [
                            "nodes"
                          ],
                          "count": true,
                          "expected": {
                            "source": "item",
                            "path": [
                              "node_count"
                            ]
                          }
                        },
                        {
                          "path": [
                            "nodes"
                          ],
                          "every": {
                            "path": [
                              "status"
                            ],
                            "expected": {
                              "source": "literal",
                              "value": "ready"
                            }
                          }
                        }
                      ]
                    }
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "degraded",
                "destroyed"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "not": {
                    "path": [
                      "version"
                    ],
                    "expected": {
                      "source": "request",
                      "path": [
                        "version"
                      ]
                    }
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Cluster is running at the requested version with every node pool that is not being deleted at its size and every worker ready again. Running at the old version means the upgrade was not started. The build each worker reports and workload health are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/events": {
      "get": {
        "operationId": "list_kubernetes_event",
        "summary": "List a Kubernetes cluster's events.",
        "description": "You can still list them after the cluster is deleted.",
        "tags": [
          "kubernetes_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:kubernetes_cluster_id/events",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kubernetes_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/node-pools": {
      "get": {
        "operationId": "list_kubernetes_node_pool",
        "summary": "List a Kubernetes cluster's node pools.",
        "description": "Returns every node pool in one page.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kubernetes_node_pool objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesNodePoolList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "labels",
          "taints",
          "status",
          "status_message",
          "nodes_ready",
          "scaling",
          "nodes"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kubernetes_node_pool",
        "summary": "Add a node pool to a Kubernetes cluster.",
        "description": "We create its workers shortly after the response. A node pool with workers returns as `scaling`. The `scaling` field shows how the change is going, and the new workers are listed as `queued`.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_node_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesNodePoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The cluster or the server type doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The name, server type, labels or taints aren't valid. Or the cluster would have more than 10 node pools or more than 100 workers. The `server_type` is deprecated. The error's `details` name its replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
                    "description": "The node pool's name, unique in the cluster, up to 30 lowercase letters, digits and hyphens, starting and ending with a letter or digit.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "server_type": {
                    "type": "string",
                    "description": "The server type of the workers. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "vcpu",
                        "ram_gb",
                        "storage_gb"
                      ]
                    }
                  },
                  "node_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many workers the node pool should have, from 0 to 100. The node pools of a cluster can have 100 workers in total.",
                    "x-cli-input": {
                      "order": 20
                    },
                    "default": 1
                  },
                  "labels": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "additionalProperties": true,
                    "description": "The Kubernetes labels of the workers, up to 10 string pairs. Keys and values are up to 63 characters. Leave it out, or send `null`, for no labels.",
                    "x-cli-input": {
                      "order": 40,
                      "group": "Advanced"
                    }
                  },
                  "taints": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "description": "The taint's key, in the same form as a Kubernetes label key."
                        },
                        "value": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "The taint's value, up to 63 characters. You can leave it out."
                        },
                        "effect": {
                          "type": "string",
                          "enum": [
                            "NoSchedule",
                            "PreferNoSchedule",
                            "NoExecute"
                          ],
                          "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                        }
                      },
                      "required": [
                        "key",
                        "effect"
                      ]
                    },
                    "description": "The Kubernetes taints of the workers, up to 10. Leave it out, or send `null`, for no taints.",
                    "x-cli-input": {
                      "order": 50,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "name",
                  "server_type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "labels",
          "taints",
          "status",
          "status_message",
          "nodes_ready",
          "scaling",
          "nodes"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "result": {
            "operation": "get_kubernetes_node_pool",
            "bindings": {
              "id": {
                "source": "result",
                "path": [
                  "id"
                ]
              },
              "kubernetes_cluster_id": {
                "source": "params",
                "path": [
                  "kubernetes_cluster_id"
                ]
              }
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "node_pools"
                ],
                "matching": {
                  "source": "result",
                  "path": []
                },
                "match_by": "id",
                "every": {
                  "all": [
                    {
                      "path": [
                        "nodes"
                      ],
                      "count": true,
                      "expected": {
                        "source": "matched",
                        "path": [
                          "node_count"
                        ]
                      }
                    },
                    {
                      "path": [
                        "nodes"
                      ],
                      "every": {
                        "path": [
                          "status"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": "ready"
                        }
                      }
                    }
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the control plane reports running and this pool has its accepted live count with every node ready; not label/taint application or workload health"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/node-pools/{id}": {
      "delete": {
        "operationId": "delete_kubernetes_node_pool",
        "summary": "Delete a Kubernetes node pool.",
        "description": "The node pool is returned as `deleting`, with a `node_count` of 0. We then move the pods off the node pool's workers and remove the workers.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools/:id",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_node_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesNodePoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-notes": [
          "Once deleted, the node pool stays available as `destroyed`. Pods get up to 5 minutes to move off a worker. A worker can be removed before every pod has left."
        ],
        "x-cli-default-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "labels",
          "taints",
          "status",
          "status_message",
          "nodes_ready",
          "scaling",
          "nodes"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_node_pool",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "destroyed"
            }
          },
          "messages": [
            "status_message"
          ],
          "description": "Node pool is destroyed, so every worker has left the cluster. Whether every pod moved off first, and whether the worker servers are gone, is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_kubernetes_node_pool",
        "summary": "Get a Kubernetes node pool and its workers.",
        "description": "A deleted node pool can still be fetched, as `destroyed`.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools/:id",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kubernetes_node_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesNodePoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "labels",
          "taints",
          "status",
          "status_message",
          "nodes_ready",
          "scaling",
          "nodes"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_node_pool",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "before": "get_kubernetes_node_pool",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "active"
                }
              },
              {
                "path": [
                  "nodes"
                ],
                "count": true,
                "expected": {
                  "source": "before",
                  "path": [
                    "node_count"
                  ]
                }
              },
              {
                "path": [
                  "nodes"
                ],
                "every": {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "ready"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "deleting",
                "destroyed"
              ]
            }
          ],
          "description": "this pool has its initially observed desired count with all nodes ready; control-plane health is not checked by this pool-only read"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_kubernetes_node_pool",
        "summary": "Change a Kubernetes node pool's `node_count`, `labels` or `taints`.",
        "description": "We apply the change shortly after the response. A change of size returns as `scaling`. The `scaling` field shows how the change is going, and new workers are listed as `queued`.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools/:id",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_node_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesNodePoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `node_count`, labels or taints aren't valid, or the cluster would have more than 100 workers.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "node_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many workers the node pool should have, from 0 to 100. The node pools of a cluster can have 100 workers in total."
                  },
                  "labels": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "additionalProperties": true,
                    "description": "The new Kubernetes labels of the workers, up to 10 string pairs. The new labels replace all labels. Keys and values are up to 63 characters. Send `null` or an empty object to remove all labels."
                  },
                  "taints": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "description": "The taint's key, in the same form as a Kubernetes label key."
                        },
                        "value": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "The taint's value, up to 63 characters. You can leave it out."
                        },
                        "effect": {
                          "type": "string",
                          "enum": [
                            "NoSchedule",
                            "PreferNoSchedule",
                            "NoExecute"
                          ],
                          "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                        }
                      },
                      "required": [
                        "key",
                        "effect"
                      ]
                    },
                    "description": "The new Kubernetes taints of the workers, up to 10. The new taints replace all taints. Send `null` or an empty list to remove all taints."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-notes": [
          "Removed workers are gone once `nodes` no longer lists them. Labels and taints reach the workers shortly after the response."
        ],
        "x-cli-default-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "node_count",
          "labels",
          "taints",
          "status",
          "status_message",
          "nodes_ready",
          "scaling",
          "nodes"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.list"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_cluster",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "result": {
            "operation": "get_kubernetes_node_pool",
            "bindings": {
              "id": {
                "source": "result",
                "path": [
                  "id"
                ]
              },
              "kubernetes_cluster_id": {
                "source": "params",
                "path": [
                  "kubernetes_cluster_id"
                ]
              }
            }
          },
          "before": "get_kubernetes_node_pool",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "when": {
            "path": [
              "node_count"
            ],
            "at_least": {
              "source": "before",
              "path": [
                "node_count"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "node_pools"
                ],
                "matching": {
                  "source": "result",
                  "path": []
                },
                "match_by": "id",
                "every": {
                  "all": [
                    {
                      "path": [
                        "nodes"
                      ],
                      "count": true,
                      "expected": {
                        "source": "matched",
                        "path": [
                          "node_count"
                        ]
                      }
                    },
                    {
                      "path": [
                        "nodes"
                      ],
                      "every": {
                        "path": [
                          "status"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": "ready"
                        }
                      }
                    }
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the control plane reports running and this pool has its accepted live count with every node ready; not label/taint application or workload health"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/node-pools/{id}/nodes/{node_id}/recycle": {
      "post": {
        "operationId": "recycle_kubernetes_node_pool",
        "summary": "Replace a worker with a new one.",
        "description": "We move the pods off the old worker and remove it shortly after the response.",
        "tags": [
          "kubernetes_node_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:kubernetes_cluster_id/node-pools/:id/nodes/:node_id/recycle",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the node pool the worker belongs to. Get it via [List Kubernetes node pools](/docs/cloud/api/kubernetes-node-pools/list-kubernetes-node-pools/).",
            "x-path-wildcard": false
          },
          {
            "name": "node_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the worker to replace, from the node pool's `nodes`. Use the worker's `id`, never its `server_id`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the worker being replaced, as `replacing`.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "The ID of the worker being replaced."
                    },
                    "name": {
                      "type": "string",
                      "description": "The name in Kubernetes of the worker being replaced."
                    },
                    "server_id": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The ID of the server of the worker being replaced."
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "queued",
                        "provisioning",
                        "joining",
                        "ready",
                        "not_ready",
                        "draining",
                        "replacing",
                        "destroyed"
                      ],
                      "description": "The worker's state, `replacing` in this response."
                    },
                    "version": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The Kubernetes version the worker last reported."
                    },
                    "last_seen_at": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When we last saw the worker ready."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The cluster has no such node pool, or the node pool has no such worker.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-notes": [
          "To follow the replacement, get the node pool and watch its `nodes`, or look for the cluster's `node_replaced` event."
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "version",
          "last_seen_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_node_pool.recycle"
        },
        "x-cli-wait": {
          "observe": "get_kubernetes_node_pool",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "before": "get_kubernetes_node_pool",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "nodes"
                ],
                "every": {
                  "not": {
                    "path": [
                      "id"
                    ],
                    "expected": {
                      "source": "params",
                      "path": [
                        "node_id"
                      ]
                    }
                  }
                }
              },
              {
                "path": [
                  "nodes"
                ],
                "count": true,
                "expected": {
                  "source": "before",
                  "path": [
                    "node_count"
                  ]
                }
              },
              {
                "path": [
                  "nodes"
                ],
                "every": {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "ready"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "deleting",
                "destroyed"
              ]
            },
            {
              "not": {
                "path": [
                  "nodes"
                ],
                "every": {
                  "not": {
                    "all": [
                      {
                        "path": [
                          "id"
                        ],
                        "expected": {
                          "source": "params",
                          "path": [
                            "node_id"
                          ]
                        }
                      },
                      {
                        "path": [
                          "status"
                        ],
                        "in": [
                          "ready",
                          "not_ready"
                        ]
                      }
                    ]
                  }
                }
              }
            },
            {
              "all": [
                {
                  "path": [
                    "nodes"
                  ],
                  "every": {
                    "not": {
                      "path": [
                        "id"
                      ],
                      "expected": {
                        "source": "params",
                        "path": [
                          "node_id"
                        ]
                      }
                    }
                  }
                },
                {
                  "not": {
                    "path": [
                      "status_message"
                    ],
                    "expected": {
                      "source": "literal",
                      "value": null
                    }
                  }
                },
                {
                  "not": {
                    "path": [
                      "status_message"
                    ],
                    "expected": {
                      "source": "before",
                      "path": [
                        "status_message"
                      ]
                    }
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The old worker is gone and the node pool is back at its size with every worker ready. The old worker back in ready or not_ready means no replacement could be created, and a new status_message without the old worker means it was removed without one. Workload health is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/scheduled-snapshots": {
      "get": {
        "operationId": "list_kubernetes_scheduled_snapshot",
        "summary": "List a Kubernetes cluster's snapshot schedules.",
        "description": "Returns every schedule in one page.",
        "tags": [
          "kubernetes_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:kubernetes_cluster_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kubernetes_scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kubernetes_scheduled_snapshot",
        "summary": "Schedule snapshots of a Kubernetes cluster's control plane.",
        "tags": [
          "kubernetes_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:kubernetes_cluster_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single kubernetes_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster has no control plane yet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `frequency` is missing or isn't `hourly`, `daily`, `weekly` or `monthly`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KubernetesScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_kubernetes_scheduled_snapshot",
        "summary": "Delete a snapshot schedule.",
        "description": "We keep the snapshots it has already created.",
        "tags": [
          "kubernetes_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/kubernetes-clusters/:kubernetes_cluster_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "operationId": "update_kubernetes_scheduled_snapshot",
        "summary": "Change how often a schedule creates snapshots.",
        "tags": [
          "kubernetes_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/kubernetes-clusters/:kubernetes_cluster_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single kubernetes_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `frequency` isn't `hourly`, `daily`, `weekly` or `monthly`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KubernetesScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-clusters/{kubernetes_cluster_id}/snapshots": {
      "get": {
        "operationId": "list_kubernetes_snapshot",
        "summary": "List a Kubernetes cluster's snapshots, with their status and size.",
        "tags": [
          "kubernetes_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-clusters/:kubernetes_cluster_id/snapshots",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of kubernetes_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "status",
          "snapshot_type",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "list_kubernetes_snapshot",
          "inputs": {
            "id": {
              "type": "string"
            }
          },
          "bindings": {
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "select": {
            "id": {
              "source": "input",
              "path": [
                "id"
              ]
            }
          },
          "pagination": {
            "page_param": "page",
            "total_path": [
              "meta",
              "total"
            ],
            "per_page_path": [
              "meta",
              "per_page"
            ]
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the selected control-plane snapshot is currently available; not worker or persistent-volume backup"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_kubernetes_snapshot",
        "summary": "Create a snapshot of a Kubernetes cluster's control plane.",
        "description": "We create it shortly after the response.",
        "tags": [
          "kubernetes_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/kubernetes-clusters/:kubernetes_cluster_id/snapshots",
        "parameters": [
          {
            "name": "kubernetes_cluster_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Kubernetes cluster. Get it via [List Kubernetes clusters](/docs/cloud/api/kubernetes-clusters/list-kubernetes-clusters/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single kubernetes_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The cluster has no control plane yet, with the code `cluster_not_ready`. Or a snapshot of the cluster is already being created, with the code `snapshot_in_progress`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The name is longer than 255 characters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KubernetesSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "status",
          "snapshot_type",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "list_kubernetes_snapshot",
          "bindings": {
            "kubernetes_cluster_id": {
              "source": "params",
              "path": [
                "kubernetes_cluster_id"
              ]
            }
          },
          "select": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "pagination": {
            "page_param": "page",
            "total_path": [
              "meta",
              "total"
            ],
            "per_page_path": [
              "meta",
              "per_page"
            ]
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the returned control-plane snapshot is available; not worker or persistent-volume backup"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/kubernetes-versions": {
      "get": {
        "operationId": "list_kubernetes_version",
        "summary": "List the Kubernetes versions you can create a cluster on.",
        "description": "A cluster's `available_versions` lists the versions it can upgrade to.",
        "tags": [
          "kubernetes_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/kubernetes-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of kubernetes_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KubernetesVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "version",
          "build",
          "latest"
        ],
        "x-cli-response-fields": [
          "version",
          "build",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.kubernetes_version.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "versions"
          ],
          "attributes_path": [],
          "id_path": [
            "version"
          ]
        }
      }
    },
    "/v1/load-balancer-types": {
      "get": {
        "operationId": "list_load_balancer_type",
        "summary": "List the load balancer types you can order.",
        "description": "Returns every type in one page.",
        "tags": [
          "load_balancer_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancer-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of load_balancer_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "max_connections",
          "max_services",
          "max_targets"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "max_connections",
          "max_services",
          "max_targets",
          "max_certificates",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/load-balancer-types/{name}": {
      "get": {
        "operationId": "get_load_balancer_type",
        "summary": "Get a load balancer type by its name, including a deprecated type that has a replacement.",
        "tags": [
          "load_balancer_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancer-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `LB1`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single load_balancer_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "max_connections",
          "max_services",
          "max_targets"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "max_connections",
          "max_services",
          "max_targets",
          "max_certificates",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/load-balancers": {
      "get": {
        "operationId": "list_load_balancer",
        "summary": "List your load balancers.",
        "description": "The list includes `failed` and `destroyed` load balancers.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "rescaling",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only load balancers in this state."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the load balancer with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only load balancers whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only load balancers with this tag, such as `metadata[env]=prod`. Repeat it to filter by several tags, and a load balancer must have all of them."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of load_balancer objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_load_balancer",
        "summary": "Create a load balancer, with its services and targets if you send them.",
        "description": "A `running` load balancer can still have targets that are down, so check each service's `target_health`.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the load balancer. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of load balancers, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team to create the load balancer in. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The load balancer's name. Must be unique among your organization's load balancers that aren't `failed` or `destroyed`.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "type": {
                    "type": "string",
                    "description": "The load balancer's type, such as `LB1`. Get the types via [List load balancer types](/docs/cloud/api/load-balancer-types/list-load-balancer-types/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_load_balancer_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "max_connections",
                        "max_targets"
                      ]
                    }
                  },
                  "algorithm": {
                    "type": "string",
                    "enum": [
                      "round_robin",
                      "least_connections",
                      "source_ip"
                    ],
                    "description": "How the load balancer picks a target for each connection.",
                    "x-enum-descriptions": {
                      "round_robin": "Sends each new connection to the next target in turn.",
                      "least_connections": "Sends each new connection to the target with the fewest open connections.",
                      "source_ip": "Sends all connections from one client IP to the same target."
                    },
                    "default": "round_robin"
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of your private networks to attach. The networks must be in the load balancer's team. Get them via [List networks](/docs/cloud/api/networks/list-networks/).",
                    "x-cli-input": {
                      "order": 70,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of the firewalls to attach, at most one. The firewall must be in the load balancer's team. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
                    "x-cli-input": {
                      "order": 80,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term. Defaults to `monthly`.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "default": "monthly"
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  },
                  "services": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "protocol": {
                          "type": "string",
                          "enum": [
                            "tcp",
                            "http",
                            "https",
                            "udp"
                          ],
                          "description": "The protocol the service listens for.\n\n- `tcp`: Forwards TCP connections.\n- `http`: Forwards HTTP requests.\n- `https`: Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.\n- `udp`: Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`.",
                          "x-enum-descriptions": {
                            "tcp": "Forwards TCP connections.",
                            "http": "Forwards HTTP requests.",
                            "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.",
                            "udp": "Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`."
                          }
                        },
                        "listen_port": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The port to listen on, 1–65535. Can't be `8402` or `9901`, which the load balancer uses itself."
                        },
                        "destination_port": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The port on the targets to send traffic to, 1–65535."
                        },
                        "redirect_http": {
                          "type": "boolean",
                          "description": "Whether HTTP requests are redirected to this HTTPS service. Only `https` services can redirect."
                        },
                        "http_timeout_seconds": {
                          "type": "integer",
                          "format": "int64",
                          "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds, 5–600. Only `http` and `https` services use it."
                        },
                        "sticky_sessions": {
                          "type": "boolean",
                          "description": "Whether a cookie sends each client to the same target. Only `http` and `https` services can use sticky sessions."
                        },
                        "sticky_cookie_name": {
                          "type": "string",
                          "description": "The name of the sticky session cookie, 1–64 letters, digits, underscores, dots or hyphens. Defaults to `BSLBSTICKY`."
                        },
                        "sticky_cookie_lifetime_seconds": {
                          "type": "integer",
                          "format": "int64",
                          "description": "How long the sticky session cookie lasts, 1–86400 seconds."
                        },
                        "proxy_protocol": {
                          "type": "string",
                          "enum": [
                            "disabled",
                            "v1",
                            "v2"
                          ],
                          "description": "The PROXY protocol version the targets accept, or `disabled`. A `udp` service can't use it."
                        },
                        "certificate_ids": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "The IDs of the certificates to present. An `https` service requires at least one, and a `udp` service can't have any."
                        },
                        "health_check": {
                          "type": "object",
                          "properties": {
                            "protocol": {
                              "type": "string",
                              "enum": [
                                "tcp",
                                "http"
                              ],
                              "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.\n- `http`: Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`.",
                              "x-enum-descriptions": {
                                "tcp": "Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.",
                                "http": "Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`."
                              }
                            },
                            "port": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "format": "int64",
                              "description": "The port we check, 1–65535. Defaults to `destination_port`."
                            },
                            "interval_seconds": {
                              "type": "integer",
                              "format": "int64",
                              "description": "How often we check each target, 2–3600 seconds."
                            },
                            "timeout_seconds": {
                              "type": "integer",
                              "format": "int64",
                              "description": "The check timeout in seconds, 1–60."
                            },
                            "retries": {
                              "type": "integer",
                              "format": "int64",
                              "description": "How many checks in a row must fail before a target is down, 1–10."
                            },
                            "domain": {
                              "type": [
                                "string",
                                "null"
                              ],
                              "description": "The hostname we send in the `Host` header of an HTTP check."
                            },
                            "path": {
                              "type": "string",
                              "description": "The path an HTTP check requests, starting with `/`, with no spaces or quotes."
                            },
                            "response": {
                              "type": [
                                "string",
                                "null"
                              ],
                              "description": "Text the response must contain, at most 255 characters with no line breaks or quotes."
                            },
                            "status_codes": {
                              "type": "string",
                              "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
                            },
                            "tls": {
                              "type": "boolean",
                              "description": "Whether checks connect with TLS."
                            }
                          },
                          "description": "How the service checks that its targets are healthy."
                        }
                      },
                      "required": [
                        "protocol",
                        "listen_port",
                        "destination_port"
                      ]
                    },
                    "description": "Services to create with the load balancer. Each service accepts the same settings as [Create a load balancer service](/docs/cloud/api/load-balancer-services/create-load-balancer-service/).",
                    "x-cli-input": {
                      "order": 40,
                      "group": "Advanced"
                    }
                  },
                  "targets": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "server",
                            "label_selector"
                          ],
                          "description": "What the target points at.\n\n- `server`: One server. Send `server_id` and leave out `selector`.\n- `label_selector`: Every server that has the tags in `selector`. Send `selector` and leave out `server_id`.",
                          "x-enum-descriptions": {
                            "server": "One server. Send `server_id` and leave out `selector`.",
                            "label_selector": "Every server that has the tags in `selector`. Send `selector` and leave out `server_id`."
                          }
                        },
                        "server_id": {
                          "type": "string",
                          "description": "The ID of the server to send traffic to. A `server` target requires it, and a `label_selector` target can't have it."
                        },
                        "selector": {
                          "type": "object",
                          "additionalProperties": true,
                          "description": "The tags a server must have to receive traffic, as string pairs. A `label_selector` target requires at least one tag, and a `server` target can't have it."
                        },
                        "use_private_ip": {
                          "type": "boolean",
                          "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP."
                        }
                      },
                      "required": [
                        "type"
                      ]
                    },
                    "description": "Targets to create with the load balancer. Each target accepts the same settings as [Create a load balancer target](/docs/cloud/api/load-balancer-targets/create-load-balancer-target/).",
                    "x-cli-input": {
                      "order": 50,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name",
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-cli-wait": {
          "observe": "get_load_balancer",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created load balancer reports running; not verified traffic, TLS issuance or target health"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{id}": {
      "delete": {
        "operationId": "delete_load_balancer",
        "summary": "Delete a load balancer.",
        "description": "The load balancer is `destroyed` at once.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/load-balancers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A Kubernetes Service created the load balancer. Delete the Service to delete the load balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_load_balancer",
        "summary": "Get a load balancer, with its status, addresses, services and targets.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-cli-wait": {
          "observe": "get_load_balancer",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the load balancer currently reports running; not traffic, TLS or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_load_balancer",
        "summary": "Update a load balancer's name, algorithm, tags or billing term.",
        "description": "The change applies without downtime.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/load-balancers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoadBalancerUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{id}/firewalls": {
      "post": {
        "operationId": "attach_load_balancer_firewall",
        "summary": "Attach a firewall to a load balancer.",
        "description": "The firewall must be in the load balancer's team. A load balancer can have one firewall. The firewall's rules apply shortly after the response.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer to attach the firewall to. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/)."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_load_balancer_firewall",
        "summary": "Detach a firewall from a load balancer.",
        "description": "The firewall's rules stop applying shortly after the response.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/load-balancers/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer to detach the firewall from. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/load-balancers/{id}/metrics": {
      "get": {
        "operationId": "metrics_load_balancer",
        "summary": "Get a load balancer's connections and traffic over time.",
        "description": "Defaults to the last day. A range can be up to 366 days long.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range, included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range, not included, in ISO 8601, such as `2026-07-01T12:00:00Z`. Defaults to now. Must be after `from`."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the history as one object, with the range it covers.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "load_balancer_id": {
                      "type": "string",
                      "description": "The load balancer's ID."
                    },
                    "load_balancer_name": {
                      "type": "string",
                      "description": "The load balancer's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range the metrics cover."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range the metrics cover."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the points are.",
                      "x-enum-descriptions": {
                        "raw": "One point a minute, for a range up to one day.",
                        "hourly": "One point an hour, for a longer range."
                      }
                    },
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "dt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "connections": {
                            "type": "object",
                            "properties": {
                              "open": {
                                "type": "number"
                              },
                              "open_max": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "per_second": {
                                "type": "number"
                              }
                            }
                          },
                          "traffic": {
                            "type": "object",
                            "properties": {
                              "bytes_in_per_second": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "bytes_out_per_second": {
                                "type": "integer",
                                "format": "int64"
                              }
                            }
                          }
                        }
                      },
                      "description": "The metrics, one entry per point."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "load_balancer_id",
          "load_balancer_name",
          "from",
          "to",
          "resolution",
          "data"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/load-balancers/{id}/networks": {
      "post": {
        "operationId": "attach_load_balancer_network",
        "summary": "Attach a private network to a load balancer.",
        "description": "The network must be in the load balancer's team. The load balancer joins the network shortly after the response.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer to attach the network to. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach. Get it via [List networks](/docs/cloud/api/networks/list-networks/)."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_load_balancer_network",
        "summary": "Detach a private network from a load balancer.",
        "description": "The load balancer leaves the network shortly after the response.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/load-balancers/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer to detach the network from. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/load-balancers/{id}/rescale": {
      "post": {
        "operationId": "rescale_load_balancer",
        "summary": "Change a load balancer's type.",
        "description": "Traffic stops for a short time during the change. The load balancer must be `running`. The load balancer's services, certificates and targets must fit in the new type. The response already shows the new `type` while the change is in progress.",
        "tags": [
          "load_balancer"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single load_balancer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The load balancer isn't `running`, or another change is in progress. The zone has no room for the new type right now. A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type, such as `LB2`. Get the types via [List load balancer types](/docs/cloud/api/load-balancer-types/list-load-balancer-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_load_balancer_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "max_connections",
                        "max_targets"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "algorithm"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "algorithm",
          "status",
          "status_message",
          "public_ips",
          "private_ips",
          "network_ids",
          "firewall_ids",
          "services",
          "targets",
          "config_applied_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer.list"
        },
        "x-cli-wait": {
          "observe": "get_load_balancer",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "type"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Load balancer is running again after the rescale. It returns to running even when the type change on its server didn't finish, so that is not verified, and the load balancer's events say how the change went."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{load_balancer_id}/events": {
      "get": {
        "operationId": "list_load_balancer_event",
        "summary": "List a load balancer's events.",
        "description": "You can still list them after the load balancer is deleted.",
        "tags": [
          "load_balancer_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers/:load_balancer_id/events",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of load_balancer_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "load_balancer_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{load_balancer_id}/services": {
      "get": {
        "operationId": "list_load_balancer_service",
        "summary": "List a load balancer's services.",
        "description": "Returns every service in one page.",
        "tags": [
          "load_balancer_service"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers/:load_balancer_id/services",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of load_balancer_service objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerServiceList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port"
        ],
        "x-cli-name-fields": [
          "listen_port"
        ],
        "x-cli-response-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port",
          "redirect_http",
          "http_timeout_seconds",
          "sticky_sessions",
          "sticky_cookie_name",
          "sticky_cookie_lifetime_seconds",
          "proxy_protocol",
          "certificate_ids",
          "health_check",
          "target_health",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_service.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_load_balancer_service",
        "summary": "Add a service to a load balancer.",
        "description": "A running load balancer starts listening on the service's port shortly after the response.",
        "tags": [
          "load_balancer_service"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers/:load_balancer_id/services",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single load_balancer_service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerServiceDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The load balancer has as many services as its type allows. The load balancer would present more certificates than its type allows. A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoadBalancerServiceCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port"
        ],
        "x-cli-name-fields": [
          "listen_port"
        ],
        "x-cli-response-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port",
          "redirect_http",
          "http_timeout_seconds",
          "sticky_sessions",
          "sticky_cookie_name",
          "sticky_cookie_lifetime_seconds",
          "proxy_protocol",
          "certificate_ids",
          "health_check",
          "target_health",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_service.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{load_balancer_id}/services/{id}": {
      "delete": {
        "operationId": "delete_load_balancer_service",
        "summary": "Remove a service from a load balancer.",
        "description": "A running load balancer stops listening on the service's port shortly after the response.",
        "tags": [
          "load_balancer_service"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/load-balancers/:load_balancer_id/services/:id",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the service to remove.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "operationId": "update_load_balancer_service",
        "summary": "Update a load balancer's service.",
        "description": "A running load balancer applies the change shortly after the response.",
        "tags": [
          "load_balancer_service"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/load-balancers/:load_balancer_id/services/:id",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the service to update.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single load_balancer_service.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerServiceDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The load balancer would present more certificates than its type allows. A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoadBalancerServiceUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port"
        ],
        "x-cli-name-fields": [
          "listen_port"
        ],
        "x-cli-response-fields": [
          "id",
          "protocol",
          "listen_port",
          "destination_port",
          "redirect_http",
          "http_timeout_seconds",
          "sticky_sessions",
          "sticky_cookie_name",
          "sticky_cookie_lifetime_seconds",
          "proxy_protocol",
          "certificate_ids",
          "health_check",
          "target_health",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_service.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{load_balancer_id}/targets": {
      "get": {
        "operationId": "list_load_balancer_target",
        "summary": "List a load balancer's targets.",
        "description": "A `label_selector` target is one entry, however many servers match it.",
        "tags": [
          "load_balancer_target"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/load-balancers/:load_balancer_id/targets",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of load_balancer_target objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerTargetList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "type",
          "server_id",
          "selector"
        ],
        "x-cli-name-fields": [
          "server_id",
          "type"
        ],
        "x-cli-response-fields": [
          "id",
          "type",
          "server_id",
          "selector",
          "use_private_ip",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_target.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_load_balancer_target",
        "summary": "Add a target to a load balancer.",
        "description": "A running load balancer starts sending traffic to the target shortly after the response. When a `selector` matches more servers than the load balancer's type allows, the load balancer keeps its previous configuration, and its `status_message` says why.",
        "tags": [
          "load_balancer_target"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/load-balancers/:load_balancer_id/targets",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false,
            "examples": {
              "send_traffic_to_servers_with_a_tag": {
                "summary": "Send traffic to servers with a tag",
                "value": "7a1d5b0c-2f4e-4a53-8f0e-6b7c1d9e2a10"
              }
            }
          }
        ],
        "responses": {
          "201": {
            "description": "A single load_balancer_target.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoadBalancerTargetDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The load balancer has as many targets as its type allows. A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoadBalancerTargetCreate"
              },
              "examples": {
                "send_traffic_to_servers_with_a_tag": {
                  "summary": "Send traffic to servers with a tag",
                  "value": {
                    "type": "label_selector",
                    "selector": {
                      "role": "web"
                    }
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "type",
          "server_id",
          "selector"
        ],
        "x-cli-name-fields": [
          "server_id",
          "type"
        ],
        "x-cli-response-fields": [
          "id",
          "type",
          "server_id",
          "selector",
          "use_private_ip",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.load_balancer_target.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/load-balancers/{load_balancer_id}/targets/{id}": {
      "delete": {
        "operationId": "delete_load_balancer_target",
        "summary": "Remove a target from a load balancer.",
        "description": "A running load balancer stops sending traffic to the target shortly after the response.",
        "tags": [
          "load_balancer_target"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/load-balancers/:load_balancer_id/targets/:id",
        "parameters": [
          {
            "name": "load_balancer_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the load balancer. Get it via [List load balancers](/docs/cloud/api/load-balancers/list-load-balancers/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the target to remove.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A Kubernetes Service created the load balancer. Change the Service instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/mysql": {
      "get": {
        "operationId": "list_mysql",
        "summary": "List your MySQL instances in this zone.",
        "description": "The list includes `failed` and `destroyed` instances.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "upgrading",
                "restoring",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only instances with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the instance with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only instances whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only instances with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match instances that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of mysql objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_mysql",
        "summary": "Create a MySQL instance.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the MySQL instance. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of MySQL instances, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, type, network or firewall doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another MySQL action is running in your organization at the same time, with the code `concurrent_create_limit`. Or we couldn't set up the instance, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MySQLCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created instance reports running; not public TLS or client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql-snapshots": {
      "get": {
        "operationId": "list_flat_mysql_snapshot",
        "summary": "List the snapshots of all your MySQL instances.",
        "description": "The list includes snapshots of deleted instances.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql-snapshots",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the snapshots of the MySQL instance with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of mysql_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_flat_mysql_snapshot",
        "summary": "Create a snapshot of the MySQL instance in `mysql_id`.",
        "description": "MySQL writes its pending changes to disk first, so the snapshot is consistent.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql-snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance in `mysql_id` doesn't exist, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance can't be snapshotted in its current state, or a snapshot of it is already being created, with the code `mysql_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `mysql_id`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another snapshot is being created in your organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "mysql_id": {
                    "type": "string",
                    "description": "The ID of the MySQL instance to snapshot.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_mysql",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `orders-2026-11-24`.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
                  }
                },
                "required": [
                  "mysql_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_mysql_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql-snapshots/{id}": {
      "delete": {
        "operationId": "delete_flat_mysql_snapshot",
        "summary": "Delete a MySQL snapshot by its ID alone, even after its instance is deleted.",
        "description": "The snapshot's status is `deleting` until the snapshot is removed.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_mysql_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_flat_mysql_snapshot",
        "summary": "Get a MySQL snapshot by its ID alone, even after its instance is deleted.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql-snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_flat_mysql_snapshot",
        "summary": "Restore an `available` snapshot into a new MySQL instance, by the snapshot's ID alone.",
        "description": "The new instance gets its own ID, hostname and credentials. The instance the snapshot was taken from must still exist.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql-snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, was saved without its instance's settings, or its instance is deleted, with the code `snapshot_not_restorable`. The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql-types": {
      "get": {
        "operationId": "list_mysql_type",
        "summary": "List the MySQL types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "mysql_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of mysql_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_disk_gb",
          "max_connections"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_disk_gb",
          "max_connections",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/mysql-types/{name}": {
      "get": {
        "operationId": "get_mysql_type",
        "summary": "Get a MySQL type by its name.",
        "description": "You can also get a deprecated type that has a replacement.",
        "tags": [
          "mysql_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `MY8`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_disk_gb",
          "max_connections"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_disk_gb",
          "max_connections",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/mysql-versions": {
      "get": {
        "operationId": "list_mysql_version",
        "summary": "List the MySQL versions we offer.",
        "description": "An instance's `available_engine_versions` lists the ones it can upgrade to.",
        "tags": [
          "mysql_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of mysql_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_version.list"
        },
        "x-response-envelope": {
          "list_path": [
            "versions"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/mysql/{id}": {
      "delete": {
        "operationId": "delete_mysql",
        "summary": "Delete an instance.",
        "description": "The instance's status becomes `destroyed` at once, and its nodes are removed in the background.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_mysql",
        "summary": "Get a MySQL instance.",
        "description": "Get the `admin` user's password via [Get a MySQL instance's credentials](/docs/cloud/api/mysqls/credentials-mysql/).",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_mysql",
        "summary": "Update an instance's name, tags, MySQL settings, `public_access`, `replica_count` or billing term.",
        "description": "The changes apply without downtime.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/mysql/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single mysql. (the request changes `public_access` or `replica_count`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MySQLUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "when": {
            "path": [
              "replica_count"
            ],
            "at_least": {
              "source": "literal",
              "value": 0
            }
          },
          "success": {
            "all": [
              {
                "any": [
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 0
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 3
                        }
                      }
                    ]
                  }
                ]
              },
              {
                "path": [
                  "replica_count"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "replica_count"
                  ]
                }
              },
              {
                "path": [
                  "members"
                ],
                "every": {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "When the request sets replica_count, the instance has that many replicas and every member reports running. A change of only public_access or other settings is sent without waiting."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/credentials": {
      "get": {
        "operationId": "credentials_mysql",
        "summary": "Get the `admin` user's password, the URIs to connect with and the `ca_certificate` to verify the instance with.",
        "description": "You can get the password again at any time.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the `admin` user's connection details.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name, `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The `admin` user's password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The default database's name."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect from your private networks, with the password and `ssl-mode=REQUIRED`.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect from the internet, with the password and `ssl-mode=REQUIRED`, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous password stops working, 24 hours after a rotation, or `null` when no rotation is in progress."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "public_uri",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/mysql/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_mysql_credentials",
        "summary": "Set a new password for the `admin` user.",
        "description": "The previous password keeps working for 24 hours. The instance must be `running` or `degraded`.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance whose credentials to rotate.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the `admin` user's connection details with the new password.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name, `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The `admin` user's new password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The default database's name."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect from your private networks, with the new password.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect from the internet, with the new password, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous password stops working, 24 hours from now."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "public_uri",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/mysql/{id}/failover": {
      "post": {
        "operationId": "failover_mysql",
        "summary": "Make the most up-to-date replica the new primary.",
        "description": "The primary and at least one replica must be running. Every write the primary confirmed is kept. The instance's status stays `running` throughout.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/failover",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance to fail over.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_mysql",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "members"
            ],
            "matching": {
              "source": "before",
              "path": [
                "members"
              ]
            },
            "match_by": "id",
            "every": {
              "any": [
                {
                  "path": [
                    "role"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "replica"
                  }
                },
                {
                  "all": [
                    {
                      "not": {
                        "path": [
                          "role"
                        ],
                        "expected": {
                          "source": "matched",
                          "path": [
                            "role"
                          ]
                        }
                      }
                    },
                    {
                      "path": [
                        "role"
                      ],
                      "expected": {
                        "source": "literal",
                        "value": "primary"
                      }
                    }
                  ]
                }
              ]
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The former primary is now a replica and a former replica is the primary. The endpoint's DNS and the old primary catching up are not verified, and a failover Cloud skips leaves the wait running until it times out."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/firewalls": {
      "post": {
        "operationId": "attach_mysql_firewall",
        "summary": "Attach a firewall to every node of the instance.",
        "description": "The firewall must be in the instance's team. An instance can have at most one firewall.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance to attach the firewall to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_mysql_firewall",
        "summary": "Detach a firewall from every node of the instance.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance to detach the firewall from.",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/mysql/{id}/metrics": {
      "get": {
        "operationId": "metrics_mysql",
        "summary": "Get each node's queries, threads, buffer pool hit ratio, rows read and written, disk use and replication lag over time.",
        "description": "Defaults to the last day. A range can be at most 366 days.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range. Defaults to now."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns each node's metrics over time.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "mysql_id": {
                      "type": "string",
                      "description": "The instance's ID."
                    },
                    "mysql_name": {
                      "type": "string",
                      "description": "The instance's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range returned."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range returned."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the values are.",
                      "x-enum-descriptions": {
                        "raw": "A value for each minute, for a range of up to one day.",
                        "hourly": "A value for each hour, for a longer range."
                      }
                    },
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "member_id": {
                            "type": "string"
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "primary",
                              "replica"
                            ]
                          },
                          "data": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "dt": {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                "queries_per_second": {
                                  "type": "number"
                                },
                                "slow_queries_per_second": {
                                  "type": "number"
                                },
                                "threads": {
                                  "type": "object",
                                  "properties": {
                                    "connected": {
                                      "type": "number"
                                    },
                                    "connected_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "running": {
                                      "type": "number"
                                    },
                                    "max_connections": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "buffer_pool_hit_ratio": {
                                  "type": "number"
                                },
                                "rows_read_per_second": {
                                  "type": "number"
                                },
                                "rows_written_per_second": {
                                  "type": "number"
                                },
                                "disk": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "usable_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "replication_lag_seconds": {
                                  "type": "number"
                                }
                              }
                            }
                          }
                        }
                      },
                      "description": "Each node's metrics over time. Every point has its time, the queries and rows per second, the threads, the buffer pool hit ratio, the disk use and the replication lag."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "mysql_id",
          "mysql_name",
          "from",
          "to",
          "resolution",
          "members"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/mysql/{id}/networks": {
      "post": {
        "operationId": "attach_mysql_network",
        "summary": "Attach a private network to every node of the instance.",
        "description": "The network must be in the instance's team. The nodes join the network shortly after the response.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance to attach the network to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_mysql_network",
        "summary": "Detach a private network from every node of the instance.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance to detach the network from.",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/mysql/{id}/rescale": {
      "post": {
        "operationId": "rescale_mysql",
        "summary": "Change an instance's type.",
        "description": "Your data must use at most 80% of the new type's `usable_disk_gb`. A disk never shrinks, even on a smaller type. If the rescale doesn't finish, the instance returns to `running` with a `status_message`.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type, such as `MY2`. Get the types via [List MySQL types](/docs/cloud/api/mysql-types/list-mysql-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_mysql_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_disk_gb",
                        "max_connections"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Every member was resized to the new type and the instance is back to running. Disk growth inside the members is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/restore": {
      "post": {
        "operationId": "restore_mysql",
        "summary": "Restore an instance from one of its own snapshots.",
        "description": "Data written after the snapshot is lost. The replicas are rebuilt. The instance's status is `running` again when the restore is done.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of the instance's snapshot to restore. Get the snapshots via [List a MySQL instance's snapshots](/docs/cloud/api/mysql-snapshots/list-mysql-snapshots/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_mysql_snapshot",
                      "bindings": {
                        "mysql_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "status",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance returned to running after accepted restore; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_mysql",
        "summary": "Upgrade an instance to a newer MySQL version.",
        "description": "We create a snapshot of the instance first. To go back, restore that snapshot with [Restore a MySQL instance](/docs/cloud/api/mysqls/restore-mysql/). The upgrade is done when the instance is `running` on the new `engine_version`. If the instance is back to `running` on its old version with a `status_message`, the upgrade failed.",
        "tags": [
          "mysql"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/MySQLDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "pre_upgrade_snapshot_id": {
                          "type": "string",
                          "description": "The ID of the snapshot we created before the upgrade."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "engine_version": {
                    "type": "string",
                    "description": "The version to upgrade to, one of the instance's `available_engine_versions`."
                  }
                },
                "required": [
                  "engine_version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "pre_upgrade_snapshot_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.upgrade"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_mysql",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "engine_version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "engine_version"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "engine_version"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "engine_version"
                    ]
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance reports running on the requested engine line; not workload verification"
        },
        "x-cli-one-time-fields": [
          "pre_upgrade_snapshot_id"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/events": {
      "get": {
        "operationId": "list_mysql_event",
        "summary": "List a MySQL instance's events.",
        "description": "You can still list them after the instance is deleted.",
        "tags": [
          "mysql_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:mysql_id/events",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of mysql_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/scheduled-snapshots": {
      "get": {
        "operationId": "list_mysql_scheduled_snapshot",
        "summary": "List a MySQL instance's snapshot schedules.",
        "tags": [
          "mysql_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:mysql_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of mysql_scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "mysql_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_mysql_scheduled_snapshot",
        "summary": "Create a snapshot schedule for a MySQL instance.",
        "description": "The instance must be `running` or `degraded` and have a primary. The schedule counts toward your organization's limit of snapshot schedules.",
        "tags": [
          "mysql_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:mysql_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single mysql_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshot schedules, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, or it has no primary, with the code `mysql_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MySQLScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "mysql_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_mysql_scheduled_snapshot",
        "summary": "Delete a snapshot schedule.",
        "description": "The snapshots the schedule already created are kept.",
        "tags": [
          "mysql_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql/:mysql_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_mysql_scheduled_snapshot",
        "summary": "Get a snapshot schedule of a MySQL instance.",
        "tags": [
          "mysql_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:mysql_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "mysql_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_mysql_scheduled_snapshot",
        "summary": "Change how often a snapshot schedule creates snapshots.",
        "tags": [
          "mysql_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/mysql/:mysql_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MySQLScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "mysql_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/snapshots": {
      "get": {
        "operationId": "list_mysql_snapshot",
        "summary": "List a MySQL instance's snapshots, with their status and size.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:mysql_id/snapshots",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of mysql_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_mysql_snapshot",
        "summary": "Create a snapshot of a MySQL instance.",
        "description": "MySQL writes its pending changes to disk first, so the snapshot is consistent.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:mysql_id/snapshots",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MySQLSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "mysql_id": {
              "source": "params",
              "path": [
                "mysql_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/snapshots/{id}": {
      "delete": {
        "operationId": "delete_mysql_snapshot",
        "summary": "Delete a snapshot.",
        "description": "The snapshot's status is `deleting` until the snapshot is removed.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/mysql/:mysql_id/snapshots/:id",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "mysql_id": {
              "source": "params",
              "path": [
                "mysql_id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_mysql_snapshot",
        "summary": "Get a snapshot of a MySQL instance, with its status and size.",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/mysql/:mysql_id/snapshots/:id",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single mysql_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "mysql_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "mysql_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "mysql_id": {
              "source": "params",
              "path": [
                "mysql_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/mysql/{mysql_id}/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_mysql_snapshot",
        "summary": "Restore an `available` snapshot into a new MySQL instance in the same team and zone.",
        "description": "The new instance has the type, settings and networks the instance had when the snapshot was taken. The new instance gets its own ID, hostname and credentials. `public_access` is off on the new instance. To roll back the instance itself, use [Restore a MySQL instance](/docs/cloud/api/mysqls/restore-mysql/).",
        "tags": [
          "mysql_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/mysql/:mysql_id/snapshots/:id/restore",
        "parameters": [
          {
            "name": "mysql_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the MySQL instance. Get it via [List MySQL instances](/docs/cloud/api/mysqls/list-mysqls/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single mysql.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MySQLDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_disk_gb",
          "max_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "sql_mode",
          "sql_require_primary_key",
          "default_time_zone",
          "max_allowed_packet",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.mysql.list"
        },
        "x-cli-wait": {
          "observe": "get_mysql",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/networks": {
      "get": {
        "operationId": "list_network",
        "summary": "List the private networks in this zone.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/networks",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only networks whose `name` or `ip_prefix` contains this text, ignoring case."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of network objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip_prefix",
          "ip_prefix_length"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.network.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_network",
        "summary": "Create a private network.",
        "description": "You can attach servers to the network right away.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/networks",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of networks, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id`, `name`, `ip_prefix` or `ip_prefix_length`, or the prefix or its length isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NetworkCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip_prefix",
          "ip_prefix_length"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.network.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/networks/{id}": {
      "delete": {
        "operationId": "delete_network",
        "summary": "Remove a private network.",
        "description": "We detach every server from the network shortly after. To choose when each server loses the network, detach the servers first.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/networks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_network",
        "summary": "Get a private network, with the IP range it uses.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/networks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip_prefix",
          "ip_prefix_length"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.network.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_network",
        "summary": "Rename a private network.",
        "description": "The network's IP range can't be changed.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/networks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NetworkUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip_prefix",
          "ip_prefix_length"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.network.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/networks/{id}/attach": {
      "post": {
        "operationId": "attach_network",
        "summary": "Attach a server to a private network.",
        "description": "A server can be on several networks. A running server also gets the next free private address in the network's range, if your quota of private addresses per server allows one. A server that isn't running gets no address. Add one via [Add a private IP to a server](/docs/cloud/api/server-private-ips/create-server-private-ip/) once the server is running.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/networks/:id/attach",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the network to attach the server to. Get it via [List networks](/docs/cloud/api/networks/list-networks/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NetworkDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is already attached to this network, with the code `already_attached`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to attach to the network. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status"
                      ]
                    }
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip_prefix",
          "ip_prefix_length"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.network.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/networks/{id}/attach/{server_id}": {
      "delete": {
        "operationId": "detach_network",
        "summary": "Detach a server from a private network.",
        "description": "The server loses its private addresses on this network.",
        "tags": [
          "network"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/networks/:id/attach/:server_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the network to detach the server from. Get it via [List networks](/docs/cloud/api/networks/list-networks/).",
            "x-path-wildcard": false
          },
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server to detach from the network. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The server isn't attached to this network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/object-proxies": {
      "get": {
        "operationId": "list_object_cache",
        "summary": "List your object caches in this zone, including `failed` and `destroyed` ones.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only object caches in this state."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the object cache with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only object caches whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only object caches with this tag, such as `metadata[env]=prod`. Repeat it to filter by several tags, and an object cache must have all of them."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of object_cache objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_object_cache",
        "summary": "Create an object cache.",
        "description": "We first check that we can reach every bucket at your storage provider with the keys you send.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the object cache. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. We couldn't reach a bucket at your storage provider with its keys, with the code `origin_check_failed`. The message names the bucket.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team to create the object cache in. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The object cache's name, at most 255 characters. Must be unique among your organization's object caches that aren't `failed` or `destroyed`.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "type": {
                    "type": "string",
                    "description": "The object cache's type, such as `OP100`. Get the types via [List object cache types](/docs/cloud/api/object-cache-types/list-object-cache-types/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_object_cache_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_cache_gb"
                      ]
                    }
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of your private networks to attach. The networks must be in the object cache's team. Get them via [List networks](/docs/cloud/api/networks/list-networks/).",
                    "x-cli-input": {
                      "order": 70,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The ID of the firewall to attach, at most one. The firewall must be in the object cache's team. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/).",
                    "x-cli-input": {
                      "order": 80,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "placement_group_id": {
                    "type": "string",
                    "description": "The ID of your placement group to create the object cache in. Must be in the object cache's team. Get it via [List placement groups](/docs/cloud/api/placement-groups/list-placement-groups/).",
                    "x-cli-input": {
                      "order": 90,
                      "group": "Advanced",
                      "lookup": "list_placement_group",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ],
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      }
                    }
                  },
                  "public_access": {
                    "type": "boolean",
                    "description": "Whether the object cache also gets a public HTTPS endpoint.",
                    "default": false
                  },
                  "public_ipv4": {
                    "type": "boolean",
                    "description": "Whether the object cache gets a public IPv4 address. Can't be changed later.",
                    "default": false
                  },
                  "max_capacity_gb": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The cache space to use, in GB, from 10 to the type's `usable_cache_gb`. Defaults to the type's `usable_cache_gb`."
                  },
                  "eviction_policy": {
                    "type": "string",
                    "enum": [
                      "least_frequently_used",
                      "least_recently_used"
                    ],
                    "description": "Which cached objects we remove first when the cache is full.",
                    "x-enum-descriptions": {
                      "least_frequently_used": "Removes the objects read least often, so a frequently read object survives a flood of one-off reads.",
                      "least_recently_used": "Removes the objects read longest ago, which suits workloads that scan through data."
                    },
                    "default": "least_frequently_used"
                  },
                  "cache_ttl_seconds": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How long we keep an object in the cache, in seconds, from 60 to 2592000.",
                    "default": 86400
                  },
                  "listing_cache_ttl_seconds": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How long we keep a bucket listing in the cache, in seconds, from 0 to 86400. `0` turns listing caching off.",
                    "default": 0
                  },
                  "fsync": {
                    "type": "boolean",
                    "description": "Whether a write waits until your storage provider has stored the object. With `false`, a write is confirmed once the object cache has saved it to its own disk, and the object is uploaded to your storage provider later.",
                    "default": true
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term. Defaults to `monthly`.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "default": "monthly"
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  },
                  "buckets": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "description": "The bucket name clients use with the object cache, 3–63 lowercase letters, digits, dots and hyphens, starting and ending with a letter or digit. Must be unique in the object cache. Defaults to `origin_bucket`."
                        },
                        "origin_endpoint": {
                          "type": "string",
                          "description": "The HTTPS URL of your storage provider's S3 endpoint, such as `https://s3.eu-central-1.amazonaws.com`. Must use a hostname, not an IP address. Can't have credentials, a path, a query or a fragment."
                        },
                        "origin_bucket": {
                          "type": "string",
                          "description": "The name of the bucket at your storage provider, at most 255 characters."
                        },
                        "origin_prefix": {
                          "type": "string",
                          "description": "A folder in the bucket at your storage provider to serve as the whole bucket, such as `tenant-a/`. Clients see only the objects under it. Leave it out to serve the whole bucket."
                        },
                        "origin_region": {
                          "type": "string",
                          "description": "The region of your storage provider, such as `us-east-1` or `auto`. Defaults to `us-east-1`."
                        },
                        "origin_force_path_style": {
                          "type": "boolean",
                          "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname. Defaults to `true`."
                        },
                        "origin_access_key_id": {
                          "type": "string",
                          "description": "The access key ID for your storage provider."
                        },
                        "origin_secret_access_key": {
                          "type": "string",
                          "description": "The secret key for your storage provider."
                        }
                      },
                      "required": [
                        "origin_endpoint",
                        "origin_bucket",
                        "origin_access_key_id",
                        "origin_secret_access_key"
                      ]
                    },
                    "description": "The buckets to serve, from 1 to 20. Each bucket maps a bucket name to a bucket at your storage provider, with its keys. We never return the keys.",
                    "x-sensitive": true,
                    "x-cli-input": {
                      "order": 40
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name",
                  "type",
                  "buckets"
                ]
              },
              "examples": {
                "create_an_object_cache": {
                  "summary": "Create an object cache",
                  "value": {
                    "team_id": "t123",
                    "name": "my-cache",
                    "type": "OP100",
                    "buckets": [
                      {
                        "origin_endpoint": "https://s3.us-west-2.amazonaws.com",
                        "origin_bucket": "my-bucket",
                        "origin_access_key_id": "your-access-key-id",
                        "origin_secret_access_key": "your-secret-access-key"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-cli-wait": {
          "observe": "get_object_cache",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created object cache reports running; not client connectivity or object contents"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{id}": {
      "delete": {
        "operationId": "delete_object_cache",
        "summary": "Delete an object cache.",
        "description": "The object cache is `destroyed` at once.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/object-proxies/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_object_cache",
        "summary": "Get an object cache.",
        "description": "Get its S3 keys via [Get an object cache's credentials](/docs/cloud/api/object-caches/credentials-object-cache/).",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-cli-wait": {
          "observe": "get_object_cache",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the object cache currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_object_cache",
        "summary": "Update an object cache's name, tags, cache settings, `public_access` or billing term.",
        "description": "The change applies shortly after the response. `config_applied_at` says when the object cache last applied its settings.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/object-proxies/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single object_cache. (the request changes `public_access`)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ObjectCacheUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-cli-wait": {
          "observe": "get_object_cache",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_object_cache",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "when": {
            "all": [
              {
                "path": [
                  "public_access"
                ],
                "in": [
                  true,
                  false
                ]
              },
              {
                "not": {
                  "path": [
                    "public_access"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "public_access"
                    ]
                  }
                }
              }
            ]
          },
          "success": {
            "not": {
              "path": [
                "config_applied_at"
              ],
              "expected": {
                "source": "before",
                "path": [
                  "config_applied_at"
                ]
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "When the request changes public_access, the object cache applied a new configuration after the request, as config_applied_at shows. Other changes are sent without waiting. A sync already running when the request arrived can also end the wait, and DNS for the public hostname and client connectivity are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{id}/credentials": {
      "get": {
        "operationId": "credentials_object_cache",
        "summary": "Get the S3 keys and endpoint URLs that clients use to connect to an object cache.",
        "description": "You can get them again at any time.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the keys and endpoint URLs as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "access_key_id": {
                      "type": "string",
                      "description": "The access key ID.",
                      "x-sensitive": true
                    },
                    "secret_access_key": {
                      "type": "string",
                      "description": "The secret access key.",
                      "x-sensitive": true
                    },
                    "endpoints": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is on."
                    },
                    "previous_access_key_id": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The previous access key ID, which keeps working until `rotating_until`, or `null` when no rotation is in progress.",
                      "x-sensitive": true
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous key stops working, or `null` when no rotation is in progress."
                    },
                    "usage": {
                      "type": "string",
                      "description": "An example command for the AWS CLI. Clients must use path-style addressing."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "access_key_id",
          "secret_access_key",
          "endpoints",
          "previous_access_key_id",
          "rotating_until",
          "usage"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/object-proxies/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_object_cache_credentials",
        "summary": "Create new S3 keys for an object cache.",
        "description": "The old keys keep working for `grace_seconds`. The object cache must be `running` or `degraded`.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache whose credentials to rotate. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the new keys and the endpoint URLs as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "access_key_id": {
                      "type": "string",
                      "description": "The new access key ID.",
                      "x-sensitive": true
                    },
                    "secret_access_key": {
                      "type": "string",
                      "description": "The new secret access key.",
                      "x-sensitive": true
                    },
                    "endpoints": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is on."
                    },
                    "previous_access_key_id": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The previous access key ID, which keeps working until `rotating_until`, or `null` when `grace_seconds` is `0`.",
                      "x-sensitive": true
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous key stops working."
                    },
                    "usage": {
                      "type": "string",
                      "description": "An example command for the AWS CLI. Clients must use path-style addressing."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "grace_seconds": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How long the old keys keep working, in seconds, from 0 to 86400. Defaults to `86400`, one day. Send `0` to stop them at once, such as when the keys leaked.",
                    "default": 86400
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-response-fields": [
          "access_key_id",
          "secret_access_key",
          "endpoints",
          "previous_access_key_id",
          "rotating_until",
          "usage"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/object-proxies/{id}/firewalls": {
      "post": {
        "operationId": "attach_object_cache_firewall",
        "summary": "Attach a firewall to an object cache.",
        "description": "The firewall must be in the object cache's team. An object cache can have one firewall. We apply its rules shortly after the response.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache to attach the firewall to. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach. Get it via [List firewalls](/docs/cloud/api/firewalls/list-firewalls/)."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_object_cache_firewall",
        "summary": "Detach a firewall from an object cache.",
        "description": "We remove its rules shortly after the response.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/object-proxies/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache to detach the firewall from. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/object-proxies/{id}/networks": {
      "post": {
        "operationId": "attach_object_cache_network",
        "summary": "Attach one of your private networks to an object cache.",
        "description": "The network must be in the object cache's team. We add an endpoint in the network shortly after the response.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache to attach the network to. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach. Get it via [List networks](/docs/cloud/api/networks/list-networks/)."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-cli-wait": {
          "observe": "get_object_cache",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_object_cache",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "not": {
                  "path": [
                    "network_ids"
                  ],
                  "every": {
                    "not": {
                      "path": [],
                      "expected": {
                        "source": "request",
                        "path": [
                          "network_id"
                        ]
                      }
                    }
                  }
                }
              },
              {
                "not": {
                  "path": [
                    "config_applied_at"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "config_applied_at"
                    ]
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The network is attached and config_applied_at moved past its value from before the request, so the object cache applied a configuration that opens its port to the network. A sync already running when the request arrived can also end the wait, and the network interface on the server is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_object_cache_network",
        "summary": "Detach a private network from an object cache.",
        "description": "We remove the object cache's endpoint from the network shortly after the response.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/object-proxies/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache to detach the network from. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/object-proxies/{id}/purge": {
      "post": {
        "operationId": "purge_object_cache",
        "summary": "Remove cached objects from an object cache, for every bucket, one bucket or a key prefix in it.",
        "description": "We remove them shortly after the response. The object cache must be `running` or `degraded`.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:id/purge",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "bucket": {
                    "type": "string",
                    "description": "The name of the bucket to purge. Leave it out to purge every bucket."
                  },
                  "prefix": {
                    "type": "string",
                    "description": "Purge the keys that start with this prefix. Leave it out to purge every key."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{id}/rescale": {
      "post": {
        "operationId": "rescale_object_cache",
        "summary": "Change an object cache's type.",
        "description": "The cached objects are kept. The object cache must be `running` or `degraded`. The object cache's `max_capacity_gb` must fit in the new type.",
        "tags": [
          "object_cache"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single object_cache.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `max_capacity_gb` is larger than the new type's cache space, with the code `does_not_fit`. Lower `max_capacity_gb` first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type, such as `OP500`. Get the types via [List object cache types](/docs/cloud/api/object-cache-types/list-object-cache-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_object_cache_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_cache_gb"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "usable_cache_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_cache_gb",
          "status",
          "status_message",
          "eviction_policy",
          "max_capacity_gb",
          "cache_ttl_seconds",
          "listing_cache_ttl_seconds",
          "fsync",
          "public_access",
          "public_ipv4",
          "placement_group_id",
          "cache_used_gb",
          "config_applied_at",
          "endpoints",
          "buckets",
          "network_ids",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache.list"
        },
        "x-cli-wait": {
          "observe": "get_object_cache",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "type"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the object cache reports running with its backing server on the requested plan; not subsequent cache sync or client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{object_proxy_id}/buckets": {
      "get": {
        "operationId": "list_object_cache_bucket",
        "summary": "List the buckets an object cache serves.",
        "description": "Returns every bucket in one page.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies/:object_proxy_id/buckets",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of object_cache_bucket objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheBucketList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket",
          "origin_prefix",
          "origin_region",
          "origin_force_path_style",
          "origin_creation_date",
          "scoped_credentials",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_bucket.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_object_cache_bucket",
        "summary": "Add a bucket to an object cache.",
        "description": "We first check that we can reach the bucket at your storage provider with its keys. The new bucket gets its own access keys. An object cache serves at most 20 buckets.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:object_proxy_id/buckets",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single object_cache_bucket.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheBucketDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "We couldn't reach the bucket at your storage provider with its keys, with the code `origin_check_failed`. A field is missing or isn't valid, or the object cache already serves 20 buckets.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ObjectCacheBucketCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket",
          "origin_prefix",
          "origin_region",
          "origin_force_path_style",
          "origin_creation_date",
          "scoped_credentials",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_bucket.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{object_proxy_id}/buckets/{id}": {
      "delete": {
        "operationId": "delete_object_cache_bucket",
        "summary": "Remove a bucket from an object cache.",
        "description": "We delete its cached objects in the background. An object cache must keep at least one bucket.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/object-proxies/:object_proxy_id/buckets/:id",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The bucket is the object cache's only bucket, with the code `last_bucket`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "operationId": "update_object_cache_bucket",
        "summary": "Update a bucket's keys for your storage provider, its region or `origin_force_path_style`.",
        "description": "You can send one key without the other. We check that new keys work before we save them.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/object-proxies/:object_proxy_id/buckets/:id",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single object_cache_bucket.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheBucketDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request sends `name`, `origin_endpoint`, `origin_bucket` or `origin_prefix`, which can't be changed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ObjectCacheBucketUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "origin_endpoint",
          "origin_bucket",
          "origin_prefix",
          "origin_region",
          "origin_force_path_style",
          "origin_creation_date",
          "scoped_credentials",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_bucket.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxies/{object_proxy_id}/buckets/{id}/credentials": {
      "get": {
        "operationId": "credentials_object_cache_bucket",
        "summary": "Get the access keys of an object cache bucket.",
        "description": "The keys work for this bucket only. You can get them again at any time.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies/:object_proxy_id/buckets/:id/credentials",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the bucket's own access keys and the object cache's URLs as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "bucket": {
                      "type": "string",
                      "description": "The bucket's `name`."
                    },
                    "access_key_id": {
                      "type": "string",
                      "description": "The bucket's access key ID.",
                      "x-sensitive": true
                    },
                    "secret_access_key": {
                      "type": "string",
                      "description": "The bucket's secret access key.",
                      "x-sensitive": true
                    },
                    "endpoints": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The object cache's endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is `true`."
                    },
                    "previous_access_key_id": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The previous access key ID, which still works until `rotating_until`, or `null` when no rotation is in progress.",
                      "x-sensitive": true
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous access key stops working, or `null` when no rotation is in progress."
                    },
                    "usage": {
                      "type": "string",
                      "description": "An example AWS CLI command that lists the bucket. Clients must send the bucket name in the URL path."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The bucket has no access keys of its own yet, with the code `no_credentials`. Create them with [Rotate an object cache bucket's credentials](/docs/cloud/api/object-cache-buckets/rotate-object-cache-bucket-credentials/).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The object cache is deleted, with the code `object_proxy_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "bucket",
          "access_key_id",
          "secret_access_key",
          "endpoints",
          "previous_access_key_id",
          "rotating_until",
          "usage"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_bucket.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/object-proxies/{object_proxy_id}/buckets/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_object_cache_bucket_credentials",
        "summary": "Create new access keys for an object cache bucket, or its first ones.",
        "description": "The old keys keep working for `grace_seconds`. The object cache must be `running` or `degraded`.",
        "tags": [
          "object_cache_bucket"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/object-proxies/:object_proxy_id/buckets/:id/credentials/rotate",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache bucket whose credentials to rotate. Get it via [List object cache buckets](/docs/cloud/api/object-cache-buckets/list-object-cache-buckets/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the bucket's new access keys and the object cache's URLs as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "bucket": {
                      "type": "string",
                      "description": "The bucket's `name`."
                    },
                    "access_key_id": {
                      "type": "string",
                      "description": "The bucket's new access key ID.",
                      "x-sensitive": true
                    },
                    "secret_access_key": {
                      "type": "string",
                      "description": "The bucket's new secret access key.",
                      "x-sensitive": true
                    },
                    "endpoints": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The object cache's endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is `true`."
                    },
                    "previous_access_key_id": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The previous access key ID, which still works until `rotating_until`, or `null` when no rotation is in progress.",
                      "x-sensitive": true
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous access key stops working, or `null` when no rotation is in progress."
                    },
                    "usage": {
                      "type": "string",
                      "description": "An example AWS CLI command that lists the bucket. Clients must send the bucket name in the URL path."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The object cache is deleted, with the code `object_proxy_destroyed`. The object cache isn't `running` or `degraded`, with the code `object_proxy_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `grace_seconds` isn't between 0 and 86400, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "grace_seconds": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How long the old keys keep working, in seconds, from 0 to 86400. Defaults to `86400`, one day. Send `0` to stop them at once, such as when the keys leaked.",
                    "default": 86400
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-response-fields": [
          "bucket",
          "access_key_id",
          "secret_access_key",
          "endpoints",
          "previous_access_key_id",
          "rotating_until",
          "usage"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_bucket.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/object-proxies/{object_proxy_id}/events": {
      "get": {
        "operationId": "list_object_cache_event",
        "summary": "List an object cache's events.",
        "description": "You can still list them after the object cache is deleted.",
        "tags": [
          "object_cache_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxies/:object_proxy_id/events",
        "parameters": [
          {
            "name": "object_proxy_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the object cache. Get it via [List object caches](/docs/cloud/api/object-caches/list-object-caches/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of object_cache_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "object_proxy_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/object-proxy-types": {
      "get": {
        "operationId": "list_object_cache_type",
        "summary": "List the object cache types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "object_cache_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxy-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of object_cache_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_cache_gb",
          "max_cached_entries"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_cache_gb",
          "max_cached_entries",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/object-proxy-types/{name}": {
      "get": {
        "operationId": "get_object_cache_type",
        "summary": "Get an object cache type by its name, including a deprecated type that has a replacement.",
        "tags": [
          "object_cache_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/object-proxy-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `OP100`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single object_cache_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ObjectCacheTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_cache_gb",
          "max_cached_entries"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_cache_gb",
          "max_cached_entries",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.object_cache_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/otlp": {
      "get": {
        "operationId": "list_otlp",
        "summary": "List the OTLP exports in this zone.",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/otlp",
        "parameters": [
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "Only exports of the team with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of otlp objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OtlpList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "endpoint",
          "status",
          "last_delivered_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "endpoint",
          "header_names",
          "resource_types",
          "temporality",
          "status",
          "paused_reason",
          "last_delivered_at",
          "last_error",
          "last_error_at",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.otlp.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_otlp",
        "summary": "Create an OTLP export.",
        "description": "The export sends metrics from the time you create it. To check that the receiver accepts the metrics, use [Test an OTLP export](/docs/cloud/api/otlps/test-otlp/).",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/otlp",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single otlp.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OtlpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of OTLP exports in this zone, with the code `quota_exceeded`. Paused exports count too.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the team in `team_id`, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id`, `name`, `endpoint` or `resource_types`, a value isn't valid, another export in the organization has the name, or the endpoint or a header is refused, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OtlpCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "endpoint",
          "status",
          "last_delivered_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "endpoint",
          "header_names",
          "resource_types",
          "temporality",
          "status",
          "paused_reason",
          "last_delivered_at",
          "last_error",
          "last_error_at",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.otlp.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/otlp/{id}": {
      "delete": {
        "operationId": "delete_otlp",
        "summary": "Remove an OTLP export.",
        "description": "The export stops sending metrics.",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/otlp/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_otlp",
        "summary": "Get an OTLP export, with its status and its last delivery or error.",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/otlp/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single otlp.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OtlpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "endpoint",
          "status",
          "last_delivered_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "endpoint",
          "header_names",
          "resource_types",
          "temporality",
          "status",
          "paused_reason",
          "last_delivered_at",
          "last_error",
          "last_error_at",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.otlp.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_otlp",
        "summary": "Update an OTLP export.",
        "description": "Set `status` to `paused` to stop it, or to `active` to resume it.",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/otlp/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single otlp.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OtlpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, another export in the organization has the name, or the endpoint or a header is refused, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OtlpUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "endpoint",
          "status",
          "last_delivered_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "endpoint",
          "header_names",
          "resource_types",
          "temporality",
          "status",
          "paused_reason",
          "last_delivered_at",
          "last_error",
          "last_error_at",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.otlp.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/otlp/{id}/test": {
      "post": {
        "operationId": "test_otlp",
        "summary": "Send one data point to the receiver now, named `betterstack.otlp.test` with the value `1`.",
        "description": "We wait up to 5 seconds for the receiver's response. The test doesn't change the export's status or last delivery. You can test a paused export too.",
        "tags": [
          "otlp"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/otlp/:id/test",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single otlp.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/OtlpDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "meta": {
                          "type": "object",
                          "properties": {
                            "delivered": {
                              "type": "boolean",
                              "description": "Whether the receiver accepted the data point."
                            },
                            "http_status": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "format": "int64",
                              "description": "The HTTP status the receiver returned, or `null` when no response arrived."
                            },
                            "error": {
                              "type": [
                                "string",
                                "null"
                              ],
                              "description": "Why the test failed, such as HTTP 401, or how many data points the receiver rejected. `error` is `null` when the test went through without a problem."
                            }
                          }
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Your organization sent more than 30 OTLP tests in the current minute, with the code `rate_limited`. The `Retry-After` header says how many seconds to wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "endpoint",
          "status",
          "last_delivered_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "endpoint",
          "header_names",
          "resource_types",
          "temporality",
          "status",
          "paused_reason",
          "last_delivered_at",
          "last_error",
          "last_error_at",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.otlp.list"
        },
        "x-response-envelope": {
          "item_path": [
            "data"
          ],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/placement-groups": {
      "get": {
        "operationId": "list_placement_group",
        "summary": "List the placement groups in this zone.",
        "description": "Filter by part of a name or by tags.",
        "tags": [
          "placement_group"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/placement-groups",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only groups whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only groups with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match groups that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of placement_group objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PlacementGroupList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "placement_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "placement_type",
          "server_ids",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.placement_group.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_placement_group",
        "summary": "Create a placement group.",
        "description": "A new placement group is ready at once and starts empty.",
        "tags": [
          "placement_group"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/placement-groups",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single placement_group.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PlacementGroupDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of placement groups, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the team in `team_id`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id`, `name` or `placement_type`, or its `placement_type` isn't `spread` or `compact`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PlacementGroupCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "placement_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "placement_type",
          "server_ids",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.placement_group.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/placement-groups/{id}": {
      "delete": {
        "operationId": "delete_placement_group",
        "summary": "Remove a placement group.",
        "description": "The placement group must be empty, so delete its servers first.",
        "tags": [
          "placement_group"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/placement-groups/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The group still has servers in it, with the code `placement_group_in_use`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_placement_group",
        "summary": "Get a placement group, with its placement type and the servers in it.",
        "tags": [
          "placement_group"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/placement-groups/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single placement_group.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PlacementGroupDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "placement_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "placement_type",
          "server_ids",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.placement_group.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_placement_group",
        "summary": "Update a placement group's `name` or `metadata`.",
        "description": "Any other field in the body is ignored.",
        "tags": [
          "placement_group"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/placement-groups/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single placement_group.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PlacementGroupDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PlacementGroupUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "placement_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "placement_type",
          "server_ids",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.placement_group.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres": {
      "get": {
        "operationId": "list_postgres",
        "summary": "List your PostgreSQL instances in this zone.",
        "description": "The list includes `failed` and `destroyed` instances.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "upgrading",
                "restoring",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only instances with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the instance with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only instances whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only instances with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match instances that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_postgres",
        "summary": "Create a PostgreSQL instance with its first database and an `admin` user.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the PostgreSQL instance. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of PostgreSQL instances, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, type, network or firewall doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another PostgreSQL action is running in your organization at the same time, with the code `concurrent_create_limit`. Or we couldn't set up the instance, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created instance reports running; not client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres-snapshots": {
      "get": {
        "operationId": "list_flat_postgres_snapshot",
        "summary": "List the snapshots of all your PostgreSQL instances.",
        "description": "The list includes snapshots of deleted instances.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres-snapshots",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the snapshots of the PostgreSQL instance with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_flat_postgres_snapshot",
        "summary": "Create a snapshot of the PostgreSQL instance in `postgres_id`.",
        "description": "The primary writes its pending changes to disk first, so the snapshot is consistent.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres-snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance in `postgres_id` doesn't exist, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance can't be snapshotted in its current state, or a snapshot of it is already being created, with the code `postgres_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `postgres_id`, or the `name` isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another snapshot is being created in your organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "postgres_id": {
                    "type": "string",
                    "description": "The ID of the PostgreSQL instance to create a snapshot of.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_postgres",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `db-2026-11-24`.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
                  }
                },
                "required": [
                  "postgres_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_postgres_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres-snapshots/{id}": {
      "delete": {
        "operationId": "delete_flat_postgres_snapshot",
        "summary": "Delete an `available` or `failed` PostgreSQL snapshot by its ID alone, even after its instance is deleted.",
        "description": "The snapshot's status is `deleting` until the snapshot is removed.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_postgres_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_flat_postgres_snapshot",
        "summary": "Get a PostgreSQL snapshot by its ID alone, even after its instance is deleted.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres-snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_flat_postgres_snapshot",
        "summary": "Restore an `available` snapshot into a new PostgreSQL instance, by the snapshot's ID alone.",
        "description": "The instance the snapshot was taken from must still exist.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres-snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, was saved without its instance's settings, or its instance is deleted, with the code `snapshot_not_restorable`. The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres-types": {
      "get": {
        "operationId": "list_postgres_type",
        "summary": "List the PostgreSQL types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "postgres_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of postgres_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_storage_gb",
          "max_connections",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/postgres-types/{name}": {
      "get": {
        "operationId": "get_postgres_type",
        "summary": "Get a PostgreSQL type by its name.",
        "description": "You can also get a deprecated type that has a replacement.",
        "tags": [
          "postgres_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `PG1`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_storage_gb",
          "max_connections",
          "vcpu",
          "ram_gb"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "vcpu",
          "ram_gb",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/postgres-versions": {
      "get": {
        "operationId": "list_postgres_version",
        "summary": "List the PostgreSQL major versions we offer.",
        "description": "An instance's `available_engine_versions` lists the ones it can upgrade to.",
        "tags": [
          "postgres_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of postgres_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_version.list"
        },
        "x-response-envelope": {
          "list_path": [
            "versions"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/postgres/{id}": {
      "delete": {
        "operationId": "delete_postgres",
        "summary": "Delete an instance.",
        "description": "The instance's status becomes `destroyed` at once, and its nodes are removed in the background.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_postgres",
        "summary": "Get a PostgreSQL instance.",
        "description": "Get the `admin` user's password via [Get a PostgreSQL instance's credentials](/docs/cloud/api/postgreses/credentials-postgres/).",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_postgres",
        "summary": "Update an instance's name, tags, PostgreSQL settings, `public_access`, `replica_count` or billing term.",
        "description": "The PostgreSQL settings apply without a restart.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/postgres/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single postgres. (`public_access` or `replica_count` changes)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "when": {
            "path": [
              "replica_count"
            ],
            "at_least": {
              "source": "literal",
              "value": 0
            }
          },
          "success": {
            "all": [
              {
                "any": [
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 0
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 3
                        }
                      }
                    ]
                  }
                ]
              },
              {
                "path": [
                  "replica_count"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "replica_count"
                  ]
                }
              },
              {
                "path": [
                  "members"
                ],
                "every": {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "When the request sets replica_count, the instance has that many replicas and every member reports running. A change of only public_access or other settings is sent without waiting."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/credentials": {
      "get": {
        "operationId": "credentials_postgres",
        "summary": "Get the `admin` user's password, the URIs to connect with and the `ca_certificate` to verify the instance with.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the `admin` user's connection details.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name, `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The user's password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The database the URIs connect to, `defaultdb` when the instance has it, or else the first database by name."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect straight to PostgreSQL from your private networks, with the password and `sslmode=verify-full`.",
                      "x-sensitive": true
                    },
                    "pooled_uri": {
                      "type": "string",
                      "description": "The URI to connect through PgBouncer from your private networks, with the password and `sslmode=verify-full`.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect straight to PostgreSQL from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "public_pooled_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect through PgBouncer from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance is destroyed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "pooled_uri",
          "public_uri",
          "public_pooled_uri",
          "ca_certificate"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/postgres/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_postgres_credentials",
        "summary": "Replace the `admin` user's password with a new generated one.",
        "description": "Open connections keep working. New connections need the new password at once.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance whose credentials to rotate.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the `admin` user's connection details with the new password.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name, `admin`."
                    },
                    "password": {
                      "type": "string",
                      "description": "The new password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The database the URIs connect to."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect straight to PostgreSQL from your private networks, with the new password.",
                      "x-sensitive": true
                    },
                    "pooled_uri": {
                      "type": "string",
                      "description": "The URI to connect through PgBouncer from your private networks, with the new password.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect straight to PostgreSQL from the internet, with the new password, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "public_pooled_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect through PgBouncer from the internet, with the new password, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "pooled_uri",
          "public_uri",
          "public_pooled_uri",
          "ca_certificate"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/postgres/{id}/failover": {
      "post": {
        "operationId": "failover_postgres",
        "summary": "Make the most up-to-date running replica the new primary.",
        "description": "The primary and at least one replica must be running. Every write the primary confirmed is kept. The instance's status stays `running` throughout.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/failover",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance to fail over.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_postgres",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "members"
            ],
            "matching": {
              "source": "before",
              "path": [
                "members"
              ]
            },
            "match_by": "id",
            "every": {
              "any": [
                {
                  "path": [
                    "role"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "replica"
                  }
                },
                {
                  "all": [
                    {
                      "not": {
                        "path": [
                          "role"
                        ],
                        "expected": {
                          "source": "matched",
                          "path": [
                            "role"
                          ]
                        }
                      }
                    },
                    {
                      "path": [
                        "role"
                      ],
                      "expected": {
                        "source": "literal",
                        "value": "primary"
                      }
                    }
                  ]
                }
              ]
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The former primary is now a replica and a former replica is the primary. The endpoint's DNS and the old primary catching up are not verified, and a failover Cloud skips leaves the wait running until it times out."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/firewalls": {
      "post": {
        "operationId": "attach_postgres_firewall",
        "summary": "Attach a firewall to every node of the instance.",
        "description": "The firewall must be in the instance's team. An instance can have at most one firewall.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance to attach the firewall to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_postgres_firewall",
        "summary": "Detach a firewall from every node of the instance.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance to detach the firewall from.",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/postgres/{id}/metrics": {
      "get": {
        "operationId": "metrics_postgres",
        "summary": "Get each node's transactions, writes, connections, cache hit ratio, disk use and replication lag over time.",
        "description": "Defaults to the last day. A range can be at most 366 days.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range. Defaults to now."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns each node's metrics over time.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "postgres_id": {
                      "type": "string",
                      "description": "The instance's ID."
                    },
                    "postgres_name": {
                      "type": "string",
                      "description": "The instance's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range returned."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range returned."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the points are.",
                      "x-enum-descriptions": {
                        "raw": "One point per minute, for a range of up to one day.",
                        "hourly": "One point per hour, for a longer range."
                      }
                    },
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "member_id": {
                            "type": "string"
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "primary",
                              "replica"
                            ],
                            "description": "Whether the node is the primary or a replica.\n\n- `primary`: The node that accepts writes.\n- `replica`: A read-only copy of the primary.",
                            "x-enum-descriptions": {
                              "primary": "The node that accepts writes.",
                              "replica": "A read-only copy of the primary."
                            }
                          },
                          "data": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "dt": {
                                  "type": "string",
                                  "format": "date-time"
                                },
                                "transactions_per_second": {
                                  "type": "number"
                                },
                                "writes_per_second": {
                                  "type": "number"
                                },
                                "connections": {
                                  "type": "object",
                                  "properties": {
                                    "direct": {
                                      "type": "number"
                                    },
                                    "direct_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "pooled": {
                                      "type": "number"
                                    },
                                    "pooled_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "max_connections": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "max_pooled_connections": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "cache_hit_ratio": {
                                  "type": "number"
                                },
                                "disk": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64"
                                    },
                                    "usable_bytes": {
                                      "type": "integer",
                                      "format": "int64"
                                    }
                                  }
                                },
                                "replication_lag_seconds": {
                                  "type": "number"
                                }
                              }
                            }
                          }
                        }
                      },
                      "description": "Each node's metrics over time. Every point has the transaction and write rates, the connections straight to PostgreSQL and through PgBouncer, the cache hit ratio, the disk use and the replication lag."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "postgres_id",
          "postgres_name",
          "from",
          "to",
          "resolution",
          "members"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/postgres/{id}/networks": {
      "post": {
        "operationId": "attach_postgres_network",
        "summary": "Attach a private network to every node of the instance.",
        "description": "The network must be in the instance's team.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance to attach the network to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_postgres_network",
        "summary": "Detach a private network from every node of the instance.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance to detach the network from.",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/postgres/{id}/rescale": {
      "post": {
        "operationId": "rescale_postgres",
        "summary": "Change the instance's type.",
        "description": "Your data must use at most 80% of the new type's `usable_storage_gb`. A disk never shrinks, even on a smaller type. If the rescale doesn't finish, the instance returns to `running` with a `status_message`.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The name of the new PostgreSQL type. Must differ from the current type. Get the types via [List PostgreSQL types](/docs/cloud/api/postgres-types/list-postgres-types/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_postgres_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_storage_gb",
                        "max_connections"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Every member was resized to the new type and the instance is back to running. Disk growth inside the members is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/restore": {
      "post": {
        "operationId": "restore_postgres",
        "summary": "Restore the instance from one of its own `available` snapshots.",
        "description": "Every change made after the snapshot is lost. The replicas are rebuilt.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of a snapshot of this instance. Get the snapshots via [List a PostgreSQL instance's snapshots](/docs/cloud/api/postgres-snapshots/list-postgres-snapshots/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_postgres_snapshot",
                      "bindings": {
                        "postgres_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "status",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance returned to running after accepted restore; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_postgres",
        "summary": "Upgrade the instance to a newer PostgreSQL major version.",
        "description": "We create a snapshot of the instance first. The upgrade can't be undone. The instance is `running` again both when the upgrade finishes and when the upgrade stops partway. Check `status_message`, which says when the upgrade didn't finish or the replicas are still being rebuilt.",
        "tags": [
          "postgres"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/PostgresDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "pre_upgrade_snapshot_id": {
                          "type": "string",
                          "description": "The ID of the snapshot we created before the upgrade."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "engine_version": {
                    "type": "string",
                    "description": "The major version to upgrade to, one of the instance's `available_engine_versions`."
                  }
                },
                "required": [
                  "engine_version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "pre_upgrade_snapshot_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.upgrade"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "engine_version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "engine_version"
                  ]
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the upgrade could not be completed; the instance keeps serving its current version — retry the upgrade"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "any": [
                    {
                      "not": {
                        "path": [
                          "engine_version"
                        ],
                        "expected": {
                          "source": "request",
                          "path": [
                            "engine_version"
                          ]
                        }
                      }
                    },
                    {
                      "path": [
                        "status_message"
                      ],
                      "expected": {
                        "source": "literal",
                        "value": "the upgrade could not be completed; the instance keeps serving its current version — retry the upgrade"
                      }
                    }
                  ]
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The instance is back to running on the requested version. Replicas rebuilding after the upgrade, extensions and your data are not verified."
        },
        "x-cli-one-time-fields": [
          "pre_upgrade_snapshot_id"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/databases": {
      "get": {
        "operationId": "list_postgres_database",
        "summary": "List a PostgreSQL instance's databases.",
        "description": "Returns every database in one page.",
        "tags": [
          "postgres_database"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/databases",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_database objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDatabaseList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_database.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_postgres_database",
        "summary": "Create a database with `UTF8` encoding and the `C.UTF-8` locale.",
        "description": "Clients can also reach the database through PgBouncer, under the same name. The database is ready a few seconds after the response. An instance can have at most 25 databases.",
        "tags": [
          "postgres_database"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/databases",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_database.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDatabaseDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance must be `running` or `degraded` to add a database.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Too many databases are being created at the same time. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresDatabaseCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_database.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/databases/{id}": {
      "delete": {
        "operationId": "delete_postgres_database",
        "summary": "Delete a database and all its data.",
        "description": "The database's open connections are closed first. The database is removed from every user's `privileges`. An instance must keep at least one database.",
        "tags": [
          "postgres_database"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:postgres_id/databases/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, or this is its last database.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't delete the database. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/postgres/{postgres_id}/events": {
      "get": {
        "operationId": "list_postgres_event",
        "summary": "List a PostgreSQL instance's events.",
        "description": "You can still list them after the instance is deleted.",
        "tags": [
          "postgres_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/events",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/scheduled-snapshots": {
      "get": {
        "operationId": "list_postgres_scheduled_snapshot",
        "summary": "List a PostgreSQL instance's snapshot schedules.",
        "tags": [
          "postgres_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "postgres_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_postgres_scheduled_snapshot",
        "summary": "Create a snapshot schedule for a PostgreSQL instance.",
        "description": "The instance must be `running` or `degraded` and have a primary. The schedule counts toward your organization's limit of snapshot schedules.",
        "tags": [
          "postgres_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single postgres_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "postgres_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_postgres_scheduled_snapshot",
        "summary": "Delete a snapshot schedule.",
        "description": "The snapshots the schedule already created are kept.",
        "tags": [
          "postgres_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:postgres_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_postgres_scheduled_snapshot",
        "summary": "Get a snapshot schedule of a PostgreSQL instance.",
        "tags": [
          "postgres_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "postgres_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_postgres_scheduled_snapshot",
        "summary": "Change how often a snapshot schedule creates snapshots.",
        "tags": [
          "postgres_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/postgres/:postgres_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "postgres_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/snapshots": {
      "get": {
        "operationId": "list_postgres_snapshot",
        "summary": "List a PostgreSQL instance's snapshots, with their status and size.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/snapshots",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_postgres_snapshot",
        "summary": "Create a snapshot of a PostgreSQL instance.",
        "description": "The primary writes its pending changes to disk first, so the snapshot is consistent.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/snapshots",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "postgres_id": {
              "source": "params",
              "path": [
                "postgres_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/snapshots/{id}": {
      "delete": {
        "operationId": "delete_postgres_snapshot",
        "summary": "Delete an `available` or `failed` snapshot.",
        "description": "The snapshot's status is `deleting` until the snapshot is removed.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:postgres_id/snapshots/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "postgres_id": {
              "source": "params",
              "path": [
                "postgres_id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_postgres_snapshot",
        "summary": "Get a snapshot of a PostgreSQL instance.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/snapshots/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single postgres_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "postgres_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "postgres_id",
          "server_id",
          "name",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "postgres_id": {
              "source": "params",
              "path": [
                "postgres_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_postgres_snapshot",
        "summary": "Restore an `available` snapshot into a new PostgreSQL instance in the same team and zone.",
        "description": "The new instance has the snapshot's type, settings, databases, users and networks. The new instance gets new IDs, a new hostname and a new certificate. Every user gets a new password. `public_access` is off on the new instance.",
        "tags": [
          "postgres_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/snapshots/:id/restore",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_storage_gb",
          "max_connections",
          "max_pooled_connections",
          "engine_version",
          "engine_patch_version",
          "available_engine_versions",
          "status",
          "status_message",
          "statement_timeout",
          "idle_in_transaction_session_timeout",
          "work_mem_mb",
          "log_min_duration_statement",
          "public_access",
          "replica_count",
          "read_only",
          "endpoint",
          "members",
          "databases",
          "users",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres.list"
        },
        "x-cli-wait": {
          "observe": "get_postgres",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/users": {
      "get": {
        "operationId": "list_postgres_user",
        "summary": "List the users of a PostgreSQL instance.",
        "description": "Returns every user in one page. Get a user's password via [Get a PostgreSQL user's credentials](/docs/cloud/api/postgres-users/credentials-postgres-user/).",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/users",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A list of postgres_user objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresUserList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_postgres_user",
        "summary": "Create a user with a strong generated password.",
        "description": "The user is added to PostgreSQL shortly after the response. Get the password via [Get a PostgreSQL user's credentials](/docs/cloud/api/postgres-users/credentials-postgres-user/). An instance can have up to 25 users.",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/users",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresUserDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, with the code `postgres_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another user is being created on this instance at the same time. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresUserCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/users/{id}": {
      "delete": {
        "operationId": "delete_postgres_user",
        "summary": "Delete a user.",
        "description": "The tables and other objects the user owns move to the default `admin` user. The default `admin` user can't be deleted. The instance must be `running` or `degraded`.",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/postgres/:postgres_id/users/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't remove the user from PostgreSQL. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "operationId": "update_postgres_user",
        "summary": "Replace a user's access to databases.",
        "description": "The change applies in PostgreSQL shortly after the response. The default `admin` user can't be updated. The instance must be `running` or `degraded`.",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/postgres/:postgres_id/users/:id",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single postgres_user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PostgresUserDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostgresUserUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "username",
          "default_user"
        ],
        "x-cli-name-fields": [
          "username"
        ],
        "x-cli-response-fields": [
          "id",
          "username",
          "default_user",
          "privileges",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_user.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/postgres/{postgres_id}/users/{id}/credentials": {
      "get": {
        "operationId": "credentials_postgres_user",
        "summary": "Get a user's password, the URIs to connect with and the `ca_certificate` to verify the instance with.",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/postgres/:postgres_id/users/:id/credentials",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the user's connection details.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name."
                    },
                    "password": {
                      "type": "string",
                      "description": "The user's password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The database the URIs connect to, `defaultdb` when the instance has it, or else the first database by name."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect straight to PostgreSQL from your private networks, with the password and `sslmode=verify-full`.",
                      "x-sensitive": true
                    },
                    "pooled_uri": {
                      "type": "string",
                      "description": "The URI to connect through the PgBouncer connection pool from your private networks, with the password and `sslmode=verify-full`.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect straight to PostgreSQL from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "public_pooled_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect through the PgBouncer connection pool from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "pooled_uri",
          "public_uri",
          "public_pooled_uri",
          "ca_certificate"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_user.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/postgres/{postgres_id}/users/{id}/reset-password": {
      "post": {
        "operationId": "reset_postgres_user_password",
        "summary": "Replace a user's password with a new generated one.",
        "description": "The new password works at once, and the old one stops working at once. Open connections stay open. The instance must be `running` or `degraded`.",
        "tags": [
          "postgres_user"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/postgres/:postgres_id/users/:id/reset-password",
        "parameters": [
          {
            "name": "postgres_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the PostgreSQL instance. Get it via [List PostgreSQL instances](/docs/cloud/api/postgreses/list-postgreses/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the user's connection details with the new password.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The user name."
                    },
                    "password": {
                      "type": "string",
                      "description": "The new password.",
                      "x-sensitive": true
                    },
                    "database": {
                      "type": "string",
                      "description": "The database the URIs connect to."
                    },
                    "uri": {
                      "type": "string",
                      "description": "The URI to connect straight to PostgreSQL from your private networks, with the new password.",
                      "x-sensitive": true
                    },
                    "pooled_uri": {
                      "type": "string",
                      "description": "The URI to connect through the PgBouncer connection pool from your private networks, with the new password.",
                      "x-sensitive": true
                    },
                    "public_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect straight to PostgreSQL from the internet, with the new password, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "public_pooled_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The URI to connect through the PgBouncer connection pool from the internet, with the new password, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": "string",
                      "description": "The CA certificate in PEM format, to verify the instance's certificate."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "password",
          "database",
          "uri",
          "pooled_uri",
          "public_uri",
          "public_pooled_uri",
          "ca_certificate"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.postgres_user.reset_password"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/quotas": {
      "get": {
        "operationId": "get_quota",
        "summary": "Get your organization's limits in this zone and how much of each it uses.",
        "description": "The numbers cover the whole organization, all teams together.",
        "tags": [
          "quota"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/quotas",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A single quota.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuotaDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "firewalls",
          "firewall_rules",
          "reserved_ipv4_addresses",
          "reserved_ipv6_addresses",
          "public_ipv4_addresses",
          "public_ipv6_addresses",
          "private_ips_per_server_per_network",
          "regular_vcpus",
          "spot_vcpus",
          "dedicated_vcpus",
          "ram_gb",
          "spot_servers",
          "regular_servers",
          "dedicated_servers",
          "servers_per_minute",
          "snapshots_per_minute",
          "volume_snapshots_per_minute",
          "rescales_per_minute",
          "api_requests_per_minute",
          "placement_group_count",
          "placement_group_servers",
          "volumes",
          "volume_storage_gb",
          "volume_snapshots",
          "snapshots",
          "snapshot_storage_gb",
          "volume_snapshot_storage_gb",
          "scheduled_snapshots",
          "scheduled_volume_snapshots",
          "ssh_keys",
          "webhooks",
          "otlps",
          "networks",
          "cloudflare_records",
          "load_balancers",
          "valkeys",
          "mysqls",
          "postgres_instances",
          "clickhouses",
          "kafkas",
          "object_proxies",
          "certificates",
          "kubernetes_control_planes",
          "server_pool_size",
          "console_sessions"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.quota.get"
        },
        "x-response-envelope": {
          "item_path": [
            "data"
          ],
          "list_path": [
            "data"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/reserved-ips": {
      "get": {
        "operationId": "list_reserved_ip",
        "summary": "List the reserved IPs in this zone, with the server each one is assigned to.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/reserved-ips",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only reserved IPs whose `name` or `ptr_record` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only reserved IPs with this tag, sent as `metadata[<key>]=<value>`, such as `metadata[env]=prod`. Repeat it to match reserved IPs that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of reserved_ip objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_reserved_ip",
        "summary": "Reserve a new public IP address in this zone.",
        "description": "To use the address, send its ID in `reserved_ip_ids` to [Create a server](/docs/cloud/api/servers/create-server/), or assign it to a running server via [Assign a reserved IP](/docs/cloud/api/reserved-ips/assign-reserved-ip/).",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/reserved-ips",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the reserved IP. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of reserved IPv4 or IPv6 addresses, or of public addresses overall, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no free address of this type, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id` or `type`, or `type`, `term` or `ptr_record` isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another address is being reserved in the organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team that owns the reserved IP. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "ipv4",
                      "ipv6"
                    ],
                    "description": "Whether to reserve an IPv4 or an IPv6 address.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The reserved IP's name, unique in the organization.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term. Defaults to `monthly`.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "x-cli-input": {
                      "order": 40
                    },
                    "default": "monthly"
                  },
                  "ptr_record": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The reverse DNS name for the address. Send `null` for none.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced"
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/reserved-ips/promote": {
      "post": {
        "operationId": "promote_reserved_ip",
        "summary": "Turn a public address that one of your servers already has into a reserved IP.",
        "description": "The reserved IP belongs to the server's team. The address stays the same, so you keep it when you delete the server and your DNS records keep working.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/reserved-ips/promote",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of reserved addresses of this type, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server of yours with this address.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The address is already a reserved IP, with the code `ip_already_reserved`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `ip`, or `ptr_record` isn't a valid hostname.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "ip": {
                    "type": "string",
                    "description": "The address to turn into a reserved IP, such as `203.0.113.7`. One of your servers must have it.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_ip",
                      "select": {
                        "visibility": {
                          "source": "literal",
                          "value": "public"
                        },
                        "available": {
                          "source": "literal",
                          "value": false
                        },
                        "reservation": {
                          "source": "literal",
                          "value": null
                        }
                      },
                      "value_field": "ip",
                      "label_fields": [
                        "ip",
                        "type"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The reserved IP's name, unique in the organization.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "ptr_record": {
                    "type": "string",
                    "description": "The reverse DNS name for the address.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced"
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "ip"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/reserved-ips/{id}": {
      "delete": {
        "operationId": "delete_reserved_ip",
        "summary": "Remove a reserved IP.",
        "description": "The address goes back to the zone, and you might not get the same address again. Unassign the reserved IP first.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/reserved-ips/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The address is still assigned to a server, with the code `reservation_in_use`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_reserved_ip",
        "summary": "Get a reserved IP, with its address and the server it's assigned to.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/reserved-ips/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_reserved_ip",
        "summary": "Update a reserved IP's name, reverse DNS name, billing term or tags.",
        "description": "The address stays the same.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/reserved-ips/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReservedIpUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/reserved-ips/{id}/assign": {
      "delete": {
        "operationId": "unassign_reserved_ip",
        "summary": "Remove a reserved IP from its server.",
        "description": "You keep the reserved IP. The server must be running or stopped. A reserved IP that the server booted with can't be unassigned, and stays reserved when you delete the server.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/reserved-ips/:id/assign",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The address isn't assigned, with the code `ip_not_assigned`. Or the server booted with the address, with the code `ip_is_primary`. Or the server is neither running nor stopped, with the code `server_not_running`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't change the server's network, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-cli-wait": {
          "observe": "get_reserved_ip",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "server_id"
            ],
            "expected": {
              "source": "literal",
              "value": null
            }
          },
          "description": "The address is no longer assigned to a server, which Cloud finishes before it answers."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "assign_reserved_ip",
        "summary": "Assign a reserved IP to a running server.",
        "description": "The address works on the server by the time the request returns.",
        "tags": [
          "reserved_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/reserved-ips/:id/assign",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single reserved_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReservedIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The address is already assigned, with the code `ip_already_assigned`. Or the server isn't running, with the code `server_not_running`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't change the server's network, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the running server to assign the address to. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "bindings": {
                        "status": {
                          "source": "literal",
                          "value": "running"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "ptr_record": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The reverse DNS name for the address while it's assigned to this server. Used instead of the reserved IP's `ptr_record`."
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "ip",
          "type",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "ip",
          "type",
          "gateway",
          "term",
          "server_id",
          "server",
          "ptr_record",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.reserved_ip.list"
        },
        "x-cli-wait": {
          "observe": "get_reserved_ip",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "server_id"
            ],
            "expected": {
              "source": "request",
              "path": [
                "server_id"
              ]
            }
          },
          "description": "The address is assigned to the requested server, which Cloud finishes before it answers. Whether the address is reachable from everywhere yet is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/scheduled-snapshots": {
      "get": {
        "operationId": "list_scheduled_snapshot",
        "summary": "List the server snapshot schedules in this zone.",
        "tags": [
          "scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/scheduled-snapshots",
        "parameters": [
          {
            "name": "server_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return only the schedules of the server with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_scheduled_snapshot",
        "summary": "Create a snapshot schedule for a server.",
        "description": "A schedule's snapshots count toward the same limit as the ones you create yourself, and have the `snapshot_type` `scheduled`.",
        "tags": [
          "scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/scheduled-snapshots",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `server_id`, or `frequency` isn't `hourly`, `daily`, `weekly` or `monthly`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_scheduled_snapshot",
        "summary": "Remove a snapshot schedule.",
        "description": "We keep the snapshots it has already created.",
        "tags": [
          "scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to remove. Get it via [List snapshot schedules](/docs/cloud/api/scheduled-snapshots/list-scheduled-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_scheduled_snapshot",
        "summary": "Get a server's snapshot schedule, with how often it runs and when it last ran.",
        "tags": [
          "scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to get. Get it via [List snapshot schedules](/docs/cloud/api/scheduled-snapshots/list-scheduled-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_scheduled_snapshot",
        "summary": "Change how often a schedule creates snapshots.",
        "description": "The schedule's server can't be changed.",
        "tags": [
          "scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to update. Get it via [List snapshot schedules](/docs/cloud/api/scheduled-snapshots/list-scheduled-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/server-types": {
      "get": {
        "operationId": "list_server_type",
        "summary": "List the server types you can order in this zone.",
        "description": "A type's family says what hardware it runs on. `AM` and `IS` types have shared AMD and Intel CPUs, `AMS` and `ISS` types are spot servers on the same CPUs, and `AMD` types have dedicated AMD CPUs. `M` types run on Mac hardware and `G` types have GPUs.",
        "tags": [
          "server_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/server-types",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "family",
          "vcpu",
          "ram_gb",
          "storage_gb",
          "availability"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "family",
          "vcpu",
          "ram_gb",
          "storage_gb",
          "bandwidth_gbit",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/server-types/availability": {
      "get": {
        "operationId": "list_server_type_availability",
        "summary": "List every server type with whether your organization can start `count` new servers of it.",
        "description": "Each type is checked on its own.",
        "tags": [
          "server_type_availability"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/server-types/availability",
        "parameters": [
          {
            "name": "count",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "How many servers of one type to start, from 1 to 100."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server_type_availability objects.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ServerTypeAvailabilityList"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "meta": {
                          "type": "object",
                          "properties": {
                            "count": {
                              "type": "integer",
                              "format": "int64",
                              "description": "The `count` the list was checked for."
                            }
                          }
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `count` isn't an integer from 1 to 100, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't check the zone's capacity, with the code `capacity_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "status"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "status"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_type_availability.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/server-types/{name}": {
      "get": {
        "operationId": "get_server_type",
        "summary": "Get a server type by name.",
        "description": "You can also get a deprecated type that has a replacement. A deprecated type's `availability` is `unavailable`, and `replacement` names the type to use instead.",
        "tags": [
          "server_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/server-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the server type to get, such as `AM4`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "family",
          "vcpu",
          "ram_gb",
          "storage_gb",
          "availability"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "family",
          "vcpu",
          "ram_gb",
          "storage_gb",
          "bandwidth_gbit",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/servers": {
      "get": {
        "operationId": "list_server",
        "summary": "List the servers in this zone, with their status and type.",
        "description": "Filter by status, name, pool or metadata.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers",
        "parameters": [
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "live_first"
              ]
            },
            "description": "Send `live_first` to list servers that aren't `destroyed` or `terminated` first, newest first in each group. By default, the newest server comes first."
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "starting",
                "running",
                "stopping",
                "stopped",
                "pooled",
                "snapshotting",
                "migrating",
                "rescuing",
                "restoring",
                "rescaling",
                "destroyed",
                "terminating",
                "terminated"
              ]
            },
            "description": "Return only servers with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return only servers with exactly this name."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return servers whose name contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only servers with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match servers that have every given tag."
          },
          {
            "name": "pool_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only servers from the server pool with this ID, both spare servers and claimed ones."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_server",
        "summary": "Create a server, a virtual machine in this zone.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ServerDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "root_password": {
                          "type": "string",
                          "description": "The one-time root password, returned only when you send `root_password` as `true`.",
                          "x-sensitive": true
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the server. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached one of its limits, such as its number of servers, with the code `quota_exceeded`. Or the organization is restricted because of fraud, with the code `organization_restricted`. Or the request sets a parameter the token can't set, with the code `forbidden`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the team, server type, image, SSH key, network, firewall, placement group or one of the `reserved_ip_ids` in the request. Or the Cloudflare account in a `cloudflare_account_id` isn't connected to your team.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value is missing or invalid, such as a `user_data` that breaks a rule or a `term` other than `monthly` or `annual`, with the code `validation_failed`. The error's `details` names each field. A Cloudflare account that you must connect again returns `validation_failed`. A `cloudflare_domain` that isn't a zone of the account in `cloudflare_account_id` returns `validation_failed` too. A deprecated `server_type` returns the code `type_deprecated`, and `details.replacement` names the type to send instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up the server, with the code `orchestration_failed`. Or the organization is creating too many servers at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
                    "x-cli-input": {
                      "order": 40
                    }
                  },
                  "server_type": {
                    "type": "string",
                    "description": "The name of the server type, such as `AM4`. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_server_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "family",
                        "vcpu",
                        "ram_gb",
                        "storage_gb",
                        "availability"
                      ]
                    }
                  },
                  "image": {
                    "type": "string",
                    "description": "The `slug` of an available image, such as `ubuntu-26-04`. Get the images via [List images](/docs/cloud/api/images/list-images/). Can't be changed after the server is created.",
                    "x-cli-input": {
                      "order": 30,
                      "lookup": "list_image",
                      "value_field": "slug",
                      "label_fields": [
                        "slug"
                      ]
                    }
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of private networks to attach. Each network must belong to the server's team. To change them later, use [Attach a network](/docs/cloud/api/networks/attach-network/) or [Detach a network](/docs/cloud/api/networks/detach-network/).",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "ip_prefix",
                        "ip_prefix_length"
                      ]
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The firewall to attach, as a list with at most one ID. The firewall must belong to the server's team. To change it later, use [Attach a firewall](/docs/cloud/api/firewalls/attach-firewall/) or [Detach a firewall](/docs/cloud/api/firewalls/detach-firewall/).",
                    "x-cli-input": {
                      "order": 120,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id"
                      ]
                    }
                  },
                  "placement_group_id": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The ID of a placement group to add the server to. The placement group must belong to the server's team. Can't be changed after the server is created.",
                    "x-cli-input": {
                      "order": 130,
                      "group": "Advanced",
                      "lookup": "list_placement_group",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "placement_type"
                      ]
                    }
                  },
                  "ssh_keys": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The `slug` of each SSH key to add. Get the keys via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/), or add one via [Create an SSH key](/docs/cloud/api/ssh-keys/create-ssh-key/). Each key must belong to the server's team. Send at least one key, unless `root_password` is `true`.",
                    "x-cli-input": {
                      "order": 50,
                      "lookup": "list_ssh_key",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "slug",
                      "label_fields": [
                        "slug",
                        "team_id"
                      ]
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 200,
                      "group": "Advanced"
                    }
                  },
                  "ddos_protection": {
                    "type": "boolean",
                    "description": "Whether to turn on DDoS protection. Can't be changed after the server is created.",
                    "x-cli-input": {
                      "order": 160,
                      "group": "Advanced"
                    },
                    "default": false
                  },
                  "ai_engineer_access": {
                    "type": "boolean",
                    "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH. Can't be changed after the server is created.",
                    "x-cli-input": {
                      "order": 170,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "vulnerability_monitoring": {
                    "type": "boolean",
                    "description": "Whether to scan the server daily for open ports and vulnerable software versions.",
                    "x-cli-input": {
                      "order": 180,
                      "group": "Advanced"
                    },
                    "default": false
                  },
                  "observability": {
                    "type": "boolean",
                    "description": "Whether to install the Better Stack collector. Can't be changed after the server is created.",
                    "x-cli-input": {
                      "order": 190,
                      "group": "Advanced"
                    },
                    "default": false
                  },
                  "reserved_ip_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of reserved IPs the server boots with, instead of new addresses. Each one must belong to the server's team and not be assigned to a server.",
                    "x-cli-input": {
                      "order": 140,
                      "group": "Advanced",
                      "lookup": "list_reserved_ip",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        },
                        "server_id": {
                          "source": "literal",
                          "value": null
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "ip",
                        "type"
                      ]
                    }
                  },
                  "public_ipv4": {
                    "type": "boolean",
                    "description": "Whether to give the server a new public IPv4 address. A reserved IPv4 address in `reserved_ip_ids` replaces it. Send `false` for a server with only IPv6. A server with only IPv6 can't boot with a reserved IPv4 address and can't have `cloudflare_records`.",
                    "x-cli-input": {
                      "order": 150,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "cloudflare_records": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "cloudflare_account_id": {
                          "type": "string",
                          "description": "The ID of the Cloudflare account that holds the zone. Connect the account to your team first, under **Integrations** → **Cloudflare** in the web app."
                        },
                        "cloudflare_domain": {
                          "type": "string",
                          "description": "The Cloudflare zone to add the records to, such as `example.com`."
                        },
                        "cloudflare_a_record": {
                          "type": "string",
                          "description": "The name of the A and AAAA records, such as `www`."
                        },
                        "cloudflare_proxied": {
                          "type": "boolean",
                          "description": "Whether Cloudflare proxies traffic to the server."
                        },
                        "cloudflare_a_record_ttl": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The records' TTL in seconds, from `60` to `86400`, or `1` for automatic. A proxied record must use `1`. Defaults to `1`."
                        }
                      },
                      "required": [
                        "cloudflare_account_id",
                        "cloudflare_domain",
                        "cloudflare_a_record"
                      ]
                    },
                    "description": "Cloudflare DNS records to point to the new server. Each entry adds an A and an AAAA record.",
                    "x-cli-input": {
                      "order": 210,
                      "group": "Advanced"
                    }
                  },
                  "root_password": {
                    "type": "boolean",
                    "description": "Whether to return a one-time root password. The password is returned only in this response, and we don't store it.",
                    "x-cli-input": {
                      "order": 60
                    },
                    "default": false
                  },
                  "subdomain": {
                    "type": "boolean",
                    "description": "Whether to give the server a free subdomain, `<server-name>.onbetterstack.com`.",
                    "x-cli-input": {
                      "order": 155,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "user_data": {
                    "type": "string",
                    "description": "A cloud-init document or a script that runs once, at the first boot, at most 32 KiB of UTF-8. A cloud-init document starts with `#cloud-config`. A script starts with `#!` and runs as root. No response returns it, but root can read it on the server, so don't put a long-lived credential in it.",
                    "x-sensitive": true,
                    "x-cli-input": {
                      "order": 195,
                      "group": "Advanced"
                    }
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term. Defaults to `monthly`.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "x-cli-input": {
                      "order": 70
                    },
                    "default": "monthly"
                  }
                },
                "required": [
                  "team_id",
                  "name",
                  "server_type",
                  "image"
                ],
                "anyOf": [
                  {
                    "required": [
                      "ssh_keys"
                    ],
                    "properties": {
                      "ssh_keys": {
                        "minItems": 1
                      }
                    }
                  },
                  {
                    "required": [
                      "root_password"
                    ],
                    "properties": {
                      "root_password": {
                        "const": true
                      }
                    }
                  }
                ]
              },
              "examples": {
                "create_a_server": {
                  "summary": "Create a server",
                  "value": {
                    "team_id": "t123",
                    "name": "web-1",
                    "server_type": "AM1",
                    "image": "ubuntu-26-04",
                    "ssh_keys": [
                      "my-laptop"
                    ],
                    "network_ids": [
                      "0f8c3e0a-6f0e-4c4b-9d55-0a6b8f9f5b11"
                    ]
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "root_password"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.create"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Created server is running; SSH, cloud-init and application readiness are not verified.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-cli-one-time-fields": [
          "root_password"
        ],
        "x-cli-nonempty-alternatives": true,
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/pools": {
      "get": {
        "operationId": "list_server_pool",
        "summary": "List the server pools in this zone, with each pool's `target_size` and how many spare servers it has.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/pools",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server_pool objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPoolList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "server_type",
          "enabled",
          "target_size",
          "available",
          "warming"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "snapshot_id",
          "image",
          "min_size",
          "max_size",
          "growth_multiplier",
          "shrink_multiplier",
          "idle_minutes",
          "enabled",
          "public_ipv4",
          "defaults",
          "target_size",
          "available",
          "warming",
          "claims_total",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_pool.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_server_pool",
        "summary": "Create a server pool.",
        "description": "The spare servers boot from one of the team's snapshots, or from an image with a `server_type`. Send `snapshot_id` or `image`, not both. Spare servers boot a few at a time, so a large `min_size` fills over minutes. Each spare server is billed as a server of its type from its boot.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/pools",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single server_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The `max_size` of all your organization's pools together would go over its `server_pool_size` limit, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the team, snapshot, image or server type, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has both or neither of `snapshot_id` and `image`, or the `server_type` isn't the snapshot's type. Or the `name` isn't valid or is taken in the team, a size or multiplier is out of range, or `defaults` has an unknown key, with the code `validation_failed`. A deprecated `server_type` returns the code `type_deprecated`, and `details.replacement` names the type to send instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team that owns the pool. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
                    "description": "The pool's name. Must be unique in the team, with up to 63 lowercase letters, digits and hyphens, and start and end with a letter or digit.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "image": {
                    "type": "string",
                    "description": "The `slug` of the image to boot from. Get the images via [List images](/docs/cloud/api/images/list-images/). Send a `server_type` with `image`. Can't be changed after the pool is created.",
                    "x-cli-input": {
                      "order": 30,
                      "lookup": "list_image",
                      "value_field": "slug",
                      "label_fields": [
                        "slug"
                      ]
                    }
                  },
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of one of the team's snapshots to boot from. The snapshot must be `available`. The spare servers get the snapshot's server type. Can't be changed after the pool is created.",
                    "x-cli-input": {
                      "order": 31,
                      "lookup": "list_snapshot",
                      "select": {
                        "status": {
                          "source": "literal",
                          "value": "available"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "status",
                        "size_bytes",
                        "created_at"
                      ]
                    }
                  },
                  "server_type": {
                    "type": "string",
                    "description": "The server type of the spare servers. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/). Required with `image`. With `snapshot_id`, leave it out or send the snapshot's type. Can't be changed after the pool is created.",
                    "x-cli-input": {
                      "order": 40,
                      "lookup": "list_server_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "family",
                        "vcpu",
                        "ram_gb",
                        "storage_gb",
                        "availability"
                      ]
                    }
                  },
                  "min_size": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The fewest spare servers the pool keeps.",
                    "x-cli-input": {
                      "order": 50
                    },
                    "default": 0
                  },
                  "max_size": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The most spare servers the pool keeps. Counts toward your organization's `server_pool_size` quota.",
                    "x-cli-input": {
                      "order": 51
                    },
                    "default": 0
                  },
                  "growth_multiplier": {
                    "type": "number",
                    "description": "How much the pool grows when you claim a server from an empty pool. `target_size` is multiplied by this factor, from 1 to 10. `1` turns growing off.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    },
                    "default": 2.0
                  },
                  "shrink_multiplier": {
                    "type": "number",
                    "description": "How much the pool shrinks while it's full and nobody has claimed a server for `idle_minutes`. Each minute, `target_size` is multiplied by this factor, which is more than 0 and at most 1. `1` turns shrinking off.",
                    "x-cli-input": {
                      "order": 101,
                      "group": "Advanced"
                    },
                    "default": 0.8
                  },
                  "idle_minutes": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many minutes without a claim before the pool shrinks, from 1 to 1440.",
                    "x-cli-input": {
                      "order": 102,
                      "group": "Advanced"
                    },
                    "default": 5
                  },
                  "enabled": {
                    "type": "boolean",
                    "description": "Whether the pool keeps spare servers. Send `false` to create the pool without spare servers.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "public_ipv4": {
                    "type": "boolean",
                    "description": "Whether the spare servers get a public IPv4 address. A server without one has only IPv6. Can't be changed after the pool is created.",
                    "x-cli-input": {
                      "order": 120,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "defaults": {
                    "type": "object",
                    "properties": {
                      "ssh_keys": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "description": "The `slug` of each SSH key to add."
                      },
                      "firewall_ids": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "description": "The IDs of the firewalls to attach."
                      },
                      "network_ids": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "description": "The IDs of the private networks to join."
                      },
                      "metadata": {
                        "type": "object",
                        "additionalProperties": true,
                        "description": "Your own tags, as string keys and values."
                      }
                    },
                    "description": "What every spare server gets when it boots, such as `ssh_keys`, firewalls, private networks and tags. Any other key is refused.",
                    "x-cli-input": {
                      "order": 130,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name"
                ],
                "anyOf": [
                  {
                    "required": [
                      "image"
                    ]
                  },
                  {
                    "required": [
                      "snapshot_id"
                    ]
                  }
                ]
              },
              "examples": {
                "create_a_server_pool": {
                  "summary": "Create a server pool",
                  "value": {
                    "team_id": "t123",
                    "name": "web",
                    "server_type": "AM1",
                    "image": "ubuntu-26-04",
                    "min_size": 0,
                    "max_size": 1
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "server_type",
          "enabled",
          "target_size",
          "available",
          "warming"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "snapshot_id",
          "image",
          "min_size",
          "max_size",
          "growth_multiplier",
          "shrink_multiplier",
          "idle_minutes",
          "enabled",
          "public_ipv4",
          "defaults",
          "target_size",
          "available",
          "warming",
          "claims_total",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_pool.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/pools/{id}": {
      "delete": {
        "operationId": "delete_server_pool",
        "summary": "Remove a server pool and its spare servers, including the ones still booting.",
        "description": "Servers already claimed from the pool stay.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/servers/pools/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_server_pool",
        "summary": "Get a server pool, with its sizes and how many spare servers it has now.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/pools/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "server_type",
          "enabled",
          "target_size",
          "available",
          "warming"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "snapshot_id",
          "image",
          "min_size",
          "max_size",
          "growth_multiplier",
          "shrink_multiplier",
          "idle_minutes",
          "enabled",
          "public_ipv4",
          "defaults",
          "target_size",
          "available",
          "warming",
          "claims_total",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_pool.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_server_pool",
        "summary": "Change a pool's `name`, sizes, multipliers, `idle_minutes`, `enabled` or `defaults`.",
        "description": "The pool then adds or removes spare servers to reach its new target.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/servers/pools/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server_pool.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPoolDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The new `max_size` would put your organization's pools over its `server_pool_size` limit, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has `server_type`, `snapshot_id`, `image`, `team_id` or `public_ipv4`, which can't change, or a value isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerPoolUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "server_type",
          "enabled",
          "target_size",
          "available",
          "warming"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_type",
          "snapshot_id",
          "image",
          "min_size",
          "max_size",
          "growth_multiplier",
          "shrink_multiplier",
          "idle_minutes",
          "enabled",
          "public_ipv4",
          "defaults",
          "target_size",
          "available",
          "warming",
          "claims_total",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_pool.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/pools/{id}/claim": {
      "post": {
        "operationId": "claim_server_pool",
        "summary": "Claim the oldest spare server in the pool, so it's yours to use.",
        "description": "The server is already running on the addresses it booted with, and the pool's default keys work at once. Keys in `ssh_keys` and the password from `root_password` reach the server a few seconds later. The server has already booted, so you can't send `user_data`, reserved IPs, a server type or a disk size.",
        "tags": [
          "server_pool"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/pools/:id/claim",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ServerDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "root_password": {
                          "type": "string",
                          "description": "The root password, shown only this once, when the request sets `root_password` to `true`.",
                          "x-sensitive": true
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the pool, an SSH key, a firewall or a network, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The pool is disabled, with the code `pool_disabled`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `name` is missing or taken, the request names more than one firewall, or the pool's `defaults` already attach a firewall, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "The pool has no spare server right now, with the code `pool_empty`. Try again shortly, or create a server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "ssh_keys": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The `slug` of each SSH key of the pool's team to add, on top of the pool's default keys.",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_ssh_key",
                      "value_field": "slug",
                      "label_fields": [
                        "slug",
                        "team_id"
                      ]
                    }
                  },
                  "root_password": {
                    "type": "boolean",
                    "description": "Whether to set a root password. The response shows the password once.",
                    "x-cli-input": {
                      "order": 30
                    },
                    "default": false
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags for the server, as string keys and values, added to the pool's default tags.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The ID of one firewall of the pool's team to attach. Refused when the pool's `defaults` already attach a firewall.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id"
                      ]
                    }
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of private networks of the pool's team to join. Each one gets a private IP and is attached shortly after the response, as when you create a server.",
                    "x-cli-input": {
                      "order": 120,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "ip_prefix",
                        "ip_prefix_length"
                      ]
                    }
                  },
                  "subdomain": {
                    "type": "boolean",
                    "description": "Whether the server gets a free subdomain in `onbetterstack.com`, made from its name.",
                    "x-cli-input": {
                      "order": 130,
                      "group": "Advanced"
                    },
                    "default": true
                  }
                },
                "required": [
                  "name"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "root_password"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_pool.claim"
        },
        "x-cli-one-time-fields": [
          "root_password"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}": {
      "delete": {
        "operationId": "delete_server",
        "summary": "Remove a server.",
        "description": "Removing a server can't be undone. The server's `status` becomes `destroyed` at once, and we remove the server in the background. You can still get the server and its events for 3 days.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/servers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is already destroyed, with the code `server_destroyed`. Or the server is a Kubernetes worker, which you remove through its node pool, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "destroyed"
                }
              },
              {
                "path": [
                  "ip_addresses"
                ],
                "count": true,
                "expected": {
                  "source": "literal",
                  "value": 0
                }
              }
            ]
          },
          "description": "The destroyed server has given back its public addresses, which Cloud does only after the node confirms the instance is gone. Removal of its DNS records and collector is not verified, and a teardown whose node never confirms keeps the wait running until its limit."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_server",
        "summary": "Get a server, with its status, type, addresses and attached networks and firewalls.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "destroyed",
                "terminated"
              ]
            }
          ],
          "description": "Server is currently running; this does not prove SSH, cloud-init, application readiness, or completion of an earlier operation.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_server",
        "summary": "Update a server's name, tags, `vulnerability_monitoring`, subdomain or billing term.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/servers/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is a Kubernetes worker and the update changes more than its tags, with the code `kubernetes_managed`. Or the server is still in a server pool, with the code `server_pooled`. Or the change needs a running server and it isn't running, with the code `server_not_running`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The name is taken, `term` isn't `monthly` or `annual`, `metadata` has more than 10 pairs, or the server can't have a subdomain, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't change the DNS records of the server's subdomain, with the code `subdomain_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/metrics": {
      "get": {
        "operationId": "metrics_server",
        "summary": "Get the server's CPU, memory, disk space, disk reads and writes, and uptime.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range. Defaults to 24 hours before `to`. Sending `from` or `to` returns a series over time."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range. Defaults to now."
          }
        ],
        "responses": {
          "200": {
            "description": "Without `from` and `to`, you get a live reading, and the server must be running. Send `from` or `to` to get a series over time instead, which works in any status. A range longer than a day has one point per hour.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "server_id": {
                      "type": "string",
                      "description": "The server's ID, a UUID. Both a live reading and a series have it."
                    },
                    "server_name": {
                      "type": "string",
                      "description": "The server's name. Both a live reading and a series have it."
                    },
                    "sampled_at": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When we read the values. Only a live reading has it."
                    },
                    "uptime": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "properties": {
                        "started_at": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        },
                        "seconds": {
                          "type": [
                            "integer",
                            "null"
                          ],
                          "format": "int64"
                        }
                      },
                      "description": "How long the server has run since it last started. Only a live reading has it."
                    },
                    "cpu": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "properties": {
                        "usage_percent": {
                          "type": [
                            "number",
                            "null"
                          ]
                        },
                        "vcpus": {
                          "type": "integer",
                          "format": "int64"
                        }
                      },
                      "description": "CPU use as a percentage of all the server's vCPUs. Only a live reading has it, and each point of a series has its own."
                    },
                    "memory": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "properties": {
                        "used_bytes": {
                          "type": [
                            "integer",
                            "null"
                          ],
                          "format": "int64"
                        },
                        "total_bytes": {
                          "type": "integer",
                          "format": "int64"
                        },
                        "usage_percent": {
                          "type": [
                            "number",
                            "null"
                          ]
                        }
                      },
                      "description": "The server's memory use. Only a live reading has it, and each point of a series has its own."
                    },
                    "disk": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "properties": {
                        "space": {
                          "type": "object",
                          "properties": {
                            "used_bytes": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "format": "int64"
                            },
                            "total_bytes": {
                              "type": "integer",
                              "format": "int64"
                            },
                            "usage_percent": {
                              "type": [
                                "number",
                                "null"
                              ]
                            }
                          }
                        },
                        "io": {
                          "type": "object",
                          "properties": {
                            "read_bytes_per_second": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "format": "int64"
                            },
                            "write_bytes_per_second": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "format": "int64"
                            }
                          }
                        }
                      },
                      "description": "The disk space used out of the root disk, and the disk read and write rates. Only a live reading has it, and each point of a series has its own."
                    },
                    "cpu_credits": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "properties": {
                        "balance_vcpu_minutes": {
                          "type": "number"
                        },
                        "cap_vcpu_minutes": {
                          "type": "number"
                        },
                        "baseline_vcpus": {
                          "type": "number"
                        },
                        "baseline_percent": {
                          "type": "integer",
                          "format": "int64"
                        },
                        "capped": {
                          "type": "boolean"
                        },
                        "cap_reason": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "updated_at": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        }
                      },
                      "description": "The CPU credit balance of a shared or spot server. Only a live reading has it. A dedicated server doesn't have it, and neither does a server in a zone without a CPU budget."
                    },
                    "from": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "The start of the range returned. Only a series has it."
                    },
                    "to": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "The end of the range returned. Only a series has it."
                    },
                    "resolution": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "enum": [
                        "raw",
                        "hourly",
                        null
                      ],
                      "description": "How far apart the points are. Only a series has it.",
                      "x-enum-descriptions": {
                        "raw": "One point per minute, for a range of up to one day.",
                        "hourly": "One point per hour, for a longer range."
                      }
                    },
                    "data": {
                      "type": [
                        "array",
                        "null"
                      ],
                      "items": {
                        "type": "object",
                        "properties": {
                          "dt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "cpu": {
                            "type": "object",
                            "properties": {
                              "usage_percent": {
                                "type": "number"
                              },
                              "vcpus": {
                                "type": "integer",
                                "format": "int64"
                              }
                            }
                          },
                          "memory": {
                            "type": "object",
                            "properties": {
                              "used_bytes": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "total_bytes": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "usage_percent": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              }
                            }
                          },
                          "disk": {
                            "type": "object",
                            "properties": {
                              "space": {
                                "type": "object",
                                "properties": {
                                  "used_bytes": {
                                    "type": "integer",
                                    "format": "int64"
                                  },
                                  "total_bytes": {
                                    "type": "integer",
                                    "format": "int64"
                                  },
                                  "usage_percent": {
                                    "type": [
                                      "number",
                                      "null"
                                    ]
                                  }
                                }
                              },
                              "io": {
                                "type": "object",
                                "properties": {
                                  "read_bytes_per_second": {
                                    "type": "integer",
                                    "format": "int64"
                                  },
                                  "write_bytes_per_second": {
                                    "type": "integer",
                                    "format": "int64"
                                  }
                                }
                              }
                            }
                          },
                          "uptime_seconds": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "traffic": {
                            "type": "object",
                            "properties": {
                              "bytes_in": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "bytes_out": {
                                "type": "integer",
                                "format": "int64"
                              },
                              "bytes_in_intra_az": {
                                "type": [
                                  "integer",
                                  "null"
                                ],
                                "format": "int64"
                              },
                              "bytes_out_intra_az": {
                                "type": [
                                  "integer",
                                  "null"
                                ],
                                "format": "int64"
                              }
                            }
                          }
                        }
                      },
                      "description": "The points of the series, oldest first. Only a series has it. A minute or hour with no sample has no point. `traffic` counts the bytes sent and received in each point's interval. For hourly points, the bytes inside the zone, `bytes_in_intra_az` and `bytes_out_intra_az`, are `null`."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "You asked for a live reading, but the server isn't running, with the code `server_not_running`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The range isn't a valid time range, ends before it starts or is longer than 366 days, with the code `invalid_range`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't read the metrics, with the code `metrics_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "server_id",
          "server_name",
          "sampled_at",
          "uptime",
          "cpu",
          "memory",
          "disk",
          "cpu_credits",
          "from",
          "to",
          "resolution",
          "data"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/servers/{id}/rescale": {
      "post": {
        "operationId": "rescale_server",
        "summary": "Change the server's type, within its family or between the regular and dedicated families.",
        "description": "We stop the server, change its size and start it again if it was running. When the new size doesn't fit on its host, we move the server to another host. Disks grow and never shrink.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The new type would put your organization over one of its limits, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "No server type has the name in `server_type`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server's status doesn't allow a rescale, with the code `server_not_rescalable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`. Or there's no capacity for the new size, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request names the current type, a family change that isn't allowed, or a type with less storage than the current disk, with the code `validation_failed`. A deprecated type returns the code `type_deprecated`, and `details.replacement` names the type to send instead.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Too many rescales are running at once, with the code `concurrent_rescale_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_type": {
                    "type": "string",
                    "description": "The name of the new server type. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/). Must differ from the current type. A spot, Mac or GPU server can only change to a type in its own family.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "family",
                        "vcpu",
                        "ram_gb",
                        "storage_gb",
                        "availability"
                      ]
                    }
                  },
                  "preserve_disk_size": {
                    "type": "boolean",
                    "description": "Whether to keep the current root disk size instead of growing it to the new type's `storage_gb`.",
                    "x-cli-input": {
                      "order": 20,
                      "group": "Advanced"
                    },
                    "default": false
                  }
                },
                "required": [
                  "server_type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_server",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "before_condition": {
            "path": [
              "status"
            ],
            "in": [
              "running"
            ]
          },
          "reads": {
            "type": {
              "operation": "get_server_type",
              "bindings": {
                "name": {
                  "source": "request",
                  "path": [
                    "server_type"
                  ]
                }
              }
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "before",
                  "path": [
                    "status"
                  ]
                }
              },
              {
                "path": [
                  "server_type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "server_type"
                  ]
                }
              },
              {
                "path": [
                  "disk_size_gb"
                ],
                "expected": {
                  "source": "read",
                  "path": [
                    "type",
                    "storage_gb"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "running",
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "A previously running server returns to running at the requested type and catalog disk size. Default waiting refuses stopped-origin rescales because failed physical resizing can also settle stopped; guest filesystem growth is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/rescue": {
      "delete": {
        "operationId": "exit_server_rescue",
        "summary": "End rescue mode now instead of waiting for the 60-minute limit.",
        "description": "We remove the rescue system and boot the server's own system. The server stays in `rescuing` while we do. You can also end rescue mode while `rescue_state` is `activating`. If the rescue system is booting, rescue mode ends right after the boot completes. If the boot hasn't started, the server returns to the status it had before.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/servers/:id/rescue",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server isn't in rescue mode, with the code `not_in_rescue`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't end rescue mode, with the code `orchestration_failed`. The server stays in `rescuing`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "in": [
              "running",
              "stopped"
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "The server left rescue mode, and is running its own system again, or is back in its earlier status when the rescue system never booted. SSH and application readiness are not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "enter_server_rescue",
        "summary": "Boot the server into rescue mode, to repair a system that doesn't boot.",
        "description": "The rescue system is usually up in under a minute, and in about 20 minutes at most. Rescue mode ends by itself 60 minutes after the request. If the rescue system can't boot, the server returns to the status it had before and `rescue_state` is `null`. The web console isn't available in rescue mode.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/rescue",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ServerDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "rescue_password": {
                          "type": "string",
                          "description": "A one-time password to sign in to the rescue system. Returned only in this response.",
                          "x-sensitive": true
                        },
                        "rescue_expires_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "When rescue mode ends by itself and the server returns to normal, 60 minutes after it started."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is already in rescue mode, with the code `already_in_rescue`. Or its status doesn't allow rescue mode, with the code `server_not_rescuable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't start rescue mode, with the code `orchestration_failed`. The server keeps its status. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "force": {
                    "type": "boolean",
                    "description": "Whether to cut the power of a stuck server instead of shutting it down gracefully first.",
                    "default": false
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "rescue_password",
          "rescue_expires_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.enter_rescue"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "rescue_state"
            ],
            "expected": {
              "source": "literal",
              "value": "active"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "running",
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Rescue system is up after the accepted request; login with the rescue password is not verified."
        },
        "x-cli-one-time-fields": [
          "rescue_password"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/restart": {
      "post": {
        "operationId": "restart_server",
        "summary": "Restart a running server.",
        "description": "The server shows the status `running` again once it's back up.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/restart",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server's status doesn't allow a restart, with the code `server_not_restartable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Server returned to running after the accepted restart; SSH and application readiness are not verified.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/restore": {
      "post": {
        "operationId": "restore_server",
        "summary": "Restore the server from one of its own snapshots.",
        "description": "The server keeps its ID and addresses. Anything written to the disk since the snapshot is lost.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "This server has no snapshot with the ID in `snapshot_id`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot can't be restored, with the code `snapshot_not_restorable`. Or the server's status doesn't allow a restore, with the code `server_not_restorable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `snapshot_id`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of the snapshot to restore. Must be a snapshot of this server. Get it via [List snapshots](/docs/cloud/api/snapshots/list-snapshots/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_snapshot",
                      "bindings": {
                        "server_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "select": {
                        "status": {
                          "source": "literal",
                          "value": "available"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "status",
                        "size_bytes",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Server returned to running after the accepted in-place restore; restored data, volume mounts and network/firewall convergence are not verified.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/security-scan": {
      "get": {
        "operationId": "security_scan_server",
        "summary": "Get the server's latest vulnerability scan.",
        "description": "We scan daily while `vulnerability_monitoring` is on, and keep only the latest scan.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:id/security-scan",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "An empty `findings` list means the latest scan found nothing.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "last_scan_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When the latest scan ran."
                    },
                    "findings": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "The finding's ID, `<service>-<issue>`, which stays the same between scans."
                          },
                          "service": {
                            "type": "string",
                            "description": "The service the finding is about."
                          },
                          "title": {
                            "type": "string",
                            "description": "The service name, with its installed version when known."
                          },
                          "severity": {
                            "type": "string",
                            "enum": [
                              "critical",
                              "high"
                            ],
                            "description": "How serious the finding is.\n\n- `critical`: A service that must not be reachable from the internet is reachable.\n- `high`: A service reachable from the internet runs a vulnerable version.",
                            "x-enum-descriptions": {
                              "critical": "A service that must not be reachable from the internet is reachable.",
                              "high": "A service reachable from the internet runs a vulnerable version."
                            }
                          },
                          "summary": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "A short summary, or `null`."
                          },
                          "cves": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "The CVE IDs named in `description`."
                          },
                          "description": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "More about the finding, or `null`."
                          }
                        }
                      },
                      "description": "What the scan found, one entry per finding."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The server has no scan yet. We scan a running server daily while `vulnerability_monitoring` is on, so the first scan comes with the next daily run after you turn it on. The error has the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "last_scan_at",
          "findings"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.security_scan"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/servers/{id}/start": {
      "post": {
        "operationId": "start_server",
        "summary": "Start a stopped server.",
        "description": "The server shows the status `running` once it has started.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/start",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server's status doesn't allow a start, with the code `server_not_startable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Server is running after the accepted start; SSH, cloud-init and application readiness are not verified.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{id}/stop": {
      "post": {
        "operationId": "stop_server",
        "summary": "Stop a running server.",
        "description": "We shut it down gracefully unless you send `force`.",
        "tags": [
          "server"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:id/stop",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server's status doesn't allow a stop, with the code `server_not_stoppable`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "force": {
                    "type": "boolean",
                    "description": "Whether to cut the power instead of shutting the server down gracefully.",
                    "default": false
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server.list"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "stopped"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "Server is powered off; this does not verify application-level graceful shutdown."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{server_id}/events": {
      "get": {
        "operationId": "list_event",
        "summary": "List a server's events.",
        "description": "You can still list them for 3 days after the server is deleted.",
        "tags": [
          "event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:server_id/events",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server whose events to list. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{server_id}/ips": {
      "get": {
        "operationId": "list_server_public_ip",
        "summary": "List a server's public IP addresses with their reverse DNS records.",
        "tags": [
          "server_public_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:server_id/ips",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server whose addresses to list. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server_public_ip objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPublicIpList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "ip",
          "type",
          "device_name",
          "ptr_record"
        ],
        "x-cli-name-fields": [
          "ip"
        ],
        "x-cli-response-fields": [
          "id",
          "ip",
          "type",
          "device_name",
          "ptr_record"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_public_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{server_id}/ips/{id}": {
      "patch": {
        "operationId": "update_server_public_ip",
        "summary": "Set or remove the reverse DNS name of one of the server's public IP addresses.",
        "description": "DNS can show the old name for a while after the change.",
        "tags": [
          "server_public_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/servers/:server_id/ips/:id",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server the address is on. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the address to update. Get it via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single server_public_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPublicIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the server or the address.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server is a Kubernetes worker, with the code `kubernetes_managed`. The worker's cluster manages its reverse DNS.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `ptr_record` isn't a valid hostname, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "The server is locked and can't be changed, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerPublicIpUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "ip",
          "type",
          "device_name",
          "ptr_record"
        ],
        "x-cli-name-fields": [
          "ip"
        ],
        "x-cli-response-fields": [
          "id",
          "ip",
          "type",
          "device_name",
          "ptr_record"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_public_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{server_id}/private-ips": {
      "get": {
        "operationId": "list_server_private_ip",
        "summary": "List a server's private IPs in all its private networks.",
        "tags": [
          "server_private_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/servers/:server_id/private-ips",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of server_private_ip objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPrivateIpList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "network_id",
          "ip_address"
        ],
        "x-cli-name-fields": [
          "ip_address"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "network_id",
          "ip_address",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_private_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_server_private_ip",
        "summary": "Add a private IP to a server in one of its private networks.",
        "description": "The address starts working a few moments after the response.",
        "tags": [
          "server_private_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/servers/:server_id/private-ips",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "x-cli-input": {
                "order": 10,
                "lookup": "list_server",
                "value_field": "id",
                "label_fields": [
                  "name",
                  "team_id",
                  "status"
                ]
              }
            },
            "description": "The ID of the server to add the address to. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server_private_ip.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServerPrivateIpDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The server has reached its limit of private IPs in this network, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server isn't attached to the network, with the code `not_attached`. Or another server in the network has the address, with the code `ip_already_assigned`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has no `network_id`, or `ip_address` isn't a valid address, with the code `validation_failed`. Or the address is outside the network's IP range, with the code `ip_out_of_range`. Or the network has no free addresses left, with the code `network_exhausted`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerPrivateIpCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "server_id",
          "network_id",
          "ip_address"
        ],
        "x-cli-name-fields": [
          "ip_address"
        ],
        "x-cli-response-fields": [
          "id",
          "server_id",
          "network_id",
          "ip_address",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.server_private_ip.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/servers/{server_id}/private-ips/{id}": {
      "delete": {
        "operationId": "delete_server_private_ip",
        "summary": "Remove a private IP from a server.",
        "description": "Other servers in the network can then get the address. The address can still work for a few moments after the response.",
        "tags": [
          "server_private_ip"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/servers/:server_id/private-ips/:id",
        "parameters": [
          {
            "name": "server_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the server. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private IP to remove. Get it via [List server private IPs](/docs/cloud/api/server-private-ips/list-server-private-ips/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/snapshots": {
      "get": {
        "operationId": "list_snapshot",
        "summary": "List the snapshots in this zone.",
        "description": "Snapshots of deleted servers are listed too.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/snapshots",
        "parameters": [
          {
            "name": "server_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return only snapshots of the server with this ID."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return only snapshots whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Return only snapshots with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match snapshots that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "size_bytes",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_snapshot",
        "summary": "Create a snapshot of a server.",
        "description": "The server keeps running, and its disk can be slower while we copy it.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server's status doesn't allow a snapshot now. The code is `server_snapshotting` while a snapshot is being taken, `server_destroyed` for a deleted server and `server_rescaling` while it's rescaling. A server that's still in a server pool returns `server_pooled`. A server in rescue mode, or in any status other than `running`, `stopped` or `terminating`, returns `server_not_snapshottable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to create a snapshot of. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status",
                        "server_type"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the server's name followed by the date.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "size_bytes",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Captured snapshot is available; application-consistent backup is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/snapshots/{id}": {
      "delete": {
        "operationId": "delete_snapshot",
        "summary": "Remove a snapshot.",
        "description": "The snapshot's `status` becomes `deleting` until we've removed its data.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being taken or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "The snapshot is locked, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "size_bytes",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "Snapshot is no longer available through this API after accepted deletion; scope changes may also hide it, and physical storage erasure is not independently verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_snapshot",
        "summary": "Get a server snapshot, with its status and size.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "size_bytes",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Snapshot is available; application-consistent backup is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_snapshot",
        "summary": "Update a snapshot's name or tags.",
        "description": "The snapshot's data can't be changed.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "The snapshot is locked, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "server_id",
          "status",
          "size_bytes",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_snapshot",
        "summary": "Create a new server from the snapshot.",
        "description": "The original server stays as it is. The new server gets the original's team, size, SSH keys, firewall and private networks. The new server gets new IP addresses unless you send reserved IPs. To restore a snapshot taken in another zone, send the request to this zone with the other zone in `from_availability_zone`.",
        "tags": [
          "snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single server.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ServerDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "root_password": {
                          "type": "string",
                          "description": "The new server's root password. Returned once, when you send `root_password` set to `true`, so save it then.",
                          "x-sensitive": true
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of servers, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the snapshot in this zone. For a snapshot taken in another zone, send that zone in `from_availability_zone`. A `cloudflare_account_id` whose Cloudflare account isn't connected to your team also returns 404.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot can't be restored because it's still being taken or it failed, with the code `snapshot_not_restorable`. Or the zone has no room for the new server, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value is missing or invalid, with the code `validation_failed`. The same code is returned when you must connect the Cloudflare account again, or when the `cloudflare_domain` isn't a zone of the account in `cloudflare_account_id`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "The snapshot is locked, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "502": {
            "description": "We couldn't get the snapshot from the zone it was taken in, with the code `cross_az_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't create the server, with the code `orchestration_failed`. Or the organization is creating too many servers at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "504": {
            "description": "Getting the snapshot from the zone it was taken in timed out, with the code `cross_az_timeout`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new server's name. Defaults to a name made from the snapshot's name.",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "from_availability_zone": {
                    "type": "string",
                    "description": "The zone the snapshot was taken in, when it isn't this zone. The new server is created in the zone you call.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "reserved_ip_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of reserved IPs to give the new server. Each reserved IP must be unassigned, in the zone you call and in the snapshot's team.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced",
                      "lookup": "list_reserved_ip",
                      "select": {
                        "server_id": {
                          "source": "literal",
                          "value": null
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "ip",
                        "type"
                      ]
                    }
                  },
                  "public_ipv4": {
                    "type": "boolean",
                    "description": "Whether the new server gets a public IPv4 address. Leave it out to use the snapshot's setting. When you leave it out and send a reserved IPv4 address in `reserved_ip_ids`, the new server gets a public IPv4 address.",
                    "x-cli-input": {
                      "order": 120,
                      "group": "Advanced"
                    }
                  },
                  "ddos_protection": {
                    "type": "boolean",
                    "description": "Whether the new server has DDoS protection. Leave it out to use the snapshot's setting.",
                    "x-cli-input": {
                      "order": 130,
                      "group": "Advanced"
                    }
                  },
                  "ai_engineer_access": {
                    "type": "boolean",
                    "description": "Whether the Better Stack AI Engineer can sign in to the new server over SSH. Leave it out to use the snapshot's setting.",
                    "x-cli-input": {
                      "order": 140,
                      "group": "Advanced"
                    }
                  },
                  "vulnerability_monitoring": {
                    "type": "boolean",
                    "description": "Whether we scan the new server for vulnerabilities every day. Leave it out to use the snapshot's setting.",
                    "x-cli-input": {
                      "order": 150,
                      "group": "Advanced"
                    }
                  },
                  "root_password": {
                    "type": "boolean",
                    "description": "Whether to set a new root password and return it once. Send `false` or leave it out to keep the passwords from the snapshot.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "subdomain": {
                    "type": "boolean",
                    "description": "Whether the new server gets a free subdomain in `onbetterstack.com`, made from its name. Defaults to `true`. The original server keeps its subdomain.",
                    "x-cli-input": {
                      "order": 155,
                      "group": "Advanced"
                    },
                    "default": true
                  },
                  "cloudflare_records": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "cloudflare_account_id": {
                          "type": "string",
                          "description": "The ID of the Cloudflare account that holds the zone. Connect the account to your team first, under **Integrations** → **Cloudflare** in the web app."
                        },
                        "cloudflare_domain": {
                          "type": "string",
                          "description": "The Cloudflare zone to add the records to, such as `example.com`."
                        },
                        "cloudflare_a_record": {
                          "type": "string",
                          "description": "The name of the A and AAAA records, such as `www`."
                        },
                        "cloudflare_proxied": {
                          "type": "boolean",
                          "description": "Whether Cloudflare proxies traffic to the server."
                        },
                        "cloudflare_a_record_ttl": {
                          "type": "integer",
                          "format": "int64",
                          "description": "The records' TTL in seconds, from `60` to `86400`, or `1` for automatic. A proxied record must use `1`. Defaults to `1`."
                        }
                      },
                      "required": [
                        "cloudflare_account_id",
                        "cloudflare_domain",
                        "cloudflare_a_record"
                      ]
                    },
                    "description": "Cloudflare DNS records to point to the new server. Each entry adds an A and an AAAA record.",
                    "x-cli-input": {
                      "order": 160,
                      "group": "Advanced"
                    }
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "server_type"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "rescue_state",
          "server_type",
          "term",
          "disk_size_gb",
          "image",
          "network_ids",
          "firewall_ids",
          "placement_group_id",
          "pool_id",
          "claimed_at",
          "ssh_keys",
          "ip_addresses",
          "private_ips",
          "cloudflare_records",
          "subdomain",
          "ddos_protection",
          "ai_engineer_access",
          "vulnerability_monitoring",
          "observability",
          "nested_virtualization",
          "connection_tracking",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "root_password"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.snapshot.restore"
        },
        "x-cli-wait": {
          "observe": "get_server",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "stopped",
                "destroyed",
                "terminating",
                "terminated"
              ]
            }
          ],
          "description": "New returned server is running on this invocation's destination; restored data, network/firewall convergence, SSH and application readiness are not verified.",
          "ssh": {
            "collection": [
              "ip_addresses"
            ],
            "address_field": "ip",
            "type_field": "type",
            "preferred_types": [
              "ipv4",
              "ipv6"
            ]
          }
        },
        "x-cli-one-time-fields": [
          "root_password"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/ssh-keys": {
      "get": {
        "operationId": "list_ssh_key",
        "summary": "List the SSH keys in this zone, with the team each one belongs to.",
        "description": "Filter by part of a `slug` or by tags.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/ssh-keys",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Return keys whose `slug` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Return keys that have every given tag, sent as `metadata[<key>]=<value>`. Repeat it to match several tags."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of ssh_key objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SshKeyList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      },
      "post": {
        "operationId": "create_ssh_key",
        "summary": "Create an SSH key.",
        "description": "We copy it to every other zone shortly after the response. With `server_ids`, we also add the key to those of the servers that are running, in any zone.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/ssh-keys",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single ssh_key.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/SshKeyDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "servers": {
                          "type": "object",
                          "properties": {
                            "queued": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "The IDs of the servers of this zone we're adding the key to."
                            },
                            "skipped": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "server_id": {
                                    "type": "string",
                                    "description": "The ID of the skipped server."
                                  },
                                  "reason": {
                                    "type": "string",
                                    "enum": [
                                      "kubernetes_managed",
                                      "locked",
                                      "server_not_running"
                                    ],
                                    "description": "Why we skipped the server.\n\n- `kubernetes_managed`: The server is a Kubernetes worker.\n- `locked`: The server is locked.\n- `server_not_running`: The server isn't running.",
                                    "x-enum-descriptions": {
                                      "kubernetes_managed": "The server is a Kubernetes worker.",
                                      "locked": "The server is locked.",
                                      "server_not_running": "The server isn't running."
                                    }
                                  }
                                }
                              },
                              "description": "The servers of this zone that can't get the key now, each with a reason."
                            },
                            "forwarded": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "The IDs of the servers in other zones. The key is added to each of them once it has been copied to the server's zone."
                            }
                          },
                          "description": "What we did with each server in `server_ids`, returned only when you sent it. Each server's events show whether adding the key worked."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of SSH keys, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find the team in `team_id`, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `slug` is taken in the team, `public_key` isn't a valid OpenSSH key, or `server_ids` isn't a list of at most 100 server IDs, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "A create with servers in `server_ids` counts toward the limit that attach and detach share, 30 requests per organization per minute, with the code `rate_limited`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SshKeyCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "servers"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.create"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/ssh-keys/{slug}": {
      "delete": {
        "operationId": "delete_ssh_key",
        "summary": "Remove an SSH key that no server uses.",
        "description": "We remove it from every other zone in the background. The `slug` stays taken until the key is gone from every zone.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/ssh-keys/:slug",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "[^/]+"
            },
            "description": "The `slug` of the key to remove. Get it via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/).",
            "x-path-wildcard": false
          },
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "The ID of the team that owns the key. Send it when more than one of your teams has a key with this `slug`."
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A server still has the key attached, with the code `ssh_key_in_use`. Detach the key from every server first, via [Detach an SSH key](/docs/cloud/api/ssh-keys/detach-ssh-key/) with `all` set to `true`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "More than one of your teams has a key with this `slug`, and the request has no `team_id`, with the code `team_required`. The error's `details.team_ids` lists the teams.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_ssh_key",
        "summary": "Get an SSH key by its `slug`, with the key itself and the servers that have it.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/ssh-keys/:slug",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "[^/]+"
            },
            "description": "The `slug` of the key to get. Get it via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/).",
            "x-path-wildcard": false
          },
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "The ID of the team that owns the key. Send it when more than one of your teams has a key with this `slug`."
          }
        ],
        "responses": {
          "200": {
            "description": "A single ssh_key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SshKeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "More than one of your teams has a key with this `slug`, and the request has no `team_id`, with the code `team_required`. The error's `details.team_ids` lists the teams.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      },
      "patch": {
        "operationId": "update_ssh_key",
        "summary": "Update an SSH key's tags.",
        "description": "An update replaces every tag.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/ssh-keys/:slug",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "[^/]+"
            },
            "description": "The `slug` of the key to update. Get it via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/).",
            "x-path-wildcard": false
          },
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "The ID of the team that owns the key. Send it when more than one of your teams has a key with this `slug`."
          }
        ],
        "responses": {
          "200": {
            "description": "A single ssh_key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SshKeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "More than one of your teams has a key with this `slug`, and the request has no `team_id`, with the code `team_required`. The error's `details.team_ids` lists the teams.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SshKeyUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/ssh-keys/{slug}/attach": {
      "post": {
        "operationId": "attach_ssh_key",
        "summary": "Add the key to the root user's `authorized_keys` on running servers in this zone.",
        "description": "The key usually reaches each server within seconds. Each server records `ssh_key_attached` or `ssh_key_attach_failed` in its events. The key shows in the server's `ssh_keys` at once, and a later restore or rescue keeps it. Attaching a key that a server already has is safe, and puts the key back on the server if it went missing there.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/ssh-keys/:slug/attach",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "[^/]+"
            },
            "description": "The `slug` of the key to attach. Get it via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/).",
            "x-path-wildcard": false
          },
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "The ID of the team that owns the key. Send it when more than one of your teams has a key with this `slug`."
          }
        ],
        "responses": {
          "202": {
            "description": "A single ssh_key.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/SshKeyDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "servers": {
                          "type": "object",
                          "properties": {
                            "queued": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "The IDs of the servers we're changing."
                            },
                            "skipped": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "server_id": {
                                    "type": "string",
                                    "description": "The ID of the skipped server."
                                  },
                                  "reason": {
                                    "type": "string",
                                    "enum": [
                                      "kubernetes_managed",
                                      "locked",
                                      "server_not_running"
                                    ],
                                    "description": "Why we skipped the server.\n\n- `kubernetes_managed`: The server is a Kubernetes worker.\n- `locked`: The server is locked.\n- `server_not_running`: The server isn't running.",
                                    "x-enum-descriptions": {
                                      "kubernetes_managed": "The server is a Kubernetes worker.",
                                      "locked": "The server is locked.",
                                      "server_not_running": "The server isn't running."
                                    }
                                  }
                                }
                              },
                              "description": "The servers we skipped with `all`, each with a reason, empty when you send `server_ids`."
                            }
                          },
                          "description": "What we did with each server."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a key with this `slug` in your teams, or a server in `server_ids`, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A server in `server_ids` isn't running, with the code `server_not_running`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has neither or both of `server_ids` and `all`, or `server_ids` isn't a list of server IDs with at least one, with the code `validation_failed`. Or more than one of your teams has a key with this `slug` and the request has no `team_id`, with the code `team_required`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "A server in `server_ids` is locked, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Attach and detach share a limit of 30 requests per organization per minute, with the code `rate_limited`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of the servers to attach the key to. When one of them doesn't exist or can't get the key now, the request is refused and nothing changes. A repeated ID counts once.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "bindings": {
                        "status": {
                          "source": "literal",
                          "value": "running"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "all": {
                    "type": "boolean",
                    "description": "Whether to attach the key to every server in this zone. A server that can't get the key now is skipped and listed with a reason. Send either `all` or `server_ids`, never both.",
                    "x-cli-input": {
                      "order": 20
                    }
                  }
                },
                "anyOf": [
                  {
                    "required": [
                      "server_ids"
                    ]
                  },
                  {
                    "required": [
                      "all"
                    ]
                  }
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "servers"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.attach"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/ssh-keys/{slug}/detach": {
      "post": {
        "operationId": "detach_ssh_key",
        "summary": "Remove the key from the root user's `authorized_keys` on running servers in this zone.",
        "description": "Each server records `ssh_key_detached` or `ssh_key_detach_failed` in its events. The key leaves the server's `ssh_keys` once it's removed from the server. Detaching a key twice is safe.",
        "tags": [
          "ssh_key"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/ssh-keys/:slug/detach",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "[^/]+"
            },
            "description": "The `slug` of the key to detach. Get it via [List SSH keys](/docs/cloud/api/ssh-keys/list-ssh-keys/).",
            "x-path-wildcard": false
          },
          {
            "name": "team_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^t[1-9][0-9]*$"
            },
            "description": "The ID of the team that owns the key. Send it when more than one of your teams has a key with this `slug`."
          }
        ],
        "responses": {
          "202": {
            "description": "A single ssh_key.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/SshKeyDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "servers": {
                          "type": "object",
                          "properties": {
                            "queued": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "The IDs of the servers we're changing."
                            },
                            "skipped": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "server_id": {
                                    "type": "string",
                                    "description": "The ID of the skipped server."
                                  },
                                  "reason": {
                                    "type": "string",
                                    "enum": [
                                      "kubernetes_managed",
                                      "locked",
                                      "server_not_running"
                                    ],
                                    "description": "Why we skipped the server.\n\n- `kubernetes_managed`: The server is a Kubernetes worker.\n- `locked`: The server is locked.\n- `server_not_running`: The server isn't running.",
                                    "x-enum-descriptions": {
                                      "kubernetes_managed": "The server is a Kubernetes worker.",
                                      "locked": "The server is locked.",
                                      "server_not_running": "The server isn't running."
                                    }
                                  }
                                }
                              },
                              "description": "The servers we skipped with `all`, each with a reason, empty when you send `server_ids`."
                            }
                          },
                          "description": "What we did with each server."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a key with this `slug` in your teams, or a server in `server_ids`, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "A server in `server_ids` isn't running, with the code `server_not_running`. Or the server is a Kubernetes worker, with the code `kubernetes_managed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has neither or both of `server_ids` and `all`, or `server_ids` isn't a list of server IDs with at least one, with the code `validation_failed`. Or more than one of your teams has a key with this `slug` and the request has no `team_id`, with the code `team_required`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "A server in `server_ids` is locked, with the code `locked`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Attach and detach share a limit of 30 requests per organization per minute, with the code `rate_limited`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of the servers to detach the key from. When one of them doesn't exist or can't change now, the request is refused and nothing changes. A repeated ID counts once.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "bindings": {
                        "status": {
                          "source": "literal",
                          "value": "running"
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "all": {
                    "type": "boolean",
                    "description": "Whether to detach the key from every server in this zone that has it. A server that can't change now is skipped and listed with a reason. Send either `all` or `server_ids`, never both.",
                    "x-cli-input": {
                      "order": 20
                    }
                  }
                },
                "anyOf": [
                  {
                    "required": [
                      "server_ids"
                    ]
                  },
                  {
                    "required": [
                      "all"
                    ]
                  }
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "slug",
          "team_id",
          "created_at"
        ],
        "x-cli-name-fields": [
          "slug"
        ],
        "x-cli-response-fields": [
          "slug",
          "public_key",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "servers"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.ssh_key.attach"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "slug"
          ]
        }
      }
    },
    "/v1/valkey": {
      "get": {
        "operationId": "list_valkey",
        "summary": "List your Valkey instances in this zone.",
        "description": "The list includes `failed` and `destroyed` instances.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "provisioning",
                "running",
                "degraded",
                "rescaling",
                "upgrading",
                "restoring",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only instances with this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the instance with exactly this `name`."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only instances whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only instances with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match instances that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of valkey objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_valkey",
        "summary": "Create a Valkey instance.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the Valkey instance. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of Valkey instances, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The team, type, network or firewall doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another Valkey action is running in your organization at the same time, with the code `concurrent_create_limit`. Or we couldn't set up the instance, with the code `orchestration_failed`. List your instances before you try again, so you don't create a second one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "team_id": {
                    "type": "string",
                    "pattern": "^t[1-9][0-9]*$",
                    "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
                    "x-cli-input": {
                      "order": 10
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The instance's name, at most 255 characters. Must be unique among your organization's Valkey instances that aren't `destroyed` or `failed`.",
                    "x-cli-input": {
                      "order": 40
                    }
                  },
                  "type": {
                    "type": "string",
                    "description": "The instance's type, such as `VK2`. Get the types via [List Valkey types](/docs/cloud/api/valkey-types/list-valkey-types/).",
                    "x-cli-input": {
                      "order": 20,
                      "lookup": "list_valkey_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_memory_gb",
                        "max_connections"
                      ]
                    }
                  },
                  "engine_version": {
                    "type": "string",
                    "description": "The Valkey version, such as `9.1`. Get the versions via [List Valkey versions](/docs/cloud/api/valkey-versions/list-valkey-versions/). Defaults to the latest version.",
                    "x-cli-input": {
                      "order": 30,
                      "lookup": "list_valkey_version",
                      "value_field": "engine_version",
                      "label_fields": [
                        "engine_version",
                        "latest"
                      ]
                    }
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the instance has besides the primary, from `0` to `2`.",
                    "default": 0
                  },
                  "eviction_policy": {
                    "type": "string",
                    "enum": [
                      "noeviction",
                      "allkeys-lru",
                      "allkeys-lfu",
                      "allkeys-random",
                      "volatile-lru",
                      "volatile-lfu",
                      "volatile-random",
                      "volatile-ttl"
                    ],
                    "description": "What Valkey does when memory is full, as its `maxmemory-policy` setting.",
                    "x-enum-descriptions": {
                      "noeviction": "Valkey refuses writes when memory is full.",
                      "allkeys-lru": "Valkey evicts the least recently used keys.",
                      "allkeys-lfu": "Valkey evicts the least frequently used keys.",
                      "allkeys-random": "Valkey evicts random keys.",
                      "volatile-lru": "Valkey evicts the least recently used keys that have an expiry.",
                      "volatile-lfu": "Valkey evicts the least frequently used keys that have an expiry.",
                      "volatile-random": "Valkey evicts random keys that have an expiry.",
                      "volatile-ttl": "Valkey evicts the keys with an expiry that expire soonest."
                    },
                    "default": "noeviction"
                  },
                  "persistence": {
                    "type": "string",
                    "enum": [
                      "rdb",
                      "none"
                    ],
                    "description": "Whether Valkey keeps the data across restarts. Snapshots work either way.",
                    "x-enum-descriptions": {
                      "rdb": "Valkey keeps the data across restarts.",
                      "none": "Valkey keeps the data in memory only, as a pure cache."
                    },
                    "default": "rdb"
                  },
                  "public_access": {
                    "type": "boolean",
                    "description": "Whether the primary accepts connections with TLS on a public IP. Private networks work either way.",
                    "default": false
                  },
                  "network_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The IDs of the private networks attached to every node. Each network must be in the instance's team.",
                    "x-cli-input": {
                      "order": 70,
                      "group": "Advanced",
                      "lookup": "list_network",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ]
                    }
                  },
                  "firewall_ids": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. The firewall must be in the instance's team.",
                    "x-cli-input": {
                      "order": 80,
                      "group": "Advanced",
                      "lookup": "list_firewall",
                      "select": {
                        "team_id": {
                          "source": "request",
                          "path": [
                            "team_id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id"
                      ]
                    }
                  },
                  "term": {
                    "type": "string",
                    "enum": [
                      "monthly",
                      "annual"
                    ],
                    "description": "The billing term.",
                    "x-enum-descriptions": {
                      "monthly": "Billed each month.",
                      "annual": "Paid for a year at a time."
                    },
                    "default": "monthly"
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "team_id",
                  "name",
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the created resource reports running; not replica or broker health, TLS issuance, or client connectivity"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey-snapshots": {
      "get": {
        "operationId": "list_flat_valkey_snapshot",
        "summary": "List the snapshots of all your Valkey instances.",
        "description": "The list includes snapshots of deleted instances.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey-snapshots",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the snapshots of the Valkey instance with this ID."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of valkey_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_flat_valkey_snapshot",
        "summary": "Create a snapshot of the Valkey instance in `valkey_id`.",
        "description": "Valkey saves its data to disk first.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey-snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots or snapshot storage, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance in `valkey_id` doesn't exist, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, has no primary, or a snapshot of it is already being created, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `valkey_id`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another snapshot is being created in your organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "valkey_id": {
                    "type": "string",
                    "description": "The ID of the Valkey instance to create a snapshot of.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_valkey",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "team_id",
                        "status"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `cache-2026-11-24`.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
                  }
                },
                "required": [
                  "valkey_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_valkey_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey-snapshots/{id}": {
      "delete": {
        "operationId": "delete_flat_valkey_snapshot",
        "summary": "Delete an `available` or `failed` Valkey snapshot by its ID, also after its instance is deleted.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_flat_valkey_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_flat_valkey_snapshot",
        "summary": "Get a Valkey snapshot by its ID, also after its instance is deleted.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey-snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_flat_valkey_snapshot",
        "summary": "Create a new Valkey instance from an `available` snapshot, by the snapshot's ID alone.",
        "description": "The original instance must still exist.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey-snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, was saved without its instance's settings, or its instance is deleted, with the code `snapshot_not_restorable`. The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey-types": {
      "get": {
        "operationId": "list_valkey_type",
        "summary": "List the Valkey types we offer.",
        "description": "Returns every type in one page.",
        "tags": [
          "valkey_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey-types",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of valkey_type objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyTypeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_memory_gb",
          "max_connections"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_memory_gb",
          "max_connections",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/valkey-types/{name}": {
      "get": {
        "operationId": "get_valkey_type",
        "summary": "Get a Valkey type by its name.",
        "description": "You can also get a deprecated type that has a replacement.",
        "tags": [
          "valkey_type"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey-types/:name",
        "parameters": [
          {
            "name": "name",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The name of the type to get, such as `VK1`.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey_type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyTypeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist, or it's deprecated and has no replacement.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "name",
          "usable_memory_gb",
          "max_connections"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "name",
          "usable_memory_gb",
          "max_connections",
          "availability",
          "replacement"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_type.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "name"
          ]
        }
      }
    },
    "/v1/valkey-versions": {
      "get": {
        "operationId": "list_valkey_version",
        "summary": "List the Valkey versions we offer.",
        "description": "An instance's `available_engine_versions` lists the ones it can upgrade to.",
        "tags": [
          "valkey_version"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey-versions",
        "parameters": [],
        "responses": {
          "200": {
            "description": "A list of valkey_version objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-fields": [
          "engine_version",
          "latest"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_version.list"
        },
        "x-response-envelope": {
          "list_path": [
            "versions"
          ],
          "attributes_path": []
        }
      }
    },
    "/v1/valkey/{id}": {
      "delete": {
        "operationId": "delete_valkey",
        "summary": "Delete a Valkey instance and its snapshot schedules.",
        "description": "The instance is `destroyed` at once. The instance's snapshots stay.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance is already deleted, with the code `valkey_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_valkey",
        "summary": "Get a Valkey instance.",
        "description": "Get its `auth_token` via [Get a Valkey instance's credentials](/docs/cloud/api/valkeys/credentials-valkey/).",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the resource currently reports running; not client connectivity or earlier operation completion"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_valkey",
        "summary": "Update a Valkey instance's `name`, `metadata`, `eviction_policy`, `persistence`, `public_access`, `replica_count` or `term`.",
        "description": "Changes apply without a restart.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/valkey/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "202": {
            "description": "A single valkey. (`public_access` or `replica_count` changes, which we apply shortly after the response)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `name`, `eviction_policy`, `persistence`, `replica_count` or `term` isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ValkeyUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "when": {
            "path": [
              "replica_count"
            ],
            "at_least": {
              "source": "literal",
              "value": 0
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "any": [
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 0
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 1
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      }
                    ]
                  },
                  {
                    "all": [
                      {
                        "path": [
                          "replica_count"
                        ],
                        "expected": {
                          "source": "literal",
                          "value": 2
                        }
                      },
                      {
                        "path": [
                          "members"
                        ],
                        "count": true,
                        "expected": {
                          "source": "literal",
                          "value": 3
                        }
                      }
                    ]
                  }
                ]
              },
              {
                "path": [
                  "members"
                ],
                "every": {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "When the request sets replica_count, the instance is running with a primary and that many replicas, every member running. A change of only public_access or other settings is sent without waiting, and the TLS endpoint is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/credentials": {
      "get": {
        "operationId": "credentials_valkey",
        "summary": "Get a Valkey instance's `auth_token` and the URIs to connect with.",
        "description": "You can get them again at any time while the instance exists.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:id/credentials",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the credentials as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The username, always `default`."
                    },
                    "auth_token": {
                      "type": "string",
                      "description": "The AUTH token.",
                      "x-sensitive": true
                    },
                    "uri": {
                      "type": "string",
                      "description": "A `valkey://` URI for your private networks, with the `auth_token` in it.",
                      "x-sensitive": true
                    },
                    "tls_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "A `valkeys://` URI for the public TLS endpoint, with the `auth_token` in it, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The CA certificate to verify the public TLS endpoint with, in PEM format, or `null` when `public_access` is off."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous token stops working after a rotation, or `null` when no rotation is in progress."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance is deleted, with the code `valkey_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "auth_token",
          "uri",
          "tls_uri",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/valkey/{id}/credentials/rotate": {
      "post": {
        "operationId": "rotate_valkey_credentials",
        "summary": "Generate a new `auth_token` for a Valkey instance.",
        "description": "The previous token keeps working for 24 hours, until `rotating_until`. A second rotation in that time stops the oldest token at once. Open connections stay open. The instance must be `running` or `degraded`.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/credentials/rotate",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance whose credentials to rotate.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "Returns the new credentials as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "user": {
                      "type": "string",
                      "description": "The username, always `default`."
                    },
                    "auth_token": {
                      "type": "string",
                      "description": "The new AUTH token.",
                      "x-sensitive": true
                    },
                    "uri": {
                      "type": "string",
                      "description": "A `valkey://` URI for your private networks, with the new `auth_token` in it.",
                      "x-sensitive": true
                    },
                    "tls_uri": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "A `valkeys://` URI for the public TLS endpoint, with the new `auth_token` in it, or `null` when `public_access` is off.",
                      "x-sensitive": true
                    },
                    "ca_certificate": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The CA certificate to verify the public TLS endpoint with, in PEM format, or `null` when `public_access` is off."
                    },
                    "rotating_until": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "format": "date-time",
                      "description": "When the previous token stops working, 24 hours from now."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "user",
          "auth_token",
          "uri",
          "tls_uri",
          "ca_certificate",
          "rotating_until"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.rotate_credentials"
        },
        "x-cli-export": {
          "format": "json"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/valkey/{id}/failover": {
      "post": {
        "operationId": "failover_valkey",
        "summary": "Make a replica the primary of a Valkey instance, without losing written data, such as to test failover.",
        "description": "The instance needs a running primary and a running replica. Writes fail for about 20 seconds, until your client reconnects to the hostname.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/failover",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance to fail over.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, with the code `valkey_busy`. Or the instance has no running primary and running replica, with the code `no_failover_target`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_valkey",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "members"
            ],
            "matching": {
              "source": "before",
              "path": [
                "members"
              ]
            },
            "match_by": "id",
            "every": {
              "not": {
                "all": [
                  {
                    "path": [
                      "role"
                    ],
                    "expected": {
                      "source": "literal",
                      "value": "primary"
                    }
                  },
                  {
                    "path": [
                      "role"
                    ],
                    "expected": {
                      "source": "matched",
                      "path": [
                        "role"
                      ]
                    }
                  }
                ]
              }
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "The member that was primary before the request is now a replica. A switchover Cloud skips or gives up on leaves no trace in the instance, so the wait then runs until its timeout."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/firewalls": {
      "post": {
        "operationId": "attach_valkey_firewall",
        "summary": "Attach a firewall to a Valkey instance.",
        "description": "The firewall must be in the instance's team. An instance can have at most one firewall. We apply the firewall shortly after the response.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/firewalls",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance to attach the firewall to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance's team has no firewall with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance already has a firewall, with the code `firewall_limit_reached`. Or the instance has no node to attach it to, with the code `valkey_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "firewall_id": {
                    "type": "string",
                    "description": "The ID of the firewall to attach."
                  }
                },
                "required": [
                  "firewall_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/firewalls/{firewall_id}": {
      "delete": {
        "operationId": "detach_valkey_firewall",
        "summary": "Detach a firewall from a Valkey instance.",
        "description": "We remove the firewall shortly after the response.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey/:id/firewalls/:firewall_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance to detach the firewall from.",
            "x-path-wildcard": false
          },
          {
            "name": "firewall_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the firewall to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/valkey/{id}/metrics": {
      "get": {
        "operationId": "metrics_valkey",
        "summary": "Get a Valkey instance's metrics over time for each node, such as memory, clients, operations and hit ratio.",
        "description": "Defaults to the last day. A range can be at most 366 days.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:id/metrics",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The start of the range. Defaults to one day before `to`."
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "description": "The end of the range. Defaults to now."
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the metrics as one object.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "valkey_id": {
                      "type": "string",
                      "description": "The instance's ID, a UUID."
                    },
                    "valkey_name": {
                      "type": "string",
                      "description": "The instance's name."
                    },
                    "from": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The start of the range, included."
                    },
                    "to": {
                      "type": "string",
                      "format": "date-time",
                      "description": "The end of the range, not included."
                    },
                    "resolution": {
                      "type": "string",
                      "enum": [
                        "raw",
                        "hourly"
                      ],
                      "description": "How far apart the points are.",
                      "x-enum-descriptions": {
                        "raw": "One point a minute, for a range up to one day.",
                        "hourly": "One point an hour, for a longer range."
                      }
                    },
                    "members": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "member_id": {
                            "type": "string",
                            "description": "The node's ID."
                          },
                          "role": {
                            "type": "string",
                            "description": "The node's role, `primary` or `replica`."
                          },
                          "data": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "dt": {
                                  "type": "string",
                                  "format": "date-time",
                                  "description": "The start of the minute or hour the point covers."
                                },
                                "memory": {
                                  "type": "object",
                                  "properties": {
                                    "used_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The average memory used, in bytes."
                                    },
                                    "used_bytes_max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most memory used, in bytes."
                                    },
                                    "usable_bytes": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The type's memory for your data, in bytes."
                                    }
                                  },
                                  "description": "Memory use."
                                },
                                "clients": {
                                  "type": "object",
                                  "properties": {
                                    "connected": {
                                      "type": "number",
                                      "description": "The average number of connected clients."
                                    },
                                    "connected_max": {
                                      "type": "integer",
                                      "format": "int64",
                                      "description": "The most connected clients."
                                    }
                                  },
                                  "description": "Connected clients."
                                },
                                "operations_per_second": {
                                  "type": "number",
                                  "description": "Commands per second."
                                },
                                "hit_ratio": {
                                  "type": "number",
                                  "description": "The share of key lookups that found the key, from 0 to 1."
                                },
                                "evicted_keys_per_second": {
                                  "type": "number",
                                  "description": "Keys evicted per second."
                                },
                                "expired_keys_per_second": {
                                  "type": "number",
                                  "description": "Keys expired per second."
                                },
                                "replication_lag_bytes": {
                                  "type": "integer",
                                  "format": "int64",
                                  "description": "How far a replica is behind the primary, in bytes."
                                }
                              }
                            },
                            "description": "The node's metrics, one entry per point."
                          }
                        }
                      },
                      "description": "The metrics of each node."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A time isn't valid, `from` isn't before `to`, or the range is longer than 366 days, with the code `invalid_range`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't read the metrics, with the code `metrics_unavailable`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-response-fields": [
          "valkey_id",
          "valkey_name",
          "from",
          "to",
          "resolution",
          "members"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.metrics"
        },
        "x-response-envelope": {
          "item_path": [],
          "attributes_path": []
        }
      }
    },
    "/v1/valkey/{id}/networks": {
      "post": {
        "operationId": "attach_valkey_network",
        "summary": "Attach a private network to a Valkey instance.",
        "description": "The network must be in the instance's team. Each node gets an address in the network shortly after the response.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/networks",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance to attach the network to.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance's team has no private network with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The network is already attached, with the code `already_attached`. Or the instance has no node to attach it to, with the code `valkey_unavailable`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "network_id": {
                    "type": "string",
                    "description": "The ID of the private network to attach."
                  }
                },
                "required": [
                  "network_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/networks/{network_id}": {
      "delete": {
        "operationId": "detach_valkey_network",
        "summary": "Detach a private network from a Valkey instance.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey/:id/networks/:network_id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance to detach the network from.",
            "x-path-wildcard": false
          },
          {
            "name": "network_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the private network to detach.",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/valkey/{id}/rescale": {
      "post": {
        "operationId": "rescale_valkey",
        "summary": "Change a Valkey instance's type.",
        "description": "We resize the nodes one at a time, replicas first. A smaller type is refused unless the primary's data fits in 90% of its memory.",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/rescale",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The type doesn't exist.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The data doesn't fit the smaller type, with the code `does_not_fit`. Or the instance already has this type, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "description": "The new type. Must differ from the current one.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_valkey_type",
                      "value_field": "name",
                      "label_fields": [
                        "name",
                        "usable_memory_gb",
                        "max_connections"
                      ]
                    }
                  }
                },
                "required": [
                  "type"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "not": {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              },
              {
                "path": [
                  "type"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "type"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "status_message"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "the rescale did not complete; some members may still be resizing — contact support if this persists"
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "Every member was resized to the requested plan and the instance is running again without a rescale error. Client reconnection is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/restore": {
      "post": {
        "operationId": "restore_valkey",
        "summary": "Restore a snapshot onto a Valkey instance.",
        "description": "The instance keeps its hostname, `auth_token`, networks and firewall. The instance gets the Valkey version the snapshot has, which can be older. A snapshot of an earlier primary, such as one taken before a failover, can only be restored to a new instance with [Restore a Valkey instance's snapshot](/docs/cloud/api/valkey-snapshots/restore-valkey-snapshot/).",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The instance has no snapshot with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, the snapshot isn't `available`, or the snapshot is of an earlier primary.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request has no `snapshot_id`, or the value isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "snapshot_id": {
                    "type": "string",
                    "description": "The ID of the snapshot to restore. Must be a snapshot of the instance's current primary.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_valkey_snapshot",
                      "bindings": {
                        "valkey_id": {
                          "source": "params",
                          "path": [
                            "id"
                          ]
                        }
                      },
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "id",
                        "status",
                        "created_at"
                      ]
                    }
                  }
                },
                "required": [
                  "snapshot_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance returned to running after accepted restore; restored data still requires verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{id}/upgrade": {
      "post": {
        "operationId": "upgrade_valkey",
        "summary": "Upgrade a Valkey instance to a newer Valkey version, at most one major version up.",
        "description": "We create a snapshot first and upgrade once the snapshot is done. The upgrade can't be undone. To go back, restore that snapshot onto the instance with [Restore a Valkey instance](/docs/cloud/api/valkeys/restore-valkey/).",
        "tags": [
          "valkey"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:id/upgrade",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ValkeyDocument"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "pre_upgrade_snapshot_id": {
                          "type": "string",
                          "description": "The ID of the snapshot we created before the upgrade. Later responses don't include it."
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots, with the code `quota_exceeded`. We create a snapshot before the upgrade, so the upgrade needs room for one more.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, or we can't create the snapshot now, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The version isn't one of `available_engine_versions`, with the code `invalid_engine_version`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "engine_version": {
                    "type": "string",
                    "description": "The version to upgrade to, one of `available_engine_versions`."
                  }
                },
                "required": [
                  "engine_version"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata",
          "pre_upgrade_snapshot_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.upgrade"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "before": "get_valkey",
          "before_bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "running"
                }
              },
              {
                "path": [
                  "engine_version"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "engine_version"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            },
            {
              "all": [
                {
                  "path": [
                    "status"
                  ],
                  "expected": {
                    "source": "literal",
                    "value": "running"
                  }
                },
                {
                  "path": [
                    "engine_version"
                  ],
                  "expected": {
                    "source": "before",
                    "path": [
                      "engine_version"
                    ]
                  }
                }
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the instance reports running on the requested engine line; not workload verification"
        },
        "x-cli-one-time-fields": [
          "pre_upgrade_snapshot_id"
        ],
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/events": {
      "get": {
        "operationId": "list_valkey_event",
        "summary": "List a Valkey instance's events.",
        "description": "You can still list them after the instance is deleted.",
        "tags": [
          "valkey_event"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:valkey_id/events",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of valkey_event objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyEventList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "action",
          "actor",
          "created_at"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "action",
          "user_id",
          "actor",
          "details",
          "created_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_event.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/scheduled-snapshots": {
      "get": {
        "operationId": "list_valkey_scheduled_snapshot",
        "summary": "List a Valkey instance's snapshot schedules.",
        "tags": [
          "valkey_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:valkey_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of valkey_scheduled_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyScheduledSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "valkey_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_valkey_scheduled_snapshot",
        "summary": "Create a snapshot schedule for a Valkey instance.",
        "description": "The instance must be `running` or `degraded` and have a primary. The schedule counts toward your organization's limit of snapshot schedules. The first snapshot follows the schedule.",
        "tags": [
          "valkey_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:valkey_id/scheduled-snapshots",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "201": {
            "description": "A single valkey_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshot schedules, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, or it has no primary, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `frequency` is missing or isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ValkeyScheduledSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "valkey_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_valkey_scheduled_snapshot",
        "summary": "Delete a snapshot schedule.",
        "description": "The snapshots the schedule already created are kept.",
        "tags": [
          "valkey_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey/:valkey_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_valkey_scheduled_snapshot",
        "summary": "Get a snapshot schedule of a Valkey instance.",
        "tags": [
          "valkey_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:valkey_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "valkey_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_valkey_scheduled_snapshot",
        "summary": "Change how often a snapshot schedule creates snapshots.",
        "tags": [
          "valkey_scheduled_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/valkey/:valkey_id/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey_scheduled_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyScheduledSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ValkeyScheduledSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "valkey_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "server_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_scheduled_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/snapshots": {
      "get": {
        "operationId": "list_valkey_snapshot",
        "summary": "List a Valkey instance's snapshots, with their status and size.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:valkey_id/snapshots",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of valkey_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_valkey_snapshot",
        "summary": "Create a snapshot of a Valkey instance from its current primary.",
        "description": "Valkey saves its data to disk first.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:valkey_id/snapshots",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of snapshots or snapshot storage, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The instance isn't `running` or `degraded`, has no primary, or a snapshot of it is already being created, with the code `valkey_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another snapshot is being created in your organization at the same time, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `cache-2026-11-24`."
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "valkey_id": {
              "source": "params",
              "path": [
                "valkey_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/snapshots/{id}": {
      "delete": {
        "operationId": "delete_valkey_snapshot",
        "summary": "Delete an `available` or `failed` snapshot of a Valkey instance.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/valkey/:valkey_id/snapshots/:id",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            },
            "valkey_id": {
              "source": "params",
              "path": [
                "valkey_id"
              ]
            }
          },
          "disappearance": true,
          "description": "the snapshot is no longer available through this API; not independently verified storage erasure"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_valkey_snapshot",
        "summary": "Get a snapshot of a Valkey instance, with its status and size.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/valkey/:valkey_id/snapshots/:id",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single valkey_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeySnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "valkey_id",
          "status",
          "size_bytes",
          "created_at"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "valkey_id",
          "name",
          "server_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            },
            "valkey_id": {
              "source": "params",
              "path": [
                "valkey_id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "the snapshot is available; not application-consistent data verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/valkey/{valkey_id}/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_valkey_snapshot",
        "summary": "Create a new Valkey instance from an `available` snapshot, in the same team and zone.",
        "description": "The new instance gets the snapshot's data, type, Valkey version, eviction policy and persistence setting. The new instance gets its own ID, hostname and `auth_token`. The new instance's `public_access` is `false`. The replicas are added once the primary is ready.",
        "tags": [
          "valkey_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/valkey/:valkey_id/snapshots/:id/restore",
        "parameters": [
          {
            "name": "valkey_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the Valkey instance. Get it via [List Valkey instances](/docs/cloud/api/valkeys/list-valkeys/).",
            "x-path-wildcard": false
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single valkey.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ValkeyDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of Valkey instances, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "The snapshot doesn't exist, or the type it was taken on no longer exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, or was saved without its instance's settings, with the code `snapshot_not_restorable`. The zone has no capacity, with the code `no_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value for the new instance isn't valid, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Another Valkey action is running in your organization at the same time, with the code `concurrent_create_limit`. Or we couldn't set up the new instance, with the code `orchestration_failed`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The new instance's name. Defaults to the original instance's name followed by `-restored-` and four random characters."
                  },
                  "replica_count": {
                    "type": "integer",
                    "format": "int64",
                    "description": "How many replicas the new instance has, from `0` to `2`. Defaults to the number the instance had when the snapshot was taken."
                  }
                }
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "type",
          "engine_version",
          "replica_count"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "type",
          "usable_memory_gb",
          "max_connections",
          "engine_version",
          "available_engine_versions",
          "status",
          "status_message",
          "eviction_policy",
          "persistence",
          "public_access",
          "replica_count",
          "endpoint",
          "members",
          "network_ids",
          "firewall_ids",
          "latest_snapshot_at",
          "term",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.valkey.list"
        },
        "x-cli-wait": {
          "observe": "get_valkey",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "running"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "destroyed",
                "degraded"
              ]
            }
          ],
          "messages": [
            "status_message"
          ],
          "description": "the new returned instance reports running; replicas and restored data still require verification"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes": {
      "get": {
        "operationId": "list_volume",
        "summary": "List the volumes in this zone.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "creating",
                "attaching",
                "attached",
                "detaching",
                "available",
                "moving",
                "resizing",
                "snapshotting",
                "deleting",
                "failed",
                "destroyed"
              ]
            },
            "description": "Only volumes in this status."
          },
          {
            "name": "name",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only the volume with exactly this `name`."
          },
          {
            "name": "server_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only volumes attached to this server."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only volumes whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only volumes with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match volumes that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of volume objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_volume",
        "summary": "Create a volume and attach it to a server.",
        "description": "With `auto_mount`, the server mounts the volume once the server is running.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "Your organization hasn't made its first payment yet, with the code `payment_required`. The error can also have `first_purchase`, with the `url` of a page where you make the payment. Paying creates the volume. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of volumes or volume storage, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The server isn't running or stopped, or you asked for a `format` on a server that isn't running, with the code `server_not_running`. Or the server's host doesn't have enough disk space, with the code `insufficient_host_capacity`. Contact support to move the server to another host.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "Too many volumes are being created at the same time in the organization, with the code `concurrent_create_limit`. Try again shortly.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The volume's name, unique among the organization's volumes. A deleted volume's name can be used again.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "size_gb": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The volume's size in GiB, from 1 to 3072.",
                    "x-cli-input": {
                      "order": 30
                    }
                  },
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to attach the volume to. Get it via [List servers](/docs/cloud/api/servers/list-servers/). The server must be running or stopped. The volume belongs to the server's team and is stored on the server's host. A server can have up to 10 volumes.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status",
                        "server_type"
                      ]
                    }
                  },
                  "volume_type": {
                    "type": "string",
                    "enum": [
                      "nvme"
                    ],
                    "description": "The kind of storage, always `nvme`.",
                    "x-cli-input": {
                      "order": 110,
                      "group": "Advanced"
                    },
                    "default": "nvme"
                  },
                  "format": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "enum": [
                      "ext4",
                      "xfs",
                      null
                    ],
                    "description": "The filesystem to create on the volume. The server must be running to create one. Leave it out or send `null` for a volume without a filesystem.",
                    "x-cli-input": {
                      "order": 40
                    }
                  },
                  "auto_mount": {
                    "type": "boolean",
                    "description": "Whether the server mounts the volume automatically. Needs a `format`.",
                    "x-cli-input": {
                      "order": 50
                    },
                    "default": false
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "name",
                  "size_gb",
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "attached"
                }
              },
              {
                "path": [
                  "server_id"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "server_id"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "attached",
                "available",
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Created volume is attached to the requested server; an available surviving volume is not successful attachment, and guest mount readiness is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/scheduled-snapshots": {
      "get": {
        "operationId": "list_scheduled_volume_snapshot",
        "summary": "List the volume snapshot schedules in this zone.",
        "tags": [
          "scheduled_volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes/scheduled-snapshots",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of scheduled_volume_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledVolumeSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_scheduled_volume_snapshot",
        "summary": "Create a snapshot schedule for a volume.",
        "description": "A schedule's snapshots count toward the same limit as the ones you create yourself, and have the `snapshot_type` `scheduled`.",
        "tags": [
          "scheduled_volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes/scheduled-snapshots",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single scheduled_volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledVolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a volume with this ID, with the code `not_found`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The volume is deleted, with the code `volume_destroyed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `volume_id`, or `frequency` isn't `hourly`, `daily`, `weekly` or `monthly`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduledVolumeSnapshotCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/scheduled-snapshots/{id}": {
      "delete": {
        "operationId": "delete_scheduled_volume_snapshot",
        "summary": "Remove a snapshot schedule.",
        "description": "We keep the snapshots it has already created.",
        "tags": [
          "scheduled_volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/volumes/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to remove. Get it via [List volume snapshot schedules](/docs/cloud/api/scheduled-volume-snapshots/list-scheduled-volume-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_scheduled_volume_snapshot",
        "summary": "Get a volume's snapshot schedule, with how often it runs and when it last ran.",
        "tags": [
          "scheduled_volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to get. Get it via [List volume snapshot schedules](/docs/cloud/api/scheduled-volume-snapshots/list-scheduled-volume-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single scheduled_volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledVolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_scheduled_volume_snapshot",
        "summary": "Change how often a schedule creates snapshots.",
        "description": "A schedule's volume can't be changed.",
        "tags": [
          "scheduled_volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/volumes/scheduled-snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "The ID of the snapshot schedule to update. Get it via [List volume snapshot schedules](/docs/cloud/api/scheduled-volume-snapshots/list-scheduled-volume-snapshots/).",
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single scheduled_volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScheduledVolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The `frequency` isn't `hourly`, `daily`, `weekly` or `monthly`, with the code `validation_failed`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduledVolumeSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at"
        ],
        "x-cli-name-fields": [
          "frequency"
        ],
        "x-cli-response-fields": [
          "id",
          "volume_id",
          "frequency",
          "last_run_at",
          "created_at",
          "updated_at"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.scheduled_volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/snapshots": {
      "get": {
        "operationId": "list_volume_snapshot",
        "summary": "List the volume snapshots in this zone.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes/snapshots",
        "parameters": [
          {
            "name": "volume_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only snapshots of the volume with this ID."
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only snapshots whose `name` contains this text, ignoring case."
          },
          {
            "name": "metadata",
            "in": "query",
            "required": false,
            "schema": {
              "type": "object",
              "additionalProperties": true
            },
            "description": "Only snapshots with this tag, sent as `metadata[<key>]=<value>`. Repeat it to match snapshots that have every given tag."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of volume_snapshot objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeSnapshotList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "volume_id",
          "status",
          "size_gb",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "volume_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "size_gb",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_volume_snapshot",
        "summary": "Create a snapshot of a volume.",
        "description": "We keep the snapshot in object storage.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes/snapshots",
        "parameters": [],
        "responses": {
          "202": {
            "description": "A single volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "Your organization has reached its limit of volume snapshots, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a volume with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The volume is deleted, with the code `volume_destroyed`. Or another change to the volume is in progress, with the code `volume_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "volume_id": {
                    "type": "string",
                    "description": "The ID of the volume to back up. Get it via [List volumes](/docs/cloud/api/volumes/list-volumes/).",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_volume",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status",
                        "size_gb",
                        "server_id"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The snapshot's name. Defaults to the volume's name and the date.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "volume_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "volume_id",
          "status",
          "size_gb",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "volume_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "size_gb",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_volume_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Captured volume snapshot is available; application-consistent backup is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/snapshots/{id}": {
      "delete": {
        "operationId": "delete_volume_snapshot",
        "summary": "Remove a volume snapshot.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/volumes/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot is still being created or already being deleted, with the code `volume_snapshot_busy`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "volume_id",
          "status",
          "size_gb",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "volume_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "size_gb",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_volume_snapshot",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "disappearance": true,
          "description": "Volume snapshot is no longer available through this API after accepted deletion; scope changes may also hide it, and physical storage erasure is not independently verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_volume_snapshot",
        "summary": "Get a volume snapshot, with its status and size.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "volume_id",
          "status",
          "size_gb",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "volume_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "size_gb",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume_snapshot.list"
        },
        "x-cli-wait": {
          "observe": "get_volume_snapshot",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "available"
            }
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Volume snapshot is available; application-consistent backup is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_volume_snapshot",
        "summary": "Change a volume snapshot's name or tags.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/volumes/snapshots/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single volume_snapshot.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeSnapshotDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VolumeSnapshotUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "volume_id",
          "status",
          "size_gb",
          "availability_zone"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "volume_id",
          "snapshot_type",
          "status",
          "size_bytes",
          "size_gb",
          "availability_zone",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume_snapshot.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/snapshots/{id}/restore": {
      "post": {
        "operationId": "restore_volume_snapshot",
        "summary": "Create a new volume from the snapshot and attach it to a server.",
        "description": "The original volume stays as it is.",
        "tags": [
          "volume_snapshot"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes/snapshots/:id/restore",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The new volume would put your organization over its limit of volumes or volume storage, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The snapshot isn't `available`, with the code `volume_snapshot_not_restorable`. Or the server is deleted or can't get a volume in its current status, with the code `server_destroyed` or `server_busy`. Or the server's host has no room for the volume, with the code `insufficient_host_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to attach the new volume to. Get it via [List servers](/docs/cloud/api/servers/list-servers/). We create the volume on that server's host.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status",
                        "server_type"
                      ]
                    }
                  },
                  "name": {
                    "type": "string",
                    "description": "The new volume's name. Defaults to the snapshot's name followed by `-restored-` and four random characters.",
                    "x-cli-input": {
                      "order": 20
                    }
                  },
                  "auto_mount": {
                    "type": "boolean",
                    "description": "Whether the server mounts the new volume's filesystem automatically when it's attached.",
                    "x-cli-input": {
                      "order": 30
                    },
                    "default": false
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": true,
                    "description": "Your own tags, as string keys and values. At most 10.",
                    "x-cli-input": {
                      "order": 100,
                      "group": "Advanced"
                    }
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "attached"
                }
              },
              {
                "path": [
                  "server_id"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "server_id"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "attached",
                "available",
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "New returned volume is attached to the requested server on this destination; an available surviving volume is not successful attachment, and guest mount/data readiness is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/{id}": {
      "delete": {
        "operationId": "delete_volume",
        "summary": "Remove a volume and the data on it.",
        "description": "Detach the volume first. A delete can't be undone, so if you might want the data back, create a snapshot first via [Create a volume snapshot](/docs/cloud/api/volume-snapshots/create-volume-snapshot/).",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/volumes/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The volume is still attached, with the code `volume_attached`. Or another change to the volume is in progress.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "expected": {
              "source": "literal",
              "value": "destroyed"
            }
          },
          "messages": [
            "failure_reason"
          ],
          "description": "Volume reached destroyed after node-side block-device deletion; unlike server deletion, this tombstone is set after deletion work."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "get": {
        "operationId": "get_volume",
        "summary": "Get a volume, with its status, size and the server it's attached to.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/volumes/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "params",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "path": [
              "status"
            ],
            "in": [
              "attached",
              "available"
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Volume is currently attached or available; this does not verify earlier attachment/resize success or guest mount readiness."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_volume",
        "summary": "Change a volume's `name` or `metadata`.",
        "description": "To make the volume larger, use [Resize a volume](/docs/cloud/api/volumes/resize-volume/).",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/volumes/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VolumeUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/{id}/attach": {
      "delete": {
        "operationId": "detach_volume",
        "summary": "Detach a volume from its server.",
        "description": "Unmount the volume on the server first, so its filesystem stays clean.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/volumes/:id/attach",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The volume isn't attached, with the code `volume_not_attached`. Or another change to the volume is in progress.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "available"
                }
              },
              {
                "path": [
                  "server_id"
                ],
                "expected": {
                  "source": "literal",
                  "value": null
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "attached",
                "available",
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Volume is available with no attached server; a failed detach remaining attached is not success."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "attach_volume",
        "summary": "Attach a volume to a server.",
        "description": "When the server is on another host, we copy the volume there first. A large volume needs longer to copy.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes/:id/attach",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a server with this ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The volume is already attached, with the code `volume_attached`. Or the server isn't running or stopped, or another change to the volume is in progress. Or the server's host doesn't have enough disk space, with the code `insufficient_host_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "server_id": {
                    "type": "string",
                    "description": "The ID of the server to attach the volume to. Get it via [List servers](/docs/cloud/api/servers/list-servers/). The server must be running or stopped.",
                    "x-cli-input": {
                      "order": 10,
                      "lookup": "list_server",
                      "value_field": "id",
                      "label_fields": [
                        "name",
                        "team_id",
                        "status",
                        "server_type"
                      ]
                    }
                  }
                },
                "required": [
                  "server_id"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "expected": {
                  "source": "literal",
                  "value": "attached"
                }
              },
              {
                "path": [
                  "server_id"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "server_id"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "attached",
                "available",
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Volume is attached to the requested server; an available surviving volume is not successful attachment, and guest mount readiness is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/volumes/{id}/resize": {
      "post": {
        "operationId": "resize_volume",
        "summary": "Make a volume larger.",
        "description": "On a mounted volume with a filesystem we created, we grow the filesystem too. Check the filesystem's size on the server once the resize is done.",
        "tags": [
          "volume"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/volumes/:id/resize",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single volume.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VolumeDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The new size would put your organization over its limit of volume storage, with the code `quota_exceeded`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "Another change to the volume is in progress. Or the volume's host doesn't have enough disk space, with the code `insufficient_host_capacity`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The new size isn't larger than the current one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "size_gb": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The new size in GiB, up to 3072. Must be larger than the current size.",
                    "x-cli-input": {
                      "order": 10
                    }
                  }
                },
                "required": [
                  "size_gb"
                ]
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "status",
          "size_gb",
          "server_id"
        ],
        "x-cli-name-fields": [
          "name"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "status",
          "volume_type",
          "size_gb",
          "server_id",
          "format",
          "auto_mount",
          "mount_path",
          "device_path",
          "failure_reason",
          "lock",
          "created_at",
          "updated_at",
          "team_id",
          "metadata"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.volume.list"
        },
        "x-cli-wait": {
          "observe": "get_volume",
          "bindings": {
            "id": {
              "source": "result",
              "path": [
                "id"
              ]
            }
          },
          "success": {
            "all": [
              {
                "path": [
                  "status"
                ],
                "in": [
                  "attached",
                  "available"
                ]
              },
              {
                "path": [
                  "size_gb"
                ],
                "expected": {
                  "source": "request",
                  "path": [
                    "size_gb"
                  ]
                }
              }
            ]
          },
          "failure": [
            {
              "path": [
                "status"
              ],
              "in": [
                "attached",
                "available",
                "failed",
                "deleting",
                "destroyed"
              ]
            }
          ],
          "messages": [
            "failure_reason"
          ],
          "description": "Volume settled at the requested block-device size; a settled old size is failure, and guest filesystem growth is not verified."
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/webhooks": {
      "get": {
        "operationId": "list_webhook",
        "summary": "List the webhooks in this zone.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/webhooks",
        "parameters": [
          {
            "name": "query",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Only webhooks whose `name` or `url` contains this text, ignoring case."
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 1
            },
            "description": "The page to return, starting at 1."
          },
          {
            "name": "per_page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int64",
              "default": 25,
              "maximum": 1000
            },
            "description": "How many entries to return per page."
          }
        ],
        "responses": {
          "200": {
            "description": "A list of webhook objects.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookList"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "url",
          "status",
          "failed_deliveries"
        ],
        "x-cli-name-fields": [
          "name",
          "url"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "url",
          "webhook_types",
          "status",
          "failed_deliveries",
          "secret",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.webhook.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "post": {
        "operationId": "create_webhook",
        "summary": "Create a webhook.",
        "description": "We create the webhook's secret for you. To create the webhook without sending notifications yet, set `status` to `paused`.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/webhooks",
        "parameters": [],
        "responses": {
          "201": {
            "description": "A single webhook.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "The request is missing `team_id`, `name`, `url` or `webhook_types`, a kind in `webhook_types` isn't supported, or `status` isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookCreate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "url",
          "status",
          "failed_deliveries"
        ],
        "x-cli-name-fields": [
          "name",
          "url"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "url",
          "webhook_types",
          "status",
          "failed_deliveries",
          "secret",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.webhook.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/webhooks/{id}": {
      "delete": {
        "operationId": "delete_webhook",
        "summary": "Remove a webhook.",
        "description": "We stop sending notifications to it at once.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "DELETE /v1/webhooks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "204": {
            "description": "No content."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        }
      },
      "get": {
        "operationId": "get_webhook",
        "summary": "Get a webhook, with the secret we sign its notifications with.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "read",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "GET /v1/webhooks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single webhook.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "A rule of the resource forbids the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "url",
          "status",
          "failed_deliveries"
        ],
        "x-cli-name-fields": [
          "name",
          "url"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "url",
          "webhook_types",
          "status",
          "failed_deliveries",
          "secret",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.webhook.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      },
      "patch": {
        "operationId": "update_webhook",
        "summary": "Update a webhook's name, URL, kinds of resources or status.",
        "description": "To stop notifications for a while, set `status` to `paused` instead of deleting the webhook.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "PATCH /v1/webhooks/:id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "200": {
            "description": "A single webhook.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WebhookUpdate"
              }
            }
          }
        },
        "x-request-envelope": {
          "attributes_path": []
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "url",
          "status",
          "failed_deliveries"
        ],
        "x-cli-name-fields": [
          "name",
          "url"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "url",
          "webhook_types",
          "status",
          "failed_deliveries",
          "secret",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.webhook.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    },
    "/v1/webhooks/{id}/test": {
      "post": {
        "operationId": "test_webhook",
        "summary": "Send a test notification for each kind of resource the webhook covers.",
        "description": "Each test notification has `event` set to `test` and `data` set to `null`. We send the notifications shortly after, so check your endpoint to see that they arrived.",
        "tags": [
          "webhook"
        ],
        "security": [
          {
            "teamApiToken": []
          },
          {
            "globalApiToken": []
          }
        ],
        "x-access": "write",
        "x-api": "cloud",
        "x-cli": true,
        "x-endpoint": "POST /v1/webhooks/:id/test",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "x-path-wildcard": false
          }
        ],
        "responses": {
          "202": {
            "description": "A single webhook.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookDocument"
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "401": {
            "description": "The API token is missing or invalid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "402": {
            "description": "The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is `payment_required`. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return `first_purchase`. The `url` in `first_purchase` opens a page where you make the payment. The resource is created after the payment. The page works until `expires_at`, 24 hours after the response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "403": {
            "description": "The request would go over a quota, with the code `quota_exceeded`. Or a read-only token tried to make a change, with the code `read_only_token`. Or a rule of the resource forbids it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "404": {
            "description": "We couldn't find a resource with this ID in this zone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "409": {
            "description": "The resource's current status doesn't allow the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "422": {
            "description": "A value isn't valid, with the code `validation_failed`. The error's `details` list the messages for each field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "423": {
            "description": "We've locked the resource, with the code `locked`. Every change to a locked resource is refused, and so is a change that involves one.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "429": {
            "description": "Too many requests, with the code `rate_limited`. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the `Retry-After` header says.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected, temporary error on our side, with the code `internal_error`. Try again.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          },
          "503": {
            "description": "We couldn't set up or change the resource, with the code `orchestration_failed`. Or the organization is creating too many resources at the same time, with the code `concurrent_create_limit`. Try again after a short wait.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CloudError"
                }
              }
            }
          }
        },
        "x-cli-default-fields": [
          "id",
          "name",
          "team_id",
          "url",
          "status",
          "failed_deliveries"
        ],
        "x-cli-name-fields": [
          "name",
          "url"
        ],
        "x-cli-response-fields": [
          "id",
          "name",
          "url",
          "webhook_types",
          "status",
          "failed_deliveries",
          "secret",
          "created_at",
          "updated_at",
          "team_id"
        ],
        "x-cli-response-schema": {
          "$ref": "#/components/schemas/CLIResponse.cloud.webhook.list"
        },
        "x-response-envelope": {
          "item_path": [],
          "list_path": [
            "data"
          ],
          "attributes_path": [],
          "id_path": [
            "id"
          ]
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "teamApiToken": {
        "type": "http",
        "scheme": "bearer",
        "description": "API token scoped to one team."
      },
      "globalApiToken": {
        "type": "http",
        "scheme": "bearer",
        "description": "Organization-wide API token that can reach several teams."
      }
    },
    "schemas": {
      "CLIResponse.cloud.certificate.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The certificate's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The certificate's name.",
            "nullable": false,
            "sensitive": false
          },
          "certificate_type": {
            "type": "string",
            "enum": [
              "uploaded",
              "managed"
            ],
            "description": "Whether you upload the certificate or we issue it.\n\n- `uploaded`: You upload the certificate. Send `certificate` and `private_key`.\n- `managed`: We issue and renew the certificate with Let's Encrypt. Send `domain_names`.",
            "x-enum-descriptions": {
              "uploaded": "You upload the certificate. Send `certificate` and `private_key`.",
              "managed": "We issue and renew the certificate with Let's Encrypt. Send `domain_names`."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "issued",
              "failed"
            ],
            "description": "Whether the certificate is ready.\n\n- `pending`: We haven't issued the certificate yet.\n- `issued`: The certificate is ready. An uploaded certificate starts in this state.\n- `failed`: We couldn't issue the certificate. `status_message` says why, and we try again every day.",
            "x-enum-descriptions": {
              "pending": "We haven't issued the certificate yet.",
              "issued": "The certificate is ready. An uploaded certificate starts in this state.",
              "failed": "We couldn't issue the certificate. `status_message` says why, and we try again every day."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the certificate isn't issued yet, or why issuing it failed.",
            "nullable": true,
            "sensitive": false
          },
          "domain_names": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The domains the certificate covers, from 1 to 100. A managed certificate requires them and can't use wildcard domains. An uploaded certificate gets its domains from the certificate itself.",
            "nullable": false,
            "sensitive": false
          },
          "certificate": {
            "type": "string",
            "description": "The certificate chain in PEM format, with the certificate first. An uploaded certificate requires it. A managed certificate has none until we issue it.",
            "nullable": true,
            "sensitive": false
          },
          "fingerprint": {
            "type": "string",
            "description": "The certificate's SHA-256 fingerprint.",
            "nullable": true,
            "sensitive": false
          },
          "not_valid_before": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate becomes valid.",
            "nullable": true,
            "sensitive": false
          },
          "not_valid_after": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate expires.",
            "nullable": true,
            "sensitive": false
          },
          "last_issued_at": {
            "type": "string",
            "format": "date-time",
            "description": "When we last issued or renewed a managed certificate. Always `null` for an uploaded certificate.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate was last changed.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the certificate. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "private_key": {
            "type": "string",
            "description": "The certificate's private key in PEM format, without a passphrase. An uploaded certificate requires a private key. The key isn't returned after it's saved.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          }
        }
      },
      "CLIResponse.cloud.clickhouse.credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The username, always `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The `admin` user's password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The default database, `defaultdb`.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "A `clickhouse://` URI for your private networks, with the password in it. The URI uses the native protocol with TLS.",
            "nullable": false,
            "sensitive": true
          },
          "https_url": {
            "type": "string",
            "description": "The HTTPS URL for your private networks, without the password.",
            "nullable": false,
            "sensitive": false
          },
          "public_uri": {
            "type": "string",
            "description": "A `clickhouse://` URI for clients on the internet, with the password in it, or `null` when `public_access` is `false`. The URI uses the native protocol with TLS.",
            "nullable": true,
            "sensitive": true
          },
          "public_https_url": {
            "type": "string",
            "description": "The HTTPS address for clients on the internet, without the password, or `null` when `public_access` is `false`.",
            "nullable": true,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the instance's TLS certificate with, in PEM format. Save it to a file for your client.",
            "nullable": false,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous password stops working after a password change, or `null` when there's no change in progress.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `CH2`. Get the types via [List ClickHouse types](/docs/cloud/api/clickhouse-types/list-clickhouse-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Storage for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_concurrent_queries": {
            "type": "integer",
            "format": "int64",
            "description": "The most queries the type runs at the same time. A query over this limit fails at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version, such as `26.8`. Get the versions via [List ClickHouse versions](/docs/cloud/api/clickhouse-versions/list-clickhouse-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact ClickHouse version the instance runs, or `null` until the instance's first upgrade.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now. The next LTS version shows up here once we offer it.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state.\n\n- `provisioning`: We're creating the instance.\n- `running`: The instance is ready.\n- `degraded`: The instance works, but needs attention. `status_message` says why.\n- `rescaling`: We're changing the type. When the change doesn't complete, the instance returns to `running` with a `status_message`.\n- `upgrading`: We're upgrading the ClickHouse version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version with a `status_message`, the upgrade failed.\n- `restoring`: We're restoring a snapshot onto the instance. The instance is `running` again once ClickHouse responds to queries.\n- `failed`: The instance couldn't be created or recovered. A failed instance stays in this state.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "The instance works, but needs attention. `status_message` says why.",
              "rescaling": "We're changing the type. When the change doesn't complete, the instance returns to `running` with a `status_message`.",
              "upgrading": "We're upgrading the ClickHouse version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version with a `status_message`, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The instance is `running` again once ClickHouse responds to queries.",
              "failed": "The instance couldn't be created or recovered. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the instance failed or is degraded, or why an operation didn't complete.",
            "nullable": true,
            "sensitive": false
          },
          "timezone": {
            "type": "string",
            "description": "The default time zone for date and time functions, `UTC` or an IANA name such as `Europe/Prague`.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the instance accepts connections on a public IP. The TLS ports `9440` and `8443` are public. The ports without TLS stay on private networks.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. The hostname resolves to the instance's addresses in those networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is `false`. The hostname resolves to the instance's public IP addresses.",
                "nullable": true
              },
              "ports": {
                "type": "object",
                "properties": {
                  "native": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port, `9000`."
                  },
                  "native_tls": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port with TLS, `9440`."
                  },
                  "http": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTP port, `8123`."
                  },
                  "https": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTPS port, `8443`."
                  }
                },
                "description": "The ports the instance listens on."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The instance's IP address in that network."
                    }
                  }
                },
                "description": "The instance's addresses in the private networks attached to it."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The instance's public IP addresses. Empty when `public_access` is `false`."
              }
            },
            "description": "Where to connect to the instance.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary"
                  ],
                  "description": "The node's role, always `primary`."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "running",
                    "down"
                  ],
                  "description": "The node's state.\n\n- `provisioning`: We're creating the node.\n- `running`: The node is up.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "running": "The node is up.",
                    "down": "The node doesn't respond."
                  }
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The node that runs the instance. An instance has one.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.clickhouse.metrics": {
        "type": "object",
        "properties": {
          "clickhouse_id": {
            "type": "string",
            "description": "The instance's ID.",
            "nullable": false,
            "sensitive": false
          },
          "clickhouse_name": {
            "type": "string",
            "description": "The instance's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range the metrics cover.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range the metrics cover.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the points are.\n\n- `raw`: One point a minute, for a range up to one day.\n- `hourly`: One point an hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "One point a minute, for a range up to one day.",
              "hourly": "One point an hour, for a longer range."
            },
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "member_id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary"
                  ],
                  "description": "The node's role, always `primary`."
                },
                "data": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "dt": {
                        "type": "string",
                        "format": "date-time",
                        "description": "The start of the minute or hour the point covers."
                      },
                      "queries_per_second": {
                        "type": "number",
                        "description": "Queries per second."
                      },
                      "failed_queries_per_second": {
                        "type": "number",
                        "description": "Failed queries per second."
                      },
                      "inserted_rows_per_second": {
                        "type": "number",
                        "description": "Inserted rows per second."
                      },
                      "inserted_bytes_per_second": {
                        "type": "number",
                        "description": "Inserted bytes per second."
                      },
                      "selected_rows_per_second": {
                        "type": "number",
                        "description": "Rows read per second."
                      },
                      "connections": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number",
                            "description": "The average number of open connections."
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most open connections."
                          }
                        },
                        "description": "Open connections."
                      },
                      "concurrent_queries": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number",
                            "description": "The average number of queries running at the same time."
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most queries running at the same time."
                          },
                          "limit": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The type's `max_concurrent_queries`."
                          }
                        },
                        "description": "Queries running at the same time."
                      },
                      "memory": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The average memory used, in bytes."
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most memory used, in bytes."
                          },
                          "ram_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The node's memory, in bytes."
                          }
                        },
                        "description": "Memory use."
                      },
                      "disk": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The average disk space used, in bytes."
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most disk space used, in bytes."
                          },
                          "usable_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The type's storage for your data, in bytes."
                          }
                        },
                        "description": "Disk use."
                      }
                    }
                  },
                  "description": "The node's metrics, one entry per point."
                }
              }
            },
            "description": "The metrics of each node.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse.rotate_credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The username, always `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The new `admin` password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The default database, `defaultdb`.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "A `clickhouse://` URI for your private networks, with the new password in it. The URI uses the native protocol with TLS.",
            "nullable": false,
            "sensitive": true
          },
          "https_url": {
            "type": "string",
            "description": "The HTTPS URL for your private networks, without the password.",
            "nullable": false,
            "sensitive": false
          },
          "public_uri": {
            "type": "string",
            "description": "A `clickhouse://` URI for clients on the internet, with the new password in it, or `null` when `public_access` is `false`. The URI uses the native protocol with TLS.",
            "nullable": true,
            "sensitive": true
          },
          "public_https_url": {
            "type": "string",
            "description": "The HTTPS address for clients on the internet, without the password, or `null` when `public_access` is `false`.",
            "nullable": true,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the instance's TLS certificate with, in PEM format. Save it to a file for your client.",
            "nullable": false,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous password stops working, 24 hours from now.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse.upgrade": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `CH2`. Get the types via [List ClickHouse types](/docs/cloud/api/clickhouse-types/list-clickhouse-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Storage for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_concurrent_queries": {
            "type": "integer",
            "format": "int64",
            "description": "The most queries the type runs at the same time. A query over this limit fails at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version, such as `26.8`. Get the versions via [List ClickHouse versions](/docs/cloud/api/clickhouse-versions/list-clickhouse-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact ClickHouse version the instance runs, or `null` until the instance's first upgrade.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now. The next LTS version shows up here once we offer it.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state.\n\n- `provisioning`: We're creating the instance.\n- `running`: The instance is ready.\n- `degraded`: The instance works, but needs attention. `status_message` says why.\n- `rescaling`: We're changing the type. When the change doesn't complete, the instance returns to `running` with a `status_message`.\n- `upgrading`: We're upgrading the ClickHouse version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version with a `status_message`, the upgrade failed.\n- `restoring`: We're restoring a snapshot onto the instance. The instance is `running` again once ClickHouse responds to queries.\n- `failed`: The instance couldn't be created or recovered. A failed instance stays in this state.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "The instance works, but needs attention. `status_message` says why.",
              "rescaling": "We're changing the type. When the change doesn't complete, the instance returns to `running` with a `status_message`.",
              "upgrading": "We're upgrading the ClickHouse version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version with a `status_message`, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The instance is `running` again once ClickHouse responds to queries.",
              "failed": "The instance couldn't be created or recovered. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the instance failed or is degraded, or why an operation didn't complete.",
            "nullable": true,
            "sensitive": false
          },
          "timezone": {
            "type": "string",
            "description": "The default time zone for date and time functions, `UTC` or an IANA name such as `Europe/Prague`.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the instance accepts connections on a public IP. The TLS ports `9440` and `8443` are public. The ports without TLS stay on private networks.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. The hostname resolves to the instance's addresses in those networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is `false`. The hostname resolves to the instance's public IP addresses.",
                "nullable": true
              },
              "ports": {
                "type": "object",
                "properties": {
                  "native": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port, `9000`."
                  },
                  "native_tls": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port with TLS, `9440`."
                  },
                  "http": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTP port, `8123`."
                  },
                  "https": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTPS port, `8443`."
                  }
                },
                "description": "The ports the instance listens on."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The instance's IP address in that network."
                    }
                  }
                },
                "description": "The instance's addresses in the private networks attached to it."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The instance's public IP addresses. Empty when `public_access` is `false`."
              }
            },
            "description": "Where to connect to the instance.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary"
                  ],
                  "description": "The node's role, always `primary`."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "running",
                    "down"
                  ],
                  "description": "The node's state.\n\n- `provisioning`: We're creating the node.\n- `running`: The node is up.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "running": "The node is up.",
                    "down": "The node doesn't respond."
                  }
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The node that runs the instance. An instance has one.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "pre_upgrade_snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot we created before the upgrade.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `snapshot_created`.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.\n\n- `user`: A Better Stack user did it. `user_id` says who.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the action, such as the new type, the new version or the snapshot ID.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse_scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the schedule belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance.",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the first one.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the snapshot was taken from.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance. The server is hidden from your list of servers. Can become `null` after the instance is deleted.",
            "nullable": true,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.\n\n- `manual`: Created by a request.\n- `scheduled`: Created by a snapshot schedule.",
            "x-enum-descriptions": {
              "manual": "Created by a request.",
              "scheduled": "Created by a snapshot schedule."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state.\n\n- `pending`: We're creating the snapshot. The snapshot then becomes `available`, or `failed` with a `failure_reason`.\n- `available`: The snapshot is ready to restore.\n- `failed`: We couldn't create the snapshot. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot's data. The snapshot is gone once we're done.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot. The snapshot then becomes `available`, or `failed` with a `failure_reason`.",
              "available": "The snapshot is ready to restore.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot's data. The snapshot is gone once we're done."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. We bill by this size. Stays `null` until the snapshot is ready.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The availability zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why creating the snapshot failed, or `null` unless the snapshot is `failed`.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null` when there's nothing more.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Our lock on the snapshot, or `null` when it isn't locked. You can still delete and restore a locked snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.clickhouse_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type name. Send it as `type` when you create or rescale a ClickHouse instance.",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Storage for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_concurrent_queries": {
            "type": "integer",
            "format": "int64",
            "description": "The most queries that can run at the same time.",
            "nullable": false,
            "sensitive": false
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of virtual CPUs.",
            "nullable": false,
            "sensitive": false
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Memory, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: You can order the type.\n- `unavailable`: The type is deprecated. Instances on it keep running, but you can't create or rescale to it.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Instances on it keep running, but you can't create or rescale to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The type to use instead of this deprecated one, or `null` for a type you can order.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.clickhouse_version.list": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version as major and minor, such as `26.8`. We install its latest patch release and keep it updated.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, in the past tense, such as `created`, `claimed`, `started`, `stopped`, `restarted`, `destroyed`, `rescaled`, `restored`, `term_changed`, `snapshot_created`, `snapshot_failed`, `reserved_ip_attached`, `reserved_ip_detached`, `ssh_key_attached`, `ssh_key_detached`, `ssh_key_attach_failed`, `ssh_key_detach_failed`, `network_attach_failed`, `rescue_entered`, `rescue_exited`, `console_opened`, `console_terminated`, `spot_terminated`, `locked` or `unlocked`. We add new actions over time, so expect values that aren't listed here.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.\n\n- `user`: A Better Stack user did it, and `user_id` names them.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it, and `user_id` names them.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "Details that depend on the action, such as the snapshot a restore used or the server types a rescale moved between.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.firewall.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The firewall's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The firewall's name, unique in your organization.",
            "nullable": false,
            "sensitive": false
          },
          "rules": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The rule's ID, a UUID."
                },
                "direction": {
                  "type": "string",
                  "description": "Which traffic the rule matches, `inbound` or `outbound`."
                },
                "protocol": {
                  "type": "string",
                  "description": "The IP protocol the rule matches. `any` matches every protocol."
                },
                "ip_addresses": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "The addresses the rule applies to, in CIDR notation."
                },
                "port_from": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The first port of the range."
                },
                "port_to": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The last port of the range, or `null` when the rule matches only `port_from`.",
                  "nullable": true
                }
              }
            },
            "description": "The firewall's rules. Add a rule via [Create a firewall rule](/docs/cloud/api/firewall-rules/create-firewall-rule/) and remove one via [Remove a firewall rule](/docs/cloud/api/firewall-rules/delete-firewall-rule/).",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the firewall was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the firewall was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the firewall. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.firewall_rule.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The rule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "direction": {
            "type": "string",
            "enum": [
              "inbound",
              "outbound"
            ],
            "description": "Which traffic the rule matches.\n\n- `inbound`: The rule matches traffic that arrives at the server.\n- `outbound`: The rule matches traffic that leaves the server.",
            "x-enum-descriptions": {
              "inbound": "The rule matches traffic that arrives at the server.",
              "outbound": "The rule matches traffic that leaves the server."
            },
            "nullable": false,
            "sensitive": false
          },
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "udp",
              "icmp",
              "gre",
              "esp",
              "any"
            ],
            "description": "The IP protocol the rule matches. `any` matches every protocol.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The addresses the rule applies to, in CIDR notation, such as `10.0.0.0/8`. Use `0.0.0.0/0` and `::/0` for every address. The list can't be empty.",
            "nullable": false,
            "sensitive": false
          },
          "port_from": {
            "type": "integer",
            "format": "int64",
            "description": "The first port of the range, from `0` to `65535`. Send it for every protocol. A protocol without ports, such as `icmp`, ignores it.",
            "nullable": false,
            "sensitive": false
          },
          "port_to": {
            "type": "integer",
            "format": "int64",
            "description": "The last port of the range, from `port_from` to `65535`.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.image.list": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "The image's name, such as `ubuntu-26-04`. Send it as `image` when you create a server.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.ip.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the public IP, private IP or reserved IP the address belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "ip": {
            "type": "string",
            "description": "The address.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or IPv6 address.",
            "nullable": false,
            "sensitive": false
          },
          "visibility": {
            "type": "string",
            "enum": [
              "public",
              "private"
            ],
            "description": "Where the address can be reached from.\n\n- `public`: The address is reachable from the internet.\n- `private`: The address is reachable only inside one of your private networks.",
            "x-enum-descriptions": {
              "public": "The address is reachable from the internet.",
              "private": "The address is reachable only inside one of your private networks."
            },
            "nullable": false,
            "sensitive": false
          },
          "available": {
            "type": "boolean",
            "description": "Whether it's a reserved IP that isn't assigned to a server.",
            "nullable": false,
            "sensitive": false
          },
          "ptr_record": {
            "type": "string",
            "description": "The reverse DNS name of a public address, or `null` for a private address.",
            "nullable": true,
            "sensitive": false
          },
          "server": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "status": {
                "type": "string"
              }
            },
            "description": "The server that has the address, or `null` when no server has it.",
            "nullable": true,
            "sensitive": false
          },
          "network": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "description": "The private network the address is in, or `null` for a public address.",
            "nullable": true,
            "sensitive": false
          },
          "reservation": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "description": "The reserved IP for the address, or `null` when it isn't reserved.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the address was added to the server or network, or reserved.",
            "nullable": false,
            "sensitive": false
          },
          "device_name": {
            "type": "string",
            "description": "The server's network interface that has the public address, such as `eth0`. Only public addresses on a server have it.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that has a private address or a reserved IP. Public addresses on a server don't have it.",
            "nullable": true,
            "sensitive": false
          },
          "network_id": {
            "type": "string",
            "description": "The ID of the network a private address is in. Only private addresses have it.",
            "nullable": false,
            "sensitive": false
          },
          "ip_address": {
            "type": "string",
            "description": "The private address, the same as `ip`. Only private addresses have it.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The name of a reserved IP that isn't assigned. Only those entries have it.",
            "nullable": true,
            "sensitive": false
          },
          "gateway": {
            "type": "string",
            "description": "The gateway of a reserved IP that isn't assigned. Only those entries have it.",
            "nullable": true,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the private address or the reserved IP was last updated. Public addresses on a server don't have it.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns a reserved IP that isn't assigned. Only those entries have it.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "The tags of a reserved IP that isn't assigned. Only those entries have it.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.kafka.consumer_groups": {
        "type": "object",
        "properties": {
          "group_id": {
            "type": "string",
            "description": "The consumer group's ID.",
            "nullable": false,
            "sensitive": false
          },
          "lag": {
            "type": "integer",
            "format": "int64",
            "description": "How many messages the group is behind, summed over its partitions.",
            "nullable": false,
            "sensitive": false
          },
          "topics": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the topics the group reads, sorted.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "integer",
            "format": "int64",
            "description": "The number of active consumers in the group.",
            "nullable": false,
            "sensitive": false
          },
          "partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions the group reads.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka.credentials": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "description": "The `default` user's username, or `null` when the cluster has no `default` user.",
            "nullable": true,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The `default` user's SCRAM password, or `null` when the cluster has no `default` user.",
            "nullable": true,
            "sensitive": true
          },
          "bootstrap_servers": {
            "type": "string",
            "description": "The private bootstrap address, as `host:port`.",
            "nullable": false,
            "sensitive": false
          },
          "public_bootstrap_servers": {
            "type": "string",
            "description": "The public bootstrap address, as `host:port`. Present only when `public_access` is on.",
            "nullable": false,
            "sensitive": false
          },
          "security_protocol": {
            "type": "string",
            "description": "The protocol clients connect with, always `SASL_SSL`.",
            "nullable": false,
            "sensitive": false
          },
          "sasl_mechanism": {
            "type": "string",
            "description": "The authentication mechanism, always `SCRAM-SHA-512`.",
            "nullable": false,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate bundle that signs the cluster's TLS certificate. Save it to a file for your client to verify the cluster.",
            "nullable": false,
            "sensitive": false
          },
          "properties": {
            "type": "object",
            "properties": {
              "bootstrap.servers": {
                "type": "string"
              },
              "security.protocol": {
                "type": "string"
              },
              "sasl.mechanism": {
                "type": "string"
              },
              "sasl.username": {
                "type": "string",
                "nullable": true
              },
              "sasl.password": {
                "type": "string",
                "nullable": true
              },
              "ssl.ca.location": {
                "type": "string"
              }
            },
            "description": "The client settings to connect with, under the names librdkafka and kcat use. The settings include the password. Replace `/path/to/betterstack-ca.pem` in `ssl.ca.location` with the path of the saved `ca_certificate`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.kafka.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The cluster's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The cluster's name, at most 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The cluster's type, such as `KA1`.",
            "nullable": false,
            "sensitive": false
          },
          "broker_count": {
            "type": "integer",
            "format": "int64",
            "description": "The number of brokers, `1` for development or `3` to keep the cluster running when a broker fails. Can't be changed after the cluster is created.",
            "nullable": false,
            "sensitive": false
          },
          "replication_factor": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies of each partition, the same as `broker_count`. Every broker stores every partition.",
            "nullable": false,
            "sensitive": false
          },
          "min_insync_replicas": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies that must confirm a write, `1` with one broker and `2` with three.",
            "nullable": false,
            "sensitive": false
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The storage for your topics on each broker, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The most partitions the cluster's type allows across all topics.",
            "nullable": false,
            "sensitive": false
          },
          "storage_budget_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The storage budget of each broker, in bytes. All topics together must fit in it.",
            "nullable": false,
            "sensitive": false
          },
          "storage_budget_used_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The storage your topics reserve, in bytes. Each topic reserves its `retention_bytes` times its number of partitions, plus one segment for each partition.",
            "nullable": false,
            "sensitive": false
          },
          "partition_count": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions across all topics.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The Kafka version as major and minor, such as `4.4`.",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact Kafka release installed, such as `4.4.0`.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the cluster to, which is only the next version we offer. Empty when the cluster runs the newest version.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "failed",
              "destroyed"
            ],
            "description": "The cluster's state.\n\n- `provisioning`: We're starting the brokers and installing Kafka.\n- `running`: The cluster is ready. Right after it's created, brokers can still be starting.\n- `degraded`: A broker is down, partitions are missing copies or a disk is almost full. `status_message` says which.\n- `rescaling`: We're changing the cluster's type.\n- `upgrading`: We're upgrading the cluster to a newer Kafka version.\n- `failed`: We couldn't create the cluster. `status_message` says why.\n- `destroyed`: The cluster is destroyed.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the brokers and installing Kafka.",
              "running": "The cluster is ready. Right after it's created, brokers can still be starting.",
              "degraded": "A broker is down, partitions are missing copies or a disk is almost full. `status_message` says which.",
              "rescaling": "We're changing the cluster's type.",
              "upgrading": "We're upgrading the cluster to a newer Kafka version.",
              "failed": "We couldn't create the cluster. `status_message` says why.",
              "destroyed": "The cluster is destroyed."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the cluster is in its current state, such as which broker is down, or `null` when there's nothing to report.",
            "nullable": true,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the cluster also has public endpoints. Clients connect with TLS and SCRAM on both the private and the public endpoints.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "bootstrap_servers": {
                "type": "string"
              },
              "hostname": {
                "type": "string",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64"
              },
              "security_protocol": {
                "type": "string"
              },
              "sasl_mechanism": {
                "type": "string"
              },
              "brokers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "node_id": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "hostname": {
                      "type": "string",
                      "nullable": true
                    }
                  }
                }
              },
              "public_bootstrap_servers": {
                "type": "string"
              },
              "public_hostname": {
                "type": "string"
              },
              "public_port": {
                "type": "integer",
                "format": "int64"
              },
              "public_brokers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "node_id": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "hostname": {
                      "type": "string"
                    }
                  }
                }
              }
            },
            "description": "The addresses clients connect to, with the bootstrap address and one address for each broker. Clients must reach every broker, not only the bootstrap address. The fields that start with `public_` are present only when `public_access` is on.",
            "nullable": false,
            "sensitive": false
          },
          "brokers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "node_id": {
                  "type": "integer",
                  "format": "int64"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "starting",
                    "running",
                    "down"
                  ]
                },
                "hostname": {
                  "type": "string",
                  "nullable": true
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "nullable": true
                },
                "under_replicated_partitions": {
                  "type": "integer",
                  "format": "int64",
                  "nullable": true
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "type": "string"
                      }
                    }
                  }
                },
                "last_seen_at": {
                  "type": "string",
                  "format": "date-time",
                  "nullable": true
                }
              }
            },
            "description": "The cluster's brokers, with their addresses on your networks and their last reported health. All brokers have the same role.",
            "nullable": false,
            "sensitive": false
          },
          "topics": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "partitions": {
                  "type": "integer",
                  "format": "int64"
                },
                "replication_factor": {
                  "type": "integer",
                  "format": "int64"
                },
                "retention_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "retention_ms": {
                  "type": "integer",
                  "format": "int64"
                },
                "cleanup_policy": {
                  "type": "string",
                  "enum": [
                    "delete",
                    "compact",
                    "compact_delete"
                  ]
                },
                "max_message_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "budget_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "nullable": true
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "nullable": true
                }
              }
            },
            "description": "The cluster's topics. Add a topic via [Create a Kafka topic](/docs/cloud/api/kafka-topics/create-kafka-topic/).",
            "nullable": false,
            "sensitive": false
          },
          "users": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "username": {
                  "type": "string"
                },
                "default_user": {
                  "type": "boolean"
                },
                "privileges": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "topic_pattern": {
                        "type": "string"
                      },
                      "permission": {
                        "type": "string",
                        "enum": [
                          "consume",
                          "produce",
                          "produce_consume"
                        ]
                      }
                    }
                  }
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "nullable": true
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "nullable": true
                }
              }
            },
            "description": "The cluster's users. Add a user via [Create a Kafka user](/docs/cloud/api/kafka-users/create-kafka-user/). Get a user's password via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of your networks attached to every broker. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to every broker. A cluster can have one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the cluster.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.kafka.metrics": {
        "type": "object",
        "properties": {
          "kafka_id": {
            "type": "string",
            "description": "The cluster's ID.",
            "nullable": false,
            "sensitive": false
          },
          "kafka_name": {
            "type": "string",
            "description": "The cluster's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range returned, included.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range returned, not included.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the values are.\n\n- `raw`: A value for each minute.\n- `hourly`: A value for each hour.",
            "x-enum-descriptions": {
              "raw": "A value for each minute.",
              "hourly": "A value for each hour."
            },
            "nullable": false,
            "sensitive": false
          },
          "brokers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "broker_id": {
                  "type": "string"
                },
                "node_id": {
                  "type": "integer",
                  "format": "int64"
                },
                "data": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "dt": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "partitions": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number"
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "limit": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "leader_partitions": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number"
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "under_replicated_partitions": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number"
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "live_brokers": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "number"
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "expected": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "disk": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "usable_bytes": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "max_consumer_group_lag": {
                        "type": "object",
                        "properties": {
                          "avg": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "max": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      }
                    }
                  }
                }
              }
            },
            "description": "The history of each broker, with the broker's ID and its Kafka node ID.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka.rotate_credentials": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "description": "The `default` user's username.",
            "nullable": true,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The new SCRAM password.",
            "nullable": true,
            "sensitive": true
          },
          "bootstrap_servers": {
            "type": "string",
            "description": "The private bootstrap address, as `host:port`.",
            "nullable": false,
            "sensitive": false
          },
          "public_bootstrap_servers": {
            "type": "string",
            "description": "The public bootstrap address, as `host:port`. Present only when `public_access` is on.",
            "nullable": false,
            "sensitive": false
          },
          "security_protocol": {
            "type": "string",
            "description": "The protocol clients connect with, always `SASL_SSL`.",
            "nullable": false,
            "sensitive": false
          },
          "sasl_mechanism": {
            "type": "string",
            "description": "The authentication mechanism, always `SCRAM-SHA-512`.",
            "nullable": false,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate bundle that signs the cluster's TLS certificate.",
            "nullable": false,
            "sensitive": false
          },
          "properties": {
            "type": "object",
            "properties": {
              "bootstrap.servers": {
                "type": "string"
              },
              "security.protocol": {
                "type": "string"
              },
              "sasl.mechanism": {
                "type": "string"
              },
              "sasl.username": {
                "type": "string",
                "nullable": true
              },
              "sasl.password": {
                "type": "string",
                "nullable": true
              },
              "ssl.ca.location": {
                "type": "string"
              }
            },
            "description": "The client settings to connect with, including the new password. Replace `/path/to/betterstack-ca.pem` in `ssl.ca.location` with the path of the saved `ca_certificate`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.kafka_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "kafka_id": {
            "type": "string",
            "description": "The ID of the Kafka cluster.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `topic_created`. Events cover the cluster, its brokers, topics and users.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The Better Stack ID of the user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who or what did it.\n\n- `user`: A Better Stack user did it.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event, such as the broker ID, topic or username. The keys depend on `action`.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When it happened. A change you requested shows when we accepted it.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka_topic.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The topic's ID, a UUID. Get, update and delete a topic by this ID, never by its name.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9._-]+$",
            "description": "The topic's name, unique in the cluster, 1–249 letters, digits, dots, hyphens and underscores. Can't be `.` or `..` or start with `__`.",
            "nullable": false,
            "sensitive": false
          },
          "partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions, at least 1. All topics together must fit within the cluster type's `max_partitions`.",
            "nullable": false,
            "sensitive": false
          },
          "replication_factor": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies of each partition, the same as the cluster's number of brokers.",
            "nullable": false,
            "sensitive": false
          },
          "retention_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The most data to keep in each partition, in bytes, at least 1048576.",
            "nullable": false,
            "sensitive": false
          },
          "retention_ms": {
            "type": "integer",
            "format": "int64",
            "description": "How long to keep messages, in milliseconds, at least 60000. `-1` keeps them with no time limit, and `retention_bytes` still limits their size.",
            "nullable": false,
            "sensitive": false
          },
          "cleanup_policy": {
            "type": "string",
            "enum": [
              "delete",
              "compact",
              "compact_delete"
            ],
            "description": "How Kafka removes old messages.\n\n- `delete`: Deletes messages older than the retention time or past the retention size.\n- `compact`: Keeps only the latest message for each key.\n- `compact_delete`: Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`.",
            "x-enum-descriptions": {
              "delete": "Deletes messages older than the retention time or past the retention size.",
              "compact": "Keeps only the latest message for each key.",
              "compact_delete": "Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`."
            },
            "nullable": false,
            "sensitive": false
          },
          "max_message_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The largest message the topic accepts, in bytes, from 1024 to 8388608.",
            "nullable": false,
            "sensitive": false
          },
          "budget_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The most disk space the topic can use on each broker, in bytes. The budget is `partitions` times `retention_bytes`, plus one segment for each partition.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the topic was created.",
            "nullable": true,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the topic was last updated.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `KA1`. Send it as `type` when you create or rescale a cluster.",
            "nullable": false,
            "sensitive": false
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The storage for your topics on each broker, in GiB. Every broker stores every partition, so this is also the cluster's storage for topics.",
            "nullable": false,
            "sensitive": false
          },
          "max_partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The most partitions a cluster of this type can have across all its topics.",
            "nullable": false,
            "sensitive": false
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of vCPUs of each broker.",
            "nullable": false,
            "sensitive": false
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The RAM of each broker, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: We offer the type.\n- `unavailable`: The type is deprecated. Clusters that have it keep running, but you can't create or rescale a cluster to it.",
            "x-enum-descriptions": {
              "global": "We offer the type.",
              "unavailable": "The type is deprecated. Clusters that have it keep running, but you can't create or rescale a cluster to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka_user.create": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The user's ID, a UUID. Requests for one user use this ID, never the `username`.",
            "nullable": false,
            "sensitive": false
          },
          "username": {
            "type": "string",
            "pattern": "^[a-z0-9][a-z0-9_-]*$",
            "description": "The name clients sign in with, unique in the cluster, up to 64 lowercase letters, digits, hyphens and underscores, starting with a letter or digit. Can't start with `betterstack`.",
            "nullable": false,
            "sensitive": false
          },
          "default_user": {
            "type": "boolean",
            "description": "Whether this is the cluster's `default` user, which every cluster comes with. You can't delete the `default` user, but you can change its privileges.",
            "nullable": false,
            "sensitive": false
          },
          "privileges": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "topic_pattern": {
                  "type": "string",
                  "pattern": "^[a-zA-Z0-9._-]*\\*?$",
                  "description": "A topic name, or a prefix followed by a trailing `*`, made of letters, digits, dots, hyphens and underscores, up to 249 characters. `*` alone matches every topic."
                },
                "permission": {
                  "type": "string",
                  "enum": [
                    "consume",
                    "produce",
                    "produce_consume"
                  ],
                  "description": "What the user can do on the matching topics.\n\n- `consume`: Read and describe the matching topics, and join consumer groups.\n- `produce`: Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.\n- `produce_consume`: Both `consume` and `produce`.",
                  "x-enum-descriptions": {
                    "consume": "Read and describe the matching topics, and join consumer groups.",
                    "produce": "Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.",
                    "produce_consume": "Both `consume` and `produce`."
                  }
                }
              },
              "required": [
                "topic_pattern",
                "permission"
              ]
            },
            "description": "The topics the user can use and what it can do on them, up to 25 entries. A user with no privileges has an empty list.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was created.",
            "nullable": true,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was last updated.",
            "nullable": true,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The generated password. Get it again later via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.kafka_user.credentials": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "description": "The user's username.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The user's password.",
            "nullable": false,
            "sensitive": true
          },
          "bootstrap_servers": {
            "type": "string",
            "description": "The private bootstrap address, as `host:port`.",
            "nullable": false,
            "sensitive": false
          },
          "public_bootstrap_servers": {
            "type": "string",
            "description": "The public bootstrap address, as `host:port`. Only a cluster with public access has it.",
            "nullable": false,
            "sensitive": false
          },
          "security_protocol": {
            "type": "string",
            "description": "The protocol clients connect with, always `SASL_SSL`.",
            "nullable": false,
            "sensitive": false
          },
          "sasl_mechanism": {
            "type": "string",
            "description": "The authentication mechanism, always `SCRAM-SHA-512`.",
            "nullable": false,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the cluster's TLS certificate with. Save it to a file for your client.",
            "nullable": false,
            "sensitive": false
          },
          "properties": {
            "type": "object",
            "properties": {
              "bootstrap.servers": {
                "type": "string",
                "description": "The private bootstrap address, as `host:port`."
              },
              "security.protocol": {
                "type": "string",
                "description": "The protocol clients connect with, always `SASL_SSL`."
              },
              "sasl.mechanism": {
                "type": "string",
                "description": "The authentication mechanism, always `SCRAM-SHA-512`."
              },
              "sasl.username": {
                "type": "string",
                "description": "The user's username."
              },
              "sasl.password": {
                "type": "string",
                "description": "The user's password."
              },
              "ssl.ca.location": {
                "type": "string",
                "description": "The placeholder `/path/to/betterstack-ca.pem`. Replace it with the path where you saved `ca_certificate`."
              }
            },
            "description": "The client settings to connect with, ready to use with librdkafka and kcat. Replace `/path/to/betterstack-ca.pem` with the path where you saved `ca_certificate`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.kafka_user.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The user's ID, a UUID. Requests for one user use this ID, never the `username`.",
            "nullable": false,
            "sensitive": false
          },
          "username": {
            "type": "string",
            "pattern": "^[a-z0-9][a-z0-9_-]*$",
            "description": "The name clients sign in with, unique in the cluster, up to 64 lowercase letters, digits, hyphens and underscores, starting with a letter or digit. Can't start with `betterstack`.",
            "nullable": false,
            "sensitive": false
          },
          "default_user": {
            "type": "boolean",
            "description": "Whether this is the cluster's `default` user, which every cluster comes with. You can't delete the `default` user, but you can change its privileges.",
            "nullable": false,
            "sensitive": false
          },
          "privileges": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "topic_pattern": {
                  "type": "string",
                  "pattern": "^[a-zA-Z0-9._-]*\\*?$",
                  "description": "A topic name, or a prefix followed by a trailing `*`, made of letters, digits, dots, hyphens and underscores, up to 249 characters. `*` alone matches every topic."
                },
                "permission": {
                  "type": "string",
                  "enum": [
                    "consume",
                    "produce",
                    "produce_consume"
                  ],
                  "description": "What the user can do on the matching topics.\n\n- `consume`: Read and describe the matching topics, and join consumer groups.\n- `produce`: Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.\n- `produce_consume`: Both `consume` and `produce`.",
                  "x-enum-descriptions": {
                    "consume": "Read and describe the matching topics, and join consumer groups.",
                    "produce": "Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.",
                    "produce_consume": "Both `consume` and `produce`."
                  }
                }
              },
              "required": [
                "topic_pattern",
                "permission"
              ]
            },
            "description": "The topics the user can use and what it can do on them, up to 25 entries. A user with no privileges has an empty list.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was created.",
            "nullable": true,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was last updated.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kafka_user.reset_password": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "description": "The user's username.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The new password.",
            "nullable": false,
            "sensitive": true
          },
          "bootstrap_servers": {
            "type": "string",
            "description": "The private bootstrap address, as `host:port`.",
            "nullable": false,
            "sensitive": false
          },
          "public_bootstrap_servers": {
            "type": "string",
            "description": "The public bootstrap address, as `host:port`. Only a cluster with public access has it.",
            "nullable": false,
            "sensitive": false
          },
          "security_protocol": {
            "type": "string",
            "description": "The protocol clients connect with, always `SASL_SSL`.",
            "nullable": false,
            "sensitive": false
          },
          "sasl_mechanism": {
            "type": "string",
            "description": "The authentication mechanism, always `SCRAM-SHA-512`.",
            "nullable": false,
            "sensitive": false
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the cluster's TLS certificate with. Save it to a file for your client.",
            "nullable": false,
            "sensitive": false
          },
          "properties": {
            "type": "object",
            "properties": {
              "bootstrap.servers": {
                "type": "string",
                "description": "The private bootstrap address, as `host:port`."
              },
              "security.protocol": {
                "type": "string",
                "description": "The protocol clients connect with, always `SASL_SSL`."
              },
              "sasl.mechanism": {
                "type": "string",
                "description": "The authentication mechanism, always `SCRAM-SHA-512`."
              },
              "sasl.username": {
                "type": "string",
                "description": "The user's username."
              },
              "sasl.password": {
                "type": "string",
                "description": "The user's password."
              },
              "ssl.ca.location": {
                "type": "string",
                "description": "The placeholder `/path/to/betterstack-ca.pem`. Replace it with the path where you saved `ca_certificate`."
              }
            },
            "description": "The client settings to connect with, including the new password, ready to use with librdkafka and kcat. Replace `/path/to/betterstack-ca.pem` with the path where you saved `ca_certificate`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.kafka_version.list": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The version as major and minor number, such as `4.4`. We pick the patch release and apply patch updates automatically.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether new clusters get this version by default.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_cluster.kubeconfig": {
        "type": "object",
        "properties": {
          "kubeconfig": {
            "type": "string",
            "description": "The kubeconfig, as YAML with the admin token. Save this value as your kubeconfig file.",
            "nullable": false,
            "sensitive": true
          },
          "server": {
            "type": "string",
            "description": "The HTTPS URL of the Kubernetes API, on port 6443.",
            "nullable": false,
            "sensitive": false
          },
          "rotated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the admin token was first issued or last rotated, or `null`.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_cluster.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The cluster's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The cluster's name, up to 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "version": {
            "type": "string",
            "description": "The Kubernetes version as major and minor number, such as `1.36`. Defaults to the newest version.",
            "nullable": false,
            "sensitive": false
          },
          "patch_version": {
            "type": "string",
            "description": "The exact Kubernetes build we installed for `version`, such as `v1.37.2+k3s1`.",
            "nullable": true,
            "sensitive": false
          },
          "available_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the cluster to now. Holds the next minor version once we offer it.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The state of the cluster's control plane. The cluster is ready when it's `running` and every node pool has `node_count` workers that are all `ready`.\n\n- `provisioning`: We're creating the control plane and the workers.\n- `running`: The control plane works. Check `node_pools` to see whether the workers are ready.\n- `degraded`: The control plane or some workers aren't healthy. `status_message` says which.\n- `upgrading`: We're upgrading the control plane and then the workers.\n- `restoring`: We're restoring the control plane from a snapshot.\n- `failed`: We couldn't create the cluster. `status_message` says why.\n- `destroyed`: The cluster is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the control plane and the workers.",
              "running": "The control plane works. Check `node_pools` to see whether the workers are ready.",
              "degraded": "The control plane or some workers aren't healthy. `status_message` says which.",
              "upgrading": "We're upgrading the control plane and then the workers.",
              "restoring": "We're restoring the control plane from a snapshot.",
              "failed": "We couldn't create the cluster. `status_message` says why.",
              "destroyed": "The cluster is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "What went wrong while creating, scaling or running the cluster, or `null`.",
            "nullable": true,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The host name of the Kubernetes API.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port of the Kubernetes API, always `6443`."
              },
              "api_allowed_cidrs": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IP ranges allowed to reach the cluster's Kubernetes API, as 1 to 50 IPv4 or IPv6 CIDRs."
              }
            },
            "description": "Where to reach the cluster's Kubernetes API, and from which IP ranges.",
            "nullable": false,
            "sensitive": false
          },
          "pod_cidr": {
            "type": "string",
            "description": "The IPv4 range for pods.",
            "nullable": false,
            "sensitive": false
          },
          "service_cidr": {
            "type": "string",
            "description": "The IPv4 range for Kubernetes services.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers were ready when we last checked.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the cluster has now. Each node pool's `node_count` says how many it should have.",
            "nullable": false,
            "sensitive": false
          },
          "node_pools": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node pool's ID, a UUID."
                },
                "name": {
                  "type": "string",
                  "description": "The node pool's name."
                },
                "server_type": {
                  "type": "string",
                  "description": "The server type of the workers."
                },
                "node_count": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers the node pool should have."
                },
                "labels": {
                  "type": "object",
                  "additionalProperties": true,
                  "description": "The Kubernetes labels of the workers, as string pairs."
                },
                "taints": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "key": {
                        "type": "string",
                        "description": "The taint's key."
                      },
                      "value": {
                        "type": "string",
                        "description": "The taint's value, or `null` when the taint has none.",
                        "nullable": true
                      },
                      "effect": {
                        "type": "string",
                        "enum": [
                          "NoSchedule",
                          "PreferNoSchedule",
                          "NoExecute"
                        ],
                        "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                      }
                    },
                    "required": [
                      "key",
                      "effect"
                    ]
                  },
                  "description": "The Kubernetes taints of the workers."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "active",
                    "scaling",
                    "deleting",
                    "destroyed"
                  ],
                  "description": "The node pool's state. A node pool that's `active` can still have workers that aren't ready."
                },
                "status_message": {
                  "type": "string",
                  "description": "Why the node pool has fewer workers than `node_count`, or `null`.",
                  "nullable": true
                },
                "nodes_ready": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers of the node pool are `ready`."
                },
                "scaling": {
                  "type": "object",
                  "properties": {
                    "from": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The number of workers before the change.",
                      "nullable": true
                    },
                    "to": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The `node_count` to reach."
                    },
                    "started_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When the change started."
                    },
                    "estimated_ready_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When we expect the change to be done."
                    }
                  },
                  "description": "How a change of size is going while the node pool is `scaling`, or `null` otherwise.",
                  "nullable": true
                },
                "nodes": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "description": "The worker's ID."
                      },
                      "name": {
                        "type": "string",
                        "description": "The worker's name in Kubernetes."
                      },
                      "server_id": {
                        "type": "string",
                        "description": "The ID of the server that runs the worker, or `null` while the worker is `queued`.",
                        "nullable": true
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "queued",
                          "provisioning",
                          "joining",
                          "ready",
                          "not_ready",
                          "draining",
                          "replacing",
                          "destroyed"
                        ],
                        "description": "The worker's state."
                      },
                      "version": {
                        "type": "string",
                        "description": "The Kubernetes version the worker reports.",
                        "nullable": true
                      },
                      "last_seen_at": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When we last saw the worker ready.",
                        "nullable": true
                      }
                    }
                  },
                  "description": "The node pool's workers."
                }
              }
            },
            "description": "The cluster's node pools, each with its workers. Deleted node pools aren't listed.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the cluster. The list is empty while the cluster has no workers. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to the workers. The list is empty while the cluster has no workers. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "kubeconfig_rotated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the admin credentials of the kubeconfig were first issued or last rotated, or `null` before they're issued.",
            "nullable": true,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest `available` snapshot of the control plane was created, or `null` when there is none.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the cluster. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.kubernetes_cluster.metrics": {
        "type": "object",
        "properties": {
          "at": {
            "type": "string",
            "format": "date-time",
            "description": "The time of the data point, or the hour it averages.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers were ready. Hourly averages are rounded.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the cluster had. Hourly averages are rounded.",
            "nullable": false,
            "sensitive": false
          },
          "pods_running": {
            "type": "integer",
            "format": "int64",
            "description": "How many pods were running. Hourly averages are rounded.",
            "nullable": false,
            "sensitive": false
          },
          "pods_capacity": {
            "type": "integer",
            "format": "int64",
            "description": "How many pods the workers can run. Hourly averages are rounded.",
            "nullable": false,
            "sensitive": false
          },
          "apiserver_up": {
            "type": "number",
            "description": "How available the Kubernetes API was, from `0` to `1`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_cluster.rotate_kubeconfig": {
        "type": "object",
        "properties": {
          "kubeconfig": {
            "type": "string",
            "description": "The new kubeconfig, as YAML with the new admin token.",
            "nullable": false,
            "sensitive": true
          },
          "server": {
            "type": "string",
            "description": "The HTTPS URL of the Kubernetes API, on port 6443.",
            "nullable": false,
            "sensitive": false
          },
          "rotated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the admin token was rotated.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_cluster.upgrade": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The cluster's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The cluster's name, up to 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "version": {
            "type": "string",
            "description": "The Kubernetes version as major and minor number, such as `1.36`. Defaults to the newest version.",
            "nullable": false,
            "sensitive": false
          },
          "patch_version": {
            "type": "string",
            "description": "The exact Kubernetes build we installed for `version`, such as `v1.37.2+k3s1`.",
            "nullable": true,
            "sensitive": false
          },
          "available_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the cluster to now. Holds the next minor version once we offer it.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The state of the cluster's control plane. The cluster is ready when it's `running` and every node pool has `node_count` workers that are all `ready`.\n\n- `provisioning`: We're creating the control plane and the workers.\n- `running`: The control plane works. Check `node_pools` to see whether the workers are ready.\n- `degraded`: The control plane or some workers aren't healthy. `status_message` says which.\n- `upgrading`: We're upgrading the control plane and then the workers.\n- `restoring`: We're restoring the control plane from a snapshot.\n- `failed`: We couldn't create the cluster. `status_message` says why.\n- `destroyed`: The cluster is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the control plane and the workers.",
              "running": "The control plane works. Check `node_pools` to see whether the workers are ready.",
              "degraded": "The control plane or some workers aren't healthy. `status_message` says which.",
              "upgrading": "We're upgrading the control plane and then the workers.",
              "restoring": "We're restoring the control plane from a snapshot.",
              "failed": "We couldn't create the cluster. `status_message` says why.",
              "destroyed": "The cluster is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "What went wrong while creating, scaling or running the cluster, or `null`.",
            "nullable": true,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The host name of the Kubernetes API.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port of the Kubernetes API, always `6443`."
              },
              "api_allowed_cidrs": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IP ranges allowed to reach the cluster's Kubernetes API, as 1 to 50 IPv4 or IPv6 CIDRs."
              }
            },
            "description": "Where to reach the cluster's Kubernetes API, and from which IP ranges.",
            "nullable": false,
            "sensitive": false
          },
          "pod_cidr": {
            "type": "string",
            "description": "The IPv4 range for pods.",
            "nullable": false,
            "sensitive": false
          },
          "service_cidr": {
            "type": "string",
            "description": "The IPv4 range for Kubernetes services.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers were ready when we last checked.",
            "nullable": false,
            "sensitive": false
          },
          "nodes_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the cluster has now. Each node pool's `node_count` says how many it should have.",
            "nullable": false,
            "sensitive": false
          },
          "node_pools": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node pool's ID, a UUID."
                },
                "name": {
                  "type": "string",
                  "description": "The node pool's name."
                },
                "server_type": {
                  "type": "string",
                  "description": "The server type of the workers."
                },
                "node_count": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers the node pool should have."
                },
                "labels": {
                  "type": "object",
                  "additionalProperties": true,
                  "description": "The Kubernetes labels of the workers, as string pairs."
                },
                "taints": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "key": {
                        "type": "string",
                        "description": "The taint's key."
                      },
                      "value": {
                        "type": "string",
                        "description": "The taint's value, or `null` when the taint has none.",
                        "nullable": true
                      },
                      "effect": {
                        "type": "string",
                        "enum": [
                          "NoSchedule",
                          "PreferNoSchedule",
                          "NoExecute"
                        ],
                        "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                      }
                    },
                    "required": [
                      "key",
                      "effect"
                    ]
                  },
                  "description": "The Kubernetes taints of the workers."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "active",
                    "scaling",
                    "deleting",
                    "destroyed"
                  ],
                  "description": "The node pool's state. A node pool that's `active` can still have workers that aren't ready."
                },
                "status_message": {
                  "type": "string",
                  "description": "Why the node pool has fewer workers than `node_count`, or `null`.",
                  "nullable": true
                },
                "nodes_ready": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers of the node pool are `ready`."
                },
                "scaling": {
                  "type": "object",
                  "properties": {
                    "from": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The number of workers before the change.",
                      "nullable": true
                    },
                    "to": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The `node_count` to reach."
                    },
                    "started_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When the change started."
                    },
                    "estimated_ready_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When we expect the change to be done."
                    }
                  },
                  "description": "How a change of size is going while the node pool is `scaling`, or `null` otherwise.",
                  "nullable": true
                },
                "nodes": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "description": "The worker's ID."
                      },
                      "name": {
                        "type": "string",
                        "description": "The worker's name in Kubernetes."
                      },
                      "server_id": {
                        "type": "string",
                        "description": "The ID of the server that runs the worker, or `null` while the worker is `queued`.",
                        "nullable": true
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "queued",
                          "provisioning",
                          "joining",
                          "ready",
                          "not_ready",
                          "draining",
                          "replacing",
                          "destroyed"
                        ],
                        "description": "The worker's state."
                      },
                      "version": {
                        "type": "string",
                        "description": "The Kubernetes version the worker reports.",
                        "nullable": true
                      },
                      "last_seen_at": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When we last saw the worker ready.",
                        "nullable": true
                      }
                    }
                  },
                  "description": "The node pool's workers."
                }
              }
            },
            "description": "The cluster's node pools, each with its workers. Deleted node pools aren't listed.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the cluster. The list is empty while the cluster has no workers. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to the workers. The list is empty while the cluster has no workers. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "kubeconfig_rotated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the admin credentials of the kubeconfig were first issued or last rotated, or `null` before they're issued.",
            "nullable": true,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest `available` snapshot of the control plane was created, or `null` when there is none.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the cluster. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "pre_upgrade_snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot we create before the upgrade. Restore it to roll the upgrade back.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the Kubernetes cluster.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `node_pool_scaled`, `node_replaced`, `upgrade_aborted` or `restore_failed`.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The Better Stack ID of the user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "description": "Who did it, `user` for a person, `api_token` for an API token and `system` for Better Stack.",
            "nullable": true,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event, such as a `snapshot_id`, a `reason`, a `node_pool` or the name of a replacement worker.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When it happened.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_node_pool.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The node pool's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
            "description": "The node pool's name, unique among the cluster's node pools.",
            "nullable": false,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The server type of the workers.",
            "nullable": false,
            "sensitive": false
          },
          "node_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the node pool should have, from 0 to 100. The node pools of a cluster can have 100 workers in total. `nodes` lists the workers the node pool has now.",
            "nullable": false,
            "sensitive": false
          },
          "labels": {
            "type": "object",
            "additionalProperties": true,
            "description": "The Kubernetes labels of the workers, as string pairs, or an empty object when there are none.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "taints": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The taint's key."
                },
                "value": {
                  "type": "string",
                  "description": "The taint's value, or `null` when the taint has none.",
                  "nullable": true
                },
                "effect": {
                  "type": "string",
                  "enum": [
                    "NoSchedule",
                    "PreferNoSchedule",
                    "NoExecute"
                  ],
                  "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                }
              },
              "required": [
                "key",
                "effect"
              ]
            },
            "description": "The Kubernetes taints of the workers, or an empty list when there are none.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "scaling",
              "deleting",
              "destroyed"
            ],
            "description": "The node pool's state. The node pool is ready when the cluster is `running` and every worker of the node pool is `ready`.\n\n- `active`: The node pool isn't changing size. The node pool's workers can still be joining or being replaced.\n- `scaling`: We're adding or removing workers to reach `node_count`. Scaling happens after you change `node_count`, or when the node pool has more or fewer workers than `node_count`.\n- `deleting`: We're removing the node pool.\n- `destroyed`: The node pool is deleted.",
            "x-enum-descriptions": {
              "active": "The node pool isn't changing size. The node pool's workers can still be joining or being replaced.",
              "scaling": "We're adding or removing workers to reach `node_count`. Scaling happens after you change `node_count`, or when the node pool has more or fewer workers than `node_count`.",
              "deleting": "We're removing the node pool.",
              "destroyed": "The node pool is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the node pool has fewer workers than `node_count`, such as a quota limit, no capacity for the server type in the zone, or a server we couldn't create. `null` again once the node pool reaches `node_count`.",
            "nullable": true,
            "sensitive": false
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers of the node pool are `ready`.",
            "nullable": false,
            "sensitive": false
          },
          "scaling": {
            "type": "object",
            "properties": {
              "from": {
                "type": "integer",
                "format": "int64",
                "description": "The number of workers before the change.",
                "nullable": true
              },
              "to": {
                "type": "integer",
                "format": "int64",
                "description": "The `node_count` to reach."
              },
              "started_at": {
                "type": "string",
                "format": "date-time",
                "description": "When the change started."
              },
              "estimated_ready_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we expect the change to be done."
              }
            },
            "description": "How a change of size is going while `status` is `scaling`, or `null` otherwise.",
            "nullable": true,
            "sensitive": false
          },
          "nodes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The worker's ID. Use it to recycle the worker."
                },
                "name": {
                  "type": "string",
                  "description": "The worker's name in Kubernetes."
                },
                "server_id": {
                  "type": "string",
                  "description": "The ID of the server that runs the worker, or `null` while the worker is `queued`.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "queued",
                    "provisioning",
                    "joining",
                    "ready",
                    "not_ready",
                    "draining",
                    "replacing",
                    "destroyed"
                  ],
                  "description": "The worker's state.\n\n- `queued`: We'll create the worker.\n- `provisioning`: We're creating the worker's server.\n- `joining`: The worker is joining the cluster.\n- `ready`: The worker is ready in Kubernetes.\n- `not_ready`: The worker joined, but Kubernetes reports it as not ready.\n- `draining`: We're moving pods off the worker before we remove it.\n- `replacing`: We're creating a new worker to replace this one.\n- `destroyed`: The worker is removed.",
                  "x-enum-descriptions": {
                    "queued": "We'll create the worker.",
                    "provisioning": "We're creating the worker's server.",
                    "joining": "The worker is joining the cluster.",
                    "ready": "The worker is ready in Kubernetes.",
                    "not_ready": "The worker joined, but Kubernetes reports it as not ready.",
                    "draining": "We're moving pods off the worker before we remove it.",
                    "replacing": "We're creating a new worker to replace this one.",
                    "destroyed": "The worker is removed."
                  }
                },
                "version": {
                  "type": "string",
                  "description": "The Kubernetes version the worker reports.",
                  "nullable": true
                },
                "last_seen_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When we last saw the worker ready.",
                  "nullable": true
                }
              }
            },
            "description": "The node pool's workers. New workers show up at once as `queued`, then go through `provisioning` and `joining` to `ready`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_node_pool.recycle": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the worker being replaced.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The name in Kubernetes of the worker being replaced.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server of the worker being replaced.",
            "nullable": true,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "queued",
              "provisioning",
              "joining",
              "ready",
              "not_ready",
              "draining",
              "replacing",
              "destroyed"
            ],
            "description": "The worker's state, `replacing` in this response.",
            "nullable": false,
            "sensitive": false
          },
          "version": {
            "type": "string",
            "description": "The Kubernetes version the worker last reported.",
            "nullable": true,
            "sensitive": false
          },
          "last_seen_at": {
            "type": "string",
            "format": "date-time",
            "description": "When we last saw the worker ready.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the cluster's control plane.",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often to create a snapshot. A monthly schedule runs on the same day each month.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.kubernetes_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the cluster's control plane. You can't change that server directly.",
            "nullable": true,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.\n\n- `manual`: You created the snapshot, or we created it before an upgrade.\n- `scheduled`: A snapshot schedule created it.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot, or we created it before an upgrade.",
              "scheduled": "A snapshot schedule created it."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. To follow a new snapshot, use [List Kubernetes snapshots](/docs/cloud/api/kubernetes-snapshots/list-kubernetes-snapshots/) until the snapshot is no longer `pending`.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready, and you can restore it.\n- `failed`: We couldn't create the snapshot. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the control plane's disk when the snapshot was taken, in bytes. We bill this size. Stays `null` until the snapshot is ready.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The zone the snapshot was taken in, which is the cluster's zone.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why the snapshot failed, or `null` unless the snapshot failed.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ]
              },
              "details": {
                "type": "string",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time"
              }
            },
            "description": "The lock we put on the snapshot, such as for non-payment, or `null` when it isn't locked.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "The snapshot's tags, as string pairs. You can't set them on a Kubernetes snapshot.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.kubernetes_version.list": {
        "type": "object",
        "properties": {
          "version": {
            "type": "string",
            "description": "The Kubernetes minor version, such as `1.37`. Send it as `version` when you create a cluster.",
            "nullable": false,
            "sensitive": false
          },
          "build": {
            "type": "string",
            "description": "The exact Kubernetes build we install for this version, such as `v1.37.2+k3s1`.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new cluster gets this version when you leave out `version`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.load_balancer.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The load balancer's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The load balancer's name. Must be unique among your organization's load balancers that aren't `failed` or `destroyed`.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The load balancer's type, such as `LB1`. Get the types via [List load balancer types](/docs/cloud/api/load-balancer-types/list-load-balancer-types/).",
            "nullable": false,
            "sensitive": false
          },
          "algorithm": {
            "type": "string",
            "enum": [
              "round_robin",
              "least_connections",
              "source_ip"
            ],
            "description": "How the load balancer picks a target for each connection.\n\n- `round_robin`: Sends each new connection to the next target in turn.\n- `least_connections`: Sends each new connection to the target with the fewest open connections.\n- `source_ip`: Sends all connections from one client IP to the same target.",
            "x-enum-descriptions": {
              "round_robin": "Sends each new connection to the next target in turn.",
              "least_connections": "Sends each new connection to the target with the fewest open connections.",
              "source_ip": "Sends all connections from one client IP to the same target."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "rescaling",
              "failed",
              "destroyed"
            ],
            "description": "The load balancer's state.\n\n- `provisioning`: We're starting the load balancer.\n- `running`: The load balancer is ready. `status_message` reports any problem. `config_applied_at` says when we last applied your configuration.\n- `rescaling`: We're changing the load balancer's type. The load balancer returns to `running` even when we couldn't apply its configuration yet. `status_message` then says why.\n- `failed`: We couldn't create the load balancer. `status_message` says why.\n- `destroyed`: The load balancer is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the load balancer.",
              "running": "The load balancer is ready. `status_message` reports any problem. `config_applied_at` says when we last applied your configuration.",
              "rescaling": "We're changing the load balancer's type. The load balancer returns to `running` even when we couldn't apply its configuration yet. `status_message` then says why.",
              "failed": "We couldn't create the load balancer. `status_message` says why.",
              "destroyed": "The load balancer is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "What went wrong when we created or configured the load balancer, or what's wrong with it now. `null` when there's nothing to report.",
            "nullable": true,
            "sensitive": false
          },
          "public_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "ip": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                }
              }
            },
            "description": "The load balancer's public IP addresses, one IPv4 and one IPv6.",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "network_id": {
                  "type": "string"
                },
                "ip_address": {
                  "type": "string"
                }
              }
            },
            "description": "The load balancer's private IP in each attached network.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the networks attached to the load balancer. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to the load balancer, at most one. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "services": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The service's ID."
                },
                "protocol": {
                  "type": "string",
                  "enum": [
                    "tcp",
                    "http",
                    "https",
                    "udp"
                  ],
                  "description": "The protocol the service listens for.\n\n- `tcp`: Forwards TCP connections.\n- `http`: Forwards HTTP requests.\n- `https`: Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests.\n- `udp`: Forwards UDP traffic.",
                  "x-enum-descriptions": {
                    "tcp": "Forwards TCP connections.",
                    "http": "Forwards HTTP requests.",
                    "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests.",
                    "udp": "Forwards UDP traffic."
                  }
                },
                "listen_port": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The port the service listens on."
                },
                "destination_port": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The port on the targets that traffic goes to."
                },
                "redirect_http": {
                  "type": "boolean",
                  "description": "Whether HTTP requests are redirected to this HTTPS service."
                },
                "http_timeout_seconds": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds."
                },
                "sticky_sessions": {
                  "type": "boolean",
                  "description": "Whether a cookie sends each client to the same target."
                },
                "sticky_cookie_name": {
                  "type": "string",
                  "description": "The name of the sticky session cookie."
                },
                "sticky_cookie_lifetime_seconds": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How long the sticky session cookie lasts, in seconds."
                },
                "proxy_protocol": {
                  "type": "string",
                  "enum": [
                    "disabled",
                    "v1",
                    "v2"
                  ],
                  "description": "The PROXY protocol version the targets accept, or `disabled`."
                },
                "certificate_ids": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "The IDs of the certificates the service presents."
                },
                "target_health": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "service_id": {
                        "type": "integer",
                        "format": "int64",
                        "description": "The ID of the service."
                      },
                      "server_id": {
                        "type": "string",
                        "description": "The ID of the target server."
                      },
                      "state": {
                        "type": "string",
                        "enum": [
                          "up",
                          "down",
                          "unknown"
                        ],
                        "description": "Whether the target is healthy.\n\n- `up`: The target passes its checks.\n- `down`: The target fails its checks.\n- `unknown`: We have no result for the target yet.",
                        "x-enum-descriptions": {
                          "up": "The target passes its checks.",
                          "down": "The target fails its checks.",
                          "unknown": "We have no result for the target yet."
                        }
                      },
                      "state_changed_at": {
                        "type": "string",
                        "format": "date-time",
                        "description": "When `state` last changed, or `null`.",
                        "nullable": true
                      },
                      "status_message": {
                        "type": "string",
                        "description": "Why the target is down, or `null`.",
                        "nullable": true
                      }
                    }
                  },
                  "description": "The latest health of each target, updated about every 30 seconds."
                },
                "health_check": {
                  "type": "object",
                  "properties": {
                    "protocol": {
                      "type": "string",
                      "enum": [
                        "tcp",
                        "http"
                      ],
                      "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection.\n- `http`: Sends an HTTP request to the target.",
                      "x-enum-descriptions": {
                        "tcp": "Checks that the target accepts a TCP connection.",
                        "http": "Sends an HTTP request to the target."
                      }
                    },
                    "port": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The port we check."
                    },
                    "interval_seconds": {
                      "type": "integer",
                      "format": "int64",
                      "description": "How often we check each target, in seconds."
                    },
                    "timeout_seconds": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The check timeout in seconds."
                    },
                    "retries": {
                      "type": "integer",
                      "format": "int64",
                      "description": "How many checks in a row must fail before a target is down."
                    },
                    "domain": {
                      "type": "string",
                      "description": "The hostname we send in the `Host` header of an HTTP check.",
                      "nullable": true
                    },
                    "path": {
                      "type": "string",
                      "description": "The path an HTTP check requests."
                    },
                    "response": {
                      "type": "string",
                      "description": "Text the response must contain.",
                      "nullable": true
                    },
                    "status_codes": {
                      "type": "string",
                      "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
                    },
                    "tls": {
                      "type": "boolean",
                      "description": "Whether checks connect with TLS."
                    }
                  },
                  "description": "How the service checks that its targets are healthy."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the service was created."
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the service was last updated."
                }
              }
            },
            "description": "The services that listen for traffic, with their settings and the latest health of each target. Add a service via [Create a load balancer service](/docs/cloud/api/load-balancer-services/create-load-balancer-service/).",
            "nullable": false,
            "sensitive": false
          },
          "targets": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The target's ID."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "server",
                    "label_selector"
                  ],
                  "description": "What the target points at.\n\n- `server`: One server, in `server_id`.\n- `label_selector`: Every server that has the tags in `selector`.",
                  "x-enum-descriptions": {
                    "server": "One server, in `server_id`.",
                    "label_selector": "Every server that has the tags in `selector`."
                  }
                },
                "server_id": {
                  "type": "string",
                  "description": "The ID of the server to send traffic to.",
                  "nullable": true
                },
                "selector": {
                  "type": "object",
                  "additionalProperties": true,
                  "description": "The tags a server must have to receive traffic, as string pairs. A server must have every pair.",
                  "nullable": true
                },
                "use_private_ip": {
                  "type": "boolean",
                  "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the target was added."
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the target was last updated."
                }
              }
            },
            "description": "The targets that receive the traffic. A `label_selector` target is one entry, however many servers match it.",
            "nullable": false,
            "sensitive": false
          },
          "config_applied_at": {
            "type": "string",
            "format": "date-time",
            "description": "When we last applied the configuration to the load balancer, or `null` until we first apply it.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the load balancer was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the load balancer was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the load balancer.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.load_balancer.metrics": {
        "type": "object",
        "properties": {
          "load_balancer_id": {
            "type": "string",
            "description": "The load balancer's ID.",
            "nullable": false,
            "sensitive": false
          },
          "load_balancer_name": {
            "type": "string",
            "description": "The load balancer's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range the metrics cover.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range the metrics cover.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the points are.\n\n- `raw`: One point a minute, for a range up to one day.\n- `hourly`: One point an hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "One point a minute, for a range up to one day.",
              "hourly": "One point an hour, for a longer range."
            },
            "nullable": false,
            "sensitive": false
          },
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "dt": {
                  "type": "string",
                  "format": "date-time"
                },
                "connections": {
                  "type": "object",
                  "properties": {
                    "open": {
                      "type": "number"
                    },
                    "open_max": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "per_second": {
                      "type": "number"
                    }
                  }
                },
                "traffic": {
                  "type": "object",
                  "properties": {
                    "bytes_in_per_second": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "bytes_out_per_second": {
                      "type": "integer",
                      "format": "int64"
                    }
                  }
                }
              }
            },
            "description": "The metrics, one entry per point.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.load_balancer_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "load_balancer_id": {
            "type": "string",
            "description": "The ID of the load balancer the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, `created`, `rescaled` or `destroyed`. The event is recorded when we accept the request, before the change is done.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who did it, or `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.\n\n- `user`: A Better Stack user did it. `user_id` says who.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event. The keys depend on `action`.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.load_balancer_service.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64",
            "description": "The service's ID.",
            "nullable": false,
            "sensitive": false
          },
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "http",
              "https",
              "udp"
            ],
            "description": "The protocol the service listens for.\n\n- `tcp`: Forwards TCP connections.\n- `http`: Forwards HTTP requests.\n- `https`: Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.\n- `udp`: Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`.",
            "x-enum-descriptions": {
              "tcp": "Forwards TCP connections.",
              "http": "Forwards HTTP requests.",
              "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.",
              "udp": "Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`."
            },
            "nullable": false,
            "sensitive": false
          },
          "listen_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port the service listens on, 1–65535. Can't be `8402` or `9901`, which the load balancer uses itself. A `tcp` and a `udp` service can use the same port.",
            "nullable": false,
            "sensitive": false
          },
          "destination_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port on the targets that traffic goes to, 1–65535.",
            "nullable": false,
            "sensitive": false
          },
          "redirect_http": {
            "type": "boolean",
            "description": "Whether HTTP requests are redirected to this HTTPS service. Only `https` services can redirect.",
            "nullable": false,
            "sensitive": false
          },
          "http_timeout_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds, 5–600. Only `http` and `https` services use it.",
            "nullable": false,
            "sensitive": false
          },
          "sticky_sessions": {
            "type": "boolean",
            "description": "Whether a cookie sends each client to the same target. Only `http` and `https` services can use sticky sessions.",
            "nullable": false,
            "sensitive": false
          },
          "sticky_cookie_name": {
            "type": "string",
            "description": "The name of the sticky session cookie, 1–64 letters, digits, underscores, dots or hyphens.",
            "nullable": false,
            "sensitive": false
          },
          "sticky_cookie_lifetime_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the sticky session cookie lasts, 1–86400 seconds.",
            "nullable": false,
            "sensitive": false
          },
          "proxy_protocol": {
            "type": "string",
            "enum": [
              "disabled",
              "v1",
              "v2"
            ],
            "description": "The PROXY protocol version the targets accept, or `disabled`. A `udp` service can't use it.",
            "nullable": false,
            "sensitive": false
          },
          "certificate_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the certificates the service presents. Get them via [List certificates](/docs/cloud/api/certificates/list-certificates/).",
            "nullable": false,
            "sensitive": false
          },
          "health_check": {
            "type": "object",
            "properties": {
              "protocol": {
                "type": "string",
                "enum": [
                  "tcp",
                  "http"
                ],
                "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.\n- `http`: Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`.",
                "x-enum-descriptions": {
                  "tcp": "Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.",
                  "http": "Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`."
                }
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port we check, 1–65535. Defaults to `destination_port`.",
                "nullable": true
              },
              "interval_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "How often we check each target, 2–3600 seconds."
              },
              "timeout_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "The check timeout in seconds, 1–60."
              },
              "retries": {
                "type": "integer",
                "format": "int64",
                "description": "How many checks in a row must fail before a target is down, 1–10."
              },
              "domain": {
                "type": "string",
                "description": "The hostname we send in the `Host` header of an HTTP check.",
                "nullable": true
              },
              "path": {
                "type": "string",
                "description": "The path an HTTP check requests, starting with `/`, with no spaces or quotes."
              },
              "response": {
                "type": "string",
                "description": "Text the response must contain, at most 255 characters with no line breaks or quotes.",
                "nullable": true
              },
              "status_codes": {
                "type": "string",
                "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
              },
              "tls": {
                "type": "boolean",
                "description": "Whether checks connect with TLS."
              }
            },
            "description": "How the service checks that its targets are healthy.",
            "nullable": false,
            "sensitive": false
          },
          "target_health": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "service_id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The ID of the service."
                },
                "server_id": {
                  "type": "string",
                  "description": "The ID of the target server."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "up",
                    "down",
                    "unknown"
                  ],
                  "description": "Whether the target is healthy.\n\n- `up`: The target passes its checks.\n- `down`: The target fails its checks.\n- `unknown`: We have no result for the target yet.",
                  "x-enum-descriptions": {
                    "up": "The target passes its checks.",
                    "down": "The target fails its checks.",
                    "unknown": "We have no result for the target yet."
                  }
                },
                "state_changed_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When `state` last changed, or `null`.",
                  "nullable": true
                },
                "status_message": {
                  "type": "string",
                  "description": "Why the target is down, or `null`.",
                  "nullable": true
                }
              }
            },
            "description": "The latest health of each target, updated about every 30 seconds.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the service was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the service was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.load_balancer_target.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64",
            "description": "The target's ID.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "enum": [
              "server",
              "label_selector"
            ],
            "description": "What the target points at.\n\n- `server`: One server. Send `server_id` and leave out `selector`.\n- `label_selector`: Every server that has the tags in `selector`. Send `selector` and leave out `server_id`.",
            "x-enum-descriptions": {
              "server": "One server. Send `server_id` and leave out `selector`.",
              "label_selector": "Every server that has the tags in `selector`. Send `selector` and leave out `server_id`."
            },
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server to send traffic to.",
            "nullable": true,
            "sensitive": false
          },
          "selector": {
            "type": "object",
            "additionalProperties": true,
            "description": "The tags a server must have to receive traffic, as string pairs. A server must have every pair.",
            "nullable": true,
            "sensitive": false,
            "x-own-keys": true
          },
          "use_private_ip": {
            "type": "boolean",
            "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the target was added.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the target was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.load_balancer_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `LB1`. Send it as `type` when you create or rescale a load balancer.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections a load balancer of this type accepts at once.",
            "nullable": false,
            "sensitive": false
          },
          "max_services": {
            "type": "integer",
            "format": "int64",
            "description": "The most services a load balancer of this type can have.",
            "nullable": false,
            "sensitive": false
          },
          "max_targets": {
            "type": "integer",
            "format": "int64",
            "description": "The most targets a load balancer of this type can have. Each server that a target's tag `selector` matches counts toward the limit.",
            "nullable": false,
            "sensitive": false
          },
          "max_certificates": {
            "type": "integer",
            "format": "int64",
            "description": "The most different certificates a load balancer of this type can present across its services.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: You can order the type.\n- `unavailable`: The type is deprecated. Load balancers that have it keep running, but you can't create or rescale a load balancer to it.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Load balancers that have it keep running, but you can't create or rescale a load balancer to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use instead of this deprecated one, or `null` for a type you can order.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql.credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name, `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The `admin` user's password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The default database's name.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect from your private networks, with the password and `ssl-mode=REQUIRED`.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect from the internet, with the password and `ssl-mode=REQUIRED`, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous password stops working, 24 hours after a rotation, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `MY1`, which sets its size. Get the types via [List MySQL types](/docs/cloud/api/mysql-types/list-mysql-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect to the instance at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The MySQL version, as major and minor, such as `9.7`. Get the versions via [List MySQL versions](/docs/cloud/api/mysql-versions/list-mysql-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact MySQL version the instance runs, or `null` until we know it.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to. An upgrade can't be undone.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`.\n\n- `provisioning`: We're starting the nodes and installing MySQL.\n- `running`: The instance is ready.\n- `degraded`: A node is down, replication is broken or the disk is almost full. `status_message` says which.\n- `rescaling`: We're changing the instance's type.\n- `upgrading`: We're upgrading the instance to a newer MySQL version.\n- `restoring`: We're restoring the instance from a snapshot.\n- `failed`: We couldn't create the instance. `status_message` says why. Create a new one instead.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the nodes and installing MySQL.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is almost full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading the instance to a newer MySQL version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "We couldn't create the instance. `status_message` says why. Create a new one instead.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "More about the status, such as what failed or which action didn't finish. `null` when there's nothing to report.",
            "nullable": true,
            "sensitive": false
          },
          "sql_mode": {
            "type": "string",
            "description": "The SQL modes, separated by commas, such as `STRICT_TRANS_TABLES,NO_ZERO_DATE`. `null` for MySQL's default modes.",
            "nullable": true,
            "sensitive": false
          },
          "sql_require_primary_key": {
            "type": "boolean",
            "description": "Whether new tables must have a primary key.",
            "nullable": false,
            "sensitive": false
          },
          "default_time_zone": {
            "type": "string",
            "description": "The default time zone. Accepts `SYSTEM`, `UTC`, an offset from `-13:59` to `+14:00`, or an IANA time zone name such as `Europe/Prague`.",
            "nullable": false,
            "sensitive": false
          },
          "max_allowed_packet": {
            "type": "integer",
            "format": "int64",
            "description": "The largest packet MySQL accepts, in bytes, from `16777216` to `1073741824`.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is almost full.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port to connect to, `3306`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the instance's primary.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ]
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ]
                },
                "replication_lag_seconds": {
                  "type": "number",
                  "nullable": true
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "type": "string"
                      }
                    }
                  }
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas. A replica's `replication_lag_seconds` says how many seconds the replica is behind the primary. `replication_lag_seconds` is `null` on the primary.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was taken, or `null` when there's none.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.mysql.metrics": {
        "type": "object",
        "properties": {
          "mysql_id": {
            "type": "string",
            "description": "The instance's ID.",
            "nullable": false,
            "sensitive": false
          },
          "mysql_name": {
            "type": "string",
            "description": "The instance's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range returned.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range returned.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the values are.\n\n- `raw`: A value for each minute, for a range of up to one day.\n- `hourly`: A value for each hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "A value for each minute, for a range of up to one day.",
              "hourly": "A value for each hour, for a longer range."
            },
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "member_id": {
                  "type": "string"
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ]
                },
                "data": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "dt": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "queries_per_second": {
                        "type": "number"
                      },
                      "slow_queries_per_second": {
                        "type": "number"
                      },
                      "threads": {
                        "type": "object",
                        "properties": {
                          "connected": {
                            "type": "number"
                          },
                          "connected_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "running": {
                            "type": "number"
                          },
                          "max_connections": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "buffer_pool_hit_ratio": {
                        "type": "number"
                      },
                      "rows_read_per_second": {
                        "type": "number"
                      },
                      "rows_written_per_second": {
                        "type": "number"
                      },
                      "disk": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "usable_bytes": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "replication_lag_seconds": {
                        "type": "number"
                      }
                    }
                  }
                }
              }
            },
            "description": "Each node's metrics over time. Every point has its time, the queries and rows per second, the threads, the buffer pool hit ratio, the disk use and the replication lag.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql.rotate_credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name, `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The `admin` user's new password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The default database's name.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect from your private networks, with the new password.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect from the internet, with the new password, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous password stops working, 24 hours from now.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql.upgrade": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `MY1`, which sets its size. Get the types via [List MySQL types](/docs/cloud/api/mysql-types/list-mysql-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect to the instance at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The MySQL version, as major and minor, such as `9.7`. Get the versions via [List MySQL versions](/docs/cloud/api/mysql-versions/list-mysql-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact MySQL version the instance runs, or `null` until we know it.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to. An upgrade can't be undone.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`.\n\n- `provisioning`: We're starting the nodes and installing MySQL.\n- `running`: The instance is ready.\n- `degraded`: A node is down, replication is broken or the disk is almost full. `status_message` says which.\n- `rescaling`: We're changing the instance's type.\n- `upgrading`: We're upgrading the instance to a newer MySQL version.\n- `restoring`: We're restoring the instance from a snapshot.\n- `failed`: We couldn't create the instance. `status_message` says why. Create a new one instead.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the nodes and installing MySQL.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is almost full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading the instance to a newer MySQL version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "We couldn't create the instance. `status_message` says why. Create a new one instead.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "More about the status, such as what failed or which action didn't finish. `null` when there's nothing to report.",
            "nullable": true,
            "sensitive": false
          },
          "sql_mode": {
            "type": "string",
            "description": "The SQL modes, separated by commas, such as `STRICT_TRANS_TABLES,NO_ZERO_DATE`. `null` for MySQL's default modes.",
            "nullable": true,
            "sensitive": false
          },
          "sql_require_primary_key": {
            "type": "boolean",
            "description": "Whether new tables must have a primary key.",
            "nullable": false,
            "sensitive": false
          },
          "default_time_zone": {
            "type": "string",
            "description": "The default time zone. Accepts `SYSTEM`, `UTC`, an offset from `-13:59` to `+14:00`, or an IANA time zone name such as `Europe/Prague`.",
            "nullable": false,
            "sensitive": false
          },
          "max_allowed_packet": {
            "type": "integer",
            "format": "int64",
            "description": "The largest packet MySQL accepts, in bytes, from `16777216` to `1073741824`.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is almost full.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port to connect to, `3306`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the instance's primary.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ]
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ]
                },
                "replication_lag_seconds": {
                  "type": "number",
                  "nullable": true
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "type": "string"
                      }
                    }
                  }
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas. A replica's `replication_lag_seconds` says how many seconds the replica is behind the primary. `replication_lag_seconds` is `null` on the primary.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was taken, or `null` when there's none.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "pre_upgrade_snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot we created before the upgrade.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `snapshot_created`.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who made the change, or `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who made the change.\n\n- `user`: A Better Stack user made the change. `user_id` says who.\n- `api_token`: A request with an API token made the change.\n- `system`: Better Stack made the change.",
            "x-enum-descriptions": {
              "user": "A Better Stack user made the change. `user_id` says who.",
              "api_token": "A request with an API token made the change.",
              "system": "Better Stack made the change."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about what happened, such as the new type or version, or the snapshot ID.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql_scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the schedule belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's primary. Changes when the instance fails over.",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` before the first one.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the snapshot was taken from.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that ran the instance's primary when the snapshot was taken, or `null` once that server is removed.",
            "nullable": true,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.\n\n- `manual`: You created the snapshot.\n- `scheduled`: A snapshot schedule created the snapshot.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its status is `available`.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready, and you can restore it.\n- `failed`: We couldn't create the snapshot. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. The snapshot is billed by this size. `null` until the snapshot is ready.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why the snapshot failed, or `null` unless the snapshot failed.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ]
              },
              "details": {
                "type": "string",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time"
              }
            },
            "description": "The lock Better Stack put on the snapshot, with its reason, or `null` when the snapshot isn't locked.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.mysql_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `MY8`. Send it as `type` when you create or rescale an instance.",
            "nullable": false,
            "sensitive": false
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections an instance of this type accepts at once.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can create instances of this type.\n\n- `global`: You can create instances of this type.\n- `unavailable`: The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it.",
            "x-enum-descriptions": {
              "global": "You can create instances of this type.",
              "unavailable": "The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use instead of this deprecated one, or `null` when the type is offered.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.mysql_version.list": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The MySQL LTS version, as major and minor, such as `9.7`.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.network.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The network's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The network's name.",
            "nullable": false,
            "sensitive": false
          },
          "ip_prefix": {
            "type": "string",
            "description": "The IPv4 or IPv6 address the network's range starts at, such as `10.0.0.0`.",
            "nullable": false,
            "sensitive": false
          },
          "ip_prefix_length": {
            "type": "integer",
            "format": "int64",
            "description": "The prefix length of the network's range, such as `24` for an IPv4 range of 256 addresses. Accepts `0` to `128`. Use at most `32` for an IPv4 range.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the network was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the network was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the network. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache.credentials": {
        "type": "object",
        "properties": {
          "access_key_id": {
            "type": "string",
            "description": "The access key ID.",
            "nullable": false,
            "sensitive": true
          },
          "secret_access_key": {
            "type": "string",
            "description": "The secret access key.",
            "nullable": false,
            "sensitive": true
          },
          "endpoints": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is on.",
            "nullable": false,
            "sensitive": false
          },
          "previous_access_key_id": {
            "type": "string",
            "description": "The previous access key ID, which keeps working until `rotating_until`, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": true
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous key stops working, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": false
          },
          "usage": {
            "type": "string",
            "description": "An example command for the AWS CLI. Clients must use path-style addressing.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The object cache's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The object cache's name, at most 255 characters. Must be unique among your organization's object caches that aren't `failed` or `destroyed`.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The object cache's type, such as `OP100`.",
            "nullable": false,
            "sensitive": false
          },
          "usable_cache_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space of the object cache's type, in GB.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "failed",
              "destroyed"
            ],
            "description": "The object cache's state.\n\n- `provisioning`: We're starting the object cache.\n- `running`: The object cache is ready.\n- `degraded`: Part of the object cache isn't working. `status_message` says why. An original bucket that is down leaves the object cache `running`.\n- `rescaling`: We're changing the object cache's type. The rescale is done when the object cache is `running` with the new `type`. When the object cache turns `degraded`, the rescale didn't finish.\n- `failed`: We couldn't create the object cache. `status_message` says why. Create a new one instead.\n- `destroyed`: The object cache is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the object cache.",
              "running": "The object cache is ready.",
              "degraded": "Part of the object cache isn't working. `status_message` says why. An original bucket that is down leaves the object cache `running`.",
              "rescaling": "We're changing the object cache's type. The rescale is done when the object cache is `running` with the new `type`. When the object cache turns `degraded`, the rescale didn't finish.",
              "failed": "We couldn't create the object cache. `status_message` says why. Create a new one instead.",
              "destroyed": "The object cache is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "Why the object cache failed or is `degraded`, or `null` when there's nothing to report.",
            "nullable": true,
            "sensitive": false
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "least_frequently_used",
              "least_recently_used"
            ],
            "description": "Which cached objects we remove first when the cache is full.\n\n- `least_frequently_used`: Removes the objects read least often, so a frequently read object survives a flood of one-off reads.\n- `least_recently_used`: Removes the objects read longest ago, which suits workloads that scan through data.",
            "x-enum-descriptions": {
              "least_frequently_used": "Removes the objects read least often, so a frequently read object survives a flood of one-off reads.",
              "least_recently_used": "Removes the objects read longest ago, which suits workloads that scan through data."
            },
            "nullable": false,
            "sensitive": false
          },
          "max_capacity_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space to use, in GB, from 10 to `usable_cache_gb`.",
            "nullable": false,
            "sensitive": false
          },
          "cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep an object in the cache, in seconds, from 60 to 2592000.",
            "nullable": false,
            "sensitive": false
          },
          "listing_cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep a bucket listing in the cache, in seconds, from 0 to 86400. `0` turns listing caching off.",
            "nullable": false,
            "sensitive": false
          },
          "fsync": {
            "type": "boolean",
            "description": "Whether a write waits until your storage provider has stored the object. With `false`, a write is confirmed once the object cache has saved it to its own disk, and the object is uploaded to your storage provider later.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the object cache also has a public HTTPS endpoint.",
            "nullable": false,
            "sensitive": false
          },
          "public_ipv4": {
            "type": "boolean",
            "description": "Whether the object cache has a public IPv4 address.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of your placement group the object cache was created in, or `null` when the object cache is in none.",
            "nullable": true,
            "sensitive": false
          },
          "cache_used_gb": {
            "type": "number",
            "description": "The cache space in use, in GB.",
            "nullable": false,
            "sensitive": false
          },
          "config_applied_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the object cache last applied its settings. An update is in effect once `config_applied_at` is later than the update. `null` until the settings are first applied.",
            "nullable": true,
            "sensitive": false
          },
          "endpoints": {
            "type": "object",
            "properties": {
              "private": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The object cache's IP address in that network."
                    },
                    "url": {
                      "type": "string",
                      "description": "The endpoint's HTTP URL."
                    }
                  }
                },
                "description": "An HTTP endpoint in each attached network."
              },
              "public": {
                "type": "object",
                "properties": {
                  "hostname": {
                    "type": "string",
                    "description": "The public hostname."
                  },
                  "url": {
                    "type": "string",
                    "description": "The endpoint's HTTPS URL."
                  },
                  "records": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The DNS records the hostname has, `AAAA`, and also `A` when `public_ipv4` is `true`."
                  }
                },
                "description": "The public HTTPS endpoint, or `null` when `public_access` is `false`.",
                "nullable": true
              }
            },
            "description": "Where S3 clients connect. Clients must use path-style addressing and sign requests with SigV4.",
            "nullable": false,
            "sensitive": false
          },
          "buckets": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The bucket's ID."
                },
                "name": {
                  "type": "string",
                  "description": "The bucket name clients use with the object cache."
                },
                "origin_endpoint": {
                  "type": "string",
                  "description": "The URL of your storage provider's S3 endpoint."
                },
                "origin_bucket": {
                  "type": "string",
                  "description": "The name of the bucket at your storage provider."
                },
                "origin_prefix": {
                  "type": "string",
                  "description": "The folder in the bucket at your storage provider that the bucket serves."
                },
                "origin_region": {
                  "type": "string",
                  "description": "The region of your storage provider."
                },
                "origin_force_path_style": {
                  "type": "boolean",
                  "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname."
                },
                "origin_creation_date": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the bucket at your storage provider was created, as your storage provider reports it.",
                  "nullable": true
                },
                "scoped_credentials": {
                  "type": "boolean",
                  "description": "Whether the bucket has its own access keys."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the bucket was added."
                }
              }
            },
            "description": "The buckets the object cache serves. Each bucket maps to a bucket at your storage provider.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the networks attached to the object cache. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the object cache was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the object cache was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the object cache.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.object_cache.rotate_credentials": {
        "type": "object",
        "properties": {
          "access_key_id": {
            "type": "string",
            "description": "The new access key ID.",
            "nullable": false,
            "sensitive": true
          },
          "secret_access_key": {
            "type": "string",
            "description": "The new secret access key.",
            "nullable": false,
            "sensitive": true
          },
          "endpoints": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is on.",
            "nullable": false,
            "sensitive": false
          },
          "previous_access_key_id": {
            "type": "string",
            "description": "The previous access key ID, which keeps working until `rotating_until`, or `null` when `grace_seconds` is `0`.",
            "nullable": true,
            "sensitive": true
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous key stops working.",
            "nullable": true,
            "sensitive": false
          },
          "usage": {
            "type": "string",
            "description": "An example command for the AWS CLI. Clients must use path-style addressing.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache_bucket.credentials": {
        "type": "object",
        "properties": {
          "bucket": {
            "type": "string",
            "description": "The bucket's `name`.",
            "nullable": false,
            "sensitive": false
          },
          "access_key_id": {
            "type": "string",
            "description": "The bucket's access key ID.",
            "nullable": false,
            "sensitive": true
          },
          "secret_access_key": {
            "type": "string",
            "description": "The bucket's secret access key.",
            "nullable": false,
            "sensitive": true
          },
          "endpoints": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The object cache's endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is `true`.",
            "nullable": false,
            "sensitive": false
          },
          "previous_access_key_id": {
            "type": "string",
            "description": "The previous access key ID, which still works until `rotating_until`, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": true
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous access key stops working, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": false
          },
          "usage": {
            "type": "string",
            "description": "An example AWS CLI command that lists the bucket. Clients must send the bucket name in the URL path.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache_bucket.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The bucket's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The bucket name clients use with the object cache, 3–63 lowercase letters, digits, dots and hyphens, starting and ending with a letter or digit.",
            "nullable": false,
            "sensitive": false
          },
          "origin_endpoint": {
            "type": "string",
            "description": "The HTTPS URL of your storage provider's S3 endpoint, such as `https://s3.us-east-1.amazonaws.com`.",
            "nullable": false,
            "sensitive": false
          },
          "origin_bucket": {
            "type": "string",
            "description": "The name of the bucket at your storage provider, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "origin_prefix": {
            "type": "string",
            "description": "A folder in the bucket at your storage provider to serve as the whole bucket, such as `tenant-a/`. Clients see only the objects under it.",
            "nullable": false,
            "sensitive": false
          },
          "origin_region": {
            "type": "string",
            "description": "The region of your storage provider, such as `us-east-1` or `auto`.",
            "nullable": false,
            "sensitive": false
          },
          "origin_force_path_style": {
            "type": "boolean",
            "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname.",
            "nullable": false,
            "sensitive": false
          },
          "origin_creation_date": {
            "type": "string",
            "format": "date-time",
            "description": "When the bucket at your storage provider was created, as your storage provider reports it.",
            "nullable": true,
            "sensitive": false
          },
          "scoped_credentials": {
            "type": "boolean",
            "description": "Whether the bucket has its own access keys. When it's `false`, create them with [Rotate an object cache bucket's credentials](/docs/cloud/api/object-cache-buckets/rotate-object-cache-bucket-credentials/).",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the bucket was added.",
            "nullable": false,
            "sensitive": false
          },
          "origin_access_key_id": {
            "type": "string",
            "description": "The access key ID for your storage provider. Not returned after it's saved.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          },
          "origin_secret_access_key": {
            "type": "string",
            "description": "The secret key for your storage provider. Not returned after it's saved.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          }
        }
      },
      "CLIResponse.cloud.object_cache_bucket.rotate_credentials": {
        "type": "object",
        "properties": {
          "bucket": {
            "type": "string",
            "description": "The bucket's `name`.",
            "nullable": false,
            "sensitive": false
          },
          "access_key_id": {
            "type": "string",
            "description": "The bucket's new access key ID.",
            "nullable": false,
            "sensitive": true
          },
          "secret_access_key": {
            "type": "string",
            "description": "The bucket's new secret access key.",
            "nullable": false,
            "sensitive": true
          },
          "endpoints": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The object cache's endpoint URLs, an HTTP URL in each attached network and the public HTTPS URL when `public_access` is `true`.",
            "nullable": false,
            "sensitive": false
          },
          "previous_access_key_id": {
            "type": "string",
            "description": "The previous access key ID, which still works until `rotating_until`, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": true
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous access key stops working, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": false
          },
          "usage": {
            "type": "string",
            "description": "An example AWS CLI command that lists the bucket. Clients must send the bucket name in the URL path.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "object_proxy_id": {
            "type": "string",
            "description": "The ID of the object cache the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `bucket_added`. An event for a change or a purge is recorded when we accept it, before the change or purge finishes.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.\n\n- `user`: A Better Stack user did it. `user_id` says who.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event. The keys depend on `action`.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.object_cache_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `OP100`. Send it as `type` when you create or rescale an object cache.",
            "nullable": false,
            "sensitive": false
          },
          "usable_cache_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space on NVMe disks, in GB.",
            "nullable": false,
            "sensitive": false
          },
          "max_cached_entries": {
            "type": "integer",
            "format": "int64",
            "description": "The most entries the cache holds.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: You can order the type.\n- `unavailable`: The type is deprecated. Object caches that have it keep running, but you can't create or rescale an object cache to it.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Object caches that have it keep running, but you can't create or rescale an object cache to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.otlp.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The export's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The export's name, up to 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "string",
            "description": "The base URL of your OTLP receiver over HTTP, such as `https://otlp.example.com`. We add `/v1/metrics` unless the URL already ends with it.",
            "nullable": false,
            "sensitive": false
          },
          "header_names": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the export's headers, in alphabetical order.",
            "nullable": false,
            "sensitive": false
          },
          "resource_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources the export sends metrics of. Use `server`.",
            "nullable": false,
            "sensitive": false
          },
          "temporality": {
            "type": "string",
            "enum": [
              "cumulative",
              "delta"
            ],
            "description": "How we send the byte counters. Defaults to `cumulative`.\n\n- `cumulative`: Each data point holds the total since the series started.\n- `delta`: Each data point holds the bytes of one interval. Prometheus-based backends refuse `delta`.",
            "x-enum-descriptions": {
              "cumulative": "Each data point holds the total since the series started.",
              "delta": "Each data point holds the bytes of one interval. Prometheus-based backends refuse `delta`."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether the export is sending. A paused export set to `active` again sends metrics from that moment on.\n\n- `active`: The export sends metrics every minute.\n- `paused`: The export sends nothing.",
            "x-enum-descriptions": {
              "active": "The export sends metrics every minute.",
              "paused": "The export sends nothing."
            },
            "nullable": false,
            "sensitive": false
          },
          "paused_reason": {
            "type": "string",
            "enum": [
              "delivery_failed",
              "destination_refused",
              null
            ],
            "description": "Why we paused the export, or `null` while the export is active or when you paused it.\n\n- `delivery_failed`: No request reached the receiver for 24 hours.\n- `destination_refused`: The endpoint's hostname resolved to a private or otherwise refused address.",
            "x-enum-descriptions": {
              "delivery_failed": "No request reached the receiver for 24 hours.",
              "destination_refused": "The endpoint's hostname resolved to a private or otherwise refused address."
            },
            "nullable": true,
            "sensitive": false
          },
          "last_delivered_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the receiver last accepted a request.",
            "nullable": true,
            "sensitive": false
          },
          "last_error": {
            "type": "string",
            "description": "Why the last delivery failed, such as HTTP 401, or how many data points the receiver rejected. `last_error` is `null` after a delivery without a problem.",
            "nullable": true,
            "sensitive": false
          },
          "last_error_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the error in `last_error` happened.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the export was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the export was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team whose metrics the export sends. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "headers": {
            "type": "object",
            "additionalProperties": true,
            "description": "The headers your receiver needs, such as `Authorization`, as an object that maps each header to a string value. You can send up to 16 headers, 8 KiB in total. We set `Content-Type`, `Content-Encoding` and `User-Agent` ourselves, and connection and proxy headers such as `Host`, `Connection` or `X-Forwarded-For` aren't allowed. An update replaces all headers. Responses show only the names, in `header_names`.",
            "nullable": false,
            "sensitive": true,
            "x-own-keys": true,
            "writeonly": true
          }
        }
      },
      "CLIResponse.cloud.placement_group.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The placement group's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The group's name.",
            "nullable": false,
            "sensitive": false
          },
          "placement_type": {
            "type": "string",
            "enum": [
              "spread",
              "compact"
            ],
            "description": "How we place the group's servers. When there isn't room, the server is still created, on another host.\n\n- `spread`: We put each server on a different host when we can.\n- `compact`: We put the servers on as few hosts as we can.",
            "x-enum-descriptions": {
              "spread": "We put each server on a different host when we can.",
              "compact": "We put the servers on as few hosts as we can."
            },
            "nullable": false,
            "sensitive": false
          },
          "server_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the servers in the group. A server joins the group when you create it with `placement_group_id`.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the group was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the group was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the group. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.postgres.credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name, `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The user's password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The database the URIs connect to, `defaultdb` when the instance has it, or else the first database by name.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from your private networks, with the password and `sslmode=verify-full`.",
            "nullable": false,
            "sensitive": true
          },
          "pooled_uri": {
            "type": "string",
            "description": "The URI to connect through PgBouncer from your private networks, with the password and `sslmode=verify-full`.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "public_pooled_uri": {
            "type": "string",
            "description": "The URI to connect through PgBouncer from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `PG1`, which sets its size. Get the types via [List PostgreSQL types](/docs/cloud/api/postgres-types/list-postgres-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect straight to PostgreSQL at once, without going through PgBouncer.",
            "nullable": false,
            "sensitive": false
          },
          "max_pooled_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect through PgBouncer at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`. Get the versions via [List PostgreSQL versions](/docs/cloud/api/postgres-versions/list-postgres-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact PostgreSQL version the instance runs, such as `19.0`, or `null` until we know it.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The major versions you can upgrade the instance to. An upgrade can't be undone.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`. A failed or destroyed instance stays that way.\n\n- `provisioning`: We're setting up the instance.\n- `running`: The instance is ready.\n- `degraded`: A node is down, replication is broken or the disk is nearly full. `status_message` says which.\n- `rescaling`: We're changing the instance's type.\n- `upgrading`: We're upgrading PostgreSQL to a new major version.\n- `restoring`: We're restoring the instance from a snapshot.\n- `failed`: Setting up the instance failed. `status_message` says why.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're setting up the instance.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is nearly full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading PostgreSQL to a new major version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "Setting up the instance failed. `status_message` says why.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "More about the status, such as why the instance failed or is degraded, that a replica is being rebuilt, or that an action didn't finish.",
            "nullable": true,
            "sensitive": false
          },
          "statement_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement can run before PostgreSQL cancels it, in milliseconds, from `0` to `3600000`. Set it to `0` for no limit.",
            "nullable": false,
            "sensitive": false
          },
          "idle_in_transaction_session_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a session can stay idle inside a transaction before PostgreSQL ends it, in milliseconds, from `0` to `86400000`. Set it to `0` for no limit.",
            "nullable": false,
            "sensitive": false
          },
          "work_mem_mb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory each sort or hash operation can use, in MiB, from `1` to `256`.",
            "nullable": false,
            "sensitive": false
          },
          "log_min_duration_statement": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement must run before PostgreSQL logs it, in milliseconds, from `-1` to `600000`. Set it to `-1` to log none.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is nearly full.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting straight to PostgreSQL, `5432`."
              },
              "pooled_port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting through PgBouncer, `6432`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, when `public_access` is on."
              }
            },
            "description": "Where to connect to the instance. Connect straight to PostgreSQL on `port`, or through PgBouncer on `pooled_port`.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "Whether the node is the primary or a replica.\n\n- `primary`: The node that accepts writes.\n- `replica`: A read-only copy of the primary.",
                  "x-enum-descriptions": {
                    "primary": "The node that accepts writes.",
                    "replica": "A read-only copy of the primary."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's status."
                },
                "replication_lag_seconds": {
                  "type": "number",
                  "description": "How far the replica is behind the primary, in seconds, or `null` on the primary.",
                  "nullable": true
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in your private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas.",
            "nullable": false,
            "sensitive": false
          },
          "databases": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the instance's databases. Add databases via [Create a PostgreSQL database](/docs/cloud/api/postgres-databases/create-postgres-database/).",
            "nullable": false,
            "sensitive": false
          },
          "users": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "username": {
                  "type": "string"
                },
                "default_user": {
                  "type": "boolean"
                },
                "privileges": {
                  "type": "object"
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's users. Add users via [Create a PostgreSQL user](/docs/cloud/api/postgres-users/create-postgres-user/), and get a user's password via [Get a PostgreSQL user's credentials](/docs/cloud/api/postgres-users/credentials-postgres-user/).",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was taken.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.postgres.metrics": {
        "type": "object",
        "properties": {
          "postgres_id": {
            "type": "string",
            "description": "The instance's ID.",
            "nullable": false,
            "sensitive": false
          },
          "postgres_name": {
            "type": "string",
            "description": "The instance's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range returned.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range returned.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the points are.\n\n- `raw`: One point per minute, for a range of up to one day.\n- `hourly`: One point per hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "One point per minute, for a range of up to one day.",
              "hourly": "One point per hour, for a longer range."
            },
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "member_id": {
                  "type": "string"
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "Whether the node is the primary or a replica.\n\n- `primary`: The node that accepts writes.\n- `replica`: A read-only copy of the primary.",
                  "x-enum-descriptions": {
                    "primary": "The node that accepts writes.",
                    "replica": "A read-only copy of the primary."
                  }
                },
                "data": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "dt": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "transactions_per_second": {
                        "type": "number"
                      },
                      "writes_per_second": {
                        "type": "number"
                      },
                      "connections": {
                        "type": "object",
                        "properties": {
                          "direct": {
                            "type": "number"
                          },
                          "direct_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "pooled": {
                            "type": "number"
                          },
                          "pooled_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "max_connections": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "max_pooled_connections": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "cache_hit_ratio": {
                        "type": "number"
                      },
                      "disk": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "usable_bytes": {
                            "type": "integer",
                            "format": "int64"
                          }
                        }
                      },
                      "replication_lag_seconds": {
                        "type": "number"
                      }
                    }
                  }
                }
              }
            },
            "description": "Each node's metrics over time. Every point has the transaction and write rates, the connections straight to PostgreSQL and through PgBouncer, the cache hit ratio, the disk use and the replication lag.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres.rotate_credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name, `admin`.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The new password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The database the URIs connect to.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from your private networks, with the new password.",
            "nullable": false,
            "sensitive": true
          },
          "pooled_uri": {
            "type": "string",
            "description": "The URI to connect through PgBouncer from your private networks, with the new password.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from the internet, with the new password, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "public_pooled_uri": {
            "type": "string",
            "description": "The URI to connect through PgBouncer from the internet, with the new password, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres.upgrade": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `PG1`, which sets its size. Get the types via [List PostgreSQL types](/docs/cloud/api/postgres-types/list-postgres-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect straight to PostgreSQL at once, without going through PgBouncer.",
            "nullable": false,
            "sensitive": false
          },
          "max_pooled_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect through PgBouncer at once.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`. Get the versions via [List PostgreSQL versions](/docs/cloud/api/postgres-versions/list-postgres-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "engine_patch_version": {
            "type": "string",
            "description": "The exact PostgreSQL version the instance runs, such as `19.0`, or `null` until we know it.",
            "nullable": true,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The major versions you can upgrade the instance to. An upgrade can't be undone.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`. A failed or destroyed instance stays that way.\n\n- `provisioning`: We're setting up the instance.\n- `running`: The instance is ready.\n- `degraded`: A node is down, replication is broken or the disk is nearly full. `status_message` says which.\n- `rescaling`: We're changing the instance's type.\n- `upgrading`: We're upgrading PostgreSQL to a new major version.\n- `restoring`: We're restoring the instance from a snapshot.\n- `failed`: Setting up the instance failed. `status_message` says why.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're setting up the instance.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is nearly full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading PostgreSQL to a new major version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "Setting up the instance failed. `status_message` says why.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "More about the status, such as why the instance failed or is degraded, that a replica is being rebuilt, or that an action didn't finish.",
            "nullable": true,
            "sensitive": false
          },
          "statement_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement can run before PostgreSQL cancels it, in milliseconds, from `0` to `3600000`. Set it to `0` for no limit.",
            "nullable": false,
            "sensitive": false
          },
          "idle_in_transaction_session_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a session can stay idle inside a transaction before PostgreSQL ends it, in milliseconds, from `0` to `86400000`. Set it to `0` for no limit.",
            "nullable": false,
            "sensitive": false
          },
          "work_mem_mb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory each sort or hash operation can use, in MiB, from `1` to `256`.",
            "nullable": false,
            "sensitive": false
          },
          "log_min_duration_statement": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement must run before PostgreSQL logs it, in milliseconds, from `-1` to `600000`. Set it to `-1` to log none.",
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is nearly full.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting straight to PostgreSQL, `5432`."
              },
              "pooled_port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting through PgBouncer, `6432`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, when `public_access` is on."
              }
            },
            "description": "Where to connect to the instance. Connect straight to PostgreSQL on `port`, or through PgBouncer on `pooled_port`.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "Whether the node is the primary or a replica.\n\n- `primary`: The node that accepts writes.\n- `replica`: A read-only copy of the primary.",
                  "x-enum-descriptions": {
                    "primary": "The node that accepts writes.",
                    "replica": "A read-only copy of the primary."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's status."
                },
                "replication_lag_seconds": {
                  "type": "number",
                  "description": "How far the replica is behind the primary, in seconds, or `null` on the primary.",
                  "nullable": true
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in your private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas.",
            "nullable": false,
            "sensitive": false
          },
          "databases": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the instance's databases. Add databases via [Create a PostgreSQL database](/docs/cloud/api/postgres-databases/create-postgres-database/).",
            "nullable": false,
            "sensitive": false
          },
          "users": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "username": {
                  "type": "string"
                },
                "default_user": {
                  "type": "boolean"
                },
                "privileges": {
                  "type": "object"
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's users. Add users via [Create a PostgreSQL user](/docs/cloud/api/postgres-users/create-postgres-user/), and get a user's password via [Get a PostgreSQL user's credentials](/docs/cloud/api/postgres-users/credentials-postgres-user/).",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was taken.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "pre_upgrade_snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot we created before the upgrade.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_database.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The database's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The database's name. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore. Can't be `postgres`, `template0` or `template1`.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the database was created.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, in the past tense, such as `created`, `rescaled` or `database_created`.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who made the change, or `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who made the change.\n\n- `user`: A Better Stack user made the change. `user_id` says who.\n- `api_token`: A request with an API token made the change.\n- `system`: Better Stack made the change.",
            "x-enum-descriptions": {
              "user": "A Better Stack user made the change. `user_id` says who.",
              "api_token": "A request with an API token made the change.",
              "system": "Better Stack made the change."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about what happened, such as the new type or version, the snapshot ID, the database or the user name.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's primary. Changes when the instance fails over.",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last ran, or `null` until the schedule first runs.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance the snapshot was taken from.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that ran the instance's primary when the snapshot was taken. Becomes `null` some time after that server is deleted.",
            "nullable": true,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "Whether the snapshot was taken on request or by a schedule.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its status is `available`. Only an `available` snapshot can be restored.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready, and you can restore it.\n- `failed`: Creating the snapshot failed. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "Creating the snapshot failed. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. The snapshot is billed by this size. `null` until the snapshot is taken.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The availability zone the snapshot was taken in.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why creating the snapshot failed, or `null` unless the snapshot failed.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "The lock Better Stack put on the snapshot, or `null` when the snapshot isn't locked. Every action on a PostgreSQL snapshot works while the snapshot is locked.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.postgres_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `PG1`. Send it as `type` when you create or rescale a PostgreSQL instance.",
            "nullable": false,
            "sensitive": false
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect straight to PostgreSQL at once, without going through PgBouncer.",
            "nullable": false,
            "sensitive": false
          },
          "max_pooled_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect through PgBouncer at once.",
            "nullable": false,
            "sensitive": false
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of virtual CPUs on each node.",
            "nullable": false,
            "sensitive": false
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory on each node, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can create instances of this type.\n\n- `global`: You can create instances of this type.\n- `unavailable`: The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it.",
            "x-enum-descriptions": {
              "global": "You can create instances of this type.",
              "unavailable": "The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The type to use instead of this deprecated one, or `null` when the type is offered.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_user.credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The user's password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The database the URIs connect to, `defaultdb` when the instance has it, or else the first database by name.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from your private networks, with the password and `sslmode=verify-full`.",
            "nullable": false,
            "sensitive": true
          },
          "pooled_uri": {
            "type": "string",
            "description": "The URI to connect through the PgBouncer connection pool from your private networks, with the password and `sslmode=verify-full`.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "public_pooled_uri": {
            "type": "string",
            "description": "The URI to connect through the PgBouncer connection pool from the internet, with the password and `sslmode=verify-full`, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_user.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The user's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "username": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The user's name in PostgreSQL. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore.",
            "nullable": false,
            "sensitive": false
          },
          "default_user": {
            "type": "boolean",
            "description": "Whether this is the instance's default `admin` user. The default user's access can't be changed. The default user can't be deleted.",
            "nullable": false,
            "sensitive": false
          },
          "privileges": {
            "type": "object",
            "additionalProperties": true,
            "description": "The user's access to each database, as an object that maps a database name to an access level, such as `{\"appdb\": \"read_write\"}`. A database that isn't in the object gets no access. `read` can read the tables in the `public` schema. `read_write` can also add, change and delete rows and run functions, but can't create tables. `all` can also create tables and schemas and maintain them, such as with `VACUUM`. `none` gives no access.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was created.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_user.reset_password": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The user name.",
            "nullable": false,
            "sensitive": false
          },
          "password": {
            "type": "string",
            "description": "The new password.",
            "nullable": false,
            "sensitive": true
          },
          "database": {
            "type": "string",
            "description": "The database the URIs connect to.",
            "nullable": false,
            "sensitive": false
          },
          "uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from your private networks, with the new password.",
            "nullable": false,
            "sensitive": true
          },
          "pooled_uri": {
            "type": "string",
            "description": "The URI to connect through the PgBouncer connection pool from your private networks, with the new password.",
            "nullable": false,
            "sensitive": true
          },
          "public_uri": {
            "type": "string",
            "description": "The URI to connect straight to PostgreSQL from the internet, with the new password, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "public_pooled_uri": {
            "type": "string",
            "description": "The URI to connect through the PgBouncer connection pool from the internet, with the new password, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate in PEM format, to verify the instance's certificate.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.postgres_version.list": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.quota.get": {
        "type": "object",
        "properties": {
          "firewalls": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many firewalls the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_rules": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many rules one firewall can have. `used` is `null` for a limit on each firewall.",
            "nullable": false,
            "sensitive": false
          },
          "reserved_ipv4_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many reserved IPv4 addresses the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "reserved_ipv6_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many reserved IPv6 addresses the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "public_ipv4_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many public IPv4 addresses the organization can hold in the zone, reserved ones included.",
            "nullable": false,
            "sensitive": false
          },
          "public_ipv6_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many public IPv6 addresses the organization can hold in the zone, reserved ones included.",
            "nullable": false,
            "sensitive": false
          },
          "private_ips_per_server_per_network": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many private addresses one server can hold in one network. `used` is `null` for a limit on each server and network.",
            "nullable": false,
            "sensitive": false
          },
          "regular_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the regular tier.",
            "nullable": false,
            "sensitive": false
          },
          "spot_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the spot tier.",
            "nullable": false,
            "sensitive": false
          },
          "dedicated_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the dedicated tier.",
            "nullable": false,
            "sensitive": false
          },
          "ram_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total memory of all your servers on every tier, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "spot_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many spot servers the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "regular_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many regular servers the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "dedicated_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many dedicated servers the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "servers_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many servers the organization can create in 60 seconds. `used` is `null` for a rate.",
            "nullable": false,
            "sensitive": false
          },
          "snapshots_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshots the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "nullable": false,
            "sensitive": false
          },
          "volume_snapshots_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshots of volumes the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "nullable": false,
            "sensitive": false
          },
          "rescales_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many server rescales the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "nullable": false,
            "sensitive": false
          },
          "api_requests_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many API requests the organization can send in one minute, all teams together. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_count": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many placement groups the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many servers one placement group can hold. `used` is `null` for a limit on each group.",
            "nullable": false,
            "sensitive": false
          },
          "volumes": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many volumes the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "volume_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of the organization's volumes in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "volume_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many volume snapshots the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many server snapshots and managed service backups the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "snapshot_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of server snapshots and managed backups, in whole GiB, rounded down.",
            "nullable": false,
            "sensitive": false
          },
          "volume_snapshot_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of every volume snapshot, in whole GiB, rounded down.",
            "nullable": false,
            "sensitive": false
          },
          "scheduled_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshot schedules of servers, managed databases and Kubernetes clusters the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "scheduled_volume_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshot schedules of volumes the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many SSH keys the organization can have. SSH keys are shared across zones, so the count is the same in each zone.",
            "nullable": false,
            "sensitive": false
          },
          "webhooks": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many webhooks the organization can have, paused ones included.",
            "nullable": false,
            "sensitive": false
          },
          "otlps": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many OTLP exports the organization can have, paused ones included.",
            "nullable": false,
            "sensitive": false
          },
          "networks": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many private networks the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many Cloudflare DNS records one server can have. `used` is `null` for a limit on each server.",
            "nullable": false,
            "sensitive": false
          },
          "load_balancers": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed load balancers the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "valkeys": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed Valkey instances the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "mysqls": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed MySQL instances the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "postgres_instances": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed PostgreSQL instances the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "clickhouses": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed ClickHouse instances the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "kafkas": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed Kafka clusters the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "object_proxies": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many object caches the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "certificates": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many uploaded and managed TLS certificates the organization can have. Certificates are shared across zones, so the count is the same in each zone.",
            "nullable": false,
            "sensitive": false
          },
          "kubernetes_control_planes": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many Kubernetes control planes the organization can have.",
            "nullable": false,
            "sensitive": false
          },
          "server_pool_size": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total maximum size of all server pools.",
            "nullable": false,
            "sensitive": false
          },
          "console_sessions": {
            "type": "object",
            "properties": {
              "used": {
                "type": "number",
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate.",
                "nullable": true
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many console sessions can be open at the same time.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.reserved_ip.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The reserved IP's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The reserved IP's name, unique in the organization.",
            "nullable": true,
            "sensitive": false
          },
          "ip": {
            "type": "string",
            "description": "The IP address.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or an IPv6 address.",
            "nullable": false,
            "sensitive": false
          },
          "gateway": {
            "type": "string",
            "description": "The gateway for the address, for when you configure the server's network yourself.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the address is assigned to, or `null` when the address isn't assigned. To change it, use [Assign a reserved IP](/docs/cloud/api/reserved-ips/assign-reserved-ip/) and [Unassign a reserved IP](/docs/cloud/api/reserved-ips/unassign-reserved-ip/).",
            "nullable": true,
            "sensitive": false
          },
          "server": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "description": "The server's ID."
              },
              "name": {
                "type": "string",
                "description": "The server's name."
              },
              "status": {
                "type": "string",
                "description": "The server's status, such as `running`."
              }
            },
            "description": "The server the address is assigned to, or `null` when the address isn't assigned.",
            "nullable": true,
            "sensitive": false
          },
          "ptr_record": {
            "type": "string",
            "description": "The reverse DNS name for the address. A `ptr_record` you send when you assign the address replaces this one while the address stays assigned.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the reserved IP was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the reserved IP was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the reserved IP. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the schedule creates snapshots of. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.scheduled_volume_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "volume_id": {
            "type": "string",
            "description": "The ID of the volume the schedule creates snapshots of. Get it via [List volumes](/docs/cloud/api/volumes/list-volumes/).",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server.create": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.\n\n- `starting`: The server is booting.\n- `running`: The server is running.\n- `stopping`: The server is shutting down.\n- `stopped`: The server is stopped.\n- `pooled`: The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.\n- `snapshotting`: We're creating a snapshot of the server.\n- `migrating`: We're moving the server to another host.\n- `rescuing`: The server is in rescue mode.\n- `restoring`: We're restoring the server from a snapshot.\n- `rescaling`: We're changing the server's type.\n- `destroyed`: The server is destroyed.\n- `terminating`: We're ending a spot server.\n- `terminated`: We've ended a spot server.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "nullable": false,
            "sensitive": false
          },
          "rescue_state": {
            "type": "string",
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.\n\n- `activating`: The server is booting the rescue system. You can sign in when it's up.\n- `active`: The rescue system is up, and you can sign in.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "nullable": true,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "nullable": false,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "nullable": true,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of the placement group the server is in.",
            "nullable": true,
            "sensitive": false
          },
          "pool_id": {
            "type": "string",
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "claimed_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": "string",
                  "description": "The reverse DNS name. `null` when none is set.",
                  "nullable": true
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "nullable": false,
            "sensitive": false
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "nullable": false,
            "sensitive": false
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "nullable": false,
            "sensitive": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "nullable": false,
            "sensitive": false
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "nullable": false,
            "sensitive": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "nullable": false,
            "sensitive": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "nullable": false,
            "sensitive": false
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": "integer",
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count.",
                "nullable": true
              },
              "measured_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute.",
                "nullable": true
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "nullable": false,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "user_data": {
            "type": "string",
            "description": "A cloud-init `#cloud-config` document or a script that runs at the first boot, at most 32 KiB. A script starts with `#!`. We don't store it, and no response returns it.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          },
          "root_password": {
            "type": "string",
            "description": "The one-time root password, returned only when you send `root_password` as `true`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.server.enter_rescue": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.\n\n- `starting`: The server is booting.\n- `running`: The server is running.\n- `stopping`: The server is shutting down.\n- `stopped`: The server is stopped.\n- `pooled`: The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.\n- `snapshotting`: We're creating a snapshot of the server.\n- `migrating`: We're moving the server to another host.\n- `rescuing`: The server is in rescue mode.\n- `restoring`: We're restoring the server from a snapshot.\n- `rescaling`: We're changing the server's type.\n- `destroyed`: The server is destroyed.\n- `terminating`: We're ending a spot server.\n- `terminated`: We've ended a spot server.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "nullable": false,
            "sensitive": false
          },
          "rescue_state": {
            "type": "string",
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.\n\n- `activating`: The server is booting the rescue system. You can sign in when it's up.\n- `active`: The rescue system is up, and you can sign in.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "nullable": true,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "nullable": false,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "nullable": true,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of the placement group the server is in.",
            "nullable": true,
            "sensitive": false
          },
          "pool_id": {
            "type": "string",
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "claimed_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": "string",
                  "description": "The reverse DNS name. `null` when none is set.",
                  "nullable": true
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "nullable": false,
            "sensitive": false
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "nullable": false,
            "sensitive": false
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "nullable": false,
            "sensitive": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "nullable": false,
            "sensitive": false
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "nullable": false,
            "sensitive": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "nullable": false,
            "sensitive": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "nullable": false,
            "sensitive": false
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": "integer",
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count.",
                "nullable": true
              },
              "measured_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute.",
                "nullable": true
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "nullable": false,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "user_data": {
            "type": "string",
            "description": "A cloud-init `#cloud-config` document or a script that runs at the first boot, at most 32 KiB. A script starts with `#!`. We don't store it, and no response returns it.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          },
          "rescue_password": {
            "type": "string",
            "description": "A one-time password to sign in to the rescue system. Returned only in this response.",
            "nullable": false,
            "sensitive": true
          },
          "rescue_expires_at": {
            "type": "string",
            "format": "date-time",
            "description": "When rescue mode ends by itself and the server returns to normal, 60 minutes after it started.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.\n\n- `starting`: The server is booting.\n- `running`: The server is running.\n- `stopping`: The server is shutting down.\n- `stopped`: The server is stopped.\n- `pooled`: The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.\n- `snapshotting`: We're creating a snapshot of the server.\n- `migrating`: We're moving the server to another host.\n- `rescuing`: The server is in rescue mode.\n- `restoring`: We're restoring the server from a snapshot.\n- `rescaling`: We're changing the server's type.\n- `destroyed`: The server is destroyed.\n- `terminating`: We're ending a spot server.\n- `terminated`: We've ended a spot server.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "nullable": false,
            "sensitive": false
          },
          "rescue_state": {
            "type": "string",
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.\n\n- `activating`: The server is booting the rescue system. You can sign in when it's up.\n- `active`: The rescue system is up, and you can sign in.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "nullable": true,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "nullable": false,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "nullable": true,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of the placement group the server is in.",
            "nullable": true,
            "sensitive": false
          },
          "pool_id": {
            "type": "string",
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "claimed_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": "string",
                  "description": "The reverse DNS name. `null` when none is set.",
                  "nullable": true
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "nullable": false,
            "sensitive": false
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "nullable": false,
            "sensitive": false
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "nullable": false,
            "sensitive": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "nullable": false,
            "sensitive": false
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "nullable": false,
            "sensitive": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "nullable": false,
            "sensitive": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "nullable": false,
            "sensitive": false
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": "integer",
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count.",
                "nullable": true
              },
              "measured_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute.",
                "nullable": true
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "nullable": false,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "user_data": {
            "type": "string",
            "description": "A cloud-init `#cloud-config` document or a script that runs at the first boot, at most 32 KiB. A script starts with `#!`. We don't store it, and no response returns it.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          }
        }
      },
      "CLIResponse.cloud.server.metrics": {
        "type": "object",
        "properties": {
          "server_id": {
            "type": "string",
            "description": "The server's ID, a UUID. Both a live reading and a series have it.",
            "nullable": false,
            "sensitive": false
          },
          "server_name": {
            "type": "string",
            "description": "The server's name. Both a live reading and a series have it.",
            "nullable": false,
            "sensitive": false
          },
          "sampled_at": {
            "type": "string",
            "format": "date-time",
            "description": "When we read the values. Only a live reading has it.",
            "nullable": true,
            "sensitive": false
          },
          "uptime": {
            "type": "object",
            "properties": {
              "started_at": {
                "type": "string",
                "format": "date-time",
                "nullable": true
              },
              "seconds": {
                "type": "integer",
                "format": "int64",
                "nullable": true
              }
            },
            "description": "How long the server has run since it last started. Only a live reading has it.",
            "nullable": true,
            "sensitive": false
          },
          "cpu": {
            "type": "object",
            "properties": {
              "usage_percent": {
                "type": "number",
                "nullable": true
              },
              "vcpus": {
                "type": "integer",
                "format": "int64"
              }
            },
            "description": "CPU use as a percentage of all the server's vCPUs. Only a live reading has it, and each point of a series has its own.",
            "nullable": true,
            "sensitive": false
          },
          "memory": {
            "type": "object",
            "properties": {
              "used_bytes": {
                "type": "integer",
                "format": "int64",
                "nullable": true
              },
              "total_bytes": {
                "type": "integer",
                "format": "int64"
              },
              "usage_percent": {
                "type": "number",
                "nullable": true
              }
            },
            "description": "The server's memory use. Only a live reading has it, and each point of a series has its own.",
            "nullable": true,
            "sensitive": false
          },
          "disk": {
            "type": "object",
            "properties": {
              "space": {
                "type": "object",
                "properties": {
                  "used_bytes": {
                    "type": "integer",
                    "format": "int64",
                    "nullable": true
                  },
                  "total_bytes": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "usage_percent": {
                    "type": "number",
                    "nullable": true
                  }
                }
              },
              "io": {
                "type": "object",
                "properties": {
                  "read_bytes_per_second": {
                    "type": "integer",
                    "format": "int64",
                    "nullable": true
                  },
                  "write_bytes_per_second": {
                    "type": "integer",
                    "format": "int64",
                    "nullable": true
                  }
                }
              }
            },
            "description": "The disk space used out of the root disk, and the disk read and write rates. Only a live reading has it, and each point of a series has its own.",
            "nullable": true,
            "sensitive": false
          },
          "cpu_credits": {
            "type": "object",
            "properties": {
              "balance_vcpu_minutes": {
                "type": "number"
              },
              "cap_vcpu_minutes": {
                "type": "number"
              },
              "baseline_vcpus": {
                "type": "number"
              },
              "baseline_percent": {
                "type": "integer",
                "format": "int64"
              },
              "capped": {
                "type": "boolean"
              },
              "cap_reason": {
                "type": "string",
                "nullable": true
              },
              "updated_at": {
                "type": "string",
                "format": "date-time",
                "nullable": true
              }
            },
            "description": "The CPU credit balance of a shared or spot server. Only a live reading has it. A dedicated server doesn't have it, and neither does a server in a zone without a CPU budget.",
            "nullable": true,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range returned. Only a series has it.",
            "nullable": true,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range returned. Only a series has it.",
            "nullable": true,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly",
              null
            ],
            "description": "How far apart the points are. Only a series has it.\n\n- `raw`: One point per minute, for a range of up to one day.\n- `hourly`: One point per hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "One point per minute, for a range of up to one day.",
              "hourly": "One point per hour, for a longer range."
            },
            "nullable": true,
            "sensitive": false
          },
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "dt": {
                  "type": "string",
                  "format": "date-time"
                },
                "cpu": {
                  "type": "object",
                  "properties": {
                    "usage_percent": {
                      "type": "number"
                    },
                    "vcpus": {
                      "type": "integer",
                      "format": "int64"
                    }
                  }
                },
                "memory": {
                  "type": "object",
                  "properties": {
                    "used_bytes": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "total_bytes": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "usage_percent": {
                      "type": "number",
                      "nullable": true
                    }
                  }
                },
                "disk": {
                  "type": "object",
                  "properties": {
                    "space": {
                      "type": "object",
                      "properties": {
                        "used_bytes": {
                          "type": "integer",
                          "format": "int64"
                        },
                        "total_bytes": {
                          "type": "integer",
                          "format": "int64"
                        },
                        "usage_percent": {
                          "type": "number",
                          "nullable": true
                        }
                      }
                    },
                    "io": {
                      "type": "object",
                      "properties": {
                        "read_bytes_per_second": {
                          "type": "integer",
                          "format": "int64"
                        },
                        "write_bytes_per_second": {
                          "type": "integer",
                          "format": "int64"
                        }
                      }
                    }
                  }
                },
                "uptime_seconds": {
                  "type": "integer",
                  "format": "int64"
                },
                "traffic": {
                  "type": "object",
                  "properties": {
                    "bytes_in": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "bytes_out": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "bytes_in_intra_az": {
                      "type": "integer",
                      "format": "int64",
                      "nullable": true
                    },
                    "bytes_out_intra_az": {
                      "type": "integer",
                      "format": "int64",
                      "nullable": true
                    }
                  }
                }
              }
            },
            "description": "The points of the series, oldest first. Only a series has it. A minute or hour with no sample has no point. `traffic` counts the bytes sent and received in each point's interval. For hourly points, the bytes inside the zone, `bytes_in_intra_az` and `bytes_out_intra_az`, are `null`.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server.security_scan": {
        "type": "object",
        "properties": {
          "last_scan_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the latest scan ran.",
            "nullable": false,
            "sensitive": false
          },
          "findings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The finding's ID, `<service>-<issue>`, which stays the same between scans."
                },
                "service": {
                  "type": "string",
                  "description": "The service the finding is about."
                },
                "title": {
                  "type": "string",
                  "description": "The service name, with its installed version when known."
                },
                "severity": {
                  "type": "string",
                  "enum": [
                    "critical",
                    "high"
                  ],
                  "description": "How serious the finding is.\n\n- `critical`: A service that must not be reachable from the internet is reachable.\n- `high`: A service reachable from the internet runs a vulnerable version.",
                  "x-enum-descriptions": {
                    "critical": "A service that must not be reachable from the internet is reachable.",
                    "high": "A service reachable from the internet runs a vulnerable version."
                  }
                },
                "summary": {
                  "type": "string",
                  "description": "A short summary, or `null`.",
                  "nullable": true
                },
                "cves": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "The CVE IDs named in `description`."
                },
                "description": {
                  "type": "string",
                  "description": "More about the finding, or `null`.",
                  "nullable": true
                }
              }
            },
            "description": "What the scan found, one entry per finding.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server_pool.claim": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.\n\n- `starting`: The server is booting.\n- `running`: The server is running.\n- `stopping`: The server is shutting down.\n- `stopped`: The server is stopped.\n- `pooled`: The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.\n- `snapshotting`: We're creating a snapshot of the server.\n- `migrating`: We're moving the server to another host.\n- `rescuing`: The server is in rescue mode.\n- `restoring`: We're restoring the server from a snapshot.\n- `rescaling`: We're changing the server's type.\n- `destroyed`: The server is destroyed.\n- `terminating`: We're ending a spot server.\n- `terminated`: We've ended a spot server.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "nullable": false,
            "sensitive": false
          },
          "rescue_state": {
            "type": "string",
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.\n\n- `activating`: The server is booting the rescue system. You can sign in when it's up.\n- `active`: The rescue system is up, and you can sign in.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "nullable": true,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "nullable": false,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "nullable": true,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of the placement group the server is in.",
            "nullable": true,
            "sensitive": false
          },
          "pool_id": {
            "type": "string",
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "claimed_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": "string",
                  "description": "The reverse DNS name. `null` when none is set.",
                  "nullable": true
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "nullable": false,
            "sensitive": false
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "nullable": false,
            "sensitive": false
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "nullable": false,
            "sensitive": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "nullable": false,
            "sensitive": false
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "nullable": false,
            "sensitive": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "nullable": false,
            "sensitive": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "nullable": false,
            "sensitive": false
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": "integer",
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count.",
                "nullable": true
              },
              "measured_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute.",
                "nullable": true
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "nullable": false,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "user_data": {
            "type": "string",
            "description": "A cloud-init `#cloud-config` document or a script that runs at the first boot, at most 32 KiB. A script starts with `#!`. We don't store it, and no response returns it.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          },
          "root_password": {
            "type": "string",
            "description": "The root password, shown only this once, when the request sets `root_password` to `true`.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.server_pool.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The pool's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
            "description": "The pool's name. Must be unique in the team, with up to 63 lowercase letters, digits and hyphens, and start and end with a letter or digit. Spare servers are named after the pool, with a hyphen and 6 hex characters added. A server gets its own name when you claim it.",
            "nullable": false,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The server type of the spare servers. For a pool that boots from a snapshot, the snapshot's server type.",
            "nullable": false,
            "sensitive": false
          },
          "snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot the spare servers boot from. `null` for a pool that boots from an image.",
            "nullable": true,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the image the spare servers boot from. `null` for a pool that boots from a snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "min_size": {
            "type": "integer",
            "format": "int64",
            "description": "The fewest spare servers the pool keeps, from 0 up to `max_size`.",
            "nullable": false,
            "sensitive": false
          },
          "max_size": {
            "type": "integer",
            "format": "int64",
            "description": "The most spare servers the pool keeps. The `max_size` of all your organization's pools together can't be more than its `server_pool_size` quota.",
            "nullable": false,
            "sensitive": false
          },
          "growth_multiplier": {
            "type": "number",
            "description": "How much the pool grows when you claim a server from an empty pool. `target_size` is multiplied by this factor, from 1 to 10. `1` turns growing off.",
            "nullable": false,
            "sensitive": false
          },
          "shrink_multiplier": {
            "type": "number",
            "description": "How much the pool shrinks while it's full and nobody has claimed a server for `idle_minutes`. Each minute, `target_size` is multiplied by this factor, which is more than 0 and at most 1. `1` turns shrinking off.",
            "nullable": false,
            "sensitive": false
          },
          "idle_minutes": {
            "type": "integer",
            "format": "int64",
            "description": "How many minutes without a claim before the pool shrinks, from 1 to 1440.",
            "nullable": false,
            "sensitive": false
          },
          "enabled": {
            "type": "boolean",
            "description": "Whether the pool keeps spare servers. A disabled pool removes all its spare servers and keeps its settings. Claiming from a disabled pool is refused.",
            "nullable": false,
            "sensitive": false
          },
          "public_ipv4": {
            "type": "boolean",
            "description": "Whether the spare servers get a public IPv4 address. A server without one has only IPv6.",
            "nullable": false,
            "sensitive": false
          },
          "defaults": {
            "type": "object",
            "properties": {
              "ssh_keys": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The `slug` of each SSH key to add."
              },
              "firewall_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the firewalls to attach."
              },
              "network_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the private networks to join."
              },
              "metadata": {
                "type": "object",
                "additionalProperties": true,
                "description": "Your own tags, as string keys and values."
              }
            },
            "description": "What every spare server gets when it boots, such as `ssh_keys`, firewalls, private networks and tags. When you claim a server and add nothing to these, the server is ready as soon as the request returns.",
            "nullable": false,
            "sensitive": false
          },
          "target_size": {
            "type": "integer",
            "format": "int64",
            "description": "The number of spare servers the pool currently aims for, from `min_size` to `max_size`. The target grows and shrinks as servers are claimed, and is 0 while the pool is disabled.",
            "nullable": false,
            "sensitive": false
          },
          "available": {
            "type": "integer",
            "format": "int64",
            "description": "How many spare servers are ready to claim right away.",
            "nullable": false,
            "sensitive": false
          },
          "warming": {
            "type": "integer",
            "format": "int64",
            "description": "How many spare servers are still booting.",
            "nullable": false,
            "sensitive": false
          },
          "claims_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many servers have been claimed from the pool.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the pool was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the pool was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the pool and its servers.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server_private_ip.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the private IP on the server, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that has the address.",
            "nullable": false,
            "sensitive": false
          },
          "network_id": {
            "type": "string",
            "description": "The ID of the private network the address is in.",
            "nullable": false,
            "sensitive": false
          },
          "ip_address": {
            "type": "string",
            "description": "The private IP address.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the address was assigned.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the private IP was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server_public_ip.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the address on this server, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "ip": {
            "type": "string",
            "description": "The IP address.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or IPv6 address.",
            "nullable": false,
            "sensitive": false
          },
          "device_name": {
            "type": "string",
            "description": "The network interface on the server that has the address, such as `eth0`.",
            "nullable": true,
            "sensitive": false
          },
          "ptr_record": {
            "type": "string",
            "description": "The reverse DNS name for the address. When the address is a reserved IP, this name replaces the reserved IP's own reverse DNS name.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `AM4`. Send it as `server_type` when you create a server.",
            "nullable": false,
            "sensitive": false
          },
          "family": {
            "type": "string",
            "description": "The family the type belongs to. `AM` has shared AMD CPUs, `AMD` dedicated AMD CPUs and `AMS` spot servers on AMD CPUs. `IS` has shared Intel CPUs and `ISS` spot servers on Intel CPUs. `M` runs on dedicated Mac hardware and `G` on dedicated servers with GPUs.",
            "nullable": false,
            "sensitive": false
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of vCPUs.",
            "nullable": false,
            "sensitive": false
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The root disk size in GiB. A server rescaled down to this type can keep its larger disk.",
            "nullable": false,
            "sensitive": false
          },
          "bandwidth_gbit": {
            "type": "integer",
            "format": "int64",
            "description": "The bandwidth limit in gigabits per second. Each network interface of the server gets this limit in each direction.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "restricted",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: You can order the type when the zone has capacity for it.\n- `restricted`: You can order the type when the zone has capacity for it, the same as `global`.\n- `unavailable`: The type is deprecated. A create or a rescale to it is refused with `type_deprecated` and the name of its replacement.",
            "x-enum-descriptions": {
              "global": "You can order the type when the zone has capacity for it.",
              "restricted": "You can order the type when the zone has capacity for it, the same as `global`.",
              "unavailable": "The type is deprecated. A create or a rescale to it is refused with `type_deprecated` and the name of its replacement."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.server_type_availability.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The server type's name, such as `AM4`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "available",
              "over_quota",
              "no_capacity"
            ],
            "description": "Whether you can start the servers now. When both a limit and the zone's capacity stand in the way, the status is `over_quota`.\n\n- `available`: Your organization's limits and the zone allow `count` more servers of this type.\n- `over_quota`: Starting `count` more servers would go over a limit of your organization, such as the number of servers or vCPUs of its tier, `ram_gb` or `public_ipv6_addresses`. A create is refused with `quota_exceeded`.\n- `no_capacity`: Your limits allow the servers, but the zone can't start `count` servers of this type now. A create is refused with `no_capacity`.",
            "x-enum-descriptions": {
              "available": "Your organization's limits and the zone allow `count` more servers of this type.",
              "over_quota": "Starting `count` more servers would go over a limit of your organization, such as the number of servers or vCPUs of its tier, `ram_gb` or `public_ipv6_addresses`. A create is refused with `quota_exceeded`.",
              "no_capacity": "Your limits allow the servers, but the zone can't start `count` servers of this type now. A create is refused with `no_capacity`."
            },
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the snapshot was taken from. `null` once that server is deleted, and you can still get and restore the snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "Whether the snapshot was taken on request or by a schedule.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its `status` is `available`. Only an `available` snapshot can be restored.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready, and you can restore it.\n- `failed`: Creating the snapshot failed. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "Creating the snapshot failed. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the server's root disk when the snapshot was taken, in bytes. We bill by this size. `null` until the snapshot is taken.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The availability zone the snapshot was taken in. A snapshot from another zone can still be restored into a new server in this zone.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why creating the snapshot failed, or `null` unless the snapshot failed.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Why and when we locked the snapshot. `null` unless we've locked it. A locked snapshot can't be changed, deleted or restored.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.snapshot.restore": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.\n\n- `starting`: The server is booting.\n- `running`: The server is running.\n- `stopping`: The server is shutting down.\n- `stopped`: The server is stopped.\n- `pooled`: The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.\n- `snapshotting`: We're creating a snapshot of the server.\n- `migrating`: We're moving the server to another host.\n- `rescuing`: The server is in rescue mode.\n- `restoring`: We're restoring the server from a snapshot.\n- `rescaling`: We're changing the server's type.\n- `destroyed`: The server is destroyed.\n- `terminating`: We're ending a spot server.\n- `terminated`: We've ended a spot server.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "nullable": false,
            "sensitive": false
          },
          "rescue_state": {
            "type": "string",
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.\n\n- `activating`: The server is booting the rescue system. You can sign in when it's up.\n- `active`: The rescue system is up, and you can sign in.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "nullable": true,
            "sensitive": false
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "nullable": false,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "nullable": false,
            "sensitive": false
          },
          "image": {
            "type": "string",
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "nullable": true,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "placement_group_id": {
            "type": "string",
            "description": "The ID of the placement group the server is in.",
            "nullable": true,
            "sensitive": false
          },
          "pool_id": {
            "type": "string",
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "claimed_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "nullable": true,
            "sensitive": false
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": "string",
                  "description": "The reverse DNS name. `null` when none is set.",
                  "nullable": true
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "nullable": false,
            "sensitive": false
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "nullable": false,
            "sensitive": false
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic.",
                  "nullable": true
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "nullable": false,
            "sensitive": false
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "nullable": false,
            "sensitive": false
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "nullable": false,
            "sensitive": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "nullable": false,
            "sensitive": false
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "nullable": false,
            "sensitive": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "nullable": false,
            "sensitive": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "nullable": false,
            "sensitive": false
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": "integer",
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count.",
                "nullable": true
              },
              "measured_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute.",
                "nullable": true
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "nullable": false,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "user_data": {
            "type": "string",
            "description": "A cloud-init `#cloud-config` document or a script that runs at the first boot, at most 32 KiB. A script starts with `#!`. We don't store it, and no response returns it.",
            "nullable": false,
            "sensitive": true,
            "writeonly": true
          },
          "root_password": {
            "type": "string",
            "description": "The new server's root password. Returned once, when you send `root_password` set to `true`, so save it then.",
            "nullable": false,
            "sensitive": true
          }
        }
      },
      "CLIResponse.cloud.ssh_key.attach": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9](?:[a-zA-Z0-9._-]*[a-zA-Z0-9])?$",
            "description": "The key's name. Must be unique in its team, up to 255 characters long, and start and end with a letter or digit. Dots, hyphens and underscores are allowed in between. A deleted key's `slug` stays taken until the key is removed from every zone.",
            "nullable": false,
            "sensitive": false
          },
          "public_key": {
            "type": "string",
            "format": "ssh-public-key",
            "description": "One OpenSSH public key, such as the contents of a `.pub` file. Never send a private key.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the key. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "servers": {
            "type": "object",
            "properties": {
              "queued": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the servers we're changing."
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "server_id": {
                      "type": "string",
                      "description": "The ID of the skipped server."
                    },
                    "reason": {
                      "type": "string",
                      "enum": [
                        "kubernetes_managed",
                        "locked",
                        "server_not_running"
                      ],
                      "description": "Why we skipped the server.\n\n- `kubernetes_managed`: The server is a Kubernetes worker.\n- `locked`: The server is locked.\n- `server_not_running`: The server isn't running.",
                      "x-enum-descriptions": {
                        "kubernetes_managed": "The server is a Kubernetes worker.",
                        "locked": "The server is locked.",
                        "server_not_running": "The server isn't running."
                      }
                    }
                  }
                },
                "description": "The servers we skipped with `all`, each with a reason, empty when you send `server_ids`."
              }
            },
            "description": "What we did with each server.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.ssh_key.create": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9](?:[a-zA-Z0-9._-]*[a-zA-Z0-9])?$",
            "description": "The key's name. Must be unique in its team, up to 255 characters long, and start and end with a letter or digit. Dots, hyphens and underscores are allowed in between. A deleted key's `slug` stays taken until the key is removed from every zone.",
            "nullable": false,
            "sensitive": false
          },
          "public_key": {
            "type": "string",
            "format": "ssh-public-key",
            "description": "One OpenSSH public key, such as the contents of a `.pub` file. Never send a private key.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the key. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "servers": {
            "type": "object",
            "properties": {
              "queued": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the servers of this zone we're adding the key to."
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "server_id": {
                      "type": "string",
                      "description": "The ID of the skipped server."
                    },
                    "reason": {
                      "type": "string",
                      "enum": [
                        "kubernetes_managed",
                        "locked",
                        "server_not_running"
                      ],
                      "description": "Why we skipped the server.\n\n- `kubernetes_managed`: The server is a Kubernetes worker.\n- `locked`: The server is locked.\n- `server_not_running`: The server isn't running.",
                      "x-enum-descriptions": {
                        "kubernetes_managed": "The server is a Kubernetes worker.",
                        "locked": "The server is locked.",
                        "server_not_running": "The server isn't running."
                      }
                    }
                  }
                },
                "description": "The servers of this zone that can't get the key now, each with a reason."
              },
              "forwarded": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the servers in other zones. The key is added to each of them once it has been copied to the server's zone."
              }
            },
            "description": "What we did with each server in `server_ids`, returned only when you sent it. Each server's events show whether adding the key worked.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.ssh_key.list": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9](?:[a-zA-Z0-9._-]*[a-zA-Z0-9])?$",
            "description": "The key's name. Must be unique in its team, up to 255 characters long, and start and end with a letter or digit. Dots, hyphens and underscores are allowed in between. A deleted key's `slug` stays taken until the key is removed from every zone.",
            "nullable": false,
            "sensitive": false
          },
          "public_key": {
            "type": "string",
            "format": "ssh-public-key",
            "description": "One OpenSSH public key, such as the contents of a `.pub` file. Never send a private key.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the key. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.valkey.credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The username, always `default`.",
            "nullable": false,
            "sensitive": false
          },
          "auth_token": {
            "type": "string",
            "description": "The AUTH token.",
            "nullable": false,
            "sensitive": true
          },
          "uri": {
            "type": "string",
            "description": "A `valkey://` URI for your private networks, with the `auth_token` in it.",
            "nullable": false,
            "sensitive": true
          },
          "tls_uri": {
            "type": "string",
            "description": "A `valkeys://` URI for the public TLS endpoint, with the `auth_token` in it, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the public TLS endpoint with, in PEM format, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous token stops working after a rotation, or `null` when no rotation is in progress.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `VK2`. Get the types via [List Valkey types](/docs/cloud/api/valkey-types/list-valkey-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_memory_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Memory for your data on each node, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most client connections the type accepts.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The Valkey version, such as `9.1`. Get the versions via [List Valkey versions](/docs/cloud/api/valkey-versions/list-valkey-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state. A new instance is ready once it's `running`. A `running` instance can still be adding a replica or opening its public TLS endpoint.\n\n- `provisioning`: We're creating the instance.\n- `running`: The instance is ready.\n- `degraded`: A node doesn't respond. `status_message` says which.\n- `rescaling`: We're changing the type. When the change doesn't complete, `status_message` says so, and so do the instance's events.\n- `upgrading`: We're upgrading the Valkey version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version, the upgrade failed.\n- `restoring`: We're restoring a snapshot onto the instance. The restore is done when the instance is `running`.\n- `failed`: The instance couldn't be created. A failed instance stays in this state.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "A node doesn't respond. `status_message` says which.",
              "rescaling": "We're changing the type. When the change doesn't complete, `status_message` says so, and so do the instance's events.",
              "upgrading": "We're upgrading the Valkey version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The restore is done when the instance is `running`.",
              "failed": "The instance couldn't be created. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "What needs attention now, such as a node that doesn't respond or a rescale or upgrade that didn't complete. `null` when nothing needs attention.",
            "nullable": true,
            "sensitive": false
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "noeviction",
              "allkeys-lru",
              "allkeys-lfu",
              "allkeys-random",
              "volatile-lru",
              "volatile-lfu",
              "volatile-random",
              "volatile-ttl"
            ],
            "description": "What Valkey does when memory is full, as its `maxmemory-policy` setting.\n\n- `noeviction`: Valkey refuses writes when memory is full.\n- `allkeys-lru`: Valkey evicts the least recently used keys.\n- `allkeys-lfu`: Valkey evicts the least frequently used keys.\n- `allkeys-random`: Valkey evicts random keys.\n- `volatile-lru`: Valkey evicts the least recently used keys that have an expiry.\n- `volatile-lfu`: Valkey evicts the least frequently used keys that have an expiry.\n- `volatile-random`: Valkey evicts random keys that have an expiry.\n- `volatile-ttl`: Valkey evicts the keys with an expiry that expire soonest.",
            "x-enum-descriptions": {
              "noeviction": "Valkey refuses writes when memory is full.",
              "allkeys-lru": "Valkey evicts the least recently used keys.",
              "allkeys-lfu": "Valkey evicts the least frequently used keys.",
              "allkeys-random": "Valkey evicts random keys.",
              "volatile-lru": "Valkey evicts the least recently used keys that have an expiry.",
              "volatile-lfu": "Valkey evicts the least frequently used keys that have an expiry.",
              "volatile-random": "Valkey evicts random keys that have an expiry.",
              "volatile-ttl": "Valkey evicts the keys with an expiry that expire soonest."
            },
            "nullable": false,
            "sensitive": false
          },
          "persistence": {
            "type": "string",
            "enum": [
              "rdb",
              "none"
            ],
            "description": "Whether Valkey keeps the data across restarts. Snapshots work either way.\n\n- `rdb`: Valkey keeps the data across restarts.\n- `none`: Valkey keeps the data in memory only, as a pure cache.",
            "x-enum-descriptions": {
              "rdb": "Valkey keeps the data across restarts.",
              "none": "Valkey keeps the data in memory only, as a pure cache."
            },
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the primary accepts connections with TLS on a public IP, on port 6380.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many replicas the instance has besides the primary, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Always points at the current primary's addresses in those networks.",
                "nullable": true
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, on the public TLS endpoint, or `null` when `public_access` is off. Always points at the current primary's public IP addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port without TLS on private networks, `6379`."
              },
              "tls_port": {
                "type": "integer",
                "format": "int64",
                "description": "The public TLS port, `6380`, or `null` when `public_access` is off.",
                "nullable": true
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The primary's IP address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in the attached private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The primary's public IP addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the current primary.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "The node's role.\n\n- `primary`: The node accepts writes.\n- `replica`: The node copies the primary and serves reads.",
                  "x-enum-descriptions": {
                    "primary": "The node accepts writes.",
                    "replica": "The node copies the primary and serves reads."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's state. Send traffic to a node only while it's `running`.\n\n- `provisioning`: We're creating the node.\n- `syncing`: The replica is copying the primary's data.\n- `running`: The node serves traffic.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "syncing": "The replica is copying the primary's data.",
                    "running": "The node serves traffic.",
                    "down": "The node doesn't respond."
                  }
                },
                "replication_lag_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How far the replica is behind the primary, in bytes, or `null` for the primary.",
                  "nullable": true
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's primary and replicas, with their addresses in your private networks.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last changed.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.valkey.metrics": {
        "type": "object",
        "properties": {
          "valkey_id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "valkey_name": {
            "type": "string",
            "description": "The instance's name.",
            "nullable": false,
            "sensitive": false
          },
          "from": {
            "type": "string",
            "format": "date-time",
            "description": "The start of the range, included.",
            "nullable": false,
            "sensitive": false
          },
          "to": {
            "type": "string",
            "format": "date-time",
            "description": "The end of the range, not included.",
            "nullable": false,
            "sensitive": false
          },
          "resolution": {
            "type": "string",
            "enum": [
              "raw",
              "hourly"
            ],
            "description": "How far apart the points are.\n\n- `raw`: One point a minute, for a range up to one day.\n- `hourly`: One point an hour, for a longer range.",
            "x-enum-descriptions": {
              "raw": "One point a minute, for a range up to one day.",
              "hourly": "One point an hour, for a longer range."
            },
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "member_id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "description": "The node's role, `primary` or `replica`."
                },
                "data": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "dt": {
                        "type": "string",
                        "format": "date-time",
                        "description": "The start of the minute or hour the point covers."
                      },
                      "memory": {
                        "type": "object",
                        "properties": {
                          "used_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The average memory used, in bytes."
                          },
                          "used_bytes_max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most memory used, in bytes."
                          },
                          "usable_bytes": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The type's memory for your data, in bytes."
                          }
                        },
                        "description": "Memory use."
                      },
                      "clients": {
                        "type": "object",
                        "properties": {
                          "connected": {
                            "type": "number",
                            "description": "The average number of connected clients."
                          },
                          "connected_max": {
                            "type": "integer",
                            "format": "int64",
                            "description": "The most connected clients."
                          }
                        },
                        "description": "Connected clients."
                      },
                      "operations_per_second": {
                        "type": "number",
                        "description": "Commands per second."
                      },
                      "hit_ratio": {
                        "type": "number",
                        "description": "The share of key lookups that found the key, from 0 to 1."
                      },
                      "evicted_keys_per_second": {
                        "type": "number",
                        "description": "Keys evicted per second."
                      },
                      "expired_keys_per_second": {
                        "type": "number",
                        "description": "Keys expired per second."
                      },
                      "replication_lag_bytes": {
                        "type": "integer",
                        "format": "int64",
                        "description": "How far a replica is behind the primary, in bytes."
                      }
                    }
                  },
                  "description": "The node's metrics, one entry per point."
                }
              }
            },
            "description": "The metrics of each node.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey.rotate_credentials": {
        "type": "object",
        "properties": {
          "user": {
            "type": "string",
            "description": "The username, always `default`.",
            "nullable": false,
            "sensitive": false
          },
          "auth_token": {
            "type": "string",
            "description": "The new AUTH token.",
            "nullable": false,
            "sensitive": true
          },
          "uri": {
            "type": "string",
            "description": "A `valkey://` URI for your private networks, with the new `auth_token` in it.",
            "nullable": false,
            "sensitive": true
          },
          "tls_uri": {
            "type": "string",
            "description": "A `valkeys://` URI for the public TLS endpoint, with the new `auth_token` in it, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": true
          },
          "ca_certificate": {
            "type": "string",
            "description": "The CA certificate to verify the public TLS endpoint with, in PEM format, or `null` when `public_access` is off.",
            "nullable": true,
            "sensitive": false
          },
          "rotating_until": {
            "type": "string",
            "format": "date-time",
            "description": "When the previous token stops working, 24 hours from now.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey.upgrade": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "nullable": false,
            "sensitive": false
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `VK2`. Get the types via [List Valkey types](/docs/cloud/api/valkey-types/list-valkey-types/).",
            "nullable": false,
            "sensitive": false
          },
          "usable_memory_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Memory for your data on each node, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most client connections the type accepts.",
            "nullable": false,
            "sensitive": false
          },
          "engine_version": {
            "type": "string",
            "description": "The Valkey version, such as `9.1`. Get the versions via [List Valkey versions](/docs/cloud/api/valkey-versions/list-valkey-versions/).",
            "nullable": false,
            "sensitive": false
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state. A new instance is ready once it's `running`. A `running` instance can still be adding a replica or opening its public TLS endpoint.\n\n- `provisioning`: We're creating the instance.\n- `running`: The instance is ready.\n- `degraded`: A node doesn't respond. `status_message` says which.\n- `rescaling`: We're changing the type. When the change doesn't complete, `status_message` says so, and so do the instance's events.\n- `upgrading`: We're upgrading the Valkey version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version, the upgrade failed.\n- `restoring`: We're restoring a snapshot onto the instance. The restore is done when the instance is `running`.\n- `failed`: The instance couldn't be created. A failed instance stays in this state.\n- `destroyed`: The instance is deleted.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "A node doesn't respond. `status_message` says which.",
              "rescaling": "We're changing the type. When the change doesn't complete, `status_message` says so, and so do the instance's events.",
              "upgrading": "We're upgrading the Valkey version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The restore is done when the instance is `running`.",
              "failed": "The instance couldn't be created. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "status_message": {
            "type": "string",
            "description": "What needs attention now, such as a node that doesn't respond or a rescale or upgrade that didn't complete. `null` when nothing needs attention.",
            "nullable": true,
            "sensitive": false
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "noeviction",
              "allkeys-lru",
              "allkeys-lfu",
              "allkeys-random",
              "volatile-lru",
              "volatile-lfu",
              "volatile-random",
              "volatile-ttl"
            ],
            "description": "What Valkey does when memory is full, as its `maxmemory-policy` setting.\n\n- `noeviction`: Valkey refuses writes when memory is full.\n- `allkeys-lru`: Valkey evicts the least recently used keys.\n- `allkeys-lfu`: Valkey evicts the least frequently used keys.\n- `allkeys-random`: Valkey evicts random keys.\n- `volatile-lru`: Valkey evicts the least recently used keys that have an expiry.\n- `volatile-lfu`: Valkey evicts the least frequently used keys that have an expiry.\n- `volatile-random`: Valkey evicts random keys that have an expiry.\n- `volatile-ttl`: Valkey evicts the keys with an expiry that expire soonest.",
            "x-enum-descriptions": {
              "noeviction": "Valkey refuses writes when memory is full.",
              "allkeys-lru": "Valkey evicts the least recently used keys.",
              "allkeys-lfu": "Valkey evicts the least frequently used keys.",
              "allkeys-random": "Valkey evicts random keys.",
              "volatile-lru": "Valkey evicts the least recently used keys that have an expiry.",
              "volatile-lfu": "Valkey evicts the least frequently used keys that have an expiry.",
              "volatile-random": "Valkey evicts random keys that have an expiry.",
              "volatile-ttl": "Valkey evicts the keys with an expiry that expire soonest."
            },
            "nullable": false,
            "sensitive": false
          },
          "persistence": {
            "type": "string",
            "enum": [
              "rdb",
              "none"
            ],
            "description": "Whether Valkey keeps the data across restarts. Snapshots work either way.\n\n- `rdb`: Valkey keeps the data across restarts.\n- `none`: Valkey keeps the data in memory only, as a pure cache.",
            "x-enum-descriptions": {
              "rdb": "Valkey keeps the data across restarts.",
              "none": "Valkey keeps the data in memory only, as a pure cache."
            },
            "nullable": false,
            "sensitive": false
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the primary accepts connections with TLS on a public IP, on port 6380.",
            "nullable": false,
            "sensitive": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many replicas the instance has besides the primary, from `0` to `2`.",
            "nullable": false,
            "sensitive": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Always points at the current primary's addresses in those networks.",
                "nullable": true
              },
              "public_hostname": {
                "type": "string",
                "description": "The hostname to connect to from the internet, on the public TLS endpoint, or `null` when `public_access` is off. Always points at the current primary's public IP addresses.",
                "nullable": true
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port without TLS on private networks, `6379`."
              },
              "tls_port": {
                "type": "integer",
                "format": "int64",
                "description": "The public TLS port, `6380`, or `null` when `public_access` is off.",
                "nullable": true
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The primary's IP address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in the attached private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The primary's public IP addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the current primary.",
            "nullable": false,
            "sensitive": false
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "The node's role.\n\n- `primary`: The node accepts writes.\n- `replica`: The node copies the primary and serves reads.",
                  "x-enum-descriptions": {
                    "primary": "The node accepts writes.",
                    "replica": "The node copies the primary and serves reads."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's state. Send traffic to a node only while it's `running`.\n\n- `provisioning`: We're creating the node.\n- `syncing`: The replica is copying the primary's data.\n- `running`: The node serves traffic.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "syncing": "The replica is copying the primary's data.",
                    "running": "The node serves traffic.",
                    "down": "The node doesn't respond."
                  }
                },
                "replication_lag_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How far the replica is behind the primary, in bytes, or `null` for the primary.",
                  "nullable": true
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's primary and replicas, with their addresses in your private networks.",
            "nullable": false,
            "sensitive": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "nullable": false,
            "sensitive": false
          },
          "latest_snapshot_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "nullable": true,
            "sensitive": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.\n\n- `monthly`: Billed each month.\n- `annual`: Paid for a year at a time.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last changed.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          },
          "pre_upgrade_snapshot_id": {
            "type": "string",
            "description": "The ID of the snapshot we created before the upgrade. Later responses don't include it.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey_event.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance the event belongs to.",
            "nullable": false,
            "sensitive": false
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `failed_over`. An event for a request is recorded when we accept the request, before the work is done.",
            "nullable": false,
            "sensitive": false
          },
          "user_id": {
            "type": "integer",
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "nullable": true,
            "sensitive": false
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.\n\n- `user`: A Better Stack user did it. `user_id` says who.\n- `api_token`: A request with an API token did it.\n- `system`: Better Stack did it, such as a failover.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it, such as a failover."
            },
            "nullable": false,
            "sensitive": false
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the action, such as the snapshot ID, the new type or the nodes of a failover.",
            "nullable": false,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event happened.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey_scheduled_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's current primary. Changes after a failover.",
            "nullable": false,
            "sensitive": false
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months.",
            "nullable": false,
            "sensitive": false
          },
          "last_run_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule last ran, or `null` before the first run.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance the snapshot was taken from.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that ran the instance's primary. The server isn't in your list of servers. Can become `null` after the server is deleted.",
            "nullable": true,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.\n\n- `manual`: A request created the snapshot.\n- `scheduled`: A snapshot schedule created the snapshot.",
            "x-enum-descriptions": {
              "manual": "A request created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. A new snapshot is ready once it's `available`.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready to restore.\n- `failed`: The snapshot couldn't be created. `failure_reason` says why.\n- `deleting`: We're removing the snapshot's data. The snapshot is gone once we're done.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready to restore.",
              "failed": "The snapshot couldn't be created. `failure_reason` says why.",
              "deleting": "We're removing the snapshot's data. The snapshot is gone once we're done."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. We bill by this size. `null` until the snapshot is ready.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The availability zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why the snapshot couldn't be created, or `null` unless the snapshot is `failed`.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null` when there's nothing more.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Our lock on the snapshot, or `null` when it isn't locked.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.valkey_type.list": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `VK1`. Send it as `type` when you create or rescale an instance.",
            "nullable": false,
            "sensitive": false
          },
          "usable_memory_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory for your data on each node, in GiB.",
            "nullable": false,
            "sensitive": false
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections an instance of this type accepts at once.",
            "nullable": false,
            "sensitive": false
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.\n\n- `global`: You can order the type.\n- `unavailable`: The type is deprecated. Instances that have it keep running, but you can't create or rescale an instance to it.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Instances that have it keep running, but you can't create or rescale an instance to it."
            },
            "nullable": false,
            "sensitive": false
          },
          "replacement": {
            "type": "string",
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "nullable": true,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.valkey_version.list": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The Valkey version as major and minor, such as `9.1`.",
            "nullable": false,
            "sensitive": false
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "CLIResponse.cloud.volume.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The volume's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The volume's name.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "creating",
              "attaching",
              "attached",
              "detaching",
              "available",
              "moving",
              "resizing",
              "snapshotting",
              "deleting",
              "failed",
              "destroyed"
            ],
            "description": "The volume's state. While a change to the volume is in progress, other changes to it are refused.\n\n- `creating`: We're creating the volume.\n- `attaching`: We're attaching the volume to a server.\n- `attached`: The volume is attached to a server.\n- `detaching`: We're detaching the volume.\n- `available`: The volume isn't attached to a server. A new volume that ends up `available` couldn't be attached, and `failure_reason` says why.\n- `moving`: We're copying the volume to the host of the server you're attaching it to.\n- `resizing`: We're growing the volume.\n- `snapshotting`: We're creating a snapshot of the volume.\n- `deleting`: We're deleting the volume.\n- `failed`: We couldn't create the volume. A failed volume stays in this state.\n- `destroyed`: The volume is deleted.",
            "x-enum-descriptions": {
              "creating": "We're creating the volume.",
              "attaching": "We're attaching the volume to a server.",
              "attached": "The volume is attached to a server.",
              "detaching": "We're detaching the volume.",
              "available": "The volume isn't attached to a server. A new volume that ends up `available` couldn't be attached, and `failure_reason` says why.",
              "moving": "We're copying the volume to the host of the server you're attaching it to.",
              "resizing": "We're growing the volume.",
              "snapshotting": "We're creating a snapshot of the volume.",
              "deleting": "We're deleting the volume.",
              "failed": "We couldn't create the volume. A failed volume stays in this state.",
              "destroyed": "The volume is deleted."
            },
            "nullable": false,
            "sensitive": false
          },
          "volume_type": {
            "type": "string",
            "enum": [
              "nvme"
            ],
            "description": "The kind of storage, always `nvme`.",
            "nullable": false,
            "sensitive": false
          },
          "size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The volume's size in GiB, from 1 to 3072.",
            "nullable": false,
            "sensitive": false
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the volume is attached to, or `null` when the volume isn't attached.",
            "nullable": true,
            "sensitive": false
          },
          "format": {
            "type": "string",
            "enum": [
              "ext4",
              "xfs",
              null
            ],
            "description": "The filesystem we created on the volume, or `null` for a volume without a filesystem.",
            "nullable": true,
            "sensitive": false
          },
          "auto_mount": {
            "type": "boolean",
            "description": "Whether the server mounts the volume automatically when it's attached.",
            "nullable": false,
            "sensitive": false
          },
          "mount_path": {
            "type": "string",
            "description": "Where the server mounts the volume, under `/mnt`, or `null` when the volume isn't mounted.",
            "nullable": true,
            "sensitive": false
          },
          "device_path": {
            "type": "string",
            "description": "The volume's device path on the server, under `/dev/disk/by-id`. Use the device path in `/etc/fstab`, since it doesn't change. `null` while the volume isn't attached.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why the last change to the volume failed, such as an attach, detach or resize. The reason stays after the volume is back to `available` or `attached`.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the volume."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the volume."
              }
            },
            "description": "Our lock on the volume, or `null`. A locked volume can't be changed. Every change is refused with the code `locked`.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the volume was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the volume was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the volume. A volume belongs to the team of the server you created it on.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.volume_snapshot.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The volume snapshot's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name.",
            "nullable": false,
            "sensitive": false
          },
          "volume_id": {
            "type": "string",
            "description": "The ID of the volume the snapshot was taken from, or `null` once that volume is deleted. You can still get and restore a snapshot of a deleted volume.",
            "nullable": true,
            "sensitive": false
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.\n\n- `manual`: You created the snapshot.\n- `scheduled`: A snapshot schedule created the snapshot.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. A new snapshot is ready when it's `available`.\n\n- `pending`: We're creating the snapshot.\n- `available`: The snapshot is ready, and you can restore it.\n- `failed`: We couldn't create the snapshot. `failure_reason` says why.\n- `deleting`: We're deleting the snapshot.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "nullable": false,
            "sensitive": false
          },
          "size_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The volume's size in bytes when the snapshot was taken, the same size as `size_gb`. We bill the snapshot by this size. `null` until the snapshot is ready.",
            "nullable": true,
            "sensitive": false
          },
          "size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The volume's size in GB. A volume restored from the snapshot gets this size.",
            "nullable": true,
            "sensitive": false
          },
          "availability_zone": {
            "type": "string",
            "description": "The availability zone the snapshot was taken in.",
            "nullable": true,
            "sensitive": false
          },
          "failure_reason": {
            "type": "string",
            "description": "Why creating the snapshot failed, or `null` unless the snapshot is `failed`.",
            "nullable": true,
            "sensitive": false
          },
          "lock": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the volume snapshot."
              },
              "details": {
                "type": "string",
                "description": "More about the lock, or `null`.",
                "nullable": true
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the volume snapshot."
              }
            },
            "description": "Our lock on the volume snapshot, or `null`. A locked volume snapshot can't be changed, deleted or restored.",
            "nullable": true,
            "sensitive": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "nullable": false,
            "sensitive": false,
            "x-own-keys": true
          }
        }
      },
      "CLIResponse.cloud.webhook.list": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The webhook's ID, a UUID.",
            "nullable": false,
            "sensitive": false
          },
          "name": {
            "type": "string",
            "description": "The webhook's name.",
            "nullable": false,
            "sensitive": false
          },
          "url": {
            "type": "string",
            "description": "The URL we send notifications to.",
            "nullable": false,
            "sensitive": false
          },
          "webhook_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources we notify about. Accepts `server`, `snapshot`, `reserved_ip`, `network`, `firewall`, `ssh_key`, `placement_group`, `scheduled_snapshot`, `load_balancer`, `certificate`, `volume`, `volume_snapshot`, `scheduled_volume_snapshot`, `valkey`, `mysql`, `postgres`, `clickhouse`, `kafka` and `object_proxy`. `object_proxy` covers object caches. A notification names its kind in its `object` field.",
            "nullable": false,
            "sensitive": false
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether we send notifications to the webhook.\n\n- `active`: We send notifications.\n- `paused`: We send no notifications until you set it back to `active`.",
            "x-enum-descriptions": {
              "active": "We send notifications.",
              "paused": "We send no notifications until you set it back to `active`."
            },
            "nullable": false,
            "sensitive": false
          },
          "failed_deliveries": {
            "type": "integer",
            "format": "int64",
            "description": "The number of notifications in a row that we couldn't deliver. A delivered notification resets the count to `0`.",
            "nullable": false,
            "sensitive": false
          },
          "secret": {
            "type": "string",
            "description": "The secret we sign notifications with. Each notification has an `X-Signature` header, `sha256=` followed by the HMAC-SHA256 of the body made with this secret. We create the secret with the webhook, and every response includes it.",
            "nullable": false,
            "sensitive": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the webhook was created.",
            "nullable": false,
            "sensitive": false
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the webhook was last updated.",
            "nullable": false,
            "sensitive": false
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the webhook. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "nullable": false,
            "sensitive": false
          }
        }
      },
      "Certificate": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The certificate's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The certificate's name.",
            "x-cli-input": {
              "order": 30
            }
          },
          "certificate_type": {
            "type": "string",
            "enum": [
              "uploaded",
              "managed"
            ],
            "description": "Whether you upload the certificate or we issue it.",
            "x-enum-descriptions": {
              "uploaded": "You upload the certificate. Send `certificate` and `private_key`.",
              "managed": "We issue and renew the certificate with Let's Encrypt. Send `domain_names`."
            },
            "x-cli-input": {
              "order": 20
            },
            "default": "uploaded"
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "issued",
              "failed"
            ],
            "description": "Whether the certificate is ready.",
            "x-enum-descriptions": {
              "pending": "We haven't issued the certificate yet.",
              "issued": "The certificate is ready. An uploaded certificate starts in this state.",
              "failed": "We couldn't issue the certificate. `status_message` says why, and we try again every day."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the certificate isn't issued yet, or why issuing it failed.",
            "readOnly": true
          },
          "domain_names": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The domains the certificate covers, from 1 to 100. A managed certificate requires them and can't use wildcard domains. An uploaded certificate gets its domains from the certificate itself.",
            "x-cli-input": {
              "order": 40
            }
          },
          "certificate": {
            "type": [
              "string",
              "null"
            ],
            "description": "The certificate chain in PEM format, with the certificate first. An uploaded certificate requires it. A managed certificate has none until we issue it.",
            "x-cli-input": {
              "order": 50
            }
          },
          "fingerprint": {
            "type": [
              "string",
              "null"
            ],
            "description": "The certificate's SHA-256 fingerprint.",
            "readOnly": true
          },
          "not_valid_before": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the certificate becomes valid.",
            "readOnly": true
          },
          "not_valid_after": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the certificate expires.",
            "readOnly": true
          },
          "last_issued_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When we last issued or renewed a managed certificate. Always `null` for an uploaded certificate.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the certificate was last changed.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the certificate. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "CertificateCreate": {
        "$ref": "#/components/schemas/CertificateCreateAttributes"
      },
      "CertificateCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The certificate's name.",
            "x-cli-input": {
              "order": 30
            }
          },
          "certificate_type": {
            "type": "string",
            "enum": [
              "uploaded",
              "managed"
            ],
            "description": "Whether you upload the certificate or we issue it.",
            "x-enum-descriptions": {
              "uploaded": "You upload the certificate. Send `certificate` and `private_key`.",
              "managed": "We issue and renew the certificate with Let's Encrypt. Send `domain_names`."
            },
            "x-cli-input": {
              "order": 20
            },
            "default": "uploaded"
          },
          "domain_names": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The domains the certificate covers, from 1 to 100. A managed certificate requires them and can't use wildcard domains. An uploaded certificate gets its domains from the certificate itself.",
            "x-cli-input": {
              "order": 40
            }
          },
          "certificate": {
            "type": [
              "string",
              "null"
            ],
            "description": "The certificate chain in PEM format, with the certificate first. An uploaded certificate requires it. A managed certificate has none until we issue it.",
            "x-cli-input": {
              "order": 50
            }
          },
          "private_key": {
            "type": "string",
            "description": "The certificate's private key in PEM format, without a passphrase. An uploaded certificate requires a private key. The key isn't returned after it's saved.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 60
            },
            "writeOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the certificate. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "name",
          "team_id"
        ]
      },
      "CertificateDocument": {
        "$ref": "#/components/schemas/Certificate"
      },
      "CertificateList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Certificate"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "CertificateUpdate": {
        "$ref": "#/components/schemas/CertificateUpdateAttributes"
      },
      "CertificateUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The certificate's name.",
            "x-cli-input": {
              "order": 30
            }
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "ClickHouse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `CH2`. Get the types via [List ClickHouse types](/docs/cloud/api/clickhouse-types/list-clickhouse-types/).",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_clickhouse_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_disk_gb",
                "max_concurrent_queries"
              ]
            },
            "examples": [
              "CH1"
            ]
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Storage for your data, in GiB.",
            "readOnly": true
          },
          "max_concurrent_queries": {
            "type": "integer",
            "format": "int64",
            "description": "The most queries the type runs at the same time. A query over this limit fails at once.",
            "readOnly": true
          },
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version, such as `26.8`. Get the versions via [List ClickHouse versions](/docs/cloud/api/clickhouse-versions/list-clickhouse-versions/).",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_clickhouse_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "engine_patch_version": {
            "type": [
              "string",
              "null"
            ],
            "description": "The exact ClickHouse version the instance runs, or `null` until the instance's first upgrade.",
            "readOnly": true
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now. The next LTS version shows up here once we offer it.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "The instance works, but needs attention. `status_message` says why.",
              "rescaling": "We're changing the type. When the change doesn't complete, the instance returns to `running` with a `status_message`.",
              "upgrading": "We're upgrading the ClickHouse version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version with a `status_message`, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The instance is `running` again once ClickHouse responds to queries.",
              "failed": "The instance couldn't be created or recovered. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the instance failed or is degraded, or why an operation didn't complete.",
            "readOnly": true
          },
          "timezone": {
            "type": "string",
            "description": "The default time zone for date and time functions, `UTC` or an IANA name such as `Europe/Prague`.",
            "default": "UTC"
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the instance accepts connections on a public IP. The TLS ports `9440` and `8443` are public. The ports without TLS stay on private networks.",
            "default": false
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. The hostname resolves to the instance's addresses in those networks."
              },
              "public_hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is `false`. The hostname resolves to the instance's public IP addresses."
              },
              "ports": {
                "type": "object",
                "properties": {
                  "native": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port, `9000`."
                  },
                  "native_tls": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The native protocol port with TLS, `9440`."
                  },
                  "http": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTP port, `8123`."
                  },
                  "https": {
                    "type": "integer",
                    "format": "int64",
                    "description": "The HTTPS port, `8443`."
                  }
                },
                "description": "The ports the instance listens on."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The instance's IP address in that network."
                    }
                  }
                },
                "description": "The instance's addresses in the private networks attached to it."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The instance's public IP addresses. Empty when `public_access` is `false`."
              }
            },
            "description": "Where to connect to the instance.",
            "readOnly": true
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary"
                  ],
                  "description": "The node's role, always `primary`."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "running",
                    "down"
                  ],
                  "description": "The node's state.\n\n- `provisioning`: We're creating the node.\n- `running`: The node is up.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "running": "The node is up.",
                    "down": "The node doesn't respond."
                  }
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The node that runs the instance. An instance has one.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "latest_snapshot_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "ClickHouseCreate": {
        "$ref": "#/components/schemas/ClickHouseCreateAttributes"
      },
      "ClickHouseCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's ClickHouse instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `CH2`. Get the types via [List ClickHouse types](/docs/cloud/api/clickhouse-types/list-clickhouse-types/). To change it later, use [Rescale a ClickHouse instance](/docs/cloud/api/clickhouses/rescale-clickhouse/).",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_clickhouse_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_disk_gb",
                "max_concurrent_queries"
              ]
            },
            "examples": [
              "CH1"
            ]
          },
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version, such as `26.8`. Get the versions via [List ClickHouse versions](/docs/cloud/api/clickhouse-versions/list-clickhouse-versions/). Defaults to the latest version. To change it later, use [Upgrade a ClickHouse instance](/docs/cloud/api/clickhouses/upgrade-clickhouse/).",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_clickhouse_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "timezone": {
            "type": "string",
            "description": "The default time zone for date and time functions, `UTC` or an IANA name such as `Europe/Prague`. A change applies to connections opened after it.",
            "default": "UTC"
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the instance accepts connections on a public IP. The TLS ports `9440` and `8443` are public. The ports without TLS stay on private networks.",
            "default": false
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Each network must be in the instance's team. To change them later, attach or detach a network. Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/). Can't be changed after the instance is created.",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "name",
          "type",
          "team_id"
        ]
      },
      "ClickHouseDocument": {
        "$ref": "#/components/schemas/ClickHouse"
      },
      "ClickHouseEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `snapshot_created`.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the action, such as the new type, the new version or the snapshot ID.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "ClickHouseEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouseEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ClickHouseList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouse"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ClickHouseScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the schedule belongs to.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance.",
            "readOnly": true
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the first one.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "ClickHouseScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/ClickHouseScheduledSnapshotCreateAttributes"
      },
      "ClickHouseScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        },
        "required": [
          "frequency"
        ]
      },
      "ClickHouseScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/ClickHouseScheduledSnapshot"
      },
      "ClickHouseScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouseScheduledSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ClickHouseScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/ClickHouseScheduledSnapshotUpdateAttributes"
      },
      "ClickHouseScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        }
      },
      "ClickHouseSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "clickhouse_id": {
            "type": "string",
            "description": "The ID of the ClickHouse instance the snapshot was taken from.",
            "readOnly": true
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that runs the instance. The server is hidden from your list of servers. Can become `null` after the instance is deleted.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.",
            "x-enum-descriptions": {
              "manual": "Created by a request.",
              "scheduled": "Created by a snapshot schedule."
            },
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot. The snapshot then becomes `available`, or `failed` with a `failure_reason`.",
              "available": "The snapshot is ready to restore.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot's data. The snapshot is gone once we're done."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. We bill by this size. Stays `null` until the snapshot is ready.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The availability zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why creating the snapshot failed, or `null` unless the snapshot is `failed`.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null` when there's nothing more."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Our lock on the snapshot, or `null` when it isn't locked. You can still delete and restore a locked snapshot.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "ClickHouseSnapshotCreate": {
        "$ref": "#/components/schemas/ClickHouseSnapshotCreateAttributes"
      },
      "ClickHouseSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `analytics-2026-11-24`."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
          }
        }
      },
      "ClickHouseSnapshotDocument": {
        "$ref": "#/components/schemas/ClickHouseSnapshot"
      },
      "ClickHouseSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouseSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ClickHouseType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type name. Send it as `type` when you create or rescale a ClickHouse instance.",
            "readOnly": true
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Storage for your data, in GiB.",
            "readOnly": true
          },
          "max_concurrent_queries": {
            "type": "integer",
            "format": "int64",
            "description": "The most queries that can run at the same time.",
            "readOnly": true
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of virtual CPUs.",
            "readOnly": true
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Memory, in GiB.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Instances on it keep running, but you can't create or rescale to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The type to use instead of this deprecated one, or `null` for a type you can order.",
            "readOnly": true
          }
        }
      },
      "ClickHouseTypeDocument": {
        "$ref": "#/components/schemas/ClickHouseType"
      },
      "ClickHouseTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouseType"
            }
          }
        }
      },
      "ClickHouseUpdate": {
        "$ref": "#/components/schemas/ClickHouseUpdateAttributes"
      },
      "ClickHouseUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's ClickHouse instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "timezone": {
            "type": "string",
            "description": "The default time zone for date and time functions, `UTC` or an IANA name such as `Europe/Prague`. A change applies to connections opened after it.",
            "default": "UTC"
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the instance accepts connections on a public IP. The TLS ports `9440` and `8443` are public. The ports without TLS stay on private networks.",
            "default": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. On update, a new term starts at once, and billing ends the current one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. On update, the tags you send replace every tag, so an empty object removes them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "ClickHouseVersion": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The ClickHouse LTS version as major and minor, such as `26.8`. We install its latest patch release and keep it updated.",
            "readOnly": true,
            "examples": [
              "26.8"
            ]
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "readOnly": true
          }
        }
      },
      "ClickHouseVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClickHouseVersion"
            }
          }
        }
      },
      "CloudError": {
        "type": "object",
        "description": "An error returns an object such as `{\"error\": {\"code\": \"validation_failed\", \"message\": \"Name can't be blank\", \"details\": {...}}}`. The error's `code` never changes, so check the code in your program. Only a 422 response has `details`. A 402 response can have `first_purchase`, with the `url` of a page where you make the first payment. A 5xx response has a generic `message` that doesn't name the cause.",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "message": {
                "type": [
                  "string",
                  "object",
                  "array"
                ],
                "description": "Human-readable failure message."
              },
              "code": {
                "type": [
                  "string",
                  "object",
                  "array"
                ],
                "description": "Code."
              },
              "details": {
                "type": [
                  "string",
                  "object",
                  "array"
                ],
                "description": "Details."
              },
              "first_purchase": {
                "type": [
                  "string",
                  "object",
                  "array"
                ],
                "description": "First purchase."
              }
            }
          }
        }
      },
      "Event": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, in the past tense, such as `created`, `claimed`, `started`, `stopped`, `restarted`, `destroyed`, `rescaled`, `restored`, `term_changed`, `snapshot_created`, `snapshot_failed`, `reserved_ip_attached`, `reserved_ip_detached`, `ssh_key_attached`, `ssh_key_detached`, `ssh_key_attach_failed`, `ssh_key_detach_failed`, `network_attach_failed`, `rescue_entered`, `rescue_exited`, `console_opened`, `console_terminated`, `spot_terminated`, `locked` or `unlocked`. We add new actions over time, so expect values that aren't listed here.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it, and `user_id` names them.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "Details that depend on the action, such as the snapshot a restore used or the server types a rescale moved between.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "EventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Event"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "Firewall": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The firewall's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The firewall's name, unique in your organization.",
            "x-cli-input": {
              "order": 20
            }
          },
          "rules": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The rule's ID, a UUID."
                },
                "direction": {
                  "type": "string",
                  "description": "Which traffic the rule matches, `inbound` or `outbound`."
                },
                "protocol": {
                  "type": "string",
                  "description": "The IP protocol the rule matches. `any` matches every protocol."
                },
                "ip_addresses": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "The addresses the rule applies to, in CIDR notation."
                },
                "port_from": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The first port of the range."
                },
                "port_to": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "int64",
                  "description": "The last port of the range, or `null` when the rule matches only `port_from`."
                }
              }
            },
            "description": "The firewall's rules. Add a rule via [Create a firewall rule](/docs/cloud/api/firewall-rules/create-firewall-rule/) and remove one via [Remove a firewall rule](/docs/cloud/api/firewall-rules/delete-firewall-rule/).",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the firewall was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the firewall was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the firewall. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        }
      },
      "FirewallCreate": {
        "$ref": "#/components/schemas/FirewallCreateAttributes"
      },
      "FirewallCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The firewall's name, unique in your organization.",
            "x-cli-input": {
              "order": 20
            }
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the firewall. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        },
        "required": [
          "name",
          "team_id"
        ]
      },
      "FirewallDocument": {
        "$ref": "#/components/schemas/Firewall"
      },
      "FirewallList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Firewall"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "FirewallRule": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The rule's ID, a UUID.",
            "readOnly": true
          },
          "direction": {
            "type": "string",
            "enum": [
              "inbound",
              "outbound"
            ],
            "description": "Which traffic the rule matches.",
            "x-enum-descriptions": {
              "inbound": "The rule matches traffic that arrives at the server.",
              "outbound": "The rule matches traffic that leaves the server."
            },
            "x-cli-input": {
              "order": 20
            }
          },
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "udp",
              "icmp",
              "gre",
              "esp",
              "any"
            ],
            "description": "The IP protocol the rule matches. `any` matches every protocol.",
            "x-cli-input": {
              "order": 30
            }
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The addresses the rule applies to, in CIDR notation, such as `10.0.0.0/8`. Use `0.0.0.0/0` and `::/0` for every address. The list can't be empty.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              [
                "0.0.0.0/0",
                "::/0"
              ]
            ]
          },
          "port_from": {
            "type": "integer",
            "format": "int64",
            "description": "The first port of the range, from `0` to `65535`. Send it for every protocol. A protocol without ports, such as `icmp`, ignores it.",
            "x-cli-input": {
              "order": 50
            },
            "examples": [
              443
            ]
          },
          "port_to": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The last port of the range, from `port_from` to `65535`.",
            "x-cli-input": {
              "order": 60
            }
          }
        }
      },
      "FirewallRuleCreate": {
        "$ref": "#/components/schemas/FirewallRuleCreateAttributes"
      },
      "FirewallRuleCreateAttributes": {
        "type": "object",
        "properties": {
          "direction": {
            "type": "string",
            "enum": [
              "inbound",
              "outbound"
            ],
            "description": "Which traffic the rule matches.",
            "x-enum-descriptions": {
              "inbound": "The rule matches traffic that arrives at the server.",
              "outbound": "The rule matches traffic that leaves the server."
            },
            "x-cli-input": {
              "order": 20
            }
          },
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "udp",
              "icmp",
              "gre",
              "esp",
              "any"
            ],
            "description": "The IP protocol the rule matches. `any` matches every protocol.",
            "x-cli-input": {
              "order": 30
            }
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The addresses the rule applies to, in CIDR notation, such as `10.0.0.0/8`. Use `0.0.0.0/0` and `::/0` for every address. The list can't be empty.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              [
                "0.0.0.0/0",
                "::/0"
              ]
            ]
          },
          "port_from": {
            "type": "integer",
            "format": "int64",
            "description": "The first port of the range, from `0` to `65535`. Send it for every protocol. A protocol without ports, such as `icmp`, ignores it.",
            "x-cli-input": {
              "order": 50
            },
            "examples": [
              443
            ]
          },
          "port_to": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The last port of the range, from `port_from` to `65535`. Leave it out to match only `port_from`.",
            "x-cli-input": {
              "order": 60
            }
          }
        },
        "required": [
          "direction",
          "protocol",
          "ip_addresses",
          "port_from"
        ]
      },
      "FirewallRuleDocument": {
        "$ref": "#/components/schemas/FirewallRule"
      },
      "FirewallRuleList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FirewallRule"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "FirewallUpdate": {
        "$ref": "#/components/schemas/FirewallUpdateAttributes"
      },
      "FirewallUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The firewall's name, unique in your organization.",
            "x-cli-input": {
              "order": 20
            }
          }
        }
      },
      "Image": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "The image's name, such as `ubuntu-26-04`. Send it as `image` when you create a server.",
            "readOnly": true
          }
        }
      },
      "ImageDocument": {
        "$ref": "#/components/schemas/Image"
      },
      "ImageList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Image"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "Ip": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the public IP, private IP or reserved IP the address belongs to.",
            "readOnly": true
          },
          "ip": {
            "type": "string",
            "description": "The address.",
            "readOnly": true
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or IPv6 address.",
            "readOnly": true
          },
          "visibility": {
            "type": "string",
            "enum": [
              "public",
              "private"
            ],
            "description": "Where the address can be reached from.",
            "x-enum-descriptions": {
              "public": "The address is reachable from the internet.",
              "private": "The address is reachable only inside one of your private networks."
            },
            "readOnly": true
          },
          "available": {
            "type": "boolean",
            "description": "Whether it's a reserved IP that isn't assigned to a server.",
            "readOnly": true
          },
          "ptr_record": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reverse DNS name of a public address, or `null` for a private address.",
            "readOnly": true
          },
          "server": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "status": {
                "type": "string"
              }
            },
            "description": "The server that has the address, or `null` when no server has it.",
            "readOnly": true
          },
          "network": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "description": "The private network the address is in, or `null` for a public address.",
            "readOnly": true
          },
          "reservation": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "description": "The reserved IP for the address, or `null` when it isn't reserved.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the address was added to the server or network, or reserved.",
            "readOnly": true
          },
          "device_name": {
            "type": "string",
            "description": "The server's network interface that has the public address, such as `eth0`. Only public addresses on a server have it.",
            "readOnly": true
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that has a private address or a reserved IP. Public addresses on a server don't have it.",
            "readOnly": true
          },
          "network_id": {
            "type": "string",
            "description": "The ID of the network a private address is in. Only private addresses have it.",
            "readOnly": true
          },
          "ip_address": {
            "type": "string",
            "description": "The private address, the same as `ip`. Only private addresses have it.",
            "readOnly": true
          },
          "name": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of a reserved IP that isn't assigned. Only those entries have it.",
            "readOnly": true
          },
          "gateway": {
            "type": [
              "string",
              "null"
            ],
            "description": "The gateway of a reserved IP that isn't assigned. Only those entries have it.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the private address or the reserved IP was last updated. Public addresses on a server don't have it.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns a reserved IP that isn't assigned. Only those entries have it.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "The tags of a reserved IP that isn't assigned. Only those entries have it.",
            "readOnly": true
          }
        }
      },
      "IpList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Ip"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "Kafka": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The cluster's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The cluster's name, at most 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`."
          },
          "type": {
            "type": "string",
            "description": "The cluster's type, such as `KA1`.",
            "examples": [
              "KA1"
            ]
          },
          "broker_count": {
            "type": "integer",
            "format": "int64",
            "description": "The number of brokers, `1` for development or `3` to keep the cluster running when a broker fails. Can't be changed after the cluster is created."
          },
          "replication_factor": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies of each partition, the same as `broker_count`. Every broker stores every partition.",
            "readOnly": true
          },
          "min_insync_replicas": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies that must confirm a write, `1` with one broker and `2` with three.",
            "readOnly": true
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The storage for your topics on each broker, in GiB.",
            "readOnly": true
          },
          "max_partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The most partitions the cluster's type allows across all topics.",
            "readOnly": true
          },
          "storage_budget_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The storage budget of each broker, in bytes. All topics together must fit in it.",
            "readOnly": true
          },
          "storage_budget_used_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The storage your topics reserve, in bytes. Each topic reserves its `retention_bytes` times its number of partitions, plus one segment for each partition.",
            "readOnly": true
          },
          "partition_count": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions across all topics.",
            "readOnly": true
          },
          "engine_version": {
            "type": "string",
            "description": "The Kafka version as major and minor, such as `4.4`."
          },
          "engine_patch_version": {
            "type": [
              "string",
              "null"
            ],
            "description": "The exact Kafka release installed, such as `4.4.0`.",
            "readOnly": true
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the cluster to, which is only the next version we offer. Empty when the cluster runs the newest version.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "failed",
              "destroyed"
            ],
            "description": "The cluster's state.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the brokers and installing Kafka.",
              "running": "The cluster is ready. Right after it's created, brokers can still be starting.",
              "degraded": "A broker is down, partitions are missing copies or a disk is almost full. `status_message` says which.",
              "rescaling": "We're changing the cluster's type.",
              "upgrading": "We're upgrading the cluster to a newer Kafka version.",
              "failed": "We couldn't create the cluster. `status_message` says why.",
              "destroyed": "The cluster is destroyed."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the cluster is in its current state, such as which broker is down, or `null` when there's nothing to report.",
            "readOnly": true
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the cluster also has public endpoints. Clients connect with TLS and SCRAM on both the private and the public endpoints."
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "bootstrap_servers": {
                "type": "string"
              },
              "hostname": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "port": {
                "type": "integer",
                "format": "int64"
              },
              "security_protocol": {
                "type": "string"
              },
              "sasl_mechanism": {
                "type": "string"
              },
              "brokers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "node_id": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "hostname": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              },
              "public_bootstrap_servers": {
                "type": "string"
              },
              "public_hostname": {
                "type": "string"
              },
              "public_port": {
                "type": "integer",
                "format": "int64"
              },
              "public_brokers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "node_id": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "hostname": {
                      "type": "string"
                    }
                  }
                }
              }
            },
            "description": "The addresses clients connect to, with the bootstrap address and one address for each broker. Clients must reach every broker, not only the bootstrap address. The fields that start with `public_` are present only when `public_access` is on.",
            "readOnly": true
          },
          "brokers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "node_id": {
                  "type": "integer",
                  "format": "int64"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "starting",
                    "running",
                    "down"
                  ]
                },
                "hostname": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "disk_used_bytes": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "int64"
                },
                "under_replicated_partitions": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "int64"
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "type": "string"
                      }
                    }
                  }
                },
                "last_seen_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                }
              }
            },
            "description": "The cluster's brokers, with their addresses on your networks and their last reported health. All brokers have the same role.",
            "readOnly": true
          },
          "topics": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "partitions": {
                  "type": "integer",
                  "format": "int64"
                },
                "replication_factor": {
                  "type": "integer",
                  "format": "int64"
                },
                "retention_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "retention_ms": {
                  "type": "integer",
                  "format": "int64"
                },
                "cleanup_policy": {
                  "type": "string",
                  "enum": [
                    "delete",
                    "compact",
                    "compact_delete"
                  ]
                },
                "max_message_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "budget_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "created_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                },
                "updated_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                }
              }
            },
            "description": "The cluster's topics. Add a topic via [Create a Kafka topic](/docs/cloud/api/kafka-topics/create-kafka-topic/).",
            "readOnly": true
          },
          "users": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "username": {
                  "type": "string"
                },
                "default_user": {
                  "type": "boolean"
                },
                "privileges": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "topic_pattern": {
                        "type": "string"
                      },
                      "permission": {
                        "type": "string",
                        "enum": [
                          "consume",
                          "produce",
                          "produce_consume"
                        ]
                      }
                    }
                  }
                },
                "created_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                },
                "updated_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                }
              }
            },
            "description": "The cluster's users. Add a user via [Create a Kafka user](/docs/cloud/api/kafka-users/create-kafka-user/). Get a user's password via [Get a Kafka user's credentials](/docs/cloud/api/kafka-users/credentials-kafka-user/).",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of your networks attached to every broker. Order doesn't matter."
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to every broker. A cluster can have one firewall. Order doesn't matter."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the cluster.",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "KafkaDocument": {
        "$ref": "#/components/schemas/Kafka"
      },
      "KafkaEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "kafka_id": {
            "type": "string",
            "description": "The ID of the Kafka cluster.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `topic_created`. Events cover the cluster, its brokers, topics and users.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The Better Stack ID of the user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who or what did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event, such as the broker ID, topic or username. The keys depend on `action`.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When it happened. A change you requested shows when we accepted it.",
            "readOnly": true
          }
        }
      },
      "KafkaEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KafkaEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KafkaList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Kafka"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KafkaTopic": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The topic's ID, a UUID. Get, update and delete a topic by this ID, never by its name.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9._-]+$",
            "description": "The topic's name, unique in the cluster, 1–249 letters, digits, dots, hyphens and underscores. Can't be `.` or `..` or start with `__`."
          },
          "partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions, at least 1. All topics together must fit within the cluster type's `max_partitions`."
          },
          "replication_factor": {
            "type": "integer",
            "format": "int64",
            "description": "The number of copies of each partition, the same as the cluster's number of brokers.",
            "readOnly": true
          },
          "retention_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The most data to keep in each partition, in bytes, at least 1048576."
          },
          "retention_ms": {
            "type": "integer",
            "format": "int64",
            "description": "How long to keep messages, in milliseconds, at least 60000. `-1` keeps them with no time limit, and `retention_bytes` still limits their size."
          },
          "cleanup_policy": {
            "type": "string",
            "enum": [
              "delete",
              "compact",
              "compact_delete"
            ],
            "description": "How Kafka removes old messages.",
            "x-enum-descriptions": {
              "delete": "Deletes messages older than the retention time or past the retention size.",
              "compact": "Keeps only the latest message for each key.",
              "compact_delete": "Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`."
            }
          },
          "max_message_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The largest message the topic accepts, in bytes, from 1024 to 8388608."
          },
          "budget_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The most disk space the topic can use on each broker, in bytes. The budget is `partitions` times `retention_bytes`, plus one segment for each partition.",
            "readOnly": true
          },
          "created_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the topic was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the topic was last updated.",
            "readOnly": true
          }
        }
      },
      "KafkaTopicDocument": {
        "$ref": "#/components/schemas/KafkaTopic"
      },
      "KafkaTopicList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KafkaTopic"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KafkaTopicUpdate": {
        "$ref": "#/components/schemas/KafkaTopicUpdateAttributes"
      },
      "KafkaTopicUpdateAttributes": {
        "type": "object",
        "properties": {
          "partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The number of partitions, at least 1. All topics together must fit within the cluster type's `max_partitions`. On update, you can only increase it."
          },
          "retention_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The most data to keep in each partition, in bytes, at least 1048576. All topics together, plus one segment for each partition, must fit in the cluster's storage budget."
          },
          "retention_ms": {
            "type": "integer",
            "format": "int64",
            "description": "How long to keep messages, in milliseconds, at least 60000. `-1` keeps them with no time limit, and `retention_bytes` still limits their size."
          },
          "cleanup_policy": {
            "type": "string",
            "enum": [
              "delete",
              "compact",
              "compact_delete"
            ],
            "description": "How Kafka removes old messages.",
            "x-enum-descriptions": {
              "delete": "Deletes messages older than the retention time or past the retention size.",
              "compact": "Keeps only the latest message for each key.",
              "compact_delete": "Keeps only the latest message for each key, and also deletes messages past retention. Kafka calls it `compact,delete`."
            }
          },
          "max_message_bytes": {
            "type": "integer",
            "format": "int64",
            "description": "The largest message the topic accepts, in bytes, from 1024 to 8388608."
          }
        }
      },
      "KafkaType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `KA1`. Send it as `type` when you create or rescale a cluster.",
            "readOnly": true
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The storage for your topics on each broker, in GiB. Every broker stores every partition, so this is also the cluster's storage for topics.",
            "readOnly": true
          },
          "max_partitions": {
            "type": "integer",
            "format": "int64",
            "description": "The most partitions a cluster of this type can have across all its topics.",
            "readOnly": true
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of vCPUs of each broker.",
            "readOnly": true
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The RAM of each broker, in GiB.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "We offer the type.",
              "unavailable": "The type is deprecated. Clusters that have it keep running, but you can't create or rescale a cluster to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "readOnly": true
          }
        }
      },
      "KafkaTypeDocument": {
        "$ref": "#/components/schemas/KafkaType"
      },
      "KafkaTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KafkaType"
            }
          }
        }
      },
      "KafkaUpdate": {
        "$ref": "#/components/schemas/KafkaUpdateAttributes"
      },
      "KafkaUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The cluster's name, at most 255 characters. Must be unique among your organization's clusters that aren't `failed` or `destroyed`."
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the cluster also has public endpoints. Clients connect with TLS and SCRAM on both the private and the public endpoints."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. A change applies at once, from `monthly` to `annual` or back. Billing ends the current term and starts the new one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag."
          }
        }
      },
      "KafkaUser": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The user's ID, a UUID. Requests for one user use this ID, never the `username`.",
            "readOnly": true
          },
          "username": {
            "type": "string",
            "pattern": "^[a-z0-9][a-z0-9_-]*$",
            "description": "The name clients sign in with, unique in the cluster, up to 64 lowercase letters, digits, hyphens and underscores, starting with a letter or digit. Can't start with `betterstack`."
          },
          "default_user": {
            "type": "boolean",
            "description": "Whether this is the cluster's `default` user, which every cluster comes with. You can't delete the `default` user, but you can change its privileges.",
            "readOnly": true
          },
          "privileges": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "topic_pattern": {
                  "type": "string",
                  "pattern": "^[a-zA-Z0-9._-]*\\*?$",
                  "description": "A topic name, or a prefix followed by a trailing `*`, made of letters, digits, dots, hyphens and underscores, up to 249 characters. `*` alone matches every topic."
                },
                "permission": {
                  "type": "string",
                  "enum": [
                    "consume",
                    "produce",
                    "produce_consume"
                  ],
                  "description": "What the user can do on the matching topics.\n\n- `consume`: Read and describe the matching topics, and join consumer groups.\n- `produce`: Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.\n- `produce_consume`: Both `consume` and `produce`.",
                  "x-enum-descriptions": {
                    "consume": "Read and describe the matching topics, and join consumer groups.",
                    "produce": "Write and describe the matching topics, and use transactions and the `enable.idempotence` producer setting.",
                    "produce_consume": "Both `consume` and `produce`."
                  }
                }
              },
              "required": [
                "topic_pattern",
                "permission"
              ]
            },
            "description": "The topics the user can use and what it can do on them, up to 25 entries. A user with no privileges has an empty list."
          },
          "created_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the user was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the user was last updated.",
            "readOnly": true
          }
        }
      },
      "KafkaUserDocument": {
        "$ref": "#/components/schemas/KafkaUser"
      },
      "KafkaUserList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KafkaUser"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KafkaVersion": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The version as major and minor number, such as `4.4`. We pick the patch release and apply patch updates automatically.",
            "readOnly": true,
            "examples": [
              "4.4"
            ]
          },
          "latest": {
            "type": "boolean",
            "description": "Whether new clusters get this version by default.",
            "readOnly": true
          }
        }
      },
      "KafkaVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KafkaVersion"
            }
          }
        }
      },
      "KubernetesCluster": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The cluster's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The cluster's name, up to 255 characters."
          },
          "version": {
            "type": "string",
            "description": "The Kubernetes version as major and minor number, such as `1.36`. Defaults to the newest version."
          },
          "patch_version": {
            "type": [
              "string",
              "null"
            ],
            "description": "The exact Kubernetes build we installed for `version`, such as `v1.37.2+k3s1`.",
            "readOnly": true
          },
          "available_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the cluster to now. Holds the next minor version once we offer it.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The state of the cluster's control plane. The cluster is ready when it's `running` and every node pool has `node_count` workers that are all `ready`.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the control plane and the workers.",
              "running": "The control plane works. Check `node_pools` to see whether the workers are ready.",
              "degraded": "The control plane or some workers aren't healthy. `status_message` says which.",
              "upgrading": "We're upgrading the control plane and then the workers.",
              "restoring": "We're restoring the control plane from a snapshot.",
              "failed": "We couldn't create the cluster. `status_message` says why.",
              "destroyed": "The cluster is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "What went wrong while creating, scaling or running the cluster, or `null`.",
            "readOnly": true
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The host name of the Kubernetes API."
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port of the Kubernetes API, always `6443`."
              },
              "api_allowed_cidrs": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IP ranges allowed to reach the cluster's Kubernetes API, as 1 to 50 IPv4 or IPv6 CIDRs."
              }
            },
            "description": "Where to reach the cluster's Kubernetes API, and from which IP ranges.",
            "readOnly": true
          },
          "pod_cidr": {
            "type": "string",
            "description": "The IPv4 range for pods.",
            "default": "10.42.0.0/16"
          },
          "service_cidr": {
            "type": "string",
            "description": "The IPv4 range for Kubernetes services.",
            "default": "10.43.0.0/16"
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers were ready when we last checked.",
            "readOnly": true
          },
          "nodes_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the cluster has now. Each node pool's `node_count` says how many it should have.",
            "readOnly": true
          },
          "node_pools": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node pool's ID, a UUID."
                },
                "name": {
                  "type": "string",
                  "description": "The node pool's name."
                },
                "server_type": {
                  "type": "string",
                  "description": "The server type of the workers."
                },
                "node_count": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers the node pool should have."
                },
                "labels": {
                  "type": "object",
                  "additionalProperties": true,
                  "description": "The Kubernetes labels of the workers, as string pairs."
                },
                "taints": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "key": {
                        "type": "string",
                        "description": "The taint's key."
                      },
                      "value": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "description": "The taint's value, or `null` when the taint has none."
                      },
                      "effect": {
                        "type": "string",
                        "enum": [
                          "NoSchedule",
                          "PreferNoSchedule",
                          "NoExecute"
                        ],
                        "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                      }
                    },
                    "required": [
                      "key",
                      "effect"
                    ]
                  },
                  "description": "The Kubernetes taints of the workers."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "active",
                    "scaling",
                    "deleting",
                    "destroyed"
                  ],
                  "description": "The node pool's state. A node pool that's `active` can still have workers that aren't ready."
                },
                "status_message": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "Why the node pool has fewer workers than `node_count`, or `null`."
                },
                "nodes_ready": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How many workers of the node pool are `ready`."
                },
                "scaling": {
                  "type": [
                    "object",
                    "null"
                  ],
                  "properties": {
                    "from": {
                      "type": [
                        "integer",
                        "null"
                      ],
                      "format": "int64",
                      "description": "The number of workers before the change."
                    },
                    "to": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The `node_count` to reach."
                    },
                    "started_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When the change started."
                    },
                    "estimated_ready_at": {
                      "type": "string",
                      "format": "date-time",
                      "description": "When we expect the change to be done."
                    }
                  },
                  "description": "How a change of size is going while the node pool is `scaling`, or `null` otherwise."
                },
                "nodes": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "description": "The worker's ID."
                      },
                      "name": {
                        "type": "string",
                        "description": "The worker's name in Kubernetes."
                      },
                      "server_id": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "description": "The ID of the server that runs the worker, or `null` while the worker is `queued`."
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "queued",
                          "provisioning",
                          "joining",
                          "ready",
                          "not_ready",
                          "draining",
                          "replacing",
                          "destroyed"
                        ],
                        "description": "The worker's state."
                      },
                      "version": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "description": "The Kubernetes version the worker reports."
                      },
                      "last_seen_at": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "format": "date-time",
                        "description": "When we last saw the worker ready."
                      }
                    }
                  },
                  "description": "The node pool's workers."
                }
              }
            },
            "description": "The cluster's node pools, each with its workers. Deleted node pools aren't listed.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the cluster. The list is empty while the cluster has no workers. Order doesn't matter."
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to the workers. The list is empty while the cluster has no workers. Order doesn't matter."
          },
          "kubeconfig_rotated_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the admin credentials of the kubeconfig were first issued or last rotated, or `null` before they're issued.",
            "readOnly": true
          },
          "latest_snapshot_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the newest `available` snapshot of the control plane was created, or `null` when there is none.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the cluster was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the cluster. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "KubernetesClusterDocument": {
        "$ref": "#/components/schemas/KubernetesCluster"
      },
      "KubernetesClusterList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesCluster"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KubernetesEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the Kubernetes cluster.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `node_pool_scaled`, `node_replaced`, `upgrade_aborted` or `restore_failed`.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The Better Stack ID of the user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": [
              "string",
              "null"
            ],
            "description": "Who did it, `user` for a person, `api_token` for an API token and `system` for Better Stack.",
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event, such as a `snapshot_id`, a `reason`, a `node_pool` or the name of a replacement worker.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When it happened.",
            "readOnly": true
          }
        }
      },
      "KubernetesEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KubernetesNodePool": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The node pool's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
            "description": "The node pool's name, unique among the cluster's node pools."
          },
          "server_type": {
            "type": "string",
            "description": "The server type of the workers.",
            "examples": [
              "AM2"
            ]
          },
          "node_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers the node pool should have, from 0 to 100. The node pools of a cluster can have 100 workers in total. `nodes` lists the workers the node pool has now.",
            "default": 1
          },
          "labels": {
            "type": "object",
            "additionalProperties": true,
            "description": "The Kubernetes labels of the workers, as string pairs, or an empty object when there are none."
          },
          "taints": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "description": "The taint's key."
                },
                "value": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "The taint's value, or `null` when the taint has none."
                },
                "effect": {
                  "type": "string",
                  "enum": [
                    "NoSchedule",
                    "PreferNoSchedule",
                    "NoExecute"
                  ],
                  "description": "What the taint does to pods that don't tolerate it, as in Kubernetes."
                }
              },
              "required": [
                "key",
                "effect"
              ]
            },
            "description": "The Kubernetes taints of the workers, or an empty list when there are none."
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "scaling",
              "deleting",
              "destroyed"
            ],
            "description": "The node pool's state. The node pool is ready when the cluster is `running` and every worker of the node pool is `ready`.",
            "x-enum-descriptions": {
              "active": "The node pool isn't changing size. The node pool's workers can still be joining or being replaced.",
              "scaling": "We're adding or removing workers to reach `node_count`. Scaling happens after you change `node_count`, or when the node pool has more or fewer workers than `node_count`.",
              "deleting": "We're removing the node pool.",
              "destroyed": "The node pool is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the node pool has fewer workers than `node_count`, such as a quota limit, no capacity for the server type in the zone, or a server we couldn't create. `null` again once the node pool reaches `node_count`.",
            "readOnly": true
          },
          "nodes_ready": {
            "type": "integer",
            "format": "int64",
            "description": "How many workers of the node pool are `ready`.",
            "readOnly": true
          },
          "scaling": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "from": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "The number of workers before the change."
              },
              "to": {
                "type": "integer",
                "format": "int64",
                "description": "The `node_count` to reach."
              },
              "started_at": {
                "type": "string",
                "format": "date-time",
                "description": "When the change started."
              },
              "estimated_ready_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we expect the change to be done."
              }
            },
            "description": "How a change of size is going while `status` is `scaling`, or `null` otherwise.",
            "readOnly": true
          },
          "nodes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The worker's ID. Use it to recycle the worker."
                },
                "name": {
                  "type": "string",
                  "description": "The worker's name in Kubernetes."
                },
                "server_id": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "The ID of the server that runs the worker, or `null` while the worker is `queued`."
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "queued",
                    "provisioning",
                    "joining",
                    "ready",
                    "not_ready",
                    "draining",
                    "replacing",
                    "destroyed"
                  ],
                  "description": "The worker's state.\n\n- `queued`: We'll create the worker.\n- `provisioning`: We're creating the worker's server.\n- `joining`: The worker is joining the cluster.\n- `ready`: The worker is ready in Kubernetes.\n- `not_ready`: The worker joined, but Kubernetes reports it as not ready.\n- `draining`: We're moving pods off the worker before we remove it.\n- `replacing`: We're creating a new worker to replace this one.\n- `destroyed`: The worker is removed.",
                  "x-enum-descriptions": {
                    "queued": "We'll create the worker.",
                    "provisioning": "We're creating the worker's server.",
                    "joining": "The worker is joining the cluster.",
                    "ready": "The worker is ready in Kubernetes.",
                    "not_ready": "The worker joined, but Kubernetes reports it as not ready.",
                    "draining": "We're moving pods off the worker before we remove it.",
                    "replacing": "We're creating a new worker to replace this one.",
                    "destroyed": "The worker is removed."
                  }
                },
                "version": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "The Kubernetes version the worker reports."
                },
                "last_seen_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time",
                  "description": "When we last saw the worker ready."
                }
              }
            },
            "description": "The node pool's workers. New workers show up at once as `queued`, then go through `provisioning` and `joining` to `ready`.",
            "readOnly": true
          }
        }
      },
      "KubernetesNodePoolDocument": {
        "$ref": "#/components/schemas/KubernetesNodePool"
      },
      "KubernetesNodePoolList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesNodePool"
            }
          }
        }
      },
      "KubernetesScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the cluster's control plane.",
            "readOnly": true
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often to create a snapshot. A monthly schedule runs on the same day each month."
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "KubernetesScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/KubernetesScheduledSnapshotCreateAttributes"
      },
      "KubernetesScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often to create a snapshot. A monthly schedule runs on the same day each month."
          }
        },
        "required": [
          "frequency"
        ]
      },
      "KubernetesScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/KubernetesScheduledSnapshot"
      },
      "KubernetesScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesScheduledSnapshot"
            }
          }
        }
      },
      "KubernetesScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/KubernetesScheduledSnapshotUpdateAttributes"
      },
      "KubernetesScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often to create a snapshot. A monthly schedule runs on the same day each month."
          }
        }
      },
      "KubernetesSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name, at most 255 characters."
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that runs the cluster's control plane. You can't change that server directly.",
            "readOnly": true
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot, or we created it before an upgrade.",
              "scheduled": "A snapshot schedule created it."
            },
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. To follow a new snapshot, use [List Kubernetes snapshots](/docs/cloud/api/kubernetes-snapshots/list-kubernetes-snapshots/) until the snapshot is no longer `pending`.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the control plane's disk when the snapshot was taken, in bytes. We bill this size. Stays `null` until the snapshot is ready.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The zone the snapshot was taken in, which is the cluster's zone.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the snapshot failed, or `null` unless the snapshot failed.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ]
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "locked_at": {
                "type": "string",
                "format": "date-time"
              }
            },
            "description": "The lock we put on the snapshot, such as for non-payment, or `null` when it isn't locked.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "The snapshot's tags, as string pairs. You can't set them on a Kubernetes snapshot.",
            "readOnly": true
          }
        }
      },
      "KubernetesSnapshotCreate": {
        "$ref": "#/components/schemas/KubernetesSnapshotCreateAttributes"
      },
      "KubernetesSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name, at most 255 characters. Defaults to the cluster's name followed by the date and time, such as `prod-20261124-093000`."
          }
        }
      },
      "KubernetesSnapshotDocument": {
        "$ref": "#/components/schemas/KubernetesSnapshot"
      },
      "KubernetesSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "KubernetesVersion": {
        "type": "object",
        "properties": {
          "version": {
            "type": "string",
            "description": "The Kubernetes minor version, such as `1.37`. Send it as `version` when you create a cluster.",
            "readOnly": true,
            "examples": [
              "1.37"
            ]
          },
          "build": {
            "type": "string",
            "description": "The exact Kubernetes build we install for this version, such as `v1.37.2+k3s1`.",
            "readOnly": true
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new cluster gets this version when you leave out `version`.",
            "readOnly": true
          }
        }
      },
      "KubernetesVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KubernetesVersion"
            }
          }
        }
      },
      "LoadBalancer": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The load balancer's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The load balancer's name. Must be unique among your organization's load balancers that aren't `failed` or `destroyed`."
          },
          "type": {
            "type": "string",
            "description": "The load balancer's type, such as `LB1`. Get the types via [List load balancer types](/docs/cloud/api/load-balancer-types/list-load-balancer-types/).",
            "examples": [
              "LB1"
            ]
          },
          "algorithm": {
            "type": "string",
            "enum": [
              "round_robin",
              "least_connections",
              "source_ip"
            ],
            "description": "How the load balancer picks a target for each connection.",
            "x-enum-descriptions": {
              "round_robin": "Sends each new connection to the next target in turn.",
              "least_connections": "Sends each new connection to the target with the fewest open connections.",
              "source_ip": "Sends all connections from one client IP to the same target."
            },
            "default": "round_robin"
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "rescaling",
              "failed",
              "destroyed"
            ],
            "description": "The load balancer's state.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the load balancer.",
              "running": "The load balancer is ready. `status_message` reports any problem. `config_applied_at` says when we last applied your configuration.",
              "rescaling": "We're changing the load balancer's type. The load balancer returns to `running` even when we couldn't apply its configuration yet. `status_message` then says why.",
              "failed": "We couldn't create the load balancer. `status_message` says why.",
              "destroyed": "The load balancer is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "What went wrong when we created or configured the load balancer, or what's wrong with it now. `null` when there's nothing to report.",
            "readOnly": true
          },
          "public_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "ip": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                }
              }
            },
            "description": "The load balancer's public IP addresses, one IPv4 and one IPv6.",
            "readOnly": true
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "network_id": {
                  "type": "string"
                },
                "ip_address": {
                  "type": "string"
                }
              }
            },
            "description": "The load balancer's private IP in each attached network.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the networks attached to the load balancer. Order doesn't matter."
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the firewalls attached to the load balancer, at most one. Order doesn't matter."
          },
          "services": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The service's ID."
                },
                "protocol": {
                  "type": "string",
                  "enum": [
                    "tcp",
                    "http",
                    "https",
                    "udp"
                  ],
                  "description": "The protocol the service listens for.\n\n- `tcp`: Forwards TCP connections.\n- `http`: Forwards HTTP requests.\n- `https`: Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests.\n- `udp`: Forwards UDP traffic.",
                  "x-enum-descriptions": {
                    "tcp": "Forwards TCP connections.",
                    "http": "Forwards HTTP requests.",
                    "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests.",
                    "udp": "Forwards UDP traffic."
                  }
                },
                "listen_port": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The port the service listens on."
                },
                "destination_port": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The port on the targets that traffic goes to."
                },
                "redirect_http": {
                  "type": "boolean",
                  "description": "Whether HTTP requests are redirected to this HTTPS service."
                },
                "http_timeout_seconds": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds."
                },
                "sticky_sessions": {
                  "type": "boolean",
                  "description": "Whether a cookie sends each client to the same target."
                },
                "sticky_cookie_name": {
                  "type": "string",
                  "description": "The name of the sticky session cookie."
                },
                "sticky_cookie_lifetime_seconds": {
                  "type": "integer",
                  "format": "int64",
                  "description": "How long the sticky session cookie lasts, in seconds."
                },
                "proxy_protocol": {
                  "type": "string",
                  "enum": [
                    "disabled",
                    "v1",
                    "v2"
                  ],
                  "description": "The PROXY protocol version the targets accept, or `disabled`."
                },
                "certificate_ids": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "The IDs of the certificates the service presents."
                },
                "target_health": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "service_id": {
                        "type": "integer",
                        "format": "int64",
                        "description": "The ID of the service."
                      },
                      "server_id": {
                        "type": "string",
                        "description": "The ID of the target server."
                      },
                      "state": {
                        "type": "string",
                        "enum": [
                          "up",
                          "down",
                          "unknown"
                        ],
                        "description": "Whether the target is healthy.\n\n- `up`: The target passes its checks.\n- `down`: The target fails its checks.\n- `unknown`: We have no result for the target yet.",
                        "x-enum-descriptions": {
                          "up": "The target passes its checks.",
                          "down": "The target fails its checks.",
                          "unknown": "We have no result for the target yet."
                        }
                      },
                      "state_changed_at": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "format": "date-time",
                        "description": "When `state` last changed, or `null`."
                      },
                      "status_message": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "description": "Why the target is down, or `null`."
                      }
                    }
                  },
                  "description": "The latest health of each target, updated about every 30 seconds."
                },
                "health_check": {
                  "type": "object",
                  "properties": {
                    "protocol": {
                      "type": "string",
                      "enum": [
                        "tcp",
                        "http"
                      ],
                      "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection.\n- `http`: Sends an HTTP request to the target.",
                      "x-enum-descriptions": {
                        "tcp": "Checks that the target accepts a TCP connection.",
                        "http": "Sends an HTTP request to the target."
                      }
                    },
                    "port": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The port we check."
                    },
                    "interval_seconds": {
                      "type": "integer",
                      "format": "int64",
                      "description": "How often we check each target, in seconds."
                    },
                    "timeout_seconds": {
                      "type": "integer",
                      "format": "int64",
                      "description": "The check timeout in seconds."
                    },
                    "retries": {
                      "type": "integer",
                      "format": "int64",
                      "description": "How many checks in a row must fail before a target is down."
                    },
                    "domain": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "The hostname we send in the `Host` header of an HTTP check."
                    },
                    "path": {
                      "type": "string",
                      "description": "The path an HTTP check requests."
                    },
                    "response": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "Text the response must contain."
                    },
                    "status_codes": {
                      "type": "string",
                      "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
                    },
                    "tls": {
                      "type": "boolean",
                      "description": "Whether checks connect with TLS."
                    }
                  },
                  "description": "How the service checks that its targets are healthy."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the service was created."
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the service was last updated."
                }
              }
            },
            "description": "The services that listen for traffic, with their settings and the latest health of each target. Add a service via [Create a load balancer service](/docs/cloud/api/load-balancer-services/create-load-balancer-service/).",
            "readOnly": true
          },
          "targets": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The target's ID."
                },
                "type": {
                  "type": "string",
                  "enum": [
                    "server",
                    "label_selector"
                  ],
                  "description": "What the target points at.\n\n- `server`: One server, in `server_id`.\n- `label_selector`: Every server that has the tags in `selector`.",
                  "x-enum-descriptions": {
                    "server": "One server, in `server_id`.",
                    "label_selector": "Every server that has the tags in `selector`."
                  }
                },
                "server_id": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "The ID of the server to send traffic to."
                },
                "selector": {
                  "type": [
                    "object",
                    "null"
                  ],
                  "additionalProperties": true,
                  "description": "The tags a server must have to receive traffic, as string pairs. A server must have every pair."
                },
                "use_private_ip": {
                  "type": "boolean",
                  "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the target was added."
                },
                "updated_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the target was last updated."
                }
              }
            },
            "description": "The targets that receive the traffic. A `label_selector` target is one entry, however many servers match it.",
            "readOnly": true
          },
          "config_applied_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When we last applied the configuration to the load balancer, or `null` until we first apply it.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the load balancer was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the load balancer was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the load balancer.",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "LoadBalancerDocument": {
        "$ref": "#/components/schemas/LoadBalancer"
      },
      "LoadBalancerEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "load_balancer_id": {
            "type": "string",
            "description": "The ID of the load balancer the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, `created`, `rescaled` or `destroyed`. The event is recorded when we accept the request, before the change is done.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who did it, or `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event. The keys depend on `action`.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "LoadBalancerEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoadBalancerEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "LoadBalancerList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoadBalancer"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "LoadBalancerService": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "description": "The service's ID.",
            "format": "int64",
            "readOnly": true
          },
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "http",
              "https",
              "udp"
            ],
            "description": "The protocol the service listens for.",
            "x-enum-descriptions": {
              "tcp": "Forwards TCP connections.",
              "http": "Forwards HTTP requests.",
              "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.",
              "udp": "Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`."
            }
          },
          "listen_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port the service listens on, 1–65535. Can't be `8402` or `9901`, which the load balancer uses itself. A `tcp` and a `udp` service can use the same port.",
            "examples": [
              80
            ]
          },
          "destination_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port on the targets that traffic goes to, 1–65535.",
            "examples": [
              8080
            ]
          },
          "redirect_http": {
            "type": "boolean",
            "description": "Whether HTTP requests are redirected to this HTTPS service. Only `https` services can redirect.",
            "default": false
          },
          "http_timeout_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds, 5–600. Only `http` and `https` services use it.",
            "default": 50
          },
          "sticky_sessions": {
            "type": "boolean",
            "description": "Whether a cookie sends each client to the same target. Only `http` and `https` services can use sticky sessions.",
            "default": false
          },
          "sticky_cookie_name": {
            "type": "string",
            "description": "The name of the sticky session cookie, 1–64 letters, digits, underscores, dots or hyphens."
          },
          "sticky_cookie_lifetime_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the sticky session cookie lasts, 1–86400 seconds.",
            "default": 300
          },
          "proxy_protocol": {
            "type": "string",
            "enum": [
              "disabled",
              "v1",
              "v2"
            ],
            "description": "The PROXY protocol version the targets accept, or `disabled`. A `udp` service can't use it.",
            "default": "disabled"
          },
          "certificate_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the certificates the service presents. Get them via [List certificates](/docs/cloud/api/certificates/list-certificates/)."
          },
          "health_check": {
            "type": "object",
            "properties": {
              "protocol": {
                "type": "string",
                "enum": [
                  "tcp",
                  "http"
                ],
                "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.\n- `http`: Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`.",
                "x-enum-descriptions": {
                  "tcp": "Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.",
                  "http": "Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`."
                }
              },
              "port": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "The port we check, 1–65535. Defaults to `destination_port`."
              },
              "interval_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "How often we check each target, 2–3600 seconds."
              },
              "timeout_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "The check timeout in seconds, 1–60."
              },
              "retries": {
                "type": "integer",
                "format": "int64",
                "description": "How many checks in a row must fail before a target is down, 1–10."
              },
              "domain": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname we send in the `Host` header of an HTTP check."
              },
              "path": {
                "type": "string",
                "description": "The path an HTTP check requests, starting with `/`, with no spaces or quotes."
              },
              "response": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Text the response must contain, at most 255 characters with no line breaks or quotes."
              },
              "status_codes": {
                "type": "string",
                "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
              },
              "tls": {
                "type": "boolean",
                "description": "Whether checks connect with TLS."
              }
            },
            "description": "How the service checks that its targets are healthy."
          },
          "target_health": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "service_id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The ID of the service."
                },
                "server_id": {
                  "type": "string",
                  "description": "The ID of the target server."
                },
                "state": {
                  "type": "string",
                  "enum": [
                    "up",
                    "down",
                    "unknown"
                  ],
                  "description": "Whether the target is healthy.\n\n- `up`: The target passes its checks.\n- `down`: The target fails its checks.\n- `unknown`: We have no result for the target yet.",
                  "x-enum-descriptions": {
                    "up": "The target passes its checks.",
                    "down": "The target fails its checks.",
                    "unknown": "We have no result for the target yet."
                  }
                },
                "state_changed_at": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time",
                  "description": "When `state` last changed, or `null`."
                },
                "status_message": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "Why the target is down, or `null`."
                }
              }
            },
            "description": "The latest health of each target, updated about every 30 seconds.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the service was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the service was last updated.",
            "readOnly": true
          }
        }
      },
      "LoadBalancerServiceCreate": {
        "$ref": "#/components/schemas/LoadBalancerServiceCreateAttributes"
      },
      "LoadBalancerServiceCreateAttributes": {
        "type": "object",
        "properties": {
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "http",
              "https",
              "udp"
            ],
            "description": "The protocol the service listens for.",
            "x-enum-descriptions": {
              "tcp": "Forwards TCP connections.",
              "http": "Forwards HTTP requests.",
              "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.",
              "udp": "Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`."
            }
          },
          "listen_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port the service listens on, 1–65535. Can't be `8402` or `9901`, which the load balancer uses itself. A `tcp` and a `udp` service can use the same port.",
            "examples": [
              80
            ]
          },
          "destination_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port on the targets that traffic goes to, 1–65535.",
            "examples": [
              8080
            ]
          },
          "redirect_http": {
            "type": "boolean",
            "description": "Whether HTTP requests are redirected to this HTTPS service. Only `https` services can redirect.",
            "default": false
          },
          "http_timeout_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds, 5–600. Only `http` and `https` services use it.",
            "default": 50
          },
          "sticky_sessions": {
            "type": "boolean",
            "description": "Whether a cookie sends each client to the same target. Only `http` and `https` services can use sticky sessions.",
            "default": false
          },
          "sticky_cookie_name": {
            "type": "string",
            "description": "The name of the sticky session cookie, 1–64 letters, digits, underscores, dots or hyphens. Defaults to `BSLBSTICKY`."
          },
          "sticky_cookie_lifetime_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the sticky session cookie lasts, 1–86400 seconds.",
            "default": 300
          },
          "proxy_protocol": {
            "type": "string",
            "enum": [
              "disabled",
              "v1",
              "v2"
            ],
            "description": "The PROXY protocol version the targets accept, or `disabled`. A `udp` service can't use it.",
            "default": "disabled"
          },
          "certificate_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the certificates the service presents. Get them via [List certificates](/docs/cloud/api/certificates/list-certificates/). Each certificate must be in the load balancer's team. An `https` service requires at least one certificate. An update replaces the whole list."
          },
          "health_check": {
            "type": "object",
            "properties": {
              "protocol": {
                "type": "string",
                "enum": [
                  "tcp",
                  "http"
                ],
                "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.\n- `http`: Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`.",
                "x-enum-descriptions": {
                  "tcp": "Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.",
                  "http": "Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`."
                }
              },
              "port": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "The port we check, 1–65535. Defaults to `destination_port`."
              },
              "interval_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "How often we check each target, 2–3600 seconds."
              },
              "timeout_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "The check timeout in seconds, 1–60."
              },
              "retries": {
                "type": "integer",
                "format": "int64",
                "description": "How many checks in a row must fail before a target is down, 1–10."
              },
              "domain": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname we send in the `Host` header of an HTTP check."
              },
              "path": {
                "type": "string",
                "description": "The path an HTTP check requests, starting with `/`, with no spaces or quotes."
              },
              "response": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Text the response must contain, at most 255 characters with no line breaks or quotes."
              },
              "status_codes": {
                "type": "string",
                "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
              },
              "tls": {
                "type": "boolean",
                "description": "Whether checks connect with TLS."
              }
            },
            "description": "How the service checks that its targets are healthy. An update changes only the health check fields you send."
          }
        },
        "required": [
          "protocol",
          "listen_port",
          "destination_port"
        ]
      },
      "LoadBalancerServiceDocument": {
        "$ref": "#/components/schemas/LoadBalancerService"
      },
      "LoadBalancerServiceList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoadBalancerService"
            }
          }
        }
      },
      "LoadBalancerServiceUpdate": {
        "$ref": "#/components/schemas/LoadBalancerServiceUpdateAttributes"
      },
      "LoadBalancerServiceUpdateAttributes": {
        "type": "object",
        "properties": {
          "protocol": {
            "type": "string",
            "enum": [
              "tcp",
              "http",
              "https",
              "udp"
            ],
            "description": "The protocol the service listens for.",
            "x-enum-descriptions": {
              "tcp": "Forwards TCP connections.",
              "http": "Forwards HTTP requests.",
              "https": "Decrypts HTTPS traffic with the service's certificates and forwards HTTP requests. An `https` service requires at least one certificate in `certificate_ids`.",
              "udp": "Forwards UDP traffic. A `udp` service can't use certificates, `sticky_sessions`, `redirect_http` or `proxy_protocol`."
            }
          },
          "listen_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port the service listens on, 1–65535. Can't be `8402` or `9901`, which the load balancer uses itself. A `tcp` and a `udp` service can use the same port.",
            "examples": [
              80
            ]
          },
          "destination_port": {
            "type": "integer",
            "format": "int64",
            "description": "The port on the targets that traffic goes to, 1–65535.",
            "examples": [
              8080
            ]
          },
          "redirect_http": {
            "type": "boolean",
            "description": "Whether HTTP requests are redirected to this HTTPS service. Only `https` services can redirect.",
            "default": false
          },
          "http_timeout_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the service waits for a client or a target to send data during an HTTP request, in seconds, 5–600. Only `http` and `https` services use it.",
            "default": 50
          },
          "sticky_sessions": {
            "type": "boolean",
            "description": "Whether a cookie sends each client to the same target. Only `http` and `https` services can use sticky sessions.",
            "default": false
          },
          "sticky_cookie_name": {
            "type": "string",
            "description": "The name of the sticky session cookie, 1–64 letters, digits, underscores, dots or hyphens. Defaults to `BSLBSTICKY`."
          },
          "sticky_cookie_lifetime_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long the sticky session cookie lasts, 1–86400 seconds.",
            "default": 300
          },
          "proxy_protocol": {
            "type": "string",
            "enum": [
              "disabled",
              "v1",
              "v2"
            ],
            "description": "The PROXY protocol version the targets accept, or `disabled`. A `udp` service can't use it.",
            "default": "disabled"
          },
          "certificate_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the certificates the service presents. Get them via [List certificates](/docs/cloud/api/certificates/list-certificates/). Each certificate must be in the load balancer's team. An `https` service requires at least one certificate. An update replaces the whole list."
          },
          "health_check": {
            "type": "object",
            "properties": {
              "protocol": {
                "type": "string",
                "enum": [
                  "tcp",
                  "http"
                ],
                "description": "How we check the targets.\n\n- `tcp`: Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.\n- `http`: Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`.",
                "x-enum-descriptions": {
                  "tcp": "Checks that the target accepts a TCP connection. The default for `tcp` and `udp` services.",
                  "http": "Sends an HTTP request to the target. The default for `http` and `https` services. On a `tcp` or `udp` service, an `http` check needs its own `port`, different from `destination_port`."
                }
              },
              "port": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "The port we check, 1–65535. Defaults to `destination_port`."
              },
              "interval_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "How often we check each target, 2–3600 seconds."
              },
              "timeout_seconds": {
                "type": "integer",
                "format": "int64",
                "description": "The check timeout in seconds, 1–60."
              },
              "retries": {
                "type": "integer",
                "format": "int64",
                "description": "How many checks in a row must fail before a target is down, 1–10."
              },
              "domain": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname we send in the `Host` header of an HTTP check."
              },
              "path": {
                "type": "string",
                "description": "The path an HTTP check requests, starting with `/`, with no spaces or quotes."
              },
              "response": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Text the response must contain, at most 255 characters with no line breaks or quotes."
              },
              "status_codes": {
                "type": "string",
                "description": "The status codes that pass, separated by commas. In a pattern, `?` matches one digit and `*` any number of digits."
              },
              "tls": {
                "type": "boolean",
                "description": "Whether checks connect with TLS."
              }
            },
            "description": "How the service checks that its targets are healthy. An update changes only the health check fields you send."
          }
        }
      },
      "LoadBalancerTarget": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "description": "The target's ID.",
            "format": "int64",
            "readOnly": true
          },
          "type": {
            "type": "string",
            "enum": [
              "server",
              "label_selector"
            ],
            "description": "What the target points at.",
            "x-enum-descriptions": {
              "server": "One server. Send `server_id` and leave out `selector`.",
              "label_selector": "Every server that has the tags in `selector`. Send `selector` and leave out `server_id`."
            }
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server to send traffic to."
          },
          "selector": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true,
            "description": "The tags a server must have to receive traffic, as string pairs. A server must have every pair."
          },
          "use_private_ip": {
            "type": "boolean",
            "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP.",
            "default": false
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the target was added.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the target was last updated.",
            "readOnly": true
          }
        }
      },
      "LoadBalancerTargetCreate": {
        "$ref": "#/components/schemas/LoadBalancerTargetCreateAttributes"
      },
      "LoadBalancerTargetCreateAttributes": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "server",
              "label_selector"
            ],
            "description": "What the target points at.",
            "x-enum-descriptions": {
              "server": "One server. Send `server_id` and leave out `selector`.",
              "label_selector": "Every server that has the tags in `selector`. Send `selector` and leave out `server_id`."
            }
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server to send traffic to. The server must be in the load balancer's team. A load balancer can have each server as a target once."
          },
          "selector": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true,
            "description": "The tags a server must have to receive traffic, as string pairs. A server must have every pair. Keys and values can't be empty."
          },
          "use_private_ip": {
            "type": "boolean",
            "description": "Whether to send traffic to the servers' private IP on a network they share with the load balancer, instead of their public IP.",
            "default": false
          }
        },
        "required": [
          "type"
        ]
      },
      "LoadBalancerTargetDocument": {
        "$ref": "#/components/schemas/LoadBalancerTarget"
      },
      "LoadBalancerTargetList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoadBalancerTarget"
            }
          }
        }
      },
      "LoadBalancerType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `LB1`. Send it as `type` when you create or rescale a load balancer.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections a load balancer of this type accepts at once.",
            "readOnly": true
          },
          "max_services": {
            "type": "integer",
            "format": "int64",
            "description": "The most services a load balancer of this type can have.",
            "readOnly": true
          },
          "max_targets": {
            "type": "integer",
            "format": "int64",
            "description": "The most targets a load balancer of this type can have. Each server that a target's tag `selector` matches counts toward the limit.",
            "readOnly": true
          },
          "max_certificates": {
            "type": "integer",
            "format": "int64",
            "description": "The most different certificates a load balancer of this type can present across its services.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Load balancers that have it keep running, but you can't create or rescale a load balancer to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use instead of this deprecated one, or `null` for a type you can order.",
            "readOnly": true
          }
        }
      },
      "LoadBalancerTypeDocument": {
        "$ref": "#/components/schemas/LoadBalancerType"
      },
      "LoadBalancerTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoadBalancerType"
            }
          }
        }
      },
      "LoadBalancerUpdate": {
        "$ref": "#/components/schemas/LoadBalancerUpdateAttributes"
      },
      "LoadBalancerUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The load balancer's name. Must be unique among your organization's load balancers that aren't `failed` or `destroyed`."
          },
          "algorithm": {
            "type": "string",
            "enum": [
              "round_robin",
              "least_connections",
              "source_ip"
            ],
            "description": "How the load balancer picks a target for each connection.",
            "x-enum-descriptions": {
              "round_robin": "Sends each new connection to the next target in turn.",
              "least_connections": "Sends each new connection to the target with the fewest open connections.",
              "source_ip": "Sends all connections from one client IP to the same target."
            },
            "default": "round_robin"
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. A change applies at once, from `monthly` to `annual` or back. Billing ends the current term and starts the new one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag, so an empty object removes every tag."
          }
        }
      },
      "MySQL": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `MY1`, which sets its size. Get the types via [List MySQL types](/docs/cloud/api/mysql-types/list-mysql-types/).",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_mysql_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_disk_gb",
                "max_connections"
              ]
            },
            "examples": [
              "MY1"
            ]
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect to the instance at once.",
            "readOnly": true
          },
          "engine_version": {
            "type": "string",
            "description": "The MySQL version, as major and minor, such as `9.7`. Get the versions via [List MySQL versions](/docs/cloud/api/mysql-versions/list-mysql-versions/).",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_mysql_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "engine_patch_version": {
            "type": [
              "string",
              "null"
            ],
            "description": "The exact MySQL version the instance runs, or `null` until we know it.",
            "readOnly": true
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to. An upgrade can't be undone.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the nodes and installing MySQL.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is almost full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading the instance to a newer MySQL version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "We couldn't create the instance. `status_message` says why. Create a new one instead.",
              "destroyed": "The instance is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "More about the status, such as what failed or which action didn't finish. `null` when there's nothing to report.",
            "readOnly": true
          },
          "sql_mode": {
            "type": [
              "string",
              "null"
            ],
            "description": "The SQL modes, separated by commas, such as `STRICT_TRANS_TABLES,NO_ZERO_DATE`. `null` for MySQL's default modes."
          },
          "sql_require_primary_key": {
            "type": "boolean",
            "description": "Whether new tables must have a primary key.",
            "default": false
          },
          "default_time_zone": {
            "type": "string",
            "description": "The default time zone. Accepts `SYSTEM`, `UTC`, an offset from `-13:59` to `+14:00`, or an IANA time zone name such as `Europe/Prague`.",
            "default": "UTC"
          },
          "max_allowed_packet": {
            "type": "integer",
            "format": "int64",
            "description": "The largest packet MySQL accepts, in bytes, from `16777216` to `1073741824`.",
            "default": 67108864
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is almost full.",
            "readOnly": true
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses."
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port to connect to, `3306`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the instance's primary.",
            "readOnly": true
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ]
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ]
                },
                "replication_lag_seconds": {
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64"
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "type": "string"
                      }
                    }
                  }
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas. A replica's `replication_lag_seconds` says how many seconds the replica is behind the primary. `replication_lag_seconds` is `null` on the primary.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "latest_snapshot_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the newest available snapshot was taken, or `null` when there's none.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "MySQLCreate": {
        "$ref": "#/components/schemas/MySQLCreateAttributes"
      },
      "MySQLCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's MySQL instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `MY1`, which sets its size. Get the types via [List MySQL types](/docs/cloud/api/mysql-types/list-mysql-types/). To change it later, rescale the instance.",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_mysql_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_disk_gb",
                "max_connections"
              ]
            },
            "examples": [
              "MY1"
            ]
          },
          "engine_version": {
            "type": "string",
            "description": "The MySQL version, as major and minor, such as `9.7`. Get the versions via [List MySQL versions](/docs/cloud/api/mysql-versions/list-mysql-versions/). Defaults to the latest version. To change it later, upgrade the instance.",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_mysql_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "sql_mode": {
            "type": [
              "string",
              "null"
            ],
            "description": "The SQL modes, separated by commas, such as `STRICT_TRANS_TABLES,NO_ZERO_DATE`. `null` for MySQL's default modes."
          },
          "sql_require_primary_key": {
            "type": "boolean",
            "description": "Whether new tables must have a primary key.",
            "default": false
          },
          "default_time_zone": {
            "type": "string",
            "description": "The default time zone. Accepts `SYSTEM`, `UTC`, an offset from `-13:59` to `+14:00`, or an IANA time zone name such as `Europe/Prague`.",
            "default": "UTC"
          },
          "max_allowed_packet": {
            "type": "integer",
            "format": "int64",
            "description": "The largest packet MySQL accepts, in bytes, from `16777216` to `1073741824`.",
            "default": 67108864
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Each network must be in the instance's team. To change them later, use [Attach a network to a MySQL instance](/docs/cloud/api/mysqls/attach-mysql-network/) and [Detach a network from a MySQL instance](/docs/cloud/api/mysqls/detach-mysql-network/). Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. To change it later, use [Attach a firewall to a MySQL instance](/docs/cloud/api/mysqls/attach-mysql-firewall/) and [Detach a firewall from a MySQL instance](/docs/cloud/api/mysqls/detach-mysql-firewall/). Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/). Can't be changed after the instance is created.",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "name",
          "type",
          "team_id"
        ]
      },
      "MySQLDocument": {
        "$ref": "#/components/schemas/MySQL"
      },
      "MySQLEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `snapshot_created`.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who made the change, or `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who made the change.",
            "x-enum-descriptions": {
              "user": "A Better Stack user made the change. `user_id` says who.",
              "api_token": "A request with an API token made the change.",
              "system": "Better Stack made the change."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about what happened, such as the new type or version, or the snapshot ID.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "MySQLEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQLEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "MySQLList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQL"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "MySQLScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the schedule belongs to.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's primary. Changes when the instance fails over.",
            "readOnly": true
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` before the first one.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "MySQLScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/MySQLScheduledSnapshotCreateAttributes"
      },
      "MySQLScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        },
        "required": [
          "frequency"
        ]
      },
      "MySQLScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/MySQLScheduledSnapshot"
      },
      "MySQLScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQLScheduledSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "MySQLScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/MySQLScheduledSnapshotUpdateAttributes"
      },
      "MySQLScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        }
      },
      "MySQLSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "mysql_id": {
            "type": "string",
            "description": "The ID of the MySQL instance the snapshot was taken from.",
            "readOnly": true
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that ran the instance's primary when the snapshot was taken, or `null` once that server is removed.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its status is `available`.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. The snapshot is billed by this size. `null` until the snapshot is ready.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the snapshot failed, or `null` unless the snapshot failed.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ]
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "locked_at": {
                "type": "string",
                "format": "date-time"
              }
            },
            "description": "The lock Better Stack put on the snapshot, with its reason, or `null` when the snapshot isn't locked.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "MySQLSnapshotCreate": {
        "$ref": "#/components/schemas/MySQLSnapshotCreateAttributes"
      },
      "MySQLSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `orders-2026-11-24`."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
          }
        }
      },
      "MySQLSnapshotDocument": {
        "$ref": "#/components/schemas/MySQLSnapshot"
      },
      "MySQLSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQLSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "MySQLType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `MY8`. Send it as `type` when you create or rescale an instance.",
            "readOnly": true
          },
          "usable_disk_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections an instance of this type accepts at once.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can create instances of this type.",
            "x-enum-descriptions": {
              "global": "You can create instances of this type.",
              "unavailable": "The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use instead of this deprecated one, or `null` when the type is offered.",
            "readOnly": true
          }
        }
      },
      "MySQLTypeDocument": {
        "$ref": "#/components/schemas/MySQLType"
      },
      "MySQLTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQLType"
            }
          }
        }
      },
      "MySQLUpdate": {
        "$ref": "#/components/schemas/MySQLUpdateAttributes"
      },
      "MySQLUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's MySQL instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "sql_mode": {
            "type": [
              "string",
              "null"
            ],
            "description": "The SQL modes, separated by commas, such as `STRICT_TRANS_TABLES,NO_ZERO_DATE`. `null` for MySQL's default modes."
          },
          "sql_require_primary_key": {
            "type": "boolean",
            "description": "Whether new tables must have a primary key.",
            "default": false
          },
          "default_time_zone": {
            "type": "string",
            "description": "The default time zone. Accepts `SYSTEM`, `UTC`, an offset from `-13:59` to `+14:00`, or an IANA time zone name such as `Europe/Prague`.",
            "default": "UTC"
          },
          "max_allowed_packet": {
            "type": "integer",
            "format": "int64",
            "description": "The largest packet MySQL accepts, in bytes, from `16777216` to `1073741824`.",
            "default": 67108864
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. On update, a new term starts at once, and billing ends the current one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. On update, the tags you send replace every tag, so an empty object removes them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "MySQLVersion": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The MySQL LTS version, as major and minor, such as `9.7`.",
            "readOnly": true,
            "examples": [
              "9.7"
            ]
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "readOnly": true
          }
        }
      },
      "MySQLVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MySQLVersion"
            }
          }
        }
      },
      "Network": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The network's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The network's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "ip_prefix": {
            "type": "string",
            "description": "The IPv4 or IPv6 address the network's range starts at, such as `10.0.0.0`.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "10.0.0.0"
            ]
          },
          "ip_prefix_length": {
            "type": "integer",
            "format": "int64",
            "description": "The prefix length of the network's range, such as `24` for an IPv4 range of 256 addresses. Accepts `0` to `128`. Use at most `32` for an IPv4 range.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              16
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the network was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the network was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the network. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        }
      },
      "NetworkCreate": {
        "$ref": "#/components/schemas/NetworkCreateAttributes"
      },
      "NetworkCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The network's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "ip_prefix": {
            "type": "string",
            "description": "The IPv4 or IPv6 address the network's range starts at, such as `10.0.0.0`.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "10.0.0.0"
            ]
          },
          "ip_prefix_length": {
            "type": "integer",
            "format": "int64",
            "description": "The prefix length of the network's range, such as `24` for an IPv4 range of 256 addresses. Accepts `0` to `128`. Use at most `32` for an IPv4 range.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              16
            ]
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the network. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        },
        "required": [
          "name",
          "ip_prefix",
          "ip_prefix_length",
          "team_id"
        ]
      },
      "NetworkDocument": {
        "$ref": "#/components/schemas/Network"
      },
      "NetworkList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Network"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "NetworkUpdate": {
        "$ref": "#/components/schemas/NetworkUpdateAttributes"
      },
      "NetworkUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The network's name.",
            "x-cli-input": {
              "order": 20
            }
          }
        }
      },
      "ObjectCache": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The object cache's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The object cache's name, at most 255 characters. Must be unique among your organization's object caches that aren't `failed` or `destroyed`."
          },
          "type": {
            "type": "string",
            "description": "The object cache's type, such as `OP100`.",
            "examples": [
              "OP100"
            ]
          },
          "usable_cache_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space of the object cache's type, in GB.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "failed",
              "destroyed"
            ],
            "description": "The object cache's state.",
            "x-enum-descriptions": {
              "provisioning": "We're starting the object cache.",
              "running": "The object cache is ready.",
              "degraded": "Part of the object cache isn't working. `status_message` says why. An original bucket that is down leaves the object cache `running`.",
              "rescaling": "We're changing the object cache's type. The rescale is done when the object cache is `running` with the new `type`. When the object cache turns `degraded`, the rescale didn't finish.",
              "failed": "We couldn't create the object cache. `status_message` says why. Create a new one instead.",
              "destroyed": "The object cache is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the object cache failed or is `degraded`, or `null` when there's nothing to report.",
            "readOnly": true
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "least_frequently_used",
              "least_recently_used"
            ],
            "description": "Which cached objects we remove first when the cache is full.",
            "x-enum-descriptions": {
              "least_frequently_used": "Removes the objects read least often, so a frequently read object survives a flood of one-off reads.",
              "least_recently_used": "Removes the objects read longest ago, which suits workloads that scan through data."
            },
            "default": "least_frequently_used"
          },
          "max_capacity_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space to use, in GB, from 10 to `usable_cache_gb`."
          },
          "cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep an object in the cache, in seconds, from 60 to 2592000.",
            "default": 86400
          },
          "listing_cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep a bucket listing in the cache, in seconds, from 0 to 86400. `0` turns listing caching off.",
            "default": 0
          },
          "fsync": {
            "type": "boolean",
            "description": "Whether a write waits until your storage provider has stored the object. With `false`, a write is confirmed once the object cache has saved it to its own disk, and the object is uploaded to your storage provider later.",
            "default": true
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the object cache also has a public HTTPS endpoint.",
            "default": false
          },
          "public_ipv4": {
            "type": "boolean",
            "description": "Whether the object cache has a public IPv4 address.",
            "default": false
          },
          "placement_group_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of your placement group the object cache was created in, or `null` when the object cache is in none."
          },
          "cache_used_gb": {
            "type": "number",
            "description": "The cache space in use, in GB.",
            "readOnly": true
          },
          "config_applied_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the object cache last applied its settings. An update is in effect once `config_applied_at` is later than the update. `null` until the settings are first applied.",
            "readOnly": true
          },
          "endpoints": {
            "type": "object",
            "properties": {
              "private": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The object cache's IP address in that network."
                    },
                    "url": {
                      "type": "string",
                      "description": "The endpoint's HTTP URL."
                    }
                  }
                },
                "description": "An HTTP endpoint in each attached network."
              },
              "public": {
                "type": [
                  "object",
                  "null"
                ],
                "properties": {
                  "hostname": {
                    "type": "string",
                    "description": "The public hostname."
                  },
                  "url": {
                    "type": "string",
                    "description": "The endpoint's HTTPS URL."
                  },
                  "records": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "The DNS records the hostname has, `AAAA`, and also `A` when `public_ipv4` is `true`."
                  }
                },
                "description": "The public HTTPS endpoint, or `null` when `public_access` is `false`."
              }
            },
            "description": "Where S3 clients connect. Clients must use path-style addressing and sign requests with SigV4.",
            "readOnly": true
          },
          "buckets": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The bucket's ID."
                },
                "name": {
                  "type": "string",
                  "description": "The bucket name clients use with the object cache."
                },
                "origin_endpoint": {
                  "type": "string",
                  "description": "The URL of your storage provider's S3 endpoint."
                },
                "origin_bucket": {
                  "type": "string",
                  "description": "The name of the bucket at your storage provider."
                },
                "origin_prefix": {
                  "type": "string",
                  "description": "The folder in the bucket at your storage provider that the bucket serves."
                },
                "origin_region": {
                  "type": "string",
                  "description": "The region of your storage provider."
                },
                "origin_force_path_style": {
                  "type": "boolean",
                  "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname."
                },
                "origin_creation_date": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time",
                  "description": "When the bucket at your storage provider was created, as your storage provider reports it."
                },
                "scoped_credentials": {
                  "type": "boolean",
                  "description": "Whether the bucket has its own access keys."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the bucket was added."
                }
              }
            },
            "description": "The buckets the object cache serves. Each bucket maps to a bucket at your storage provider.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the networks attached to the object cache. Order doesn't matter."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the object cache was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the object cache was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the object cache.",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "ObjectCacheBucket": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The bucket's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The bucket name clients use with the object cache, 3–63 lowercase letters, digits, dots and hyphens, starting and ending with a letter or digit.",
            "x-cli-input": {
              "order": 50
            }
          },
          "origin_endpoint": {
            "type": "string",
            "description": "The HTTPS URL of your storage provider's S3 endpoint, such as `https://s3.us-east-1.amazonaws.com`.",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "https://s3.us-west-2.amazonaws.com"
            ]
          },
          "origin_bucket": {
            "type": "string",
            "description": "The name of the bucket at your storage provider, at most 255 characters.",
            "x-cli-input": {
              "order": 20
            },
            "examples": [
              "my-bucket"
            ]
          },
          "origin_prefix": {
            "type": "string",
            "description": "A folder in the bucket at your storage provider to serve as the whole bucket, such as `tenant-a/`. Clients see only the objects under it.",
            "x-cli-input": {
              "order": 55,
              "group": "Advanced"
            }
          },
          "origin_region": {
            "type": "string",
            "description": "The region of your storage provider, such as `us-east-1` or `auto`.",
            "x-cli-input": {
              "order": 60,
              "group": "Advanced"
            },
            "default": "us-east-1"
          },
          "origin_force_path_style": {
            "type": "boolean",
            "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced"
            },
            "default": true
          },
          "origin_creation_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the bucket at your storage provider was created, as your storage provider reports it.",
            "readOnly": true
          },
          "scoped_credentials": {
            "type": "boolean",
            "description": "Whether the bucket has its own access keys. When it's `false`, create them with [Rotate an object cache bucket's credentials](/docs/cloud/api/object-cache-buckets/rotate-object-cache-bucket-credentials/).",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the bucket was added.",
            "readOnly": true
          }
        }
      },
      "ObjectCacheBucketCreate": {
        "$ref": "#/components/schemas/ObjectCacheBucketCreateAttributes"
      },
      "ObjectCacheBucketCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The bucket name clients use with the object cache, 3–63 lowercase letters, digits, dots and hyphens, starting and ending with a letter or digit. Must be unique in the object cache. Defaults to `origin_bucket`. Can't be changed after the bucket is added.",
            "x-cli-input": {
              "order": 50
            }
          },
          "origin_endpoint": {
            "type": "string",
            "description": "The HTTPS URL of your storage provider's S3 endpoint, such as `https://s3.us-east-1.amazonaws.com`. Must use a hostname, not an IP address. Can't have credentials, a path, a query or a fragment. Can't be changed after the bucket is added.",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "https://s3.us-west-2.amazonaws.com"
            ]
          },
          "origin_bucket": {
            "type": "string",
            "description": "The name of the bucket at your storage provider, at most 255 characters. Can't be changed after the bucket is added.",
            "x-cli-input": {
              "order": 20
            },
            "examples": [
              "my-bucket"
            ]
          },
          "origin_prefix": {
            "type": "string",
            "description": "A folder in the bucket at your storage provider to serve as the whole bucket, such as `tenant-a/`. Clients see only the objects under it. Leave it out to serve the whole bucket. Can't be changed after the bucket is added.",
            "x-cli-input": {
              "order": 55,
              "group": "Advanced"
            }
          },
          "origin_region": {
            "type": "string",
            "description": "The region of your storage provider, such as `us-east-1` or `auto`.",
            "x-cli-input": {
              "order": 60,
              "group": "Advanced"
            },
            "default": "us-east-1"
          },
          "origin_force_path_style": {
            "type": "boolean",
            "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced"
            },
            "default": true
          },
          "origin_access_key_id": {
            "type": "string",
            "description": "The access key ID for your storage provider. Not returned after it's saved.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 30
            },
            "writeOnly": true
          },
          "origin_secret_access_key": {
            "type": "string",
            "description": "The secret key for your storage provider. Not returned after it's saved.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 40
            },
            "writeOnly": true
          }
        },
        "required": [
          "origin_endpoint",
          "origin_bucket",
          "origin_access_key_id",
          "origin_secret_access_key"
        ]
      },
      "ObjectCacheBucketDocument": {
        "$ref": "#/components/schemas/ObjectCacheBucket"
      },
      "ObjectCacheBucketList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ObjectCacheBucket"
            }
          }
        }
      },
      "ObjectCacheBucketUpdate": {
        "$ref": "#/components/schemas/ObjectCacheBucketUpdateAttributes"
      },
      "ObjectCacheBucketUpdateAttributes": {
        "type": "object",
        "properties": {
          "origin_region": {
            "type": "string",
            "description": "The region of your storage provider, such as `us-east-1` or `auto`.",
            "x-cli-input": {
              "order": 60,
              "group": "Advanced"
            },
            "default": "us-east-1"
          },
          "origin_force_path_style": {
            "type": "boolean",
            "description": "Whether we send the bucket name in the URL path to your storage provider, instead of in the hostname.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced"
            },
            "default": true
          },
          "origin_access_key_id": {
            "type": "string",
            "description": "The access key ID for your storage provider. Not returned after it's saved.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 30
            },
            "writeOnly": true
          },
          "origin_secret_access_key": {
            "type": "string",
            "description": "The secret key for your storage provider. Not returned after it's saved.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 40
            },
            "writeOnly": true
          }
        }
      },
      "ObjectCacheDocument": {
        "$ref": "#/components/schemas/ObjectCache"
      },
      "ObjectCacheEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "object_proxy_id": {
            "type": "string",
            "description": "The ID of the object cache the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `bucket_added`. An event for a change or a purge is recorded when we accept it, before the change or purge finishes.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the event. The keys depend on `action`.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "ObjectCacheEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ObjectCacheEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ObjectCacheList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ObjectCache"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ObjectCacheType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `OP100`. Send it as `type` when you create or rescale an object cache.",
            "readOnly": true
          },
          "usable_cache_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space on NVMe disks, in GB.",
            "readOnly": true
          },
          "max_cached_entries": {
            "type": "integer",
            "format": "int64",
            "description": "The most entries the cache holds.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Object caches that have it keep running, but you can't create or rescale an object cache to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "readOnly": true
          }
        }
      },
      "ObjectCacheTypeDocument": {
        "$ref": "#/components/schemas/ObjectCacheType"
      },
      "ObjectCacheTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ObjectCacheType"
            }
          }
        }
      },
      "ObjectCacheUpdate": {
        "$ref": "#/components/schemas/ObjectCacheUpdateAttributes"
      },
      "ObjectCacheUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The object cache's name, at most 255 characters. Must be unique among your organization's object caches that aren't `failed` or `destroyed`."
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "least_frequently_used",
              "least_recently_used"
            ],
            "description": "Which cached objects we remove first when the cache is full.",
            "x-enum-descriptions": {
              "least_frequently_used": "Removes the objects read least often, so a frequently read object survives a flood of one-off reads.",
              "least_recently_used": "Removes the objects read longest ago, which suits workloads that scan through data."
            },
            "default": "least_frequently_used"
          },
          "max_capacity_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The cache space to use, in GB, from 10 to `usable_cache_gb`."
          },
          "cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep an object in the cache, in seconds, from 60 to 2592000.",
            "default": 86400
          },
          "listing_cache_ttl_seconds": {
            "type": "integer",
            "format": "int64",
            "description": "How long we keep a bucket listing in the cache, in seconds, from 0 to 86400. `0` turns listing caching off.",
            "default": 0
          },
          "fsync": {
            "type": "boolean",
            "description": "Whether a write waits until your storage provider has stored the object. With `false`, a write is confirmed once the object cache has saved it to its own disk, and the object is uploaded to your storage provider later.",
            "default": true
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the object cache also has a public HTTPS endpoint. A change applies shortly after the response.",
            "default": false
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. A change applies at once, from `monthly` to `annual` or back. Billing ends the current term and starts the new one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag."
          }
        }
      },
      "Otlp": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The export's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The export's name, up to 255 characters.",
            "x-cli-input": {
              "order": 20
            }
          },
          "endpoint": {
            "type": "string",
            "description": "The base URL of your OTLP receiver over HTTP, such as `https://otlp.example.com`. We add `/v1/metrics` unless the URL already ends with it.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "https://otlp.example.com"
            ]
          },
          "header_names": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the export's headers, in alphabetical order.",
            "readOnly": true
          },
          "resource_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources the export sends metrics of. Use `server`.",
            "x-cli-input": {
              "order": 50
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "temporality": {
            "type": "string",
            "enum": [
              "cumulative",
              "delta"
            ],
            "description": "How we send the byte counters. Defaults to `cumulative`.",
            "x-enum-descriptions": {
              "cumulative": "Each data point holds the total since the series started.",
              "delta": "Each data point holds the bytes of one interval. Prometheus-based backends refuse `delta`."
            },
            "x-cli-input": {
              "order": 60
            },
            "default": "cumulative"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether the export is sending. A paused export set to `active` again sends metrics from that moment on.",
            "x-enum-descriptions": {
              "active": "The export sends metrics every minute.",
              "paused": "The export sends nothing."
            },
            "x-cli-input": {
              "order": 70
            },
            "default": "active"
          },
          "paused_reason": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "delivery_failed",
              "destination_refused",
              null
            ],
            "description": "Why we paused the export, or `null` while the export is active or when you paused it.",
            "x-enum-descriptions": {
              "delivery_failed": "No request reached the receiver for 24 hours.",
              "destination_refused": "The endpoint's hostname resolved to a private or otherwise refused address."
            },
            "readOnly": true
          },
          "last_delivered_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the receiver last accepted a request.",
            "readOnly": true
          },
          "last_error": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the last delivery failed, such as HTTP 401, or how many data points the receiver rejected. `last_error` is `null` after a delivery without a problem.",
            "readOnly": true
          },
          "last_error_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the error in `last_error` happened.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the export was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the export was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team whose metrics the export sends. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        }
      },
      "OtlpCreate": {
        "$ref": "#/components/schemas/OtlpCreateAttributes"
      },
      "OtlpCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The export's name, up to 255 characters. Must be unique in the organization.",
            "x-cli-input": {
              "order": 20
            }
          },
          "endpoint": {
            "type": "string",
            "description": "The base URL of your OTLP receiver over HTTP, such as `https://otlp.example.com`. We add `/v1/metrics` unless the URL already ends with it. Must use `https` and have up to 2048 characters. Can't include credentials, a query string or a fragment. An IP address in a private, loopback, link-local or multicast range is refused.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "https://otlp.example.com"
            ]
          },
          "headers": {
            "type": "object",
            "additionalProperties": true,
            "description": "The headers your receiver needs, such as `Authorization`, as an object that maps each header to a string value. You can send up to 16 headers, 8 KiB in total. We set `Content-Type`, `Content-Encoding` and `User-Agent` ourselves, and connection and proxy headers such as `Host`, `Connection` or `X-Forwarded-For` aren't allowed. An update replaces all headers. Responses show only the names, in `header_names`.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 40
            },
            "writeOnly": true
          },
          "resource_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources the export sends metrics of. Use `server`. Can't be empty.",
            "x-cli-input": {
              "order": 50
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "temporality": {
            "type": "string",
            "enum": [
              "cumulative",
              "delta"
            ],
            "description": "How we send the byte counters. Defaults to `cumulative`.",
            "x-enum-descriptions": {
              "cumulative": "Each data point holds the total since the series started.",
              "delta": "Each data point holds the bytes of one interval. Prometheus-based backends refuse `delta`."
            },
            "x-cli-input": {
              "order": 60
            },
            "default": "cumulative"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether the export is sending. A paused export set to `active` again sends metrics from that moment on.",
            "x-enum-descriptions": {
              "active": "The export sends metrics every minute.",
              "paused": "The export sends nothing."
            },
            "x-cli-input": {
              "order": 70
            },
            "default": "active"
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team whose metrics the export sends. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        },
        "required": [
          "name",
          "endpoint",
          "resource_types",
          "team_id"
        ]
      },
      "OtlpDocument": {
        "$ref": "#/components/schemas/Otlp"
      },
      "OtlpList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Otlp"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "OtlpUpdate": {
        "$ref": "#/components/schemas/OtlpUpdateAttributes"
      },
      "OtlpUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The export's name, up to 255 characters. Must be unique in the organization.",
            "x-cli-input": {
              "order": 20
            }
          },
          "endpoint": {
            "type": "string",
            "description": "The base URL of your OTLP receiver over HTTP, such as `https://otlp.example.com`. We add `/v1/metrics` unless the URL already ends with it. Must use `https` and have up to 2048 characters. Can't include credentials, a query string or a fragment. An IP address in a private, loopback, link-local or multicast range is refused.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "https://otlp.example.com"
            ]
          },
          "headers": {
            "type": "object",
            "additionalProperties": true,
            "description": "The headers your receiver needs, such as `Authorization`, as an object that maps each header to a string value. You can send up to 16 headers, 8 KiB in total. We set `Content-Type`, `Content-Encoding` and `User-Agent` ourselves, and connection and proxy headers such as `Host`, `Connection` or `X-Forwarded-For` aren't allowed. An update replaces all headers. Responses show only the names, in `header_names`.",
            "x-sensitive": true,
            "x-cli-input": {
              "order": 40
            },
            "writeOnly": true
          },
          "resource_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources the export sends metrics of. Use `server`. Can't be empty.",
            "x-cli-input": {
              "order": 50
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "temporality": {
            "type": "string",
            "enum": [
              "cumulative",
              "delta"
            ],
            "description": "How we send the byte counters. Defaults to `cumulative`.",
            "x-enum-descriptions": {
              "cumulative": "Each data point holds the total since the series started.",
              "delta": "Each data point holds the bytes of one interval. Prometheus-based backends refuse `delta`."
            },
            "x-cli-input": {
              "order": 60
            },
            "default": "cumulative"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether the export is sending. A paused export set to `active` again sends metrics from that moment on.",
            "x-enum-descriptions": {
              "active": "The export sends metrics every minute.",
              "paused": "The export sends nothing."
            },
            "x-cli-input": {
              "order": 70
            },
            "default": "active"
          }
        }
      },
      "PaginationCloudPageTotal": {
        "type": "object",
        "description": "Send `page` and `per_page` in the query. The response's `meta` holds `page`, `per_page` and `total`. To get the following page, add one to `page` until `page` times `per_page` reaches `total`.",
        "properties": {}
      },
      "PlacementGroup": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The placement group's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The group's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "placement_type": {
            "type": "string",
            "enum": [
              "spread",
              "compact"
            ],
            "description": "How we place the group's servers. When there isn't room, the server is still created, on another host.",
            "x-enum-descriptions": {
              "spread": "We put each server on a different host when we can.",
              "compact": "We put the servers on as few hosts as we can."
            },
            "x-cli-input": {
              "order": 30
            }
          },
          "server_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The IDs of the servers in the group. A server joins the group when you create it with `placement_group_id`.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the group was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the group was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the group. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "PlacementGroupCreate": {
        "$ref": "#/components/schemas/PlacementGroupCreateAttributes"
      },
      "PlacementGroupCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The group's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "placement_type": {
            "type": "string",
            "enum": [
              "spread",
              "compact"
            ],
            "description": "How we place the group's servers. When there isn't room, the server is still created, on another host. Can't be changed after the group is created.",
            "x-enum-descriptions": {
              "spread": "We put each server on a different host when we can.",
              "compact": "We put the servers on as few hosts as we can."
            },
            "x-cli-input": {
              "order": 30
            }
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the group. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "name",
          "placement_type",
          "team_id"
        ]
      },
      "PlacementGroupDocument": {
        "$ref": "#/components/schemas/PlacementGroup"
      },
      "PlacementGroupList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PlacementGroup"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "PlacementGroupUpdate": {
        "$ref": "#/components/schemas/PlacementGroupUpdateAttributes"
      },
      "PlacementGroupUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The group's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "Postgres": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `PG1`, which sets its size. Get the types via [List PostgreSQL types](/docs/cloud/api/postgres-types/list-postgres-types/).",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_postgres_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_storage_gb",
                "max_connections"
              ]
            },
            "examples": [
              "PG1"
            ]
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect straight to PostgreSQL at once, without going through PgBouncer.",
            "readOnly": true
          },
          "max_pooled_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect through PgBouncer at once.",
            "readOnly": true
          },
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`. Get the versions via [List PostgreSQL versions](/docs/cloud/api/postgres-versions/list-postgres-versions/).",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_postgres_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "engine_patch_version": {
            "type": [
              "string",
              "null"
            ],
            "description": "The exact PostgreSQL version the instance runs, such as `19.0`, or `null` until we know it.",
            "readOnly": true
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The major versions you can upgrade the instance to. An upgrade can't be undone.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's status. After you create or restore an instance, get it until its status is `running`. A failed or destroyed instance stays that way.",
            "x-enum-descriptions": {
              "provisioning": "We're setting up the instance.",
              "running": "The instance is ready.",
              "degraded": "A node is down, replication is broken or the disk is nearly full. `status_message` says which.",
              "rescaling": "We're changing the instance's type.",
              "upgrading": "We're upgrading PostgreSQL to a new major version.",
              "restoring": "We're restoring the instance from a snapshot.",
              "failed": "Setting up the instance failed. `status_message` says why.",
              "destroyed": "The instance is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "More about the status, such as why the instance failed or is degraded, that a replica is being rebuilt, or that an action didn't finish.",
            "readOnly": true
          },
          "statement_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement can run before PostgreSQL cancels it, in milliseconds, from `0` to `3600000`. Set it to `0` for no limit.",
            "default": 0
          },
          "idle_in_transaction_session_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a session can stay idle inside a transaction before PostgreSQL ends it, in milliseconds, from `0` to `86400000`. Set it to `0` for no limit.",
            "default": 0
          },
          "work_mem_mb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory each sort or hash operation can use, in MiB, from `1` to `256`.",
            "default": 4
          },
          "log_min_duration_statement": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement must run before PostgreSQL logs it, in milliseconds, from `-1` to `600000`. Set it to `-1` to log none.",
            "default": -1
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "read_only": {
            "type": "boolean",
            "description": "Whether the instance accepts only reads because its disk is nearly full.",
            "readOnly": true
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": "string",
                "description": "The hostname to connect to from your private networks. Resolves to the primary's addresses in your private networks."
              },
              "public_hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname to connect to from the internet, or `null` when `public_access` is off. Resolves to the primary's public addresses."
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting straight to PostgreSQL, `5432`."
              },
              "pooled_port": {
                "type": "integer",
                "format": "int64",
                "description": "The port for connecting through PgBouncer, `6432`."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in your private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public address."
                    },
                    "type": {
                      "type": "string",
                      "description": "Whether it's an `ipv4` or `ipv6` address."
                    }
                  }
                },
                "description": "The primary's public addresses, when `public_access` is on."
              }
            },
            "description": "Where to connect to the instance. Connect straight to PostgreSQL on `port`, or through PgBouncer on `pooled_port`.",
            "readOnly": true
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "Whether the node is the primary or a replica.\n\n- `primary`: The node that accepts writes.\n- `replica`: A read-only copy of the primary.",
                  "x-enum-descriptions": {
                    "primary": "The node that accepts writes.",
                    "replica": "A read-only copy of the primary."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's status."
                },
                "replication_lag_seconds": {
                  "type": [
                    "number",
                    "null"
                  ],
                  "description": "How far the replica is behind the primary, in seconds, or `null` on the primary."
                },
                "disk_used_bytes": {
                  "type": "integer",
                  "format": "int64",
                  "description": "The disk space the node uses, in bytes."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in your private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's nodes, the primary and its replicas.",
            "readOnly": true
          },
          "databases": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The names of the instance's databases. Add databases via [Create a PostgreSQL database](/docs/cloud/api/postgres-databases/create-postgres-database/).",
            "readOnly": true
          },
          "users": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "username": {
                  "type": "string"
                },
                "default_user": {
                  "type": "boolean"
                },
                "privileges": {
                  "type": "object"
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            },
            "description": "The instance's users. Add users via [Create a PostgreSQL user](/docs/cloud/api/postgres-users/create-postgres-user/), and get a user's password via [Get a PostgreSQL user's credentials](/docs/cloud/api/postgres-users/credentials-postgres-user/).",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "latest_snapshot_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the newest available snapshot was taken.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "PostgresCreate": {
        "$ref": "#/components/schemas/PostgresCreateAttributes"
      },
      "PostgresCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's PostgreSQL instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `PG1`, which sets its size. Get the types via [List PostgreSQL types](/docs/cloud/api/postgres-types/list-postgres-types/). To change it later, rescale the instance.",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_postgres_type",
              "value_field": "name",
              "label_fields": [
                "name",
                "usable_storage_gb",
                "max_connections"
              ]
            },
            "examples": [
              "PG1"
            ]
          },
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`. Get the versions via [List PostgreSQL versions](/docs/cloud/api/postgres-versions/list-postgres-versions/). Defaults to the newest version we offer. To change it later, upgrade the instance.",
            "x-cli-input": {
              "order": 30,
              "lookup": "list_postgres_version",
              "value_field": "engine_version",
              "label_fields": [
                "engine_version",
                "latest"
              ]
            }
          },
          "statement_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement can run before PostgreSQL cancels it, in milliseconds, from `0` to `3600000`. Set it to `0` for no limit.",
            "default": 0
          },
          "idle_in_transaction_session_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a session can stay idle inside a transaction before PostgreSQL ends it, in milliseconds, from `0` to `86400000`. Set it to `0` for no limit.",
            "default": 0
          },
          "work_mem_mb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory each sort or hash operation can use, in MiB, from `1` to `256`.",
            "default": 4
          },
          "log_min_duration_statement": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement must run before PostgreSQL logs it, in milliseconds, from `-1` to `600000`. Set it to `-1` to log none.",
            "default": -1
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "database": {
            "type": "string",
            "description": "The name of the instance's first database. Defaults to `defaultdb`.",
            "writeOnly": true,
            "default": "defaultdb"
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to every node. Each network must be in the instance's team. To change them later, use [Attach a network to a PostgreSQL instance](/docs/cloud/api/postgreses/attach-postgres-network/) and [Detach a network from a PostgreSQL instance](/docs/cloud/api/postgreses/detach-postgres-network/). Order doesn't matter.",
            "x-cli-input": {
              "order": 70,
              "group": "Advanced",
              "lookup": "list_network",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to every node. An instance can have at most one firewall. To change it later, use [Attach a firewall to a PostgreSQL instance](/docs/cloud/api/postgreses/attach-postgres-firewall/) and [Detach a firewall from a PostgreSQL instance](/docs/cloud/api/postgreses/detach-postgres-firewall/). Order doesn't matter.",
            "x-cli-input": {
              "order": 80,
              "group": "Advanced",
              "lookup": "list_firewall",
              "select": {
                "team_id": {
                  "source": "request",
                  "path": [
                    "team_id"
                  ]
                }
              },
              "value_field": "id",
              "label_fields": [
                "name",
                "id",
                "team_id"
              ]
            }
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance. Get the team ID via [List teams](/docs/uptime/api/teams/list/). Can't be changed after the instance is created.",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "name",
          "type",
          "team_id"
        ]
      },
      "PostgresDatabase": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The database's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The database's name. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore. Can't be `postgres`, `template0` or `template1`."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the database was created.",
            "readOnly": true
          }
        }
      },
      "PostgresDatabaseCreate": {
        "$ref": "#/components/schemas/PostgresDatabaseCreateAttributes"
      },
      "PostgresDatabaseCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The database's name. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore. Can't be `postgres`, `template0` or `template1`."
          }
        },
        "required": [
          "name"
        ]
      },
      "PostgresDatabaseDocument": {
        "$ref": "#/components/schemas/PostgresDatabase"
      },
      "PostgresDatabaseList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresDatabase"
            }
          }
        }
      },
      "PostgresDocument": {
        "$ref": "#/components/schemas/Postgres"
      },
      "PostgresEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, in the past tense, such as `created`, `rescaled` or `database_created`.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who made the change, or `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who made the change.",
            "x-enum-descriptions": {
              "user": "A Better Stack user made the change. `user_id` says who.",
              "api_token": "A request with an API token made the change.",
              "system": "Better Stack made the change."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about what happened, such as the new type or version, the snapshot ID, the database or the user name.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event was recorded.",
            "readOnly": true
          }
        }
      },
      "PostgresEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "PostgresList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Postgres"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "PostgresScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's primary. Changes when the instance fails over.",
            "readOnly": true
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last ran, or `null` until the schedule first runs.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "PostgresScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/PostgresScheduledSnapshotCreateAttributes"
      },
      "PostgresScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        },
        "required": [
          "frequency"
        ]
      },
      "PostgresScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/PostgresScheduledSnapshot"
      },
      "PostgresScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresScheduledSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "PostgresScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/PostgresScheduledSnapshotUpdateAttributes"
      },
      "PostgresScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        }
      },
      "PostgresSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "postgres_id": {
            "type": "string",
            "description": "The ID of the PostgreSQL instance the snapshot was taken from.",
            "readOnly": true
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that ran the instance's primary when the snapshot was taken. Becomes `null` some time after that server is deleted.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "Whether the snapshot was taken on request or by a schedule.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its status is `available`. Only an `available` snapshot can be restored.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "Creating the snapshot failed. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. The snapshot is billed by this size. `null` until the snapshot is taken.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The availability zone the snapshot was taken in.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why creating the snapshot failed, or `null` unless the snapshot failed.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null`."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "The lock Better Stack put on the snapshot, or `null` when the snapshot isn't locked. Every action on a PostgreSQL snapshot works while the snapshot is locked.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "PostgresSnapshotCreate": {
        "$ref": "#/components/schemas/PostgresSnapshotCreateAttributes"
      },
      "PostgresSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name. Defaults to the instance's name followed by the date, such as `db-2026-11-24`."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. Can't be changed after the snapshot is created."
          }
        }
      },
      "PostgresSnapshotDocument": {
        "$ref": "#/components/schemas/PostgresSnapshot"
      },
      "PostgresSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "PostgresType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `PG1`. Send it as `type` when you create or rescale a PostgreSQL instance.",
            "readOnly": true
          },
          "usable_storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The disk space for your data, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect straight to PostgreSQL at once, without going through PgBouncer.",
            "readOnly": true
          },
          "max_pooled_connections": {
            "type": "integer",
            "format": "int64",
            "description": "How many clients can connect through PgBouncer at once.",
            "readOnly": true
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of virtual CPUs on each node.",
            "readOnly": true
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory on each node, in GiB.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can create instances of this type.",
            "x-enum-descriptions": {
              "global": "You can create instances of this type.",
              "unavailable": "The type is deprecated. Instances of this type keep running, but you can't create an instance of it or rescale to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The type to use instead of this deprecated one, or `null` when the type is offered.",
            "readOnly": true
          }
        }
      },
      "PostgresTypeDocument": {
        "$ref": "#/components/schemas/PostgresType"
      },
      "PostgresTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresType"
            }
          }
        }
      },
      "PostgresUpdate": {
        "$ref": "#/components/schemas/PostgresUpdateAttributes"
      },
      "PostgresUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's PostgreSQL instances that aren't `destroyed` or `failed`.",
            "x-cli-input": {
              "order": 40
            }
          },
          "statement_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement can run before PostgreSQL cancels it, in milliseconds, from `0` to `3600000`. Set it to `0` for no limit.",
            "default": 0
          },
          "idle_in_transaction_session_timeout": {
            "type": "integer",
            "format": "int64",
            "description": "How long a session can stay idle inside a transaction before PostgreSQL ends it, in milliseconds, from `0` to `86400000`. Set it to `0` for no limit.",
            "default": 0
          },
          "work_mem_mb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory each sort or hash operation can use, in MiB, from `1` to `256`.",
            "default": 4
          },
          "log_min_duration_statement": {
            "type": "integer",
            "format": "int64",
            "description": "How long a statement must run before PostgreSQL logs it, in milliseconds, from `-1` to `600000`. Set it to `-1` to log none.",
            "default": -1
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether clients can also connect to the instance from the internet. Connections use TLS.",
            "default": false
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many read replicas the instance has, from `0` to `2`.",
            "default": 0
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. On update, a new term starts at once, and billing ends the current one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. On update, the tags you send replace every tag, so an empty object removes them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "PostgresUser": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The user's ID, a UUID.",
            "readOnly": true
          },
          "username": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The user's name in PostgreSQL. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore."
          },
          "default_user": {
            "type": "boolean",
            "description": "Whether this is the instance's default `admin` user. The default user's access can't be changed. The default user can't be deleted.",
            "readOnly": true
          },
          "privileges": {
            "type": "object",
            "additionalProperties": true,
            "description": "The user's access to each database, as an object that maps a database name to an access level, such as `{\"appdb\": \"read_write\"}`. A database that isn't in the object gets no access. `read` can read the tables in the `public` schema. `read_write` can also add, change and delete rows and run functions, but can't create tables. `all` can also create tables and schemas and maintain them, such as with `VACUUM`. `none` gives no access.",
            "examples": [
              {
                "appdb": "read_write"
              }
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the user was created.",
            "readOnly": true
          }
        }
      },
      "PostgresUserCreate": {
        "$ref": "#/components/schemas/PostgresUserCreateAttributes"
      },
      "PostgresUserCreateAttributes": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "pattern": "^[a-z_][a-z0-9_]{0,62}$",
            "description": "The user's name in PostgreSQL. Accepts up to 63 lowercase letters, digits and underscores, and must start with a letter or an underscore. Can't be `postgres` or `pgbouncer`, or start with `pg_`. Can't be changed after the user is created."
          },
          "privileges": {
            "type": "object",
            "additionalProperties": true,
            "description": "The user's access to each database, as an object that maps a database name to an access level, such as `{\"appdb\": \"read_write\"}`. A database that isn't in the object gets no access. `read` can read the tables in the `public` schema. `read_write` can also add, change and delete rows and run functions, but can't create tables. `all` can also create tables and schemas and maintain them, such as with `VACUUM`. `none` gives no access. Each key must be a database of this instance. Leave it out for no access to any database.",
            "examples": [
              {
                "appdb": "read_write"
              }
            ]
          }
        },
        "required": [
          "username"
        ]
      },
      "PostgresUserDocument": {
        "$ref": "#/components/schemas/PostgresUser"
      },
      "PostgresUserList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresUser"
            }
          }
        }
      },
      "PostgresUserUpdate": {
        "$ref": "#/components/schemas/PostgresUserUpdateAttributes"
      },
      "PostgresUserUpdateAttributes": {
        "type": "object",
        "properties": {
          "privileges": {
            "type": "object",
            "additionalProperties": true,
            "description": "The user's access to each database, as an object that maps a database name to an access level, such as `{\"appdb\": \"read_write\"}`. A database that isn't in the object gets no access. `read` can read the tables in the `public` schema. `read_write` can also add, change and delete rows and run functions, but can't create tables. `all` can also create tables and schemas and maintain them, such as with `VACUUM`. `none` gives no access. Each key must be a database of this instance. Leave it out for no access to any database. On update, the object you send replaces the user's access to every database.",
            "examples": [
              {
                "appdb": "read_write"
              }
            ]
          }
        }
      },
      "PostgresVersion": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The PostgreSQL major version, such as `19`.",
            "readOnly": true,
            "examples": [
              "19"
            ]
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "readOnly": true
          }
        }
      },
      "PostgresVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PostgresVersion"
            }
          }
        }
      },
      "Quota": {
        "type": "object",
        "properties": {
          "firewalls": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many firewalls the organization can have.",
            "readOnly": true
          },
          "firewall_rules": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many rules one firewall can have. `used` is `null` for a limit on each firewall.",
            "readOnly": true
          },
          "reserved_ipv4_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many reserved IPv4 addresses the organization can have.",
            "readOnly": true
          },
          "reserved_ipv6_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many reserved IPv6 addresses the organization can have.",
            "readOnly": true
          },
          "public_ipv4_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many public IPv4 addresses the organization can hold in the zone, reserved ones included.",
            "readOnly": true
          },
          "public_ipv6_addresses": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many public IPv6 addresses the organization can hold in the zone, reserved ones included.",
            "readOnly": true
          },
          "private_ips_per_server_per_network": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many private addresses one server can hold in one network. `used` is `null` for a limit on each server and network.",
            "readOnly": true
          },
          "regular_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the regular tier.",
            "readOnly": true
          },
          "spot_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the spot tier.",
            "readOnly": true
          },
          "dedicated_vcpus": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total vCPUs of your servers on the dedicated tier.",
            "readOnly": true
          },
          "ram_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total memory of all your servers on every tier, in GiB.",
            "readOnly": true
          },
          "spot_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many spot servers the organization can have.",
            "readOnly": true
          },
          "regular_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many regular servers the organization can have.",
            "readOnly": true
          },
          "dedicated_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many dedicated servers the organization can have.",
            "readOnly": true
          },
          "servers_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many servers the organization can create in 60 seconds. `used` is `null` for a rate.",
            "readOnly": true
          },
          "snapshots_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshots the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "readOnly": true
          },
          "volume_snapshots_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshots of volumes the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "readOnly": true
          },
          "rescales_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many server rescales the organization can start in 60 seconds. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "readOnly": true
          },
          "api_requests_per_minute": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many API requests the organization can send in one minute, all teams together. `used` is `null` for a rate. A request over the limit is refused with the code `rate_limited`.",
            "readOnly": true
          },
          "placement_group_count": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many placement groups the organization can have.",
            "readOnly": true
          },
          "placement_group_servers": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many servers one placement group can hold. `used` is `null` for a limit on each group.",
            "readOnly": true
          },
          "volumes": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many volumes the organization can have.",
            "readOnly": true
          },
          "volume_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of the organization's volumes in GiB.",
            "readOnly": true
          },
          "volume_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many volume snapshots the organization can have.",
            "readOnly": true
          },
          "snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many server snapshots and managed service backups the organization can have.",
            "readOnly": true
          },
          "snapshot_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of server snapshots and managed backups, in whole GiB, rounded down.",
            "readOnly": true
          },
          "volume_snapshot_storage_gb": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total size of every volume snapshot, in whole GiB, rounded down.",
            "readOnly": true
          },
          "scheduled_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshot schedules of servers, managed databases and Kubernetes clusters the organization can have.",
            "readOnly": true
          },
          "scheduled_volume_snapshots": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many snapshot schedules of volumes the organization can have.",
            "readOnly": true
          },
          "ssh_keys": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many SSH keys the organization can have. SSH keys are shared across zones, so the count is the same in each zone.",
            "readOnly": true
          },
          "webhooks": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many webhooks the organization can have, paused ones included.",
            "readOnly": true
          },
          "otlps": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many OTLP exports the organization can have, paused ones included.",
            "readOnly": true
          },
          "networks": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many private networks the organization can have.",
            "readOnly": true
          },
          "cloudflare_records": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many Cloudflare DNS records one server can have. `used` is `null` for a limit on each server.",
            "readOnly": true
          },
          "load_balancers": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed load balancers the organization can have.",
            "readOnly": true
          },
          "valkeys": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed Valkey instances the organization can have.",
            "readOnly": true
          },
          "mysqls": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed MySQL instances the organization can have.",
            "readOnly": true
          },
          "postgres_instances": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed PostgreSQL instances the organization can have.",
            "readOnly": true
          },
          "clickhouses": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed ClickHouse instances the organization can have.",
            "readOnly": true
          },
          "kafkas": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many managed Kafka clusters the organization can have.",
            "readOnly": true
          },
          "object_proxies": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many object caches the organization can have.",
            "readOnly": true
          },
          "certificates": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many uploaded and managed TLS certificates the organization can have. Certificates are shared across zones, so the count is the same in each zone.",
            "readOnly": true
          },
          "kubernetes_control_planes": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many Kubernetes control planes the organization can have.",
            "readOnly": true
          },
          "server_pool_size": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "The total maximum size of all server pools.",
            "readOnly": true
          },
          "console_sessions": {
            "type": "object",
            "properties": {
              "used": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "How much of the limit the organization uses in this zone, or `null` for a limit with no total, such as a rate."
              },
              "limit": {
                "type": "integer",
                "format": "int64",
                "description": "The limit that applies to the organization."
              },
              "default": {
                "type": "integer",
                "format": "int64",
                "description": "The default limit for an organization."
              }
            },
            "description": "How many console sessions can be open at the same time.",
            "readOnly": true
          }
        }
      },
      "QuotaDocument": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/Quota"
          }
        }
      },
      "ReservedIp": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The reserved IP's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reserved IP's name, unique in the organization."
          },
          "ip": {
            "type": "string",
            "description": "The IP address.",
            "readOnly": true
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or an IPv6 address."
          },
          "gateway": {
            "type": [
              "string",
              "null"
            ],
            "description": "The gateway for the address, for when you configure the server's network yourself.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server the address is assigned to, or `null` when the address isn't assigned. To change it, use [Assign a reserved IP](/docs/cloud/api/reserved-ips/assign-reserved-ip/) and [Unassign a reserved IP](/docs/cloud/api/reserved-ips/unassign-reserved-ip/).",
            "readOnly": true
          },
          "server": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "type": "string",
                "description": "The server's ID."
              },
              "name": {
                "type": "string",
                "description": "The server's name."
              },
              "status": {
                "type": "string",
                "description": "The server's status, such as `running`."
              }
            },
            "description": "The server the address is assigned to, or `null` when the address isn't assigned.",
            "readOnly": true
          },
          "ptr_record": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reverse DNS name for the address. A `ptr_record` you send when you assign the address replaces this one while the address stays assigned."
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the reserved IP was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the reserved IP was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the reserved IP. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "ReservedIpDocument": {
        "$ref": "#/components/schemas/ReservedIp"
      },
      "ReservedIpList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ReservedIp"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ReservedIpUpdate": {
        "$ref": "#/components/schemas/ReservedIpUpdateAttributes"
      },
      "ReservedIpUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reserved IP's name, unique in the organization."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. A change applies at once, from `monthly` to `annual` or back.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "ptr_record": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reverse DNS name for the address. A `ptr_record` you send when you assign the address replaces this one while the address stays assigned."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "ScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server the schedule creates snapshots of. Get it via [List servers](/docs/cloud/api/servers/list-servers/).",
            "x-cli-input": {
              "order": 10,
              "lookup": "list_server",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "status",
                "server_type"
              ]
            }
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "ScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/ScheduledSnapshotCreateAttributes"
      },
      "ScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "server_id": {
            "type": "string",
            "description": "The ID of the server the schedule creates snapshots of. Get it via [List servers](/docs/cloud/api/servers/list-servers/). Can't be changed after the schedule is created.",
            "x-cli-input": {
              "order": 10,
              "lookup": "list_server",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "status",
                "server_type"
              ]
            }
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          }
        },
        "required": [
          "server_id",
          "frequency"
        ]
      },
      "ScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/ScheduledSnapshot"
      },
      "ScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ScheduledSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/ScheduledSnapshotUpdateAttributes"
      },
      "ScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          }
        }
      },
      "ScheduledVolumeSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule's ID, a UUID.",
            "readOnly": true
          },
          "volume_id": {
            "type": "string",
            "description": "The ID of the volume the schedule creates snapshots of. Get it via [List volumes](/docs/cloud/api/volumes/list-volumes/).",
            "x-cli-input": {
              "order": 10,
              "lookup": "list_volume",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "status",
                "size_gb"
              ]
            }
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last created a snapshot, or `null` until the schedule first runs.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "ScheduledVolumeSnapshotCreate": {
        "$ref": "#/components/schemas/ScheduledVolumeSnapshotCreateAttributes"
      },
      "ScheduledVolumeSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "volume_id": {
            "type": "string",
            "description": "The ID of the volume the schedule creates snapshots of. Get it via [List volumes](/docs/cloud/api/volumes/list-volumes/). Can't be changed after the schedule is created.",
            "x-cli-input": {
              "order": 10,
              "lookup": "list_volume",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "status",
                "size_gb"
              ]
            }
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          }
        },
        "required": [
          "volume_id",
          "frequency"
        ]
      },
      "ScheduledVolumeSnapshotDocument": {
        "$ref": "#/components/schemas/ScheduledVolumeSnapshot"
      },
      "ScheduledVolumeSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ScheduledVolumeSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ScheduledVolumeSnapshotUpdate": {
        "$ref": "#/components/schemas/ScheduledVolumeSnapshotUpdateAttributes"
      },
      "ScheduledVolumeSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A monthly schedule runs on the same day each month.",
            "x-cli-input": {
              "order": 20
            }
          }
        }
      },
      "Server": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The server's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`."
          },
          "status": {
            "type": "string",
            "enum": [
              "starting",
              "running",
              "stopping",
              "stopped",
              "pooled",
              "snapshotting",
              "migrating",
              "rescuing",
              "restoring",
              "rescaling",
              "destroyed",
              "terminating",
              "terminated"
            ],
            "description": "The server's current status. After you start, stop or change the server, get it again until the change has finished.",
            "x-enum-descriptions": {
              "starting": "The server is booting.",
              "running": "The server is running.",
              "stopping": "The server is shutting down.",
              "stopped": "The server is stopped.",
              "pooled": "The server is waiting in a server pool. The server is running and billed, and nobody has claimed it yet.",
              "snapshotting": "We're creating a snapshot of the server.",
              "migrating": "We're moving the server to another host.",
              "rescuing": "The server is in rescue mode.",
              "restoring": "We're restoring the server from a snapshot.",
              "rescaling": "We're changing the server's type.",
              "destroyed": "The server is destroyed.",
              "terminating": "We're ending a spot server.",
              "terminated": "We've ended a spot server."
            },
            "readOnly": true
          },
          "rescue_state": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "activating",
              "active",
              null
            ],
            "description": "Whether the rescue system is ready. `null` when the server isn't in rescue mode. After you start rescue mode, get the server again until `rescue_state` is `active` or `null`.",
            "x-enum-descriptions": {
              "activating": "The server is booting the rescue system. You can sign in when it's up.",
              "active": "The rescue system is up, and you can sign in."
            },
            "readOnly": true
          },
          "server_type": {
            "type": "string",
            "description": "The name of the server type, such as `AM4`. The type sets the server's size. Get the types via [List server types](/docs/cloud/api/server-types/list-server-types/).",
            "examples": [
              "AM1"
            ]
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "disk_size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The size of the root disk, in GiB. Can differ from the type's `storage_gb` after a rescale that kept the disk size. A later rescale needs a type with at least this much storage, because disks never shrink.",
            "readOnly": true
          },
          "image": {
            "type": [
              "string",
              "null"
            ],
            "description": "The `slug` of the server's image, such as `ubuntu-26-04`. `null` when the image was removed after the server was created. Get the images via [List images](/docs/cloud/api/images/list-images/).",
            "examples": [
              "ubuntu-26-04"
            ]
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the server. Order doesn't matter."
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The firewall attached to the server, as a list with at most one ID. Order doesn't matter."
          },
          "placement_group_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the placement group the server is in."
          },
          "pool_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server pool the server came from. `null` for a server you created directly.",
            "readOnly": true
          },
          "claimed_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the server was claimed from its server pool. `null` for a server that's still in its pool, and for a server you created directly.",
            "readOnly": true
          },
          "ssh_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The `slug` of each of the server's SSH keys. We add them to the server at its first boot. Order doesn't matter."
          },
          "ip_addresses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "ip": {
                  "type": "string",
                  "description": "The address."
                },
                "type": {
                  "type": "string",
                  "description": "Whether it's an `ipv4` or `ipv6` address."
                },
                "reserved_ip": {
                  "type": "boolean",
                  "description": "Whether it's a reserved IP."
                },
                "ptr_record": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "description": "The reverse DNS name. `null` when none is set."
                }
              }
            },
            "description": "The server's public addresses. Get the network interface of each via [List server public IPs](/docs/cloud/api/server-public-ips/list-server-public-ips/).",
            "readOnly": true
          },
          "private_ips": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The ID of the address on the server."
                },
                "network_id": {
                  "type": "string",
                  "description": "The ID of the network."
                },
                "ip": {
                  "type": "string",
                  "description": "The address in that network."
                }
              }
            },
            "description": "The server's addresses in private networks.",
            "readOnly": true
          },
          "cloudflare_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The record's ID."
                },
                "type": {
                  "type": "string",
                  "description": "The record type, `A`, `AAAA` or `CNAME`."
                },
                "domain": {
                  "type": "string",
                  "description": "The Cloudflare zone of the record."
                },
                "a_record": {
                  "type": "string",
                  "description": "The record's name."
                },
                "proxied": {
                  "type": "boolean",
                  "description": "Whether Cloudflare proxies the record."
                },
                "ttl": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "int64",
                  "description": "The record's TTL in seconds. `1` means automatic."
                },
                "status": {
                  "type": "string",
                  "description": "Whether we've created the record, `pending`, `created` or `failed`."
                }
              }
            },
            "description": "The Cloudflare DNS records that point to the server. The list holds the A and AAAA records you asked for on create, and the CNAME, A and AAAA records of the server's subdomain in `onbetterstack.com`.",
            "readOnly": true
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`.",
            "default": true
          },
          "ddos_protection": {
            "type": "boolean",
            "description": "Whether DDoS protection is on.",
            "default": false
          },
          "ai_engineer_access": {
            "type": "boolean",
            "description": "Whether the Better Stack AI Engineer can sign in to the server over SSH.",
            "default": true
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "default": false
          },
          "observability": {
            "type": "boolean",
            "description": "Whether we installed the Better Stack collector when the server was created.",
            "default": false
          },
          "nested_virtualization": {
            "type": "boolean",
            "description": "Whether the server can run its own virtual machines. Always `false` for a server you create.",
            "readOnly": true
          },
          "connection_tracking": {
            "type": "object",
            "properties": {
              "budget": {
                "type": "integer",
                "format": "int64",
                "description": "The most connections the server can have at once, 60,000 per vCPU of its type."
              },
              "entries": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "How many connections the server had at the last count. `null` before the first count."
              },
              "measured_at": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time",
                "description": "When we last counted the connections. We count once a minute."
              },
              "over_budget": {
                "type": "boolean",
                "description": "Whether the server has more connections than its `budget`. New connections are dropped until it's back under the budget."
              }
            },
            "description": "How many connections the server has, and the most it can have. When the server goes over its `budget`, new connections are dropped.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the server."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null`."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the server."
              }
            },
            "description": "Why and when we locked the server. `null` when the server isn't locked. A locked server keeps running, but its network is cut and you can't change it.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was created. For a server moved to your team from another team's server pool, when it was moved.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the server was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the server. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "ServerDocument": {
        "$ref": "#/components/schemas/Server"
      },
      "ServerList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Server"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerPool": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The pool's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
            "description": "The pool's name. Must be unique in the team, with up to 63 lowercase letters, digits and hyphens, and start and end with a letter or digit. Spare servers are named after the pool, with a hyphen and 6 hex characters added. A server gets its own name when you claim it."
          },
          "server_type": {
            "type": "string",
            "description": "The server type of the spare servers. For a pool that boots from a snapshot, the snapshot's server type.",
            "examples": [
              "AM1"
            ]
          },
          "snapshot_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the snapshot the spare servers boot from. `null` for a pool that boots from an image."
          },
          "image": {
            "type": [
              "string",
              "null"
            ],
            "description": "The `slug` of the image the spare servers boot from. `null` for a pool that boots from a snapshot.",
            "examples": [
              "ubuntu-26-04"
            ]
          },
          "min_size": {
            "type": "integer",
            "format": "int64",
            "description": "The fewest spare servers the pool keeps, from 0 up to `max_size`.",
            "default": 0
          },
          "max_size": {
            "type": "integer",
            "format": "int64",
            "description": "The most spare servers the pool keeps. The `max_size` of all your organization's pools together can't be more than its `server_pool_size` quota.",
            "default": 0
          },
          "growth_multiplier": {
            "type": "number",
            "description": "How much the pool grows when you claim a server from an empty pool. `target_size` is multiplied by this factor, from 1 to 10. `1` turns growing off.",
            "default": 2.0
          },
          "shrink_multiplier": {
            "type": "number",
            "description": "How much the pool shrinks while it's full and nobody has claimed a server for `idle_minutes`. Each minute, `target_size` is multiplied by this factor, which is more than 0 and at most 1. `1` turns shrinking off.",
            "default": 0.8
          },
          "idle_minutes": {
            "type": "integer",
            "format": "int64",
            "description": "How many minutes without a claim before the pool shrinks, from 1 to 1440.",
            "default": 5
          },
          "enabled": {
            "type": "boolean",
            "description": "Whether the pool keeps spare servers. A disabled pool removes all its spare servers and keeps its settings. Claiming from a disabled pool is refused.",
            "default": true
          },
          "public_ipv4": {
            "type": "boolean",
            "description": "Whether the spare servers get a public IPv4 address. A server without one has only IPv6.",
            "default": true
          },
          "defaults": {
            "type": "object",
            "properties": {
              "ssh_keys": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The `slug` of each SSH key to add."
              },
              "firewall_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the firewalls to attach."
              },
              "network_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the private networks to join."
              },
              "metadata": {
                "type": "object",
                "additionalProperties": true,
                "description": "Your own tags, as string keys and values."
              }
            },
            "description": "What every spare server gets when it boots, such as `ssh_keys`, firewalls, private networks and tags. When you claim a server and add nothing to these, the server is ready as soon as the request returns."
          },
          "target_size": {
            "type": "integer",
            "format": "int64",
            "description": "The number of spare servers the pool currently aims for, from `min_size` to `max_size`. The target grows and shrinks as servers are claimed, and is 0 while the pool is disabled.",
            "readOnly": true
          },
          "available": {
            "type": "integer",
            "format": "int64",
            "description": "How many spare servers are ready to claim right away.",
            "readOnly": true
          },
          "warming": {
            "type": "integer",
            "format": "int64",
            "description": "How many spare servers are still booting.",
            "readOnly": true
          },
          "claims_total": {
            "type": "integer",
            "format": "int64",
            "description": "How many servers have been claimed from the pool.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the pool was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the pool was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the pool and its servers.",
            "examples": [
              "t123"
            ]
          }
        }
      },
      "ServerPoolDocument": {
        "$ref": "#/components/schemas/ServerPool"
      },
      "ServerPoolList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerPool"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerPoolUpdate": {
        "$ref": "#/components/schemas/ServerPoolUpdateAttributes"
      },
      "ServerPoolUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "pattern": "^[a-z0-9]([a-z0-9-]*[a-z0-9])?$",
            "description": "The pool's name. Must be unique in the team, with up to 63 lowercase letters, digits and hyphens, and start and end with a letter or digit. Spare servers are named after the pool, with a hyphen and 6 hex characters added. A server gets its own name when you claim it."
          },
          "min_size": {
            "type": "integer",
            "format": "int64",
            "description": "The fewest spare servers the pool keeps, from 0 up to `max_size`.",
            "default": 0
          },
          "max_size": {
            "type": "integer",
            "format": "int64",
            "description": "The most spare servers the pool keeps. The `max_size` of all your organization's pools together can't be more than its `server_pool_size` quota.",
            "default": 0
          },
          "growth_multiplier": {
            "type": "number",
            "description": "How much the pool grows when you claim a server from an empty pool. `target_size` is multiplied by this factor, from 1 to 10. `1` turns growing off.",
            "default": 2.0
          },
          "shrink_multiplier": {
            "type": "number",
            "description": "How much the pool shrinks while it's full and nobody has claimed a server for `idle_minutes`. Each minute, `target_size` is multiplied by this factor, which is more than 0 and at most 1. `1` turns shrinking off.",
            "default": 0.8
          },
          "idle_minutes": {
            "type": "integer",
            "format": "int64",
            "description": "How many minutes without a claim before the pool shrinks, from 1 to 1440.",
            "default": 5
          },
          "enabled": {
            "type": "boolean",
            "description": "Whether the pool keeps spare servers. A disabled pool removes all its spare servers and keeps its settings. Claiming from a disabled pool is refused.",
            "default": true
          },
          "defaults": {
            "type": "object",
            "properties": {
              "ssh_keys": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The `slug` of each SSH key to add."
              },
              "firewall_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the firewalls to attach."
              },
              "network_ids": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The IDs of the private networks to join."
              },
              "metadata": {
                "type": "object",
                "additionalProperties": true,
                "description": "Your own tags, as string keys and values."
              }
            },
            "description": "What every spare server gets when it boots, such as `ssh_keys`, firewalls, private networks and tags. When you claim a server and add nothing to these, the server is ready as soon as the request returns."
          }
        }
      },
      "ServerPrivateIp": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the private IP on the server, a UUID.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that has the address.",
            "readOnly": true
          },
          "network_id": {
            "type": "string",
            "description": "The ID of the private network the address is in.",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_network",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "ip_prefix",
                "ip_prefix_length"
              ]
            }
          },
          "ip_address": {
            "type": "string",
            "description": "The private IP address.",
            "x-cli-input": {
              "order": 30
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the address was assigned.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the private IP was last updated.",
            "readOnly": true
          }
        }
      },
      "ServerPrivateIpCreate": {
        "$ref": "#/components/schemas/ServerPrivateIpCreateAttributes"
      },
      "ServerPrivateIpCreateAttributes": {
        "type": "object",
        "properties": {
          "network_id": {
            "type": "string",
            "description": "The ID of the private network the address is in. The server must already be attached to the network.",
            "x-cli-input": {
              "order": 20,
              "lookup": "list_network",
              "value_field": "id",
              "label_fields": [
                "name",
                "team_id",
                "ip_prefix",
                "ip_prefix_length"
              ]
            }
          },
          "ip_address": {
            "type": "string",
            "description": "The private IP address. Must be in the network's IP range. Leave it out to get the next free address.",
            "x-cli-input": {
              "order": 30
            }
          }
        },
        "required": [
          "network_id"
        ]
      },
      "ServerPrivateIpDocument": {
        "$ref": "#/components/schemas/ServerPrivateIp"
      },
      "ServerPrivateIpList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerPrivateIp"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerPublicIp": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The ID of the address on this server, a UUID.",
            "readOnly": true
          },
          "ip": {
            "type": "string",
            "description": "The IP address.",
            "readOnly": true
          },
          "type": {
            "type": "string",
            "enum": [
              "ipv4",
              "ipv6"
            ],
            "description": "Whether it's an IPv4 or IPv6 address.",
            "readOnly": true
          },
          "device_name": {
            "type": [
              "string",
              "null"
            ],
            "description": "The network interface on the server that has the address, such as `eth0`.",
            "readOnly": true
          },
          "ptr_record": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reverse DNS name for the address. When the address is a reserved IP, this name replaces the reserved IP's own reverse DNS name."
          }
        }
      },
      "ServerPublicIpDocument": {
        "$ref": "#/components/schemas/ServerPublicIp"
      },
      "ServerPublicIpList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerPublicIp"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerPublicIpUpdate": {
        "$ref": "#/components/schemas/ServerPublicIpUpdateAttributes"
      },
      "ServerPublicIpUpdateAttributes": {
        "type": "object",
        "properties": {
          "ptr_record": {
            "type": [
              "string",
              "null"
            ],
            "description": "The reverse DNS name for the address. When the address is a reserved IP, this name replaces the reserved IP's own reverse DNS name. Send `null` or an empty string to remove it."
          }
        }
      },
      "ServerType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `AM4`. Send it as `server_type` when you create a server.",
            "readOnly": true
          },
          "family": {
            "type": "string",
            "description": "The family the type belongs to. `AM` has shared AMD CPUs, `AMD` dedicated AMD CPUs and `AMS` spot servers on AMD CPUs. `IS` has shared Intel CPUs and `ISS` spot servers on Intel CPUs. `M` runs on dedicated Mac hardware and `G` on dedicated servers with GPUs.",
            "readOnly": true
          },
          "vcpu": {
            "type": "integer",
            "format": "int64",
            "description": "The number of vCPUs.",
            "readOnly": true
          },
          "ram_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory in GiB.",
            "readOnly": true
          },
          "storage_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The root disk size in GiB. A server rescaled down to this type can keep its larger disk.",
            "readOnly": true
          },
          "bandwidth_gbit": {
            "type": "integer",
            "format": "int64",
            "description": "The bandwidth limit in gigabits per second. Each network interface of the server gets this limit in each direction.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "restricted",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "You can order the type when the zone has capacity for it.",
              "restricted": "You can order the type when the zone has capacity for it, the same as `global`.",
              "unavailable": "The type is deprecated. A create or a rescale to it is refused with `type_deprecated` and the name of its replacement."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "readOnly": true
          }
        }
      },
      "ServerTypeAvailability": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The server type's name, such as `AM4`.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "available",
              "over_quota",
              "no_capacity"
            ],
            "description": "Whether you can start the servers now. When both a limit and the zone's capacity stand in the way, the status is `over_quota`.",
            "x-enum-descriptions": {
              "available": "Your organization's limits and the zone allow `count` more servers of this type.",
              "over_quota": "Starting `count` more servers would go over a limit of your organization, such as the number of servers or vCPUs of its tier, `ram_gb` or `public_ipv6_addresses`. A create is refused with `quota_exceeded`.",
              "no_capacity": "Your limits allow the servers, but the zone can't start `count` servers of this type now. A create is refused with `no_capacity`."
            },
            "readOnly": true
          }
        }
      },
      "ServerTypeAvailabilityList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerTypeAvailability"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerTypeDocument": {
        "$ref": "#/components/schemas/ServerType"
      },
      "ServerTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerType"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ServerUpdate": {
        "$ref": "#/components/schemas/ServerUpdateAttributes"
      },
      "ServerUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The server's name. Must be unique among your organization's servers that aren't `destroyed` or `terminated`."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. The server's public IPs and add-ons are billed on the same term. A change applies at once, from `monthly` to `annual` or back.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "subdomain": {
            "type": "boolean",
            "description": "Whether the server has a free subdomain in `onbetterstack.com`, made from its name. The subdomain's records are in `cloudflare_records`. An update adds or removes the subdomain.",
            "default": true
          },
          "vulnerability_monitoring": {
            "type": "boolean",
            "description": "Whether we scan the server daily for open ports and vulnerable software versions. Get the latest findings via [Get a server's security scan](/docs/cloud/api/servers/security-scan-server/).",
            "default": false
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all."
          }
        }
      },
      "Snapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server the snapshot was taken from. `null` once that server is deleted, and you can still get and restore the snapshot.",
            "readOnly": true
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "Whether the snapshot was taken on request or by a schedule.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's status. After you create a snapshot, get it until its `status` is `available`. Only an `available` snapshot can be restored.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "Creating the snapshot failed. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the server's root disk when the snapshot was taken, in bytes. We bill by this size. `null` until the snapshot is taken.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The availability zone the snapshot was taken in. A snapshot from another zone can still be restored into a new server in this zone.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why creating the snapshot failed, or `null` unless the snapshot failed.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null`."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Why and when we locked the snapshot. `null` unless we've locked it. A locked snapshot can't be changed, deleted or restored.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "SnapshotDocument": {
        "$ref": "#/components/schemas/Snapshot"
      },
      "SnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Snapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "SnapshotUpdate": {
        "$ref": "#/components/schemas/SnapshotUpdateAttributes"
      },
      "SnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "SshKey": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "The key's name. Must be unique in its team, up to 255 characters long, and start and end with a letter or digit. Dots, hyphens and underscores are allowed in between. A deleted key's `slug` stays taken until the key is removed from every zone.",
            "pattern": "^[a-zA-Z0-9](?:[a-zA-Z0-9._-]*[a-zA-Z0-9])?$",
            "x-cli-input": {
              "order": 20
            },
            "examples": [
              "my-laptop"
            ]
          },
          "public_key": {
            "type": "string",
            "format": "ssh-public-key",
            "description": "One OpenSSH public key, such as the contents of a `.pub` file. Never send a private key.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEF0uIiLF54lpavoiG7O95cChLJ80vbi0Nh08Kf3+G/a me@example.com"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the key was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the key. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "SshKeyCreate": {
        "$ref": "#/components/schemas/SshKeyCreateAttributes"
      },
      "SshKeyCreateAttributes": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "pattern": "^[a-zA-Z0-9](?:[a-zA-Z0-9._-]*[a-zA-Z0-9])?$",
            "description": "The key's name. Must be unique in its team, up to 255 characters long, and start and end with a letter or digit. Dots, hyphens and underscores are allowed in between. A deleted key's `slug` stays taken until the key is removed from every zone.",
            "x-cli-input": {
              "order": 20
            },
            "examples": [
              "my-laptop"
            ]
          },
          "public_key": {
            "type": "string",
            "format": "ssh-public-key",
            "description": "One OpenSSH public key, such as the contents of a `.pub` file. Never send a private key. Can't be changed after the key is created.",
            "x-cli-input": {
              "order": 30
            },
            "examples": [
              "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEF0uIiLF54lpavoiG7O95cChLJ80vbi0Nh08Kf3+G/a me@example.com"
            ]
          },
          "server_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the servers to add the new key to, at most 100, in any zone. Only running servers get the key. The key is created even when a server can't get it. Order doesn't matter.",
            "x-cli-input": {
              "order": 40
            },
            "writeOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the key. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        },
        "required": [
          "slug",
          "public_key",
          "team_id"
        ]
      },
      "SshKeyDocument": {
        "$ref": "#/components/schemas/SshKey"
      },
      "SshKeyList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SshKey"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "SshKeyUpdate": {
        "$ref": "#/components/schemas/SshKeyUpdateAttributes"
      },
      "SshKeyUpdateAttributes": {
        "type": "object",
        "properties": {
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "Valkey": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The instance's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters."
          },
          "type": {
            "type": "string",
            "description": "The instance's type, such as `VK2`. Get the types via [List Valkey types](/docs/cloud/api/valkey-types/list-valkey-types/).",
            "examples": [
              "VK1"
            ]
          },
          "usable_memory_gb": {
            "type": "integer",
            "format": "int64",
            "description": "Memory for your data on each node, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most client connections the type accepts.",
            "readOnly": true
          },
          "engine_version": {
            "type": "string",
            "description": "The Valkey version, such as `9.1`. Get the versions via [List Valkey versions](/docs/cloud/api/valkey-versions/list-valkey-versions/)."
          },
          "available_engine_versions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The versions you can upgrade the instance to now.",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "provisioning",
              "running",
              "degraded",
              "rescaling",
              "upgrading",
              "restoring",
              "failed",
              "destroyed"
            ],
            "description": "The instance's state. A new instance is ready once it's `running`. A `running` instance can still be adding a replica or opening its public TLS endpoint.",
            "x-enum-descriptions": {
              "provisioning": "We're creating the instance.",
              "running": "The instance is ready.",
              "degraded": "A node doesn't respond. `status_message` says which.",
              "rescaling": "We're changing the type. When the change doesn't complete, `status_message` says so, and so do the instance's events.",
              "upgrading": "We're upgrading the Valkey version. The upgrade is done when the instance is `running` on the new `engine_version`. When the instance is `running` on the old version, the upgrade failed.",
              "restoring": "We're restoring a snapshot onto the instance. The restore is done when the instance is `running`.",
              "failed": "The instance couldn't be created. A failed instance stays in this state.",
              "destroyed": "The instance is deleted."
            },
            "readOnly": true
          },
          "status_message": {
            "type": [
              "string",
              "null"
            ],
            "description": "What needs attention now, such as a node that doesn't respond or a rescale or upgrade that didn't complete. `null` when nothing needs attention.",
            "readOnly": true
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "noeviction",
              "allkeys-lru",
              "allkeys-lfu",
              "allkeys-random",
              "volatile-lru",
              "volatile-lfu",
              "volatile-random",
              "volatile-ttl"
            ],
            "description": "What Valkey does when memory is full, as its `maxmemory-policy` setting.",
            "x-enum-descriptions": {
              "noeviction": "Valkey refuses writes when memory is full.",
              "allkeys-lru": "Valkey evicts the least recently used keys.",
              "allkeys-lfu": "Valkey evicts the least frequently used keys.",
              "allkeys-random": "Valkey evicts random keys.",
              "volatile-lru": "Valkey evicts the least recently used keys that have an expiry.",
              "volatile-lfu": "Valkey evicts the least frequently used keys that have an expiry.",
              "volatile-random": "Valkey evicts random keys that have an expiry.",
              "volatile-ttl": "Valkey evicts the keys with an expiry that expire soonest."
            }
          },
          "persistence": {
            "type": "string",
            "enum": [
              "rdb",
              "none"
            ],
            "description": "Whether Valkey keeps the data across restarts. Snapshots work either way.",
            "x-enum-descriptions": {
              "rdb": "Valkey keeps the data across restarts.",
              "none": "Valkey keeps the data in memory only, as a pure cache."
            }
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the primary accepts connections with TLS on a public IP, on port 6380."
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many replicas the instance has besides the primary, from `0` to `2`."
          },
          "endpoint": {
            "type": "object",
            "properties": {
              "hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname to connect to from your private networks. Always points at the current primary's addresses in those networks."
              },
              "public_hostname": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The hostname to connect to from the internet, on the public TLS endpoint, or `null` when `public_access` is off. Always points at the current primary's public IP addresses."
              },
              "port": {
                "type": "integer",
                "format": "int64",
                "description": "The port without TLS on private networks, `6379`."
              },
              "tls_port": {
                "type": [
                  "integer",
                  "null"
                ],
                "format": "int64",
                "description": "The public TLS port, `6380`, or `null` when `public_access` is off."
              },
              "private_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "network_id": {
                      "type": "string",
                      "description": "The ID of the private network."
                    },
                    "ip_address": {
                      "type": "string",
                      "description": "The primary's IP address in that network."
                    }
                  }
                },
                "description": "The primary's addresses in the attached private networks."
              },
              "public_ips": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "description": "The public IP address."
                    },
                    "type": {
                      "type": "string",
                      "description": "The address type, `ipv4` or `ipv6`."
                    }
                  }
                },
                "description": "The primary's public IP addresses, empty when `public_access` is off."
              }
            },
            "description": "Where to connect to the current primary.",
            "readOnly": true
          },
          "members": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The node's ID."
                },
                "role": {
                  "type": "string",
                  "enum": [
                    "primary",
                    "replica"
                  ],
                  "description": "The node's role.\n\n- `primary`: The node accepts writes.\n- `replica`: The node copies the primary and serves reads.",
                  "x-enum-descriptions": {
                    "primary": "The node accepts writes.",
                    "replica": "The node copies the primary and serves reads."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "provisioning",
                    "syncing",
                    "running",
                    "down"
                  ],
                  "description": "The node's state. Send traffic to a node only while it's `running`.\n\n- `provisioning`: We're creating the node.\n- `syncing`: The replica is copying the primary's data.\n- `running`: The node serves traffic.\n- `down`: The node doesn't respond.",
                  "x-enum-descriptions": {
                    "provisioning": "We're creating the node.",
                    "syncing": "The replica is copying the primary's data.",
                    "running": "The node serves traffic.",
                    "down": "The node doesn't respond."
                  }
                },
                "replication_lag_bytes": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "int64",
                  "description": "How far the replica is behind the primary, in bytes, or `null` for the primary."
                },
                "private_ips": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "network_id": {
                        "type": "string",
                        "description": "The ID of the private network."
                      },
                      "ip_address": {
                        "type": "string",
                        "description": "The node's IP address in that network."
                      }
                    }
                  },
                  "description": "The node's addresses in the attached private networks."
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "description": "When the node was created."
                }
              }
            },
            "description": "The instance's primary and replicas, with their addresses in your private networks.",
            "readOnly": true
          },
          "network_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The IDs of the private networks attached to the instance. Order doesn't matter."
          },
          "firewall_ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "uniqueItems": true,
            "x-unordered": true,
            "description": "The ID of the firewall attached to the instance. An instance can have at most one firewall. Order doesn't matter."
          },
          "latest_snapshot_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the newest available snapshot was created, or `null` when the instance has no snapshot.",
            "readOnly": true
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the instance was last changed.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the instance.",
            "examples": [
              "t123"
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "ValkeyDocument": {
        "$ref": "#/components/schemas/Valkey"
      },
      "ValkeyEvent": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The event's ID, a UUID.",
            "readOnly": true
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance the event belongs to.",
            "readOnly": true
          },
          "action": {
            "type": "string",
            "description": "What happened, such as `created`, `rescaled` or `failed_over`. An event for a request is recorded when we accept the request, before the work is done.",
            "readOnly": true
          },
          "user_id": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The ID of the Better Stack user who did it. `null` unless `actor` is `user`.",
            "readOnly": true
          },
          "actor": {
            "type": "string",
            "enum": [
              "user",
              "api_token",
              "system"
            ],
            "description": "Who did it.",
            "x-enum-descriptions": {
              "user": "A Better Stack user did it. `user_id` says who.",
              "api_token": "A request with an API token did it.",
              "system": "Better Stack did it, such as a failover."
            },
            "readOnly": true
          },
          "details": {
            "type": "object",
            "additionalProperties": true,
            "description": "More about the action, such as the snapshot ID, the new type or the nodes of a failover.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the event happened.",
            "readOnly": true
          }
        }
      },
      "ValkeyEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValkeyEvent"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ValkeyList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Valkey"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ValkeyScheduledSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The schedule ID, a UUID.",
            "readOnly": true
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance.",
            "readOnly": true
          },
          "server_id": {
            "type": "string",
            "description": "The ID of the server that runs the instance's current primary. Changes after a failover.",
            "readOnly": true
          },
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          },
          "last_run_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "description": "When the schedule last ran, or `null` before the first run.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the schedule was last updated.",
            "readOnly": true
          }
        }
      },
      "ValkeyScheduledSnapshotCreate": {
        "$ref": "#/components/schemas/ValkeyScheduledSnapshotCreateAttributes"
      },
      "ValkeyScheduledSnapshotCreateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        },
        "required": [
          "frequency"
        ]
      },
      "ValkeyScheduledSnapshotDocument": {
        "$ref": "#/components/schemas/ValkeyScheduledSnapshot"
      },
      "ValkeyScheduledSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValkeyScheduledSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ValkeyScheduledSnapshotUpdate": {
        "$ref": "#/components/schemas/ValkeyScheduledSnapshotUpdateAttributes"
      },
      "ValkeyScheduledSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "frequency": {
            "type": "string",
            "enum": [
              "hourly",
              "daily",
              "weekly",
              "monthly"
            ],
            "description": "How often we create a snapshot. A `monthly` schedule follows calendar months."
          }
        }
      },
      "ValkeySnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The snapshot's ID, a UUID.",
            "readOnly": true
          },
          "valkey_id": {
            "type": "string",
            "description": "The ID of the Valkey instance the snapshot was taken from.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server that ran the instance's primary. The server isn't in your list of servers. Can become `null` after the server is deleted.",
            "readOnly": true
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.",
            "x-enum-descriptions": {
              "manual": "A request created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. A new snapshot is ready once it's `available`.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready to restore.",
              "failed": "The snapshot couldn't be created. `failure_reason` says why.",
              "deleting": "We're removing the snapshot's data. The snapshot is gone once we're done."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The size of the instance's disk when the snapshot was taken, in bytes. We bill by this size. `null` until the snapshot is ready.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The availability zone the snapshot was taken in. A restore creates the new instance in the same zone.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the snapshot couldn't be created, or `null` unless the snapshot is `failed`.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the snapshot."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null` when there's nothing more."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the snapshot."
              }
            },
            "description": "Our lock on the snapshot, or `null` when it isn't locked.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10."
          }
        }
      },
      "ValkeySnapshotDocument": {
        "$ref": "#/components/schemas/ValkeySnapshot"
      },
      "ValkeySnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValkeySnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "ValkeyType": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The type's name, such as `VK1`. Send it as `type` when you create or rescale an instance.",
            "readOnly": true
          },
          "usable_memory_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The memory for your data on each node, in GiB.",
            "readOnly": true
          },
          "max_connections": {
            "type": "integer",
            "format": "int64",
            "description": "The most connections an instance of this type accepts at once.",
            "readOnly": true
          },
          "availability": {
            "type": "string",
            "enum": [
              "global",
              "unavailable"
            ],
            "description": "Whether you can order the type.",
            "x-enum-descriptions": {
              "global": "You can order the type.",
              "unavailable": "The type is deprecated. Instances that have it keep running, but you can't create or rescale an instance to it."
            },
            "readOnly": true
          },
          "replacement": {
            "type": [
              "string",
              "null"
            ],
            "description": "The name of the type to use in place of this deprecated one, or `null` for a type we offer.",
            "readOnly": true
          }
        }
      },
      "ValkeyTypeDocument": {
        "$ref": "#/components/schemas/ValkeyType"
      },
      "ValkeyTypeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValkeyType"
            }
          }
        }
      },
      "ValkeyUpdate": {
        "$ref": "#/components/schemas/ValkeyUpdateAttributes"
      },
      "ValkeyUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The instance's name, at most 255 characters. Must be unique among your organization's Valkey instances that aren't `destroyed` or `failed`."
          },
          "eviction_policy": {
            "type": "string",
            "enum": [
              "noeviction",
              "allkeys-lru",
              "allkeys-lfu",
              "allkeys-random",
              "volatile-lru",
              "volatile-lfu",
              "volatile-random",
              "volatile-ttl"
            ],
            "description": "What Valkey does when memory is full, as its `maxmemory-policy` setting.",
            "x-enum-descriptions": {
              "noeviction": "Valkey refuses writes when memory is full.",
              "allkeys-lru": "Valkey evicts the least recently used keys.",
              "allkeys-lfu": "Valkey evicts the least frequently used keys.",
              "allkeys-random": "Valkey evicts random keys.",
              "volatile-lru": "Valkey evicts the least recently used keys that have an expiry.",
              "volatile-lfu": "Valkey evicts the least frequently used keys that have an expiry.",
              "volatile-random": "Valkey evicts random keys that have an expiry.",
              "volatile-ttl": "Valkey evicts the keys with an expiry that expire soonest."
            }
          },
          "persistence": {
            "type": "string",
            "enum": [
              "rdb",
              "none"
            ],
            "description": "Whether Valkey keeps the data across restarts. Snapshots work either way.",
            "x-enum-descriptions": {
              "rdb": "Valkey keeps the data across restarts.",
              "none": "Valkey keeps the data in memory only, as a pure cache."
            }
          },
          "public_access": {
            "type": "boolean",
            "description": "Whether the primary accepts connections with TLS on a public IP, on port 6380. The port opens shortly after the response."
          },
          "replica_count": {
            "type": "integer",
            "format": "int64",
            "description": "How many replicas the instance has besides the primary, from `0` to `2`. We add or remove replicas shortly after the response."
          },
          "term": {
            "type": "string",
            "enum": [
              "monthly",
              "annual"
            ],
            "description": "The billing term. On update, a new term starts at once, and billing ends the current one.",
            "x-enum-descriptions": {
              "monthly": "Billed each month.",
              "annual": "Paid for a year at a time."
            },
            "default": "monthly"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. On update, the tags you send replace every tag, so an empty object removes them all."
          }
        }
      },
      "ValkeyVersion": {
        "type": "object",
        "properties": {
          "engine_version": {
            "type": "string",
            "description": "The Valkey version as major and minor, such as `9.1`.",
            "readOnly": true,
            "examples": [
              "9.1"
            ]
          },
          "latest": {
            "type": "boolean",
            "description": "Whether a new instance gets this version when you leave out `engine_version`.",
            "readOnly": true
          }
        }
      },
      "ValkeyVersionList": {
        "type": "object",
        "properties": {
          "versions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValkeyVersion"
            }
          }
        }
      },
      "Volume": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The volume's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The volume's name."
          },
          "status": {
            "type": "string",
            "enum": [
              "creating",
              "attaching",
              "attached",
              "detaching",
              "available",
              "moving",
              "resizing",
              "snapshotting",
              "deleting",
              "failed",
              "destroyed"
            ],
            "description": "The volume's state. While a change to the volume is in progress, other changes to it are refused.",
            "x-enum-descriptions": {
              "creating": "We're creating the volume.",
              "attaching": "We're attaching the volume to a server.",
              "attached": "The volume is attached to a server.",
              "detaching": "We're detaching the volume.",
              "available": "The volume isn't attached to a server. A new volume that ends up `available` couldn't be attached, and `failure_reason` says why.",
              "moving": "We're copying the volume to the host of the server you're attaching it to.",
              "resizing": "We're growing the volume.",
              "snapshotting": "We're creating a snapshot of the volume.",
              "deleting": "We're deleting the volume.",
              "failed": "We couldn't create the volume. A failed volume stays in this state.",
              "destroyed": "The volume is deleted."
            },
            "readOnly": true
          },
          "volume_type": {
            "type": "string",
            "enum": [
              "nvme"
            ],
            "description": "The kind of storage, always `nvme`.",
            "default": "nvme"
          },
          "size_gb": {
            "type": "integer",
            "format": "int64",
            "description": "The volume's size in GiB, from 1 to 3072.",
            "examples": [
              10
            ]
          },
          "server_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the server the volume is attached to, or `null` when the volume isn't attached."
          },
          "format": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "ext4",
              "xfs",
              null
            ],
            "description": "The filesystem we created on the volume, or `null` for a volume without a filesystem."
          },
          "auto_mount": {
            "type": "boolean",
            "description": "Whether the server mounts the volume automatically when it's attached.",
            "default": false
          },
          "mount_path": {
            "type": [
              "string",
              "null"
            ],
            "description": "Where the server mounts the volume, under `/mnt`, or `null` when the volume isn't mounted.",
            "readOnly": true
          },
          "device_path": {
            "type": [
              "string",
              "null"
            ],
            "description": "The volume's device path on the server, under `/dev/disk/by-id`. Use the device path in `/etc/fstab`, since it doesn't change. `null` while the volume isn't attached.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why the last change to the volume failed, such as an attach, detach or resize. The reason stays after the volume is back to `available` or `attached`.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the volume."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null`."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the volume."
              }
            },
            "description": "Our lock on the volume, or `null`. A locked volume can't be changed. Every change is refused with the code `locked`.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the volume was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the volume was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the volume. A volume belongs to the team of the server you created it on.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "VolumeDocument": {
        "$ref": "#/components/schemas/Volume"
      },
      "VolumeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Volume"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "VolumeSnapshot": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The volume snapshot's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "volume_id": {
            "type": [
              "string",
              "null"
            ],
            "description": "The ID of the volume the snapshot was taken from, or `null` once that volume is deleted. You can still get and restore a snapshot of a deleted volume.",
            "readOnly": true
          },
          "snapshot_type": {
            "type": "string",
            "enum": [
              "manual",
              "scheduled"
            ],
            "description": "How the snapshot was created.",
            "x-enum-descriptions": {
              "manual": "You created the snapshot.",
              "scheduled": "A snapshot schedule created the snapshot."
            },
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "available",
              "failed",
              "deleting"
            ],
            "description": "The snapshot's state. A new snapshot is ready when it's `available`.",
            "x-enum-descriptions": {
              "pending": "We're creating the snapshot.",
              "available": "The snapshot is ready, and you can restore it.",
              "failed": "We couldn't create the snapshot. `failure_reason` says why.",
              "deleting": "We're deleting the snapshot."
            },
            "readOnly": true
          },
          "size_bytes": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The volume's size in bytes when the snapshot was taken, the same size as `size_gb`. We bill the snapshot by this size. `null` until the snapshot is ready.",
            "readOnly": true
          },
          "size_gb": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int64",
            "description": "The volume's size in GB. A volume restored from the snapshot gets this size.",
            "readOnly": true
          },
          "availability_zone": {
            "type": [
              "string",
              "null"
            ],
            "description": "The availability zone the snapshot was taken in.",
            "readOnly": true
          },
          "failure_reason": {
            "type": [
              "string",
              "null"
            ],
            "description": "Why creating the snapshot failed, or `null` unless the snapshot is `failed`.",
            "readOnly": true
          },
          "lock": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "fraud",
                  "non_payment",
                  "abuse",
                  "legal",
                  "security",
                  "maintenance",
                  "other"
                ],
                "description": "Why we locked the volume snapshot."
              },
              "details": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "More about the lock, or `null`."
              },
              "locked_at": {
                "type": "string",
                "format": "date-time",
                "description": "When we locked the volume snapshot."
              }
            },
            "description": "Our lock on the volume snapshot, or `null`. A locked volume snapshot can't be changed, deleted or restored.",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was taken.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the snapshot was last updated.",
            "readOnly": true
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "VolumeSnapshotDocument": {
        "$ref": "#/components/schemas/VolumeSnapshot"
      },
      "VolumeSnapshotList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VolumeSnapshot"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "VolumeSnapshotUpdate": {
        "$ref": "#/components/schemas/VolumeSnapshotUpdateAttributes"
      },
      "VolumeSnapshotUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The snapshot's name."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "VolumeUpdate": {
        "$ref": "#/components/schemas/VolumeUpdateAttributes"
      },
      "VolumeUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The volume's name. Must be unique among the organization's volumes. A deleted volume's name can be used again."
          },
          "metadata": {
            "type": "object",
            "additionalProperties": true,
            "description": "Your own tags, as string keys and values. At most 10. An update replaces every tag. Send an empty object to remove them all.",
            "x-cli-input": {
              "order": 100,
              "group": "Advanced"
            }
          }
        }
      },
      "Webhook": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The webhook's ID, a UUID.",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "description": "The webhook's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "url": {
            "type": "string",
            "description": "The URL we send notifications to.",
            "x-cli-input": {
              "order": 30
            }
          },
          "webhook_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources we notify about. Accepts `server`, `snapshot`, `reserved_ip`, `network`, `firewall`, `ssh_key`, `placement_group`, `scheduled_snapshot`, `load_balancer`, `certificate`, `volume`, `volume_snapshot`, `scheduled_volume_snapshot`, `valkey`, `mysql`, `postgres`, `clickhouse`, `kafka` and `object_proxy`. `object_proxy` covers object caches. A notification names its kind in its `object` field.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether we send notifications to the webhook.",
            "x-enum-descriptions": {
              "active": "We send notifications.",
              "paused": "We send no notifications until you set it back to `active`."
            },
            "x-cli-input": {
              "order": 50
            },
            "default": "active"
          },
          "failed_deliveries": {
            "type": "integer",
            "format": "int64",
            "description": "The number of notifications in a row that we couldn't deliver. A delivered notification resets the count to `0`.",
            "readOnly": true
          },
          "secret": {
            "type": "string",
            "description": "The secret we sign notifications with. Each notification has an `X-Signature` header, `sha256=` followed by the HMAC-SHA256 of the body made with this secret. We create the secret with the webhook, and every response includes it.",
            "x-sensitive": true,
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the webhook was created.",
            "readOnly": true
          },
          "updated_at": {
            "type": "string",
            "format": "date-time",
            "description": "When the webhook was last updated.",
            "readOnly": true
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the webhook. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        }
      },
      "WebhookCreate": {
        "$ref": "#/components/schemas/WebhookCreateAttributes"
      },
      "WebhookCreateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The webhook's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "url": {
            "type": "string",
            "description": "The URL we send notifications to. Use an HTTPS URL to protect what the notifications contain. To check that the URL receives notifications, use [Test a webhook](/docs/cloud/api/webhooks/test-webhook/).",
            "x-cli-input": {
              "order": 30
            }
          },
          "webhook_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources we notify about. Accepts `server`, `snapshot`, `reserved_ip`, `network`, `firewall`, `ssh_key`, `placement_group`, `scheduled_snapshot`, `load_balancer`, `certificate`, `volume`, `volume_snapshot`, `scheduled_volume_snapshot`, `valkey`, `mysql`, `postgres`, `clickhouse`, `kafka` and `object_proxy`. `object_proxy` covers object caches. A notification names its kind in its `object` field.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether we send notifications to the webhook.",
            "x-enum-descriptions": {
              "active": "We send notifications.",
              "paused": "We send no notifications until you set it back to `active`."
            },
            "x-cli-input": {
              "order": 50
            },
            "default": "active"
          },
          "team_id": {
            "type": "string",
            "pattern": "^t[1-9][0-9]*$",
            "description": "The ID of the team that owns the webhook. Get the team ID via [List teams](/docs/uptime/api/teams/list/).",
            "x-cli-input": {
              "order": 10
            },
            "examples": [
              "t123"
            ]
          }
        },
        "required": [
          "name",
          "url",
          "webhook_types",
          "team_id"
        ]
      },
      "WebhookDocument": {
        "$ref": "#/components/schemas/Webhook"
      },
      "WebhookList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Webhook"
            }
          },
          "meta": {
            "$ref": "#/components/schemas/PaginationCloudPageTotal"
          }
        }
      },
      "WebhookUpdate": {
        "$ref": "#/components/schemas/WebhookUpdateAttributes"
      },
      "WebhookUpdateAttributes": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The webhook's name.",
            "x-cli-input": {
              "order": 20
            }
          },
          "url": {
            "type": "string",
            "description": "The URL we send notifications to. Use an HTTPS URL to protect what the notifications contain. To check that the URL receives notifications, use [Test a webhook](/docs/cloud/api/webhooks/test-webhook/).",
            "x-cli-input": {
              "order": 30
            }
          },
          "webhook_types": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The kinds of resources we notify about. Accepts `server`, `snapshot`, `reserved_ip`, `network`, `firewall`, `ssh_key`, `placement_group`, `scheduled_snapshot`, `load_balancer`, `certificate`, `volume`, `volume_snapshot`, `scheduled_volume_snapshot`, `valkey`, `mysql`, `postgres`, `clickhouse`, `kafka` and `object_proxy`. `object_proxy` covers object caches. A notification names its kind in its `object` field.",
            "x-cli-input": {
              "order": 40
            },
            "examples": [
              [
                "server"
              ]
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "paused"
            ],
            "description": "Whether we send notifications to the webhook.",
            "x-enum-descriptions": {
              "active": "We send notifications.",
              "paused": "We send no notifications until you set it back to `active`."
            },
            "x-cli-input": {
              "order": 50
            },
            "default": "active"
          }
        }
      }
    }
  }
}
