From 31dce383183aa2a5855299f3b7cfb6827872a099 Mon Sep 17 00:00:00 2001 From: dlavigne Date: Thu, 3 Mar 2016 13:33:23 -0500 Subject: [PATCH] Doc listdisks action. --- api/classes/iohyve.rst | 52 ++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 50 insertions(+), 2 deletions(-) diff --git a/api/classes/iohyve.rst b/api/classes/iohyve.rst index 2f56b6a..a98d92d 100644 --- a/api/classes/iohyve.rst +++ b/api/classes/iohyve.rst @@ -21,7 +21,7 @@ Every iohyve class request contains the following parameters: | | | | +---------------------------------+---------------+----------------------------------------------------------------------------------------------------------------------+ | action | | supported actions include "listvms", "fetchiso", "listisos", "renameiso", "rmiso", "setup", "issetup", "create", | -| | | "install", "start", "stop", "delete", "adddisk" | +| | | "install", "start", "stop", "delete", "adddisk", and "listdisks" | | | | | +---------------------------------+---------------+----------------------------------------------------------------------------------------------------------------------+ @@ -637,7 +637,7 @@ The "delete" action deletes the specified iohyve guest. "namespace": "sysadm" } - .. index:: adddisk, iohyve +.. index:: adddisk, iohyve .. _Add a Disk: @@ -687,4 +687,52 @@ The "adddisk" action adds and creates a disk for a VM. "id": "fooid", "name": "response", "namespace": "sysadm" + } + +.. index:: listdisks, iohyve + +.. _List Disks: + +List Disks +========== + +The "listdisks" action lists the disks connected to the specified VM. + +**REST Request** + +.. code-block:: json + + PUT /sysadm/iohyve + { + "name" : "bsdguest", + "action" : "listdisks" + } + +**WebSocket Request** + +.. code-block:: json + + { + "args" : { + "action" : "listdisks", + "name" : "bsdguest" + }, + "id" : "fooid", + "namespace" : "sysadm", + "name" : "iohyve" + } + +**Response** + +.. code-block:: json + + { + "args": { + "listdisks": { + "disk0": "10G" + } + }, + "id": "fooid", + "name": "response", + "namespace": "sysadm" } \ No newline at end of file