mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Update API documentation
This commit is contained in:
1 parent
21a7a68875
commit
e6d2bd4424
360 files changed
+17598
-896
No files matched your search
@@ -13,8 +13,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **201**: Instance created
|
||||
- **400**: Invalid request
|
||||
- **409**: Conflict
|
||||
|
||||
Input
|
||||
@@ -46,3 +46,9 @@ Output
|
||||
<tr><td>status</td> <td>✔</td> <td>enum</td> <td>Possible values: started, stopped, suspended</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodes.txt
|
||||
|
||||
@@ -9,8 +9,8 @@ Get a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
@@ -34,6 +34,12 @@ Output
|
||||
<tr><td>status</td> <td>✔</td> <td>enum</td> <td>Possible values: started, stopped, suspended</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_get_projectsprojectidvpcsnodesnodeid.txt
|
||||
|
||||
|
||||
PUT /v2/compute/projects/**{project_id}**/vpcs/nodes/**{node_id}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -41,8 +47,8 @@ Update a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
@@ -78,6 +84,12 @@ Output
|
||||
<tr><td>status</td> <td>✔</td> <td>enum</td> <td>Possible values: started, stopped, suspended</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_put_projectsprojectidvpcsnodesnodeid.txt
|
||||
|
||||
|
||||
DELETE /v2/compute/projects/**{project_id}**/vpcs/nodes/**{node_id}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -85,12 +97,18 @@ Delete a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance deleted
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_delete_projectsprojectidvpcsnodesnodeid.txt
|
||||
|
||||
+27
-9
@@ -9,17 +9,23 @@ Add a NIO to a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **port_number**: Port where the nio should be added
|
||||
- **node_id**: Node UUID
|
||||
- **adapter_number**: Network adapter where the nio is located
|
||||
- **port_number**: Port where the nio should be added
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **201**: NIO created
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodesnodeidadaptersadapternumberdportsportnumberdnio.txt
|
||||
|
||||
|
||||
PUT /v2/compute/projects/**{project_id}**/vpcs/nodes/**{node_id}**/adapters/**{adapter_number:\d+}**/ports/**{port_number:\d+}**/nio
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -27,17 +33,23 @@ Update a NIO from a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **port_number**: Port from where the nio should be updated
|
||||
- **node_id**: Node UUID
|
||||
- **adapter_number**: Network adapter where the nio is located
|
||||
- **port_number**: Port from where the nio should be updated
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **201**: NIO updated
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_put_projectsprojectidvpcsnodesnodeidadaptersadapternumberdportsportnumberdnio.txt
|
||||
|
||||
|
||||
DELETE /v2/compute/projects/**{project_id}**/vpcs/nodes/**{node_id}**/adapters/**{adapter_number:\d+}**/ports/**{port_number:\d+}**/nio
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@@ -45,14 +57,20 @@ Remove a NIO from a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **port_number**: Port from where the nio should be removed
|
||||
- **node_id**: Node UUID
|
||||
- **adapter_number**: Network adapter where the nio is located
|
||||
- **port_number**: Port from where the nio should be removed
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: NIO deleted
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: NIO deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_delete_projectsprojectidvpcsnodesnodeidadaptersadapternumberdportsportnumberdnio.txt
|
||||
|
||||
+2
-2
@@ -9,10 +9,10 @@ Start a packet capture on a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **port_number**: Port on the adapter
|
||||
- **node_id**: Node UUID
|
||||
- **adapter_number**: Adapter to start a packet capture
|
||||
- **port_number**: Port on the adapter
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
|
||||
+3
-3
@@ -9,14 +9,14 @@ Stop a packet capture on a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **port_number**: Port on the adapter
|
||||
- **node_id**: Node UUID
|
||||
- **adapter_number**: Adapter to stop a packet capture
|
||||
- **port_number**: Port on the adapter
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Capture stopped
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Capture stopped
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
/v2/compute/projects/{project_id}/vpcs/nodes/{node_id}/duplicate
|
||||
------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v2/compute/projects/**{project_id}**/vpcs/nodes/**{node_id}**/duplicate
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Duplicate a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Instance duplicated
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodesnodeidduplicate.txt
|
||||
|
||||
@@ -9,12 +9,18 @@ Reload a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance reloaded
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance reloaded
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodesnodeidreload.txt
|
||||
|
||||
@@ -9,14 +9,14 @@ Start a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance started
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance started
|
||||
|
||||
Output
|
||||
*******
|
||||
@@ -34,3 +34,9 @@ Output
|
||||
<tr><td>status</td> <td>✔</td> <td>enum</td> <td>Possible values: started, stopped, suspended</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodesnodeidstart.txt
|
||||
|
||||
@@ -9,12 +9,18 @@ Stop a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance stopped
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance stopped
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../../examples/compute_post_projectsprojectidvpcsnodesnodeidstop.txt
|
||||
|
||||
@@ -9,12 +9,12 @@ Suspend a VPCS instance (stop it)
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance stopped
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance stopped
|
||||
|
||||
Reference in new issue
Block a user