# Blueprint

## GET /blueprint

> List all blueprints

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"Blueprint":{"required":["name"],"type":"object","properties":{"name":{"description":"Cluster name","type":"string"},"networkingType":{"description":"Defaults to OVN","default":"ovn","enum":["ovn","ovs"],"type":"string"},"enableDistributedRouting":{"description":"Enable Cluster Wide Distributed Network Routing","default":true,"type":"boolean"},"dnsDomainName":{"description":"DNS Domain Name","type":"string"},"virtualNetworking":{"$ref":"#/components/schemas/VirtualNetworking"},"vmHighAvailability":{"$ref":"#/components/schemas/VMHighAvailability"},"autoResourceRebalancing":{"$ref":"#/components/schemas/AutoResourceRebalancing"},"imageLibraryStorage":{"description":"Library location on filesystem or Cinder volume type","type":"string"},"vmStorage":{"description":"Ephemeral Virtual Machine storage path","type":"string"},"storageBackends":{"$ref":"#/components/schemas/StorageBackends"}}},"VirtualNetworking":{"type":"object","properties":{"enabled":{"description":"Enable Virtual Networking","default":true,"type":"boolean"},"underlayType":{"description":"Underlay Technology","default":"vlan","enum":["vlan","other"],"type":"string"},"vnidRange":{"description":"VLAN / VNID Range","type":"string"}}},"VMHighAvailability":{"type":"object","properties":{"enabled":{"description":"Automatically detect host failure and recover VMs on other cluster hosts","default":false,"type":"boolean"}}},"AutoResourceRebalancing":{"type":"object","properties":{"enabled":{"description":"Automatically rebalance workloads across hosts in the cluster","default":false,"type":"boolean"},"rebalancingStrategy":{"description":"Defaults to vm_workload_consolidation, other supported value is node_resource_consolidation","default":"vm_workload_consolidation","enum":["vm_workload_consolidation","node_resource_consolidation"],"type":"string"},"rebalancingFrequencyMins":{"description":"Rebalancing frequency","default":20,"maximum":60,"minimum":1,"type":"integer"}}},"StorageBackends":{"description":"Persistent Storage Connectivity","type":"object","additionalProperties":{"description":"Volume backend name","type":"object","additionalProperties":{"type":"object","properties":{"driver":{"description":"Storage driver type","enum":["NetApp","LVM"],"type":"string"},"config":{"description":"Configuration distinct based on driver value","type":"object","additionalProperties":{"description":"Flexible configuration parameters based on storage driver","type":"string"}}}}}}}},"paths":{"/blueprint":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Blueprint"}}}},"description":"Successfully retrieved blueprints"}},"summary":"List all blueprints","tags":["Blueprint"]}}}}
```

## POST /blueprint

> Create a new blueprint

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"Blueprint":{"required":["name"],"type":"object","properties":{"name":{"description":"Cluster name","type":"string"},"networkingType":{"description":"Defaults to OVN","default":"ovn","enum":["ovn","ovs"],"type":"string"},"enableDistributedRouting":{"description":"Enable Cluster Wide Distributed Network Routing","default":true,"type":"boolean"},"dnsDomainName":{"description":"DNS Domain Name","type":"string"},"virtualNetworking":{"$ref":"#/components/schemas/VirtualNetworking"},"vmHighAvailability":{"$ref":"#/components/schemas/VMHighAvailability"},"autoResourceRebalancing":{"$ref":"#/components/schemas/AutoResourceRebalancing"},"imageLibraryStorage":{"description":"Library location on filesystem or Cinder volume type","type":"string"},"vmStorage":{"description":"Ephemeral Virtual Machine storage path","type":"string"},"storageBackends":{"$ref":"#/components/schemas/StorageBackends"}}},"VirtualNetworking":{"type":"object","properties":{"enabled":{"description":"Enable Virtual Networking","default":true,"type":"boolean"},"underlayType":{"description":"Underlay Technology","default":"vlan","enum":["vlan","other"],"type":"string"},"vnidRange":{"description":"VLAN / VNID Range","type":"string"}}},"VMHighAvailability":{"type":"object","properties":{"enabled":{"description":"Automatically detect host failure and recover VMs on other cluster hosts","default":false,"type":"boolean"}}},"AutoResourceRebalancing":{"type":"object","properties":{"enabled":{"description":"Automatically rebalance workloads across hosts in the cluster","default":false,"type":"boolean"},"rebalancingStrategy":{"description":"Defaults to vm_workload_consolidation, other supported value is node_resource_consolidation","default":"vm_workload_consolidation","enum":["vm_workload_consolidation","node_resource_consolidation"],"type":"string"},"rebalancingFrequencyMins":{"description":"Rebalancing frequency","default":20,"maximum":60,"minimum":1,"type":"integer"}}},"StorageBackends":{"description":"Persistent Storage Connectivity","type":"object","additionalProperties":{"description":"Volume backend name","type":"object","additionalProperties":{"type":"object","properties":{"driver":{"description":"Storage driver type","enum":["NetApp","LVM"],"type":"string"},"config":{"description":"Configuration distinct based on driver value","type":"object","additionalProperties":{"description":"Flexible configuration parameters based on storage driver","type":"string"}}}}}}},"responses":{"NoContent":{"description":"Operation successful"},"BadRequest":{"description":"Invalid request"},"Conflict":{"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}},"description":"Operation cannot be performed in current state"}}},"paths":{"/blueprint":{"post":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Blueprint"}}},"required":true},"responses":{"204":{"headers":{"Location":{"schema":{"type":"string"},"description":"URL of the created resource"}},"$ref":"#/components/responses/NoContent"},"400":{"$ref":"#/components/responses/BadRequest"},"409":{"$ref":"#/components/responses/Conflict"}},"summary":"Create a new blueprint","tags":["Blueprint"]}}}}
```

## GET /blueprint/{clusterName}

> Retrieve a specific blueprint

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"responses":{"NotFound":{"description":"Resource not found"}}},"paths":{"/blueprint/{clusterName}":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"default":"null","type":"string"}}},"description":"Successfully retrieved blueprint"},"404":{"$ref":"#/components/responses/NotFound"}},"summary":"Retrieve a specific blueprint","tags":["Blueprint"]}}}}
```

## PUT /blueprint/{clusterName}

> Update an existing blueprint

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"Blueprint":{"required":["name"],"type":"object","properties":{"name":{"description":"Cluster name","type":"string"},"networkingType":{"description":"Defaults to OVN","default":"ovn","enum":["ovn","ovs"],"type":"string"},"enableDistributedRouting":{"description":"Enable Cluster Wide Distributed Network Routing","default":true,"type":"boolean"},"dnsDomainName":{"description":"DNS Domain Name","type":"string"},"virtualNetworking":{"$ref":"#/components/schemas/VirtualNetworking"},"vmHighAvailability":{"$ref":"#/components/schemas/VMHighAvailability"},"autoResourceRebalancing":{"$ref":"#/components/schemas/AutoResourceRebalancing"},"imageLibraryStorage":{"description":"Library location on filesystem or Cinder volume type","type":"string"},"vmStorage":{"description":"Ephemeral Virtual Machine storage path","type":"string"},"storageBackends":{"$ref":"#/components/schemas/StorageBackends"}}},"VirtualNetworking":{"type":"object","properties":{"enabled":{"description":"Enable Virtual Networking","default":true,"type":"boolean"},"underlayType":{"description":"Underlay Technology","default":"vlan","enum":["vlan","other"],"type":"string"},"vnidRange":{"description":"VLAN / VNID Range","type":"string"}}},"VMHighAvailability":{"type":"object","properties":{"enabled":{"description":"Automatically detect host failure and recover VMs on other cluster hosts","default":false,"type":"boolean"}}},"AutoResourceRebalancing":{"type":"object","properties":{"enabled":{"description":"Automatically rebalance workloads across hosts in the cluster","default":false,"type":"boolean"},"rebalancingStrategy":{"description":"Defaults to vm_workload_consolidation, other supported value is node_resource_consolidation","default":"vm_workload_consolidation","enum":["vm_workload_consolidation","node_resource_consolidation"],"type":"string"},"rebalancingFrequencyMins":{"description":"Rebalancing frequency","default":20,"maximum":60,"minimum":1,"type":"integer"}}},"StorageBackends":{"description":"Persistent Storage Connectivity","type":"object","additionalProperties":{"description":"Volume backend name","type":"object","additionalProperties":{"type":"object","properties":{"driver":{"description":"Storage driver type","enum":["NetApp","LVM"],"type":"string"},"config":{"description":"Configuration distinct based on driver value","type":"object","additionalProperties":{"description":"Flexible configuration parameters based on storage driver","type":"string"}}}}}}},"responses":{"NoContent":{"description":"Operation successful"},"NotFound":{"description":"Resource not found"}}},"paths":{"/blueprint/{clusterName}":{"put":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Blueprint"}}},"required":true},"responses":{"204":{"$ref":"#/components/responses/NoContent"},"404":{"$ref":"#/components/responses/NotFound"}},"summary":"Update an existing blueprint","tags":["Blueprint"]}}}}
```

