AllowedLocationTemplatesResource


List virtual machine templates available in a location


Retrieve templates that are present in a given location.

GET https://example.com/api/cloud/locations/{location}/templates

Roles : [ROLE_VDC_ENUMERATE]

Parameter Type Default Value Description
categoryName String If present, filter by category name
hypervisorTypeName String If present, filter by compatibility with a hypervisor type (disk format types)
virtualdatacenter Integer If present, filter by compatibility with a virtual datacenter by VDC identifier (disk format types of the virtual datacenter type)
stateful String If present, filter persistent VM templates by ALL, USED or NOTUSED
imported Boolean false If true, include imported VM templates (from captured VMs)
ostype String If present, filter by operating system
64bits Boolean If true, only return x64 architecture; if false, only return x86 architecture.
Requires the ''ostype'' param to be set to null (null for any filter)
startwith Integer 0 The first element to be retrieved of the filtered search
description String If present, filter by the description
name String If present, filter by name
path String If present, filter by path
ovfId String If present, filter by the URI of the template definition.
For public clouds it may used as the ''image id''
creationUser String If present, filter by the user who created the template.
Can be a deleted user or an identifier
by String id Order by
has String If present filter to apply in the search.
limit Integer 25 The number of entities to retrieve
asc Boolean true If the value of the 'by' parameter must be sorted in ascending order (true) or descending order (false)
master Boolean If true, only return VM templates with instances. If false, only return VM template instances.
includeorphaninstances boolean false If true, requires ''masterInclusion=true'', includes instances with the master not visible (not shared and in another enterprise)
states String If present, filter by comma separated value of VM template states
external Boolean true If false, do not include external VM templates in the public cloud region provider. Only return the templates that physically exist in the datacenter repository
When using Docker, the container images are not physically downloaded to the datacenter repository (NFS).

Example

Get a virtual machine template available in a location


Get a template that is available to the enterprise in a location.

GET https://example.com/api/cloud/locations/{location}/templates/{template}

Roles : [ROLE_VDC_ENUMERATE]

Error Codes

  • LOCATION-4 - The location does not exist
  • VIMAGE-0 - The requested virtual machine template does not exist

Example