Exam NCM-MCI-6.10 Topic 1 Question 15 Discussion
Actual exam question for Nutanix's NCM-MCI-6.10 exam
Question #: 15
Topic #: 1
Question #: 15
Topic #: 1
An administrator is working to create a VM using Nutanix V3 API calls with the following specifications.
VM specifications:
* vCPUs: 2
* Memory: 8Gb
* Disk Size: 50Gb
* Cluster: Cluster 1
* Network: default-net
* Branding must be disabled on the VM
The API call is failing, indicating an issue with the payload:
"": [
"'metadata' is a required property",
"'spec' is a required property"
],
"message": "Request could not be processed.",
"reason": "INVALID_REQUEST"
The body is saved in desktop\API_Create_VM.txt.
Correct any issues in the text file that would prevent it from creating the VM. Also ensure the VM will be created as specified and make sure it is saved for re-use using that filename.
Deploy the VM through the API.
Note: Do not power on the VM.
VM specifications:
* vCPUs: 2
* Memory: 8Gb
* Disk Size: 50Gb
* Cluster: Cluster 1
* Network: default-net
* Branding must be disabled on the VM
The API call is failing, indicating an issue with the payload:
"": [
"'metadata' is a required property",
"'spec' is a required property"
],
"message": "Request could not be processed.",
"reason": "INVALID_REQUEST"
The body is saved in desktop\API_Create_VM.txt.
Correct any issues in the text file that would prevent it from creating the VM. Also ensure the VM will be created as specified and make sure it is saved for re-use using that filename.
Deploy the VM through the API.
Note: Do not power on the VM.
Suggested Answer:
See the Explanation below for detailed answer.
Explanation:
Here is the step-by-step solution to correct the API payload and deploy the VM.
This task is performed using the REST API Explorer within Prism Central.
1. Get Required UUIDs
To create a VM, you first need the unique IDs (UUIDs) for the target cluster and network.
* From the Prism Central dashboard, click the question mark (?) icon in the top-right corner and select REST API Explorer.
* Find Cluster 1 UUID:
* In the API Explorer, search for and select the clusters/list (POST) endpoint.
* In the Body field, paste a simple filter: { "kind": "cluster" }
* Click Send.
* In the "Response" body, find the entry for Cluster 1 and copy its metadata.uuid value.
* Find default-net UUID:
* Search for and select the subnets/list (POST) endpoint.
* In the Body field, paste: { "kind": "subnet" }
* Click Send.
* In the "Response" body, find the entry where spec.name is default-net and copy its metadata.uuid value.
2. Correct the API Payload File
The error message "'metadata' is a required property" and "'spec' is a required property" indicates the JSON in the file is malformed and missing the required root-level objects. The file content also does not match the VM specifications.
* On the desktop, open API_Create_VM.txt in Notepad.
* Delete all existing text in the file (including the POST Call and Body: lines).
* Paste the following corrected and complete JSON payload into the file.
* Replace <UUID_for_Cluster_1> and <UUID_for_default-net> with the actual UUIDs you copied in the previous step.
JSON
{
"spec": {
"name": "API_VM_Task15",
"resources": {
"power_state": "OFF",
"num_sockets": 2,
"num_vcpus_per_socket": 1,
"memory_size_mib": 8192,
"disk_list": [
{
"disk_size_mib": 51200,
"device_properties": {
"device_type": "DISK"
}
}
],
"nic_list": [
{
"subnet_reference": {
"kind": "subnet",
"uuid": "<UUID_for_default-net>"
}
}
],
"guest_customization": {
"is_overridable": true,
"override_branding": true
}
},
"cluster_reference": {
"kind": "cluster",
"uuid": "<UUID_for_Cluster_1>"
}
},
"metadata": {
"kind": "vm"
}
}
* Save and close the API_Create_VM.txt file.
Correction Summary:
* JSON Structure: The original file was malformed. The new payload provides the required spec and metadata objects at the root level.
* vCPUs: Set to 2 sockets (2 vCPUs total).
* Memory: Set to 8192 MiB (8 GB).
* Disk: Set to 51200 MiB (50 GB) and removed the unneeded CDROM.
* Cluster/Network: Placeholders are added for the required UUIDs.
* Branding: guest_customization.override_branding: true is added to disable branding for the VM.
3. Deploy the VM via API
* Return to the REST API Explorer.
* Search for and select the vms (POST) endpoint (the one with the description "Create a new vm").
* Open the corrected API_Create_VM.txt file, copy its entire contents (which now includes your specific UUIDs).
* Paste the complete JSON payload into the Body field of the vms (POST) endpoint.
* Click Send.
The API will return a 202 Accepted response, and the VM will be created (and remain powered off) on Cluster 1.
Explanation:
Here is the step-by-step solution to correct the API payload and deploy the VM.
This task is performed using the REST API Explorer within Prism Central.
1. Get Required UUIDs
To create a VM, you first need the unique IDs (UUIDs) for the target cluster and network.
* From the Prism Central dashboard, click the question mark (?) icon in the top-right corner and select REST API Explorer.
* Find Cluster 1 UUID:
* In the API Explorer, search for and select the clusters/list (POST) endpoint.
* In the Body field, paste a simple filter: { "kind": "cluster" }
* Click Send.
* In the "Response" body, find the entry for Cluster 1 and copy its metadata.uuid value.
* Find default-net UUID:
* Search for and select the subnets/list (POST) endpoint.
* In the Body field, paste: { "kind": "subnet" }
* Click Send.
* In the "Response" body, find the entry where spec.name is default-net and copy its metadata.uuid value.
2. Correct the API Payload File
The error message "'metadata' is a required property" and "'spec' is a required property" indicates the JSON in the file is malformed and missing the required root-level objects. The file content also does not match the VM specifications.
* On the desktop, open API_Create_VM.txt in Notepad.
* Delete all existing text in the file (including the POST Call and Body: lines).
* Paste the following corrected and complete JSON payload into the file.
* Replace <UUID_for_Cluster_1> and <UUID_for_default-net> with the actual UUIDs you copied in the previous step.
JSON
{
"spec": {
"name": "API_VM_Task15",
"resources": {
"power_state": "OFF",
"num_sockets": 2,
"num_vcpus_per_socket": 1,
"memory_size_mib": 8192,
"disk_list": [
{
"disk_size_mib": 51200,
"device_properties": {
"device_type": "DISK"
}
}
],
"nic_list": [
{
"subnet_reference": {
"kind": "subnet",
"uuid": "<UUID_for_default-net>"
}
}
],
"guest_customization": {
"is_overridable": true,
"override_branding": true
}
},
"cluster_reference": {
"kind": "cluster",
"uuid": "<UUID_for_Cluster_1>"
}
},
"metadata": {
"kind": "vm"
}
}
* Save and close the API_Create_VM.txt file.
Correction Summary:
* JSON Structure: The original file was malformed. The new payload provides the required spec and metadata objects at the root level.
* vCPUs: Set to 2 sockets (2 vCPUs total).
* Memory: Set to 8192 MiB (8 GB).
* Disk: Set to 51200 MiB (50 GB) and removed the unneeded CDROM.
* Cluster/Network: Placeholders are added for the required UUIDs.
* Branding: guest_customization.override_branding: true is added to disable branding for the VM.
3. Deploy the VM via API
* Return to the REST API Explorer.
* Search for and select the vms (POST) endpoint (the one with the description "Create a new vm").
* Open the corrected API_Create_VM.txt file, copy its entire contents (which now includes your specific UUIDs).
* Paste the complete JSON payload into the Body field of the vms (POST) endpoint.
* Click Send.
The API will return a 202 Accepted response, and the VM will be created (and remain powered off) on Cluster 1.
by Kim at Jun 23, 2026, 11:02 PM
Comments
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Report Comment
Commenting
You can sign-up / login (it's free).