## DELETE /blueprint/{clusterName}

> Delete a specific blueprint

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"responses":{"NoContent":{"description":"Operation successful"},"NotFound":{"description":"Resource not found"}}},"paths":{"/blueprint/{clusterName}":{"delete":{"responses":{"204":{"$ref":"#/components/responses/NoContent"},"404":{"$ref":"#/components/responses/NotFound"}},"summary":"Delete a specific blueprint","tags":["Blueprint"]}}}}
```

## PUT /hosts/{hostId}/roles/{roleName}

> Assign role to the host or update role settings

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"RoleUpdate":{"required":["backends"],"type":"object","properties":{"backends":{"description":"List of storage backends to associate with the role","type":"array","items":{"description":"List of backend names to associate with the role","type":"string"}}}}},"responses":{"BadRequest":{"description":"Invalid request"},"NotFound":{"description":"Resource not found"},"Conflict":{"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}},"description":"Operation cannot be performed in current state"}}},"paths":{"/hosts/{hostId}/roles/{roleName}":{"put":{"requestBody":{"description":"Role specific settings; required only for persistent-storage role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleUpdate"}}},"required":false},"responses":{"200":{"description":"Role assigned successfully"},"400":{"$ref":"#/components/responses/BadRequest"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"}},"summary":"Assign role to the host or update role settings","tags":["Blueprint"]}}}}
```

