Get List of vCenter Resource Pools
To get a list of vCenter resource pools in your cloud, use the following request:
1
2
| GET /vcenter/resource_pools.xml
GET /vcenter/resource_pools.json
|
XML Request Example
1
| curl -i -X GET http://onapp.test/vcenter/resource_pools.xml -u user:userpass -H 'Accept: application/xml' -H 'Content-type: application/xml'
|
JSON Request Example
1
| curl -i -X GET http://onapp.test/vcenter/resource_pools.json -u user:userpass -H 'Accept: application/json' -H 'Content-type: application/json'
|
XML Output Example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
| <vcenter_resource_pools type="array">
<vcenter_resource_pool>
<id type="integer">2</id>
<label>RP1</label>
<identifier>resgroup-2357</identifier>
<cluster_id type="integer">1</cluster_id>
<parent_id type="integer">1</parent_id>
<user_id nil="true"/>
</vcenter_resource_pool>
<vcenter_resource_pool>
<id type="integer">3</id>
<label>RP2</label>
<identifier>resgroup-2358</identifier>
<cluster_id type="integer">1</cluster_id>
<parent_id type="integer">1</parent_id>
<user_id nil="true"/>
</vcenter_resource_pool>
<vcenter_resource_pool>
<id type="integer">21</id>
<label>RD-vcd-c.onappdev.com-resource-pool</label>
<identifier>resgroup-11092</identifier>
<cluster_id type="integer">4</cluster_id>
<parent_id type="integer">17</parent_id>
<user_id nil="true"/>
</vcenter_resource_pool>
</vcenter_resource_pools>
|
Where:
id - ID of the vCenter resource pool
label - the name of the vCenter resource pool
identifier - the resource pool identifier
cluster_id - ID of the cluster the resource pool is based in
parent_id - ID of the default resource pool
user_id - equal to nil if resource pool is imported into CP or equal to user_id if created by the user via CP