mirror of
https://github.com/GNS3/gns3-server.git
synced 2025-06-16 06:18:19 +00:00
Fix doc generation
This commit is contained in:
50
docs/api/v1/vpcs/projectsprojectidvpcsvms.rst
Normal file
50
docs/api/v1/vpcs/projectsprojectidvpcsvms.rst
Normal file
@ -0,0 +1,50 @@
|
||||
/v1/projects/{project_id}/vpcs/vms
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v1/projects/**{project_id}**/vpcs/vms
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Create a new VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **201**: Instance created
|
||||
- **409**: Conflict
|
||||
|
||||
Input
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>console</td> <td> </td> <td>['integer', 'null']</td> <td>console TCP port</td> </tr>
|
||||
<tr><td>name</td> <td>✔</td> <td>string</td> <td>VPCS VM name</td> </tr>
|
||||
<tr><td>startup_script</td> <td> </td> <td>['string', 'null']</td> <td>Content of the VPCS startup script</td> </tr>
|
||||
<tr><td>vm_id</td> <td> </td> <td></td> <td>VPCS VM identifier</td> </tr>
|
||||
</table>
|
||||
|
||||
Output
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>console</td> <td>✔</td> <td>integer</td> <td>console TCP port</td> </tr>
|
||||
<tr><td>name</td> <td>✔</td> <td>string</td> <td>VPCS VM name</td> </tr>
|
||||
<tr><td>project_id</td> <td>✔</td> <td>string</td> <td>Project UUID</td> </tr>
|
||||
<tr><td>startup_script</td> <td> </td> <td>['string', 'null']</td> <td>Content of the VPCS startup script</td> </tr>
|
||||
<tr><td>vm_id</td> <td>✔</td> <td>string</td> <td>VPCS VM UUID</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/post_projectsprojectidvpcsvms.txt
|
||||
|
108
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmid.rst
Normal file
108
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmid.rst
Normal file
@ -0,0 +1,108 @@
|
||||
/v1/projects/{project_id}/vpcs/vms/{vm_id}
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
GET /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Get a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **200**: Success
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Output
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>console</td> <td>✔</td> <td>integer</td> <td>console TCP port</td> </tr>
|
||||
<tr><td>name</td> <td>✔</td> <td>string</td> <td>VPCS VM name</td> </tr>
|
||||
<tr><td>project_id</td> <td>✔</td> <td>string</td> <td>Project UUID</td> </tr>
|
||||
<tr><td>startup_script</td> <td> </td> <td>['string', 'null']</td> <td>Content of the VPCS startup script</td> </tr>
|
||||
<tr><td>vm_id</td> <td>✔</td> <td>string</td> <td>VPCS VM UUID</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/get_projectsprojectidvpcsvmsvmid.txt
|
||||
|
||||
|
||||
PUT /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Update a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **200**: Instance updated
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **409**: Conflict
|
||||
|
||||
Input
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>console</td> <td> </td> <td>['integer', 'null']</td> <td>console TCP port</td> </tr>
|
||||
<tr><td>name</td> <td> </td> <td>['string', 'null']</td> <td>VPCS VM name</td> </tr>
|
||||
<tr><td>startup_script</td> <td> </td> <td>['string', 'null']</td> <td>Content of the VPCS startup script</td> </tr>
|
||||
</table>
|
||||
|
||||
Output
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>console</td> <td>✔</td> <td>integer</td> <td>console TCP port</td> </tr>
|
||||
<tr><td>name</td> <td>✔</td> <td>string</td> <td>VPCS VM name</td> </tr>
|
||||
<tr><td>project_id</td> <td>✔</td> <td>string</td> <td>Project UUID</td> </tr>
|
||||
<tr><td>startup_script</td> <td> </td> <td>['string', 'null']</td> <td>Content of the VPCS startup script</td> </tr>
|
||||
<tr><td>vm_id</td> <td>✔</td> <td>string</td> <td>VPCS VM UUID</td> </tr>
|
||||
</table>
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/put_projectsprojectidvpcsvmsvmid.txt
|
||||
|
||||
|
||||
DELETE /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Delete a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/delete_projectsprojectidvpcsvmsvmid.txt
|
||||
|
@ -0,0 +1,52 @@
|
||||
/v1/projects/{project_id}/vpcs/vms/{vm_id}/adapters/{adapter_number:\d+}/ports/{port_number:\d+}/nio
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**/adapters/**{adapter_number:\d+}**/ports/**{port_number:\d+}**/nio
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Add a NIO to a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **adapter_number**: Network adapter where the nio is located
|
||||
- **vm_id**: UUID for the instance
|
||||
- **port_number**: Port where the nio should be added
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **201**: NIO created
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/post_projectsprojectidvpcsvmsvmidadaptersadapternumberdportsportnumberdnio.txt
|
||||
|
||||
|
||||
DELETE /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**/adapters/**{adapter_number:\d+}**/ports/**{port_number:\d+}**/nio
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Remove a NIO from a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **adapter_number**: Network adapter where the nio is located
|
||||
- **vm_id**: UUID for the instance
|
||||
- **port_number**: Port from where the nio should be removed
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: NIO deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/delete_projectsprojectidvpcsvmsvmidadaptersadapternumberdportsportnumberdnio.txt
|
||||
|
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidreload.rst
Normal file
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidreload.rst
Normal file
@ -0,0 +1,26 @@
|
||||
/v1/projects/{project_id}/vpcs/vms/{vm_id}/reload
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**/reload
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Reload a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance reloaded
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/post_projectsprojectidvpcsvmsvmidreload.txt
|
||||
|
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidstart.rst
Normal file
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidstart.rst
Normal file
@ -0,0 +1,26 @@
|
||||
/v1/projects/{project_id}/vpcs/vms/{vm_id}/start
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**/start
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Start a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance started
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/post_projectsprojectidvpcsvmsvmidstart.txt
|
||||
|
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidstop.rst
Normal file
26
docs/api/v1/vpcs/projectsprojectidvpcsvmsvmidstop.rst
Normal file
@ -0,0 +1,26 @@
|
||||
/v1/projects/{project_id}/vpcs/vms/{vm_id}/stop
|
||||
----------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /v1/projects/**{project_id}**/vpcs/vms/**{vm_id}**/stop
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Stop a VPCS instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: UUID for the project
|
||||
- **vm_id**: UUID for the instance
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance stopped
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: ../../examples/post_projectsprojectidvpcsvmsvmidstop.txt
|
||||
|
Reference in New Issue
Block a user