Ovf Manager Create Import Spec

Ovf Manager Create Import Spec

Validate the OVF descriptor against the hardware supported by the host system.

If the validation succeeds, return a result containing:

  • An ImportSpec to use when importing the entity.
  • A list of items to upload (for example disk backing files, ISO images etc.)

Required privileges: System.View

Request
URI
POST
https://{vcenter-host}/sdk/vim25/{release}/OvfManager/{moId}/CreateImportSpec
COPY
Path Parameters
string
moId
Required

The unique identifier for the managed object to which the method attaches; the serialized managed object reference for a request has the form moType/moId, in this case OvfManager/{moId}.

string
release
Required

The vSphere release schema. The current specification covers vSphere 8.0.2.0 APIs.


Request Body
CreateImportSpecRequestType of type(s) application/json
Required
{
    "ovfDescriptor": "string",
    "resourcePool": {
        "_typeName": "string",
        "type": "string",
        "value": "string"
    },
    "datastore": {
        "_typeName": "string",
        "type": "string",
        "value": "string"
    },
    "cisp": {
        "_typeName": "string",
        "locale": "string",
        "deploymentOption": "string",
        "msgBundle": [
            {
                "_typeName": "string",
                "key": "string",
                "value": "string"
            }
        ],
        "importOption": [
            "string"
        ],
        "entityName": "string",
        "hostSystem": {
            "_typeName": "string",
            "type": "string",
            "value": "string"
        },
        "networkMapping": [
            {
                "_typeName": "string",
                "name": "string",
                "network": {
                    "_typeName": "string",
                    "type": "string",
                    "value": "string"
                }
            }
        ],
        "ipAllocationPolicy": "string",
        "ipProtocol": "string",
        "propertyMapping": [
            {
                "_typeName": "string",
                "key": "string",
                "value": "string"
            }
        ],
        "resourceMapping": [
            {
                "_typeName": "string",
                "source": "string",
                "parent": {
                    "_typeName": "string",
                    "type": "string",
                    "value": "string"
                },
                "resourceSpec": {
                    "_typeName": "string",
                    "entity": {
                        "_typeName": "string",
                        "type": "string",
                        "value": "string"
                    },
                    "changeVersion": "string",
                    "lastModified": "string",
                    "cpuAllocation": {
                        "_typeName": "string",
                        "reservation": 0,
                        "expandableReservation": false,
                        "limit": 0,
                        "shares": {
                            "_typeName": "string",
                            "shares": 0,
                            "level": "string"
                        },
                        "overheadLimit": 0
                    },
                    "memoryAllocation": {
                        "_typeName": "string",
                        "reservation": 0,
                        "expandableReservation": false,
                        "limit": 0,
                        "shares": {
                            "_typeName": "string",
                            "shares": 0,
                            "level": "string"
                        },
                        "overheadLimit": 0
                    },
                    "scaleDescendantsShares": "string"
                },
                "datastore": {
                    "_typeName": "string",
                    "type": "string",
                    "value": "string"
                }
            }
        ],
        "diskProvisioning": "string",
        "instantiationOst": {
            "_typeName": "string",
            "id": "string",
            "type": "string",
            "section": [
                {
                    "_typeName": "string",
                    "lineNumber": 0,
                    "xml": "string"
                }
            ],
            "child": [
                "OvfConsumerOstNode Object"
            ],
            "entity": {
                "_typeName": "string",
                "type": "string",
                "value": "string"
            }
        }
    }
}
string
ovfDescriptor
Required

The OVF descriptor of the entity.

resourcePool
Required

Reference to an instance of the ResourcePool managed object.

datastore
Required

Reference to an instance of the Datastore managed object.

cisp
Required

Parameters for deploying an OVF.

Authentication
This operation uses the following authentication methods.
Responses
200

OK

Returns OvfCreateImportSpecResult of type(s) application/json
This response body class contains all of the following: DataObject
{
    "_typeName": "string",
    "importSpec": {
        "_typeName": "string",
        "entityConfig": {
            "_typeName": "string",
            "key": {
                "_typeName": "string",
                "type": "string",
                "value": "string"
            },
            "tag": "string",
            "startOrder": 0,
            "startDelay": 0,
            "waitingForGuest": false,
            "startAction": "string",
            "stopDelay": 0,
            "stopAction": "string",
            "destroyWithParent": false
        },
        "instantiationOst": {
            "_typeName": "string",
            "id": "string",
            "type": "string",
            "section": [
                {
                    "_typeName": "string",
                    "lineNumber": 0,
                    "xml": "string"
                }
            ],
            "child": [
                "OvfConsumerOstNode Object"
            ],
            "entity": {
                "_typeName": "string",
                "type": "string",
                "value": "string"
            }
        }
    },
    "fileItem": [
        {
            "_typeName": "string",
            "deviceId": "string",
            "path": "string",
            "compressionMethod": "string",
            "chunkSize": 0,
            "size": 0,
            "cimType": 0,
            "create": false
        }
    ],
    "warning": [
        {
            "_typeName": "string",
            "faultCause": "MethodFault Object",
            "faultMessage": [
                {
                    "_typeName": "string",
                    "key": "string",
                    "arg": [
                        {
                            "_typeName": "string",
                            "key": "string",
                            "value": {
                                "_typeName": "string"
                            }
                        }
                    ],
                    "message": "string"
                }
            ]
        }
    ],
    "error": [
        {
            "_typeName": "string",
            "faultCause": "MethodFault Object",
            "faultMessage": [
                {
                    "_typeName": "string",
                    "key": "string",
                    "arg": [
                        {
                            "_typeName": "string",
                            "key": "string",
                            "value": {
                                "_typeName": "string"
                            }
                        }
                    ],
                    "message": "string"
                }
            ]
        }
    ]
}
importSpec
Optional

An ImportSpec is used when importing VMs or vApps.

It can be built from scratch, or it can be generated from an OVF descriptor using the service interface OvfManager.

This class is the abstract base for VirtualMachineImportSpec and VirtualAppImportSpec. These three classes form a composite structure that allows us to contain arbitrarily complex entitites in a single ImportSpec.

fileItem
Optional

The files that must be uploaded by the caller as part of importing the entity.

The files must be uploaded in order, because some of them may be delta files that patch already-uploaded files.

warning
Optional

Non-fatal warnings from the processing.

The ImportSpec will be valid, but the user may choose to reject it based on these warnings.

error
Optional

Errors that happened during processing.

Something will be wrong with the ImportSpec, or it is not present.


500

TaskInProgress: if a required managed entity is busy.

VmConfigFault: if a configuration issue prevents the operation from succeeding. Typically, a more specific subclass is thrown.

ConcurrentAccess: if a concurrency issue prevents the operation from succeeding.

FileFault: if there is a generic file error

InvalidState: if the operation failed due to the current state of the system.

Returns VimFault of type(s) application/json
This response body class contains all of the following: MethodFault
{
    "_typeName": "string",
    "faultCause": "MethodFault Object",
    "faultMessage": [
        {
            "_typeName": "string",
            "key": "string",
            "arg": [
                {
                    "_typeName": "string",
                    "key": "string",
                    "value": {
                        "_typeName": "string"
                    }
                }
            ],
            "message": "string"
        }
    ]
}