## DELETE /hosts/{hostId}/roles/{roleName}

> Remove role from the host

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"responses":{"BadRequest":{"description":"Invalid request"},"NotFound":{"description":"Resource not found"}}},"paths":{"/hosts/{hostId}/roles/{roleName}":{"delete":{"responses":{"204":{"description":"Role unassigned successfully"},"400":{"$ref":"#/components/responses/BadRequest"},"404":{"$ref":"#/components/responses/NotFound"}},"summary":"Remove role from the host","tags":["Blueprint"]}}}}
```

## GET /hostconfigs

> List host configurations

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"HostConfigResponse":{"allOf":[{"$ref":"#/components/schemas/HostConfigReq"},{"type":"object","properties":{"id":{"format":"uuid","type":"string"}}}]},"HostConfigReq":{"type":"object","properties":{"name":{"type":"string"},"mgmtInterface":{"type":"string"},"vmConsoleInterface":{"type":"string"},"hostLivenessInterface":{"type":"string"},"tunnelingInterface":{"type":"string"},"imagelibInterface":{"type":"string"},"networkLabels":{"type":"object"},"clusterName":{"type":"string"}}}}},"paths":{"/hostconfigs":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HostConfigResponse"}}}},"description":"List of host configurations"}},"summary":"List host configurations","tags":["Blueprint"]}}}}
```

## POST /hostconfigs

