[{"label":"Latest (v36.3)","version":"latest"},{"version":"v36.2"},{"version":"v36.1"},{"version":"v36.0"},{"link":"https://developer.vmware.com/apis/1046/vmware-cloud-director","version":"v35.0"}]
vmware-cloud-director

Update Defined Entity

Description

Update the defined entity with the unique identifier (URN)

Request

Request

URL

URL


put
https://{api_host}/cloudapi/1.0.0/entities/{id}
Copy

Path Parameters

Path Parameters

string
id Required

Request Body

Request Body

DefinedEntity of type(s) application/json Required
{
	"entity": {},
	"name": "vspheresddc1"
}
map of object
entity Required

A JSON value representation. The JSON will be validated against the schema of the entityType that the entity is an instance of.


string
name Required

The name of the defined entity.


string
entityType Optional

The URN ID of the defined entity type that the entity is an instance of. This is a read-only field.


string
externalId Optional

An external entity’s id that this entity may have a relation to.


string
id Optional

The id of the defined entity in URN format.


org Optional

The organization of the defined entity.


owner Optional

The owner of the defined entity.


string
state Optional

Every entity is created in the “PRE_CREATED” state. Once an entity is ready to be validated against its schema, it will transition in another state - RESOLVED, if the entity is valid according to the schema, or RESOLUTION_ERROR otherwise. If an entity in an “RESOLUTION_ERROR” state is updated, it will transition to the inital “PRE_CREATED” state without performing any validation. If its in the “RESOLVED” state, then it will be validated against the entity type schema and throw an exception if its invalid.

Possible values are: PRE_CREATEDRESOLVEDRESOLUTION_ERROR

Authentication

Authentication

This operation uses the following authentication methods.

Response

Response

Response Body

Response Body

200 OK returns DefinedEntity of type(s) application/json;version=36.3
{
	"entity": {},
	"entityType": "urn:vcloud:type:vmware.vspheresddc:1.0.0",
	"externalId": "123",
	"id": "urn:vcloud:entity:vmware.vspheresddc:1.0.0:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
	"name": "vspheresddc1",
	"org": {
		"id": "string",
		"name": "string"
	},
	"owner": {
		"id": "string",
		"name": "string"
	},
	"state": "PRE_CREATED"
}
map of object
entity Required

A JSON value representation. The JSON will be validated against the schema of the entityType that the entity is an instance of.


string
name Required

The name of the defined entity.


string
entityType Optional

The URN ID of the defined entity type that the entity is an instance of. This is a read-only field.


string
externalId Optional

An external entity’s id that this entity may have a relation to.


string
id Optional

The id of the defined entity in URN format.


org Optional

The organization of the defined entity.


owner Optional

The owner of the defined entity.


string
state Optional

Every entity is created in the “PRE_CREATED” state. Once an entity is ready to be validated against its schema, it will transition in another state - RESOLVED, if the entity is valid according to the schema, or RESOLUTION_ERROR otherwise. If an entity in an “RESOLUTION_ERROR” state is updated, it will transition to the inital “PRE_CREATED” state without performing any validation. If its in the “RESOLVED” state, then it will be validated against the entity type schema and throw an exception if its invalid.

Possible values are: PRE_CREATEDRESOLVEDRESOLUTION_ERROR

Errors

Errors

400

Invalid configuration.

Code Samples

Code Samples

cURL Command

curl -X PUT -H "Content-Type: application/json" -d '{"entity":{},"entityType":"urn:vcloud:type:vmware.vspheresddc:1.0.0","externalId":"123","id":"urn:vcloud:entity:vmware.vspheresddc:1.0.0:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx","name":"vspheresddc1","org":{"id":"string","name":"string"},"owner":{"id":"string","name":"string"},"state":"PRE_CREATED"}' https://{api_host}/cloudapi/1.0.0/entities/{id}


[{"label":"Latest (v36.3)","version":"latest"},{"version":"v36.2"},{"version":"v36.1"},{"version":"v36.0"},{"link":"https://developer.vmware.com/apis/1046/vmware-cloud-director","version":"v35.0"}]
vmware-cloud-director
Feedback

Was this page helpful?