Before saving a draft and turning it into a desired state for a cluster or a standalone host, you can check whether the specification is complete and valid. You can also check whether the draft specification drifts in any way from the current state of the cluster or the host.

The Drafts service offers two methods for validating the draft software specification. To check whether a draft is complete and there are no conflicts between the draft components, or unresolved dependencies, use the POST https://<vcenter_ip_address_or_fqdn>/api/esx/settings/clusters/<cluster_id>/software/drafts/<draft_id>?action=validate&vmw-task=true or POST https://<vcenter_ip_address_or_fqdn>/api/esx/settings/hosts/<host_id>/software/drafts/<draft_id>?action=validate&vmw-task=true request depending on the targeted vSphere inventory object. Submit as path parameters the cluster ID or the standalone host ID, and the draft ID. You validate whether there were any other drafts committed for this cluster or standalone host, which can make the current commit operation invalid. The method also validates whether all components defined in the software specification are available in the depot metadata. This method does not run compliance checks against the cluster or the standalone host.

To check whether all hosts in the cluster or the standalone host are compliant with the draft software specification, use the POST https://<vcenter_ip_address_or_fqdn>/api/esx/settings/clusters/<cluster_id>/software/drafts/<draft_id>?action=scan&vmw-task=truePOST https://<vcenter_ip_address_or_fqdn>/api/esx/settings/hosts/<host_id>/software/drafts/<draft_id>?action=scan&vmw-task=true request depending on the targeted vSphere inventory object. Submit as path parameters the cluster ID or the standalone host ID, and the draft ID. This method results in running a comparison between the draft specification and the current state of each host in the cluster or the current state of the standalone host.