> Create host configuration(s)

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"HostConfigReq":{"type":"object","properties":{"name":{"type":"string"},"mgmtInterface":{"type":"string"},"vmConsoleInterface":{"type":"string"},"hostLivenessInterface":{"type":"string"},"tunnelingInterface":{"type":"string"},"imagelibInterface":{"type":"string"},"networkLabels":{"type":"object"},"clusterName":{"type":"string"}}},"HostConfigResponse":{"allOf":[{"$ref":"#/components/schemas/HostConfigReq"},{"type":"object","properties":{"id":{"format":"uuid","type":"string"}}}]}},"responses":{"Conflict":{"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}},"description":"Operation cannot be performed in current state"}}},"paths":{"/hostconfigs":{"post":{"requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/HostConfigReq"},{"type":"array","items":{"$ref":"#/components/schemas/HostConfigReq"}}]}}},"required":true},"responses":{"200":{"headers":{"Location":{"schema":{"type":"string"},"description":"URL of the created Resource"}},"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HostConfigResponse"}}}},"description":"Host configuration(s) created"},"409":{"$ref":"#/components/responses/Conflict"}},"summary":"Create host configuration(s)","tags":["Blueprint"]}}}}
```

## GET /hostconfigs/{hostConfigId}

> Get host configuration

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"HostConfigResponse":{"allOf":[{"$ref":"#/components/schemas/HostConfigReq"},{"type":"object","properties":{"id":{"format":"uuid","type":"string"}}}]},"HostConfigReq":{"type":"object","properties":{"name":{"type":"string"},"mgmtInterface":{"type":"string"},"vmConsoleInterface":{"type":"string"},"hostLivenessInterface":{"type":"string"},"tunnelingInterface":{"type":"string"},"imagelibInterface":{"type":"string"},"networkLabels":{"type":"object"},"clusterName":{"type":"string"}}}}},"paths":{"/hostconfigs/{hostConfigId}":{"get":{"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostConfigResponse"}}},"description":"Host configuration details"}},"summary":"Get host configuration","tags":["Blueprint"]}}}}
```

## PUT /hostconfigs/{hostConfigId}

> Update host configuration

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}},"schemas":{"HostConfigReq":{"type":"object","properties":{"name":{"type":"string"},"mgmtInterface":{"type":"string"},"vmConsoleInterface":{"type":"string"},"hostLivenessInterface":{"type":"string"},"tunnelingInterface":{"type":"string"},"imagelibInterface":{"type":"string"},"networkLabels":{"type":"object"},"clusterName":{"type":"string"}}},"HostConfigResponse":{"allOf":[{"$ref":"#/components/schemas/HostConfigReq"},{"type":"object","properties":{"id":{"format":"uuid","type":"string"}}}]}}},"paths":{"/hostconfigs/{hostConfigId}":{"put":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostConfigReq"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostConfigResponse"}}},"description":"Host configuration updated"}},"summary":"Update host configuration","tags":["Blueprint"]}}}}
```

## DELETE /hostconfigs/{hostConfigId}

> Delete host configuration

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}}},"paths":{"/hostconfigs/{hostConfigId}":{"delete":{"responses":{"204":{"description":"Host configuration deleted"}},"summary":"Delete host configuration","tags":["Blueprint"]}}}}
```

## PUT /hosts/{hostId}/hostconfig/{hostConfigId}

> Assign host configuration to host

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}}},"paths":{"/hosts/{hostId}/hostconfig/{hostConfigId}":{"put":{"responses":{"200":{"description":"Host configuration assigned"}},"summary":"Assign host configuration to host","tags":["Blueprint"]}}}}
```

## DELETE /hosts/{hostId}/hostconfig/{hostConfigId}

> Unassign host configuration from host

```json
{"openapi":"3.0.1","info":{"title":"Cluster Blueprint API","version":"2.0.0"},"servers":[{"url":"https://{host}/resmgr/v2","description":"PCD Resource Manager API v2","variables":{"host":{"default":"example.platform9.com","description":"The PCD controlplane hostname"}}}],"security":[{"TokenAuth":[]}],"components":{"securitySchemes":{"TokenAuth":{"type":"apiKey","description":"Keystone Authentication token","name":"x-auth-token","in":"header"}}},"paths":{"/hosts/{hostId}/hostconfig/{hostConfigId}":{"delete":{"responses":{"204":{"description":"Host configuration unassigned"}},"summary":"Unassign host configuration from host","tags":["Blueprint"]}}}}
```


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.platform9.com/api-docs/cluster-blueprint/blueprint.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
