List VM UUID via vm-name search via REST API 3 | Nutanix Community
Skip to main content

Hi,

 Using REST API 3 ,i want to list vm uuid by providing vm name in search criteria.

But i am unable to find any search filter to provide vm name.

I am using PUT /vm/list, these are the body model

{
"kind": "vm",
"sort_attribute": "string",
"filter": "string",
"length": 0,
"sort_order": "string",
"offset": 0
}

Please suggest where to put vm name search criteria.

Also, suggest if there is another call for it to list vm uuid by vm name search.

I have tried with  

"filter": "vm_name==.*clone*",

results none 

But not helping


Try this

 

{
  "kind": "vm",
  "sort_attribute": "string",
  "filter": "vm_name==*clone",
  "length": 5,
  "sort_order": "ASCENDING",
  "offset": 0
}


Reply