Get Virtual Server Status

Da Wiki Neen.
(Differenze fra le revisioni)
(Creata pagina con '<br> Use the following API call to get statues for all virtual server's status: GET /virtual_machines/:virtual_machine_id/status.xml GET /virtual_machines/:virtual_machine_id/...')
 
 
Riga 1: Riga 1:
<br>
+
<br>  
  
Use the following API call to get statues for all virtual server's status:
+
Use the following API call to get statues for all virtual server's status:  
  
GET /virtual_machines/:virtual_machine_id/status.xml
+
GET /virtual_machines/:virtual_machine_id/status.xml  
  
GET /virtual_machines/:virtual_machine_id/status.json
+
GET /virtual_machines/:virtual_machine_id/status.json  
  
XML Request example
+
'''XML Request example'''
  
curl -i -X GET -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:password --url http://<span style="background-color: navy; color: white;" />cloud.neen.it/virtual_machines/:virtual_machine_id/status.xml
+
curl -i -X GET -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:password --url http://cloud.neen.it/virtual_machines/:virtual_machine_id/status.xml  
  
JSON Request example
+
'''JSON Request example'''
  
curl -i -X GET -H 'Accept: application/json' -H 'Content-type: application/json' -u user:password --url http://<span style="background-color: navy; color: white;" />cloud.neen.it/virtual_machines/:virtual_machine_id/status.json
+
curl -i -X GET -H 'Accept: application/json' -H 'Content-type: application/json' -u user:password --url http://cloud.neen.it/virtual_machines/:virtual_machine_id/status.json  
  
XML Output example
+
'''XML Output example'''
  
&lt;virtual_machines type="array"&gt;<br> &lt;virtual_machine&gt;<br> &lt;id type="integer"&gt;48&lt;/id&gt;<br> &lt;identifier&gt;b266b5h5et39iy&lt;/identifier&gt;<br> &lt;hostname&gt;qaaoxp&lt;/hostname&gt;<br> &lt;template_id type="integer"&gt;111&lt;/template_id&gt;<br> &lt;built type="boolean"&gt;true&lt;/built&gt;<br> &lt;locked type="boolean"&gt;false&lt;/locked&gt;<br> &lt;booted type="boolean"&gt;true&lt;/booted&gt;<br> &lt;operating_system&gt;windows&lt;/operating_system&gt;<br> &lt;suspended type="boolean"&gt;false&lt;/suspended&gt;<br> &lt;enable_autoscale type="boolean"&gt;false&lt;/enable_autoscale&gt;<br> &lt;state&gt;new&lt;/state&gt;<br> &lt;/virtual_machine&gt;<br>&lt;/virtual_machines&gt;
+
<source lang="xml"><virtual_machines type="array">
 +
<virtual_machine>
 +
<id type="integer">48</id>
 +
<identifier>b266b5h5et39iy</identifier>
 +
<hostname>qaaoxp</hostname>
 +
<template_id type="integer">111</template_id>
 +
<built type="boolean">true</built>
 +
<locked type="boolean">false</locked>
 +
<booted type="boolean">true</booted>
 +
<operating_system>windows</operating_system>
 +
<suspended type="boolean">false</suspended>
 +
<enable_autoscale type="boolean">false</enable_autoscale>
 +
<state>new</state>
 +
</virtual_machine>
 +
</virtual_machines></source><br>
  
Where:
+
<br>Where:  
  
id - virtual server ID
+
*id - virtual server ID  
 +
*identifier — the VS identifier
 +
*hostname — the name of your host
 +
*template_id — the ID of the template the VS is based on
 +
*built — true if the VS is built, otherwise false
 +
*locked — true if the VS is locked; otherwise false
 +
*booted — true if the VS is running, otherwise false
 +
*operating_system — operating system used by the VS
 +
*suspended — true if VS is suspended, otherwise false
 +
*enable_autoscale — true if autoscaling is allowed for this VS
 +
*state – virtual server state
  
identifier — the VS identifier
+
<br><br>
  
hostname — the name of your host
+
[[Category:Neencloud]]
 
+
template_id — the ID of the template the VS is based on
+
 
+
built — true if the VS is built, otherwise false
+
 
+
locked — true if the VS is locked; otherwise false
+
 
+
booted — true if the VS is running, otherwise false
+
 
+
operating_system — operating system used by the VS
+
 
+
suspended — true if VS is suspended, otherwise false
+
 
+
enable_autoscale — true if autoscaling is allowed for this VS
+
 
+
state – virtual server state
+
 
+
<br><br>
+

Versione attuale delle 18:08, 20 feb 2014


Use the following API call to get statues for all virtual server's status:

GET /virtual_machines/:virtual_machine_id/status.xml

GET /virtual_machines/:virtual_machine_id/status.json

XML Request example

curl -i -X GET -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:password --url http://cloud.neen.it/virtual_machines/:virtual_machine_id/status.xml

JSON Request example

curl -i -X GET -H 'Accept: application/json' -H 'Content-type: application/json' -u user:password --url http://cloud.neen.it/virtual_machines/:virtual_machine_id/status.json

XML Output example

<virtual_machines type="array">
<virtual_machine>
<id type="integer">48</id>
<identifier>b266b5h5et39iy</identifier>
<hostname>qaaoxp</hostname>
<template_id type="integer">111</template_id>
<built type="boolean">true</built>
<locked type="boolean">false</locked>
<booted type="boolean">true</booted>
<operating_system>windows</operating_system>
<suspended type="boolean">false</suspended>
<enable_autoscale type="boolean">false</enable_autoscale>
<state>new</state>
</virtual_machine>
</virtual_machines>


Where:



Strumenti personali
Namespace
Varianti
Azioni
Navigazione
Strumenti