> For the complete documentation index, see [llms.txt](https://docs.platform9.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.platform9.com/api-docs/kubernetes-service/models.md).

# Models

## The Status object

```json
{"openapi":"3.0.3","info":{"title":"PCD-K Cluster API","version":"v1beta1"},"components":{"schemas":{"Status":{"type":"object","properties":{"apiVersion":{"type":"string"},"kind":{"type":"string"},"metadata":{"type":"object","description":"Always present; typically empty (`{}`)."},"status":{"type":"string","enum":["Success","Failure"]},"message":{"type":"string","description":"Human-readable description of the error."},"reason":{"type":"string","description":"Machine-readable reason. Common values: `NotFound`, `AlreadyExists`, `BadRequest`, `Unauthorized`, `Forbidden`, `Invalid`.\n"},"details":{"type":"object","description":"Additional error context. Present on `NotFound` (includes `name`, `group`, `kind`) and `Invalid` / `422` responses (includes `causes` with per-field errors).\n","properties":{"name":{"type":"string","description":"Name of the resource involved."},"group":{"type":"string","description":"API group of the resource (e.g. `cluster.x-k8s.io`)."},"kind":{"type":"string","description":"Resource kind (e.g. `clusters`)."},"causes":{"type":"array","description":"Per-field validation errors (present on `422` responses).","items":{"type":"object","properties":{"reason":{"type":"string"},"message":{"type":"string"},"field":{"type":"string"}}}}}},"code":{"type":"integer","description":"HTTP status code."}}}}}}
```

## The ClusterRequest object

```json
{"openapi":"3.0.3","info":{"title":"PCD-K Cluster API","version":"v1beta1"},"components":{"schemas":{"ClusterRequest":{"type":"object","required":["apiVersion","kind","metadata","spec"],"properties":{"apiVersion":{"type":"string","enum":["cluster.x-k8s.io/v1beta1"]},"kind":{"type":"string","enum":["Cluster"]},"metadata":{"type":"object","required":["name"],"properties":{"name":{"type":"string"}}},"spec":{"type":"object","required":["topology"],"properties":{"controlPlaneEndpoint":{"type":"object","description":"API server endpoint — webhook-generated from `deploymentUnit` variables, not set by the user.\nFormat: `<cluster-name>.<keystone-domain>-<keystone-tenant>.k8s.<du-name>.<du-domain>`.\nUse this host:port to reach the workload cluster's Kubernetes API.\n","properties":{"host":{"type":"string"},"port":{"type":"integer"}}},"topology":{"type":"object","required":["version","workers","variables"],"properties":{"version":{"type":"string","description":"Kubernetes version (no `v` prefix)."},"class":{"type":"string","enum":["openstack-default-v1","byoh-default-v1"],"description":"Webhook-resolved from `infrastructure.type` and `deploymentUnit.type` — omit this field.\nSet `infrastructure.type: byoh` in variables to use `byoh-default-v1`; otherwise `openstack-default-v1` is used.\n"},"classNamespace":{"type":"string","enum":["kaapi"],"description":"Webhook-set to `kaapi` — omit this field."},"workers":{"type":"object","properties":{"machineDeployments":{"type":"array","items":{"$ref":"#/components/schemas/MachineDeployment"}}}},"variables":{"type":"array","description":"Each entry is `{ name: <variable>, value: <object> }`.\nThe webhook manages `kubeadmConfigFiles`, `customSecurityGroupRules`, and\nsystem-required `apiServerFlags` automatically — do not set these.\n\n| Variable | Schema | Required | Notes |\n|---|---|---|---|\n| `deploymentUnit` | `DeploymentUnitValue` | Always | `name`, `domain`, `region` are required fields |\n| `network` | `NetworkValue` | OpenStack only | `networkID`, `subnetID` UUIDs |\n| `infrastructure` | `InfrastructureValue` | Only for BYOH | Omit entirely for OpenStack |\n| `workerNode` | `WorkerNodeValue` | OpenStack per-pool override | `flavor`, `imageName` required |\n| `rootVolume` | `RootVolumeValue` | Optional, OpenStack | Boot from Cinder volume |\n| `apiServerFlags` | string array | Optional | Merged with system defaults |\n| `controllerManagerFlags` | string array | Optional | — |\n| `schedulerFlags` | string array | Optional | — |\n| `enableSSH` | boolean | Optional, OpenStack | Adds SSH security group rule |\n| `allowedAddressPairs` | string array | Optional, OpenStack | CIDRs for allowed address pairs |\n","items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string"},"value":{}}}}}}}}}},"MachineDeployment":{"type":"object","required":["name","class"],"properties":{"name":{"type":"string","description":"Pool name — must be unique within the cluster."},"class":{"type":"string","enum":["ost-md","byoh-md"],"description":"`ost-md` for OpenStack worker pools; `byoh-md` for BYOH pools."},"replicas":{"type":"integer","minimum":0,"description":"Fixed replica count. Omit when enabling cluster autoscaler."},"failureDomain":{"type":"string","description":"Virtualized cluster name"},"metadata":{"type":"object","properties":{"annotations":{"type":"object","additionalProperties":{"type":"string"},"description":"Autoscaler annotations — set both to enable, null both to disable:\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-min-size`\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-max-size`\n"}}},"variables":{"type":"object","description":"Per-pool variable overrides. OpenStack pools use `workerNode` (and optionally\n`rootVolume`) here. BYOH pools do not use overrides.\n","properties":{"overrides":{"type":"array","items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","enum":["workerNode","rootVolume","network"]},"value":{}}}}}}}}}}}
```

## The Cluster object

```json
{"openapi":"3.0.3","info":{"title":"PCD-K Cluster API","version":"v1beta1"},"components":{"schemas":{"Cluster":{"allOf":[{"$ref":"#/components/schemas/ClusterRequest"},{"type":"object","properties":{"metadata":{"type":"object","properties":{"namespace":{"type":"string","description":"Tenant namespace the cluster belongs to."},"uid":{"type":"string","format":"uuid"},"resourceVersion":{"type":"string"},"creationTimestamp":{"type":"string","format":"date-time"},"deletionTimestamp":{"type":"string","format":"date-time","description":"Set when deletion is in progress. Present until all finalizers are removed."},"labels":{"type":"object","additionalProperties":{"type":"string"},"description":"Labels set by the webhook and controllers. Do not rely on specific values for business logic."},"finalizers":{"type":"array","items":{"type":"string"},"description":"CAPI finalizers preventing premature deletion."}}},"status":{"type":"object","properties":{"phase":{"type":"string","enum":["Provisioning","Provisioned","Deleting","Failed"]},"controlPlaneReady":{"type":"boolean"},"infrastructureReady":{"type":"boolean"},"failureMessage":{"type":"string","description":"Human-readable error message when `phase` is `Failed`."},"failureDomains":{"type":"object","description":"Map of OpenStack availability zone names to their control-plane eligibility.\nPopulated from the `OpenStackCluster` status after infrastructure is ready.\n","additionalProperties":{"type":"object","properties":{"controlPlane":{"type":"boolean"}}}},"conditions":{"type":"array","description":"Standard CAPI conditions. Key `type` values to watch:\n`Ready`, `ControlPlaneInitialized`, `ControlPlaneReady`,\n`InfrastructureReady`, `TopologyReconciled`.\nAll conditions reach `status: \"True\"` when the cluster is fully provisioned.\n","items":{"type":"object","properties":{"type":{"type":"string"},"status":{"type":"string","enum":["True","False","Unknown"]},"reason":{"type":"string"},"message":{"type":"string"},"lastTransitionTime":{"type":"string","format":"date-time"}}}}}}}}]},"ClusterRequest":{"type":"object","required":["apiVersion","kind","metadata","spec"],"properties":{"apiVersion":{"type":"string","enum":["cluster.x-k8s.io/v1beta1"]},"kind":{"type":"string","enum":["Cluster"]},"metadata":{"type":"object","required":["name"],"properties":{"name":{"type":"string"}}},"spec":{"type":"object","required":["topology"],"properties":{"controlPlaneEndpoint":{"type":"object","description":"API server endpoint — webhook-generated from `deploymentUnit` variables, not set by the user.\nFormat: `<cluster-name>.<keystone-domain>-<keystone-tenant>.k8s.<du-name>.<du-domain>`.\nUse this host:port to reach the workload cluster's Kubernetes API.\n","properties":{"host":{"type":"string"},"port":{"type":"integer"}}},"topology":{"type":"object","required":["version","workers","variables"],"properties":{"version":{"type":"string","description":"Kubernetes version (no `v` prefix)."},"class":{"type":"string","enum":["openstack-default-v1","byoh-default-v1"],"description":"Webhook-resolved from `infrastructure.type` and `deploymentUnit.type` — omit this field.\nSet `infrastructure.type: byoh` in variables to use `byoh-default-v1`; otherwise `openstack-default-v1` is used.\n"},"classNamespace":{"type":"string","enum":["kaapi"],"description":"Webhook-set to `kaapi` — omit this field."},"workers":{"type":"object","properties":{"machineDeployments":{"type":"array","items":{"$ref":"#/components/schemas/MachineDeployment"}}}},"variables":{"type":"array","description":"Each entry is `{ name: <variable>, value: <object> }`.\nThe webhook manages `kubeadmConfigFiles`, `customSecurityGroupRules`, and\nsystem-required `apiServerFlags` automatically — do not set these.\n\n| Variable | Schema | Required | Notes |\n|---|---|---|---|\n| `deploymentUnit` | `DeploymentUnitValue` | Always | `name`, `domain`, `region` are required fields |\n| `network` | `NetworkValue` | OpenStack only | `networkID`, `subnetID` UUIDs |\n| `infrastructure` | `InfrastructureValue` | Only for BYOH | Omit entirely for OpenStack |\n| `workerNode` | `WorkerNodeValue` | OpenStack per-pool override | `flavor`, `imageName` required |\n| `rootVolume` | `RootVolumeValue` | Optional, OpenStack | Boot from Cinder volume |\n| `apiServerFlags` | string array | Optional | Merged with system defaults |\n| `controllerManagerFlags` | string array | Optional | — |\n| `schedulerFlags` | string array | Optional | — |\n| `enableSSH` | boolean | Optional, OpenStack | Adds SSH security group rule |\n| `allowedAddressPairs` | string array | Optional, OpenStack | CIDRs for allowed address pairs |\n","items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string"},"value":{}}}}}}}}}},"MachineDeployment":{"type":"object","required":["name","class"],"properties":{"name":{"type":"string","description":"Pool name — must be unique within the cluster."},"class":{"type":"string","enum":["ost-md","byoh-md"],"description":"`ost-md` for OpenStack worker pools; `byoh-md` for BYOH pools."},"replicas":{"type":"integer","minimum":0,"description":"Fixed replica count. Omit when enabling cluster autoscaler."},"failureDomain":{"type":"string","description":"Virtualized cluster name"},"metadata":{"type":"object","properties":{"annotations":{"type":"object","additionalProperties":{"type":"string"},"description":"Autoscaler annotations — set both to enable, null both to disable:\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-min-size`\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-max-size`\n"}}},"variables":{"type":"object","description":"Per-pool variable overrides. OpenStack pools use `workerNode` (and optionally\n`rootVolume`) here. BYOH pools do not use overrides.\n","properties":{"overrides":{"type":"array","items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","enum":["workerNode","rootVolume","network"]},"value":{}}}}}}}}}}}
```

## The MachineDeployment object

```json
{"openapi":"3.0.3","info":{"title":"PCD-K Cluster API","version":"v1beta1"},"components":{"schemas":{"MachineDeployment":{"type":"object","required":["name","class"],"properties":{"name":{"type":"string","description":"Pool name — must be unique within the cluster."},"class":{"type":"string","enum":["ost-md","byoh-md"],"description":"`ost-md` for OpenStack worker pools; `byoh-md` for BYOH pools."},"replicas":{"type":"integer","minimum":0,"description":"Fixed replica count. Omit when enabling cluster autoscaler."},"failureDomain":{"type":"string","description":"Virtualized cluster name"},"metadata":{"type":"object","properties":{"annotations":{"type":"object","additionalProperties":{"type":"string"},"description":"Autoscaler annotations — set both to enable, null both to disable:\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-min-size`\n- `cluster.x-k8s.io/cluster-api-autoscaler-node-group-max-size`\n"}}},"variables":{"type":"object","description":"Per-pool variable overrides. OpenStack pools use `workerNode` (and optionally\n`rootVolume`) here. BYOH pools do not use overrides.\n","properties":{"overrides":{"type":"array","items":{"type":"object","required":["name","value"],"properties":{"name":{"type":"string","enum":["workerNode","rootVolume","network"]},"value":{}}}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.platform9.com/api-docs/kubernetes-service/models.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
