ePoy
Enthusiast
Enthusiast

API and wildcard in vm?filter.names

Is it possible for the rest of vcenter 6.5 using the wildcard? And return more than 1000 results?

Sample:

https://vcenter/rest/vcenter/vm?filter.names.1=MyVm0029*

or return  more than 1.000 with rest/vcenter/vm/?~method=get

Tags (1)
4 Replies
ePoy
Enthusiast
Enthusiast

UP

:smileycry:

0 Kudos
tendonsie
Contributor
Contributor

Same issue, more than 1000 vm's in one cluster.

No paging option, no % or * wildcard.

How to get all the vm names from that cluster?

0 Kudos
ePoy
Enthusiast
Enthusiast

In REST https://{{vc}}/rest/vcenter/network?filter.names= I want to put two or three more networks and something like {"text1": "text2"} .

Example: https://{{vc}}/rest/vcenter/network?filter.names= {"85-Lab": "85-Dev"}

does not work and even if I want to find all like network with the priceless text* I do not know how to do it.

Example : https://{{vc}}/rest/vcenter/network?filter.names=%85%

0 Kudos
markobosh
Contributor
Contributor

vSphere API does not provide such capability to search by partial VM name with wildcards.

There is a tricky way to do this. I am using the search functionality in vSphere Client 6.7.0 in my own vSphere Search Proxy Client.

Check my reply and the code snippet here: https://stackoverflow.com/a/61959622

0 Kudos