Update API documentation for appliance endpoints. Ref https://github.com/GNS3/gns3-gui/issues/2630

This commit is contained in:
grossmj committed 2018-11-20 13:04:27 +07:00
1 parent e5950674f8
commit ff5ba3742e
343 files changed
+12431 -11199

No files matched your search

@@ -3,6 +3,54 @@
.. contents::
POST /v2/appliances
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Create a new appliance
Response status codes
**********************
- **201**: Appliance created
- **400**: Invalid request
Input
*******
.. raw:: html
<table>
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
<tr><td>appliance_id</td> <td> </td> <td>string</td> <td>Appliance UUID from which the node has been created. Read only</td> </tr>
<tr><td>appliance_type</td> <td>&#10004;</td> <td>enum</td> <td>Possible values: cloud, ethernet_hub, ethernet_switch, docker, dynamips, vpcs, traceng, virtualbox, vmware, iou, qemu</td> </tr>
<tr><td>builtin</td> <td> </td> <td>boolean</td> <td>Appliance is builtin</td> </tr>
<tr><td>category</td> <td> </td> <td></td> <td>Appliance category</td> </tr>
<tr><td>compute_id</td> <td>&#10004;</td> <td>string</td> <td>Compute identifier</td> </tr>
<tr><td>default_name_format</td> <td> </td> <td>string</td> <td>Default name format</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>Appliance name</td> </tr>
<tr><td>symbol</td> <td> </td> <td>string</td> <td>Symbol of the appliance</td> </tr>
</table>
Output
*******
.. raw:: html
<table>
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
<tr><td>appliance_id</td> <td>&#10004;</td> <td>string</td> <td>Appliance UUID from which the node has been created. Read only</td> </tr>
<tr><td>appliance_type</td> <td>&#10004;</td> <td>enum</td> <td>Possible values: cloud, ethernet_hub, ethernet_switch, docker, dynamips, vpcs, traceng, virtualbox, vmware, iou, qemu</td> </tr>
<tr><td>builtin</td> <td>&#10004;</td> <td>boolean</td> <td>Appliance is builtin</td> </tr>
<tr><td>category</td> <td>&#10004;</td> <td></td> <td>Appliance category</td> </tr>
<tr><td>compute_id</td> <td>&#10004;</td> <td>string</td> <td>Compute identifier</td> </tr>
<tr><td>default_name_format</td> <td>&#10004;</td> <td>string</td> <td>Default name format</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>Appliance name</td> </tr>
<tr><td>symbol</td> <td>&#10004;</td> <td>string</td> <td>Symbol of the appliance</td> </tr>
</table>
Sample session
***************
.. literalinclude:: ../../../examples/controller_post_appliances.txt
GET /v2/appliances
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
List of appliance
@@ -10,12 +10,12 @@ Create a node from an appliance
Parameters
**********
- **project_id**: Project UUID
- **appliance_id**: Appliance template UUID
- **appliance_id**: Appliance UUID
Response status codes
**********************
- **201**: Node created
- **404**: The project or template doesn't exist
- **404**: The project or appliance doesn't exist
Input
*******
+1
View File
@@ -37,6 +37,7 @@ Output
<tr><td>connected</td> <td> </td> <td>boolean</td> <td>Whether the controller is connected to the compute server or not</td> </tr>
<tr><td>cpu_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>CPU usage of the compute. Read only</td> </tr>
<tr><td>host</td> <td>&#10004;</td> <td>string</td> <td>Server host</td> </tr>
<tr><td>last_error</td> <td> </td> <td>['string', 'null']</td> <td>Last error on the compute</td> </tr>
<tr><td>memory_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>RAM usage of the compute. Read only</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>Server name</td> </tr>
<tr><td>port</td> <td>&#10004;</td> <td>integer</td> <td>Server port</td> </tr>
+4 -2
View File
@@ -5,7 +5,7 @@
PUT /v2/computes/**{compute_id}**
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Get a compute server information
Update a compute server
Response status codes
**********************
@@ -39,6 +39,7 @@ Output
<tr><td>connected</td> <td> </td> <td>boolean</td> <td>Whether the controller is connected to the compute server or not</td> </tr>
<tr><td>cpu_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>CPU usage of the compute. Read only</td> </tr>
<tr><td>host</td> <td>&#10004;</td> <td>string</td> <td>Server host</td> </tr>
<tr><td>last_error</td> <td> </td> <td>['string', 'null']</td> <td>Last error on the compute</td> </tr>
<tr><td>memory_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>RAM usage of the compute. Read only</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>Server name</td> </tr>
<tr><td>port</td> <td>&#10004;</td> <td>integer</td> <td>Server port</td> </tr>
@@ -66,6 +67,7 @@ Output
<tr><td>connected</td> <td> </td> <td>boolean</td> <td>Whether the controller is connected to the compute server or not</td> </tr>
<tr><td>cpu_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>CPU usage of the compute. Read only</td> </tr>
<tr><td>host</td> <td>&#10004;</td> <td>string</td> <td>Server host</td> </tr>
<tr><td>last_error</td> <td> </td> <td>['string', 'null']</td> <td>Last error on the compute</td> </tr>
<tr><td>memory_usage_percent</td> <td> </td> <td>['number', 'null']</td> <td>RAM usage of the compute. Read only</td> </tr>
<tr><td>name</td> <td>&#10004;</td> <td>string</td> <td>Server name</td> </tr>
<tr><td>port</td> <td>&#10004;</td> <td>integer</td> <td>Server port</td> </tr>
@@ -84,7 +86,7 @@ Parameters
Response status codes
**********************
- **204**: Instance deleted
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance deleted
@@ -32,8 +32,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Drawing created
- **400**: Invalid request
Input
*******
@@ -51,8 +51,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Drawing updated
- **400**: Invalid request
Input
*******
@@ -102,8 +102,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **204**: Drawing deleted
- **400**: Invalid request
Sample session
***************
@@ -32,8 +32,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Link created
- **400**: Invalid request
Input
*******
@@ -53,8 +53,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Link updated
- **400**: Invalid request
Input
*******
@@ -108,8 +108,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **204**: Link deleted
- **400**: Invalid request
Sample session
***************
@@ -5,7 +5,7 @@
GET /v2/projects/**{project_id}**/links/**{link_id}**/pcap
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Stream the pcap capture file
Stream the PCAP capture file from compute
Parameters
**********
@@ -14,8 +14,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Capture started
- **400**: Invalid request
Input
*******
@@ -14,8 +14,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Capture stopped
- **400**: Invalid request
Sample session
***************
@@ -13,8 +13,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Instance created
- **400**: Invalid request
Input
*******
@@ -5,7 +5,7 @@
GET /v2/projects/**{project_id}**/nodes/**{node_id}**
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Update a node instance
Get a node
Response status codes
**********************
@@ -150,9 +150,9 @@ Parameters
Response status codes
**********************
- **204**: Instance deleted
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance deleted
Sample session
***************
@@ -14,8 +14,8 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Instance duplicated
- **400**: Invalid request
- **404**: Instance doesn't exist
Input
@@ -14,9 +14,9 @@ Parameters
Response status codes
**********************
- **204**: Instance reloaded
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance reloaded
Sample session
***************
@@ -14,9 +14,9 @@ Parameters
Response status codes
**********************
- **204**: Instance reloaded
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance reloaded
Sample session
***************
@@ -14,9 +14,9 @@ Parameters
Response status codes
**********************
- **204**: Instance reloaded
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance reloaded
POST /v2/projects/**{project_id}**/nodes/**{node_id}**/files/**{path:.+}**
@@ -30,7 +30,7 @@ Parameters
Response status codes
**********************
- **204**: Instance reloaded
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: Instance reloaded
@@ -14,7 +14,7 @@ Parameters
Response status codes
**********************
- **400**: Invalid request
- **201**: Disk image resized
- **400**: Invalid request
- **404**: Instance doesn't exist
@@ -13,9 +13,9 @@ Parameters
Response status codes
**********************
- **204**: All nodes successfully reloaded
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: All nodes successfully reloaded
Output
*******
@@ -13,9 +13,9 @@ Parameters
Response status codes
**********************
- **204**: All nodes successfully started
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: All nodes successfully started
Output
*******
@@ -13,9 +13,9 @@ Parameters
Response status codes
**********************
- **204**: All nodes successfully stopped
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: All nodes successfully stopped
Output
*******
@@ -13,9 +13,9 @@ Parameters
Response status codes
**********************
- **204**: All nodes successfully suspended
- **400**: Invalid request
- **404**: Instance doesn't exist
- **204**: All nodes successfully suspended
Output
*******
@@ -99,8 +99,8 @@ Parameters
Response status codes
**********************
- **404**: The project doesn't exist
- **204**: Changes have been written on disk
- **404**: The project doesn't exist
Sample session
***************
@@ -13,8 +13,8 @@ Parameters
Response status codes
**********************
- **404**: The project doesn't exist
- **204**: The project has been closed
- **404**: The project doesn't exist
Output
*******
+1 -1
View File
@@ -9,5 +9,5 @@ Dump debug information to disk (debug directory in config directory). Work only
Response status codes
**********************
- **201**: Writed
- **201**: Written
@@ -1,34 +0,0 @@
/v2/settings
------------------------------------------------------------------------------------------------------------------------------------------
.. contents::
GET /v2/settings
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Retrieve gui settings from the server. Temporary will we removed in later release
Response status codes
**********************
- **200**: OK
Sample session
***************
.. literalinclude:: ../../../examples/controller_get_settings.txt
POST /v2/settings
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Write gui settings on the server. Temporary will we removed in later releases
Response status codes
**********************
- **201**: Settings saved
Sample session
***************
.. literalinclude:: ../../../examples/controller_post_settings.txt
@@ -14,8 +14,8 @@ Parameters
Response status codes
**********************
- **404**: The project or snapshot doesn't exist
- **204**: Changes have been written on disk
- **404**: The project or snapshot doesn't exist
Sample session
***************