Create Esxs

Create Esxs

Add/Remove one or more ESX hosts in the target cloud

Request
URI
POST
https://vmc.vmware.com/vmc/api/orgs/{org}/sddcs/{sddc}/esxs
COPY
Path Parameters
string
org
Required

Organization identifier

string
sddc
Required

Sddc identifier

Query Parameters
string
action
Optional

If = 'add', will add the esx. If = 'remove', will delete the esx/esxs bound to a single cluster (Cluster Id is mandatory for non cluster 1 esx remove). If = 'force-remove', will delete the esx even if it can lead to data loss (This is an privileged operation). If = 'addToAll', will add esxs to all clusters in the SDDC (This is an privileged operation). If = 'removeFromAll', will delete the esxs from all clusters in the SDDC (This is an privileged operation). If = 'attach-diskgroup', will attach the provided diskgroups to a given host (privileged). If = 'detach-diskgroup', will detach the diskgroups of a given host (privileged). Default behaviour is 'add'


Request Body
EsxConfig of type(s) application/json
Optional
{
    "availability_zone": "string",
    "strict_placement": false,
    "cluster_id": "string",
    "esxs": [
        "string"
    ],
    "num_hosts": 0
}
string
availability_zone
Optional

Availability zone where the hosts should be provisioned. (Can be specified only for privileged host operations).

boolean
strict_placement
Optional

An option to indicate if the host needs to be strictly placed in a placement group. Fail the operation otherwise.

string
cluster_id
Optional

An optional cluster id if the esxs operation has to be on a specific cluster.

array of string
esxs
Optional

An optional list of ESX IDs to remove.

integer As int32 As int32
num_hosts
Required

num_hosts

Authentication
This operation uses the following authentication methods.
Responses
202

Accepted

Returns Task of type(s) application/json
This response body class contains all of the following: AbstractEntity
{
    "updated": "string",
    "user_id": "string",
    "updated_by_user_id": "string",
    "created": "string",
    "version": 5,
    "updated_by_user_name": "string",
    "user_name": "string",
    "id": "1d1c83ee-e0b7-4de9-b660-9a9ca1d22f32",
    "status": "string",
    "localized_error_message": "string",
    "resource_id": "string",
    "parent_task_id": "string",
    "task_version": "string",
    "correlation_id": "string",
    "start_resource_entity_version": 0,
    "customer_error_message": "string",
    "sub_status": "string",
    "task_type": "string",
    "start_time": "string",
    "task_progress_phases": [
        {
            "id": "string",
            "name": "string",
            "progress_percent": 0
        }
    ],
    "error_message": "string",
    "org_id": "1d1c83ee-e0b7-4de9-b660-9a9ca1d22f32",
    "end_resource_entity_version": 5,
    "service_errors": [
        {
            "default_message": "string",
            "original_service": "string",
            "localized_message": "string",
            "original_service_error_code": "string"
        }
    ],
    "org_type": "string",
    "estimated_remaining_minutes": 4,
    "progress_percent": 75,
    "phase_in_progress": "string",
    "resource_type": "string",
    "end_time": "string"
}

400

The sddc is not in a state that's valid for updates

Returns ErrorResponse of type(s) application/json
{
    "status": 0,
    "path": "string",
    "retryable": false,
    "error_code": "string",
    "error_messages": [
        "string"
    ]
}
integer
status
Required

HTTP status code

string
path
Required

Originating request URI

boolean
retryable
Required

If true, client should retry operation

string
error_code
Required

unique error code

array of string
error_messages
Required

localized error messages


401

Unauthorized

Operation doesn't return any data structure

403

Access not allowed to the operation for the current user

Returns ErrorResponse of type(s) application/json
{
    "status": 0,
    "path": "string",
    "retryable": false,
    "error_code": "string",
    "error_messages": [
        "string"
    ]
}
integer
status
Required

HTTP status code

string
path
Required

Originating request URI

boolean
retryable
Required

If true, client should retry operation

string
error_code
Required

unique error code

array of string
error_messages
Required

localized error messages


404

Cannot find the SDDC with the given identifier

Returns ErrorResponse of type(s) application/json
{
    "status": 0,
    "path": "string",
    "retryable": false,
    "error_code": "string",
    "error_messages": [
        "string"
    ]
}
integer
status
Required

HTTP status code

string
path
Required

Originating request URI

boolean
retryable
Required

If true, client should retry operation

string
error_code
Required

unique error code

array of string
error_messages
Required

localized error messages