Documentation is now available for the Fall 2020 Update release!

Create resources

This endpoint is used to create resources.

Leave Feedback

URL

POST https://{api-url}/api/v2/tenants/{tenantId}/resources

URL example

https://{api-url}/api/v2/tenants/client_12/resources

Parameters

Required fields are indicated.

FieldData TypeDescription
dnsNameStringDomain name service.
hostName/resourceNameString(Required) Name of resource. Mainly used to represent computing resources.
aliasNameStringAnother name for the resource.
descriptionStringDescription for the resource.
extResourceIdStringExternal ID for a third-party integration resource.
resourceTypeString(Required) Type of resource. Example: server
metadataString(Optional) Used to create a generic resource.
  • "property1" : "value1"
  • "property2" : "value2"
  • "property3" : "value3"
osStringOperating system.
serialNumberStringSerial number of the resource.
makeStringSystem vendor.
modelStringModel of the resource.
managementProfile/td>StringName of the management profile.
providerTypeStringType of provider.
providerUIDStringUnique ID of the provider.
systemIUDStringUnique ID of the system.
resourceNetworkInterfaceArrayDetails for the network interface.
  • ipAddressType.
  • macAddress
  • default
  • ipAddress
oobInterfaceCardsStringDetails for OOB interface card.
  • name (required)
  • macAddress (required)
  • description
  • url
  • oobVersion
  • accessInfo
  • accessInfoIpV4
  • remoteAccessType
  • port
  • make
  • model

Sample 1

https://{api-url}/api/v2/tenants/client_5/resources

Sample request

{ 
	"dnsName": "testdevice-api.com",
	"hostName": "testdevice-api",
	"resourceName": "CloudProviderName",
	"aliasName": "CustomName",
	"description": "test description",
	"extResourceId" : "67034",
	"resourceType": "server",
	"os": "Ubuntu 12.04.5 LTS",
	"serialNumber": "564D35B8-3FF8-D31F-935D-558A15B81234",
	"make":"Ubuntu make",
	"model":"Ubuntu model",
	"managementProfile":"Sample Gateway",
	"providerType" : "AWS",
	"providerUID" : "PVDR10",
	"systemUID"	: "LINUX100",
	"resourceNetworkInterface": [{ 
		"ipAddressType": "STATIC",
		"macAddress": "2E:8B:EB:32:7A:F9",
		"default": 1,
		"ipAddress": "192.168.56.86"
	},
	{
		"ipAddressType": "STATIC",
		"macAddress": "00:0C:29:B8:C8:8F",
		"default": 0,
		"ipAddress": "172.22.221.90"
	},
	{
		"ipAddressType": "DHCP",
		"macAddress": "00:0C:29:B8:C8:95",
		"default": 0,
		"ipAddress": "172.22.100.86"
	}],
	"oobInterfaceCards": { 
		"resourceName": "Controller 1",
		"macAddress": "hj:23:gb:67:vb:sd",
		"description": "Demo Description",
		"url": "https://www.acmeit.com/",
		"oobVersion": "7.5",
		"accessInfo": "source-ip location",
		"accessInfoIpV4": "122.28.20.123",
		"remoteAccessType": "SSH",
		"port": 443,
		"make": "Cisco Routers",
		"model": "Cisco 890 Series"
	}]
}

Sample response

{
	"resourceUUID": "63621966-582f-40d0-a146-90a4bd7c3d63",
	"tenantID": "client_5"
}

Sample 2 - create a generic resource

POST https://{api-url}}/api/v2/tenants/client_12/resources

Mandatory Fields:

  • name
  • resourceType

Optional Fields:

  • metaData
  • extResourceId

Sample request

{
	"name": "testresource-api",
	"extResourceId": "extResourceId_123",
	"hostName": "testdevice-api",
	"resourceType": "Device",
	"metaData" : {
		"property1" : "value1",
		"property2" : "value2",
		"property3" : "value3"
	}
}

Sample response

{
	"resourceUUID": "612acfb0-6890-4d52-950b-1c4ec17a7248",
	"tenantID": "client_12"
}