mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Fix API status code for start/stop/suspend/reload a node. Fixes #1353.
Fix issues with test. Update documentation.
This commit is contained in:
1 parent
f3b4cc0160
commit
0f496907a0
354 files changed
+9950
-10181
No files matched your search
@@ -9,8 +9,8 @@ Create a node from an appliance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **appliance_id**: Appliance template UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
|
||||
@@ -84,7 +84,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
|
||||
**********************
|
||||
- **201**: Drawing created
|
||||
- **400**: Invalid request
|
||||
- **201**: Drawing created
|
||||
|
||||
Input
|
||||
*******
|
||||
|
||||
@@ -51,8 +51,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Drawing updated
|
||||
- **400**: Invalid request
|
||||
- **201**: Drawing updated
|
||||
|
||||
Input
|
||||
*******
|
||||
@@ -102,8 +102,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Drawing deleted
|
||||
- **400**: Invalid request
|
||||
- **204**: Drawing deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -32,8 +32,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Link created
|
||||
- **400**: Invalid request
|
||||
- **201**: Link created
|
||||
|
||||
Input
|
||||
*******
|
||||
|
||||
@@ -53,8 +53,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Link updated
|
||||
- **400**: Invalid request
|
||||
- **201**: Link updated
|
||||
|
||||
Input
|
||||
*******
|
||||
@@ -108,8 +108,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Link deleted
|
||||
- **400**: Invalid request
|
||||
- **204**: Link deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -14,8 +14,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Capture started
|
||||
- **400**: Invalid request
|
||||
- **201**: Capture started
|
||||
|
||||
Input
|
||||
*******
|
||||
|
||||
@@ -14,8 +14,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Capture stopped
|
||||
- **400**: Invalid request
|
||||
- **201**: Capture stopped
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -13,8 +13,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Instance created
|
||||
- **400**: Invalid request
|
||||
- **201**: Instance created
|
||||
|
||||
Input
|
||||
*******
|
||||
|
||||
@@ -136,14 +136,14 @@ Delete a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance deleted
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance deleted
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -9,13 +9,13 @@ Duplicate a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **201**: Instance duplicated
|
||||
- **400**: Invalid request
|
||||
- **201**: Instance duplicated
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
Input
|
||||
|
||||
@@ -9,14 +9,14 @@ Compute the IDLE PC for a Dynamips node
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance reloaded
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance reloaded
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -9,14 +9,14 @@ Compute a list of potential idle PC for a node
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance reloaded
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance reloaded
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -9,14 +9,14 @@ Get a file in the node directory
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
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:.+}**
|
||||
@@ -25,12 +25,12 @@ Write a file in the node directory
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance reloaded
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
- **204**: Instance reloaded
|
||||
|
||||
@@ -9,8 +9,8 @@ Return all the links connected to this node
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
|
||||
@@ -9,12 +9,12 @@ Reload a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance reloaded
|
||||
- **200**: Instance reloaded
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
|
||||
@@ -9,12 +9,12 @@ Start a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance started
|
||||
- **200**: Instance started
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
|
||||
@@ -9,12 +9,12 @@ Stop a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance stopped
|
||||
- **200**: Instance stopped
|
||||
- **400**: Invalid request
|
||||
- **404**: Instance doesn't exist
|
||||
|
||||
|
||||
@@ -9,12 +9,12 @@ Suspend a node instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **node_id**: Node UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Instance suspended
|
||||
- **200**: Instance suspended
|
||||
- **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
|
||||
**********************
|
||||
- **204**: Changes have been written on disk
|
||||
- **404**: The project doesn't exist
|
||||
- **204**: Changes have been written on disk
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -13,8 +13,8 @@ Parameters
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: The project has been closed
|
||||
- **404**: The project doesn't exist
|
||||
- **204**: The project has been closed
|
||||
|
||||
Output
|
||||
*******
|
||||
|
||||
@@ -9,13 +9,13 @@ Delete a snapshot from disk
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **snapshot_id**: Snasphot UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **204**: Changes have been written on disk
|
||||
- **404**: The project or snapshot doesn't exist
|
||||
- **204**: Changes have been written on disk
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
@@ -9,8 +9,8 @@ Restore a snapshot from disk
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **project_id**: Project UUID
|
||||
- **snapshot_id**: Snasphot UUID
|
||||
- **project_id**: Project UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
|
||||
Reference in new issue
Block a user