mirror of https://github.com/GNS3/gns3-server
parent
547adf0dc6
commit
977ff0fb57
@ -0,0 +1,13 @@
|
||||
curl -i -X DELETE 'http://localhost:8000/project/{uuid}'
|
||||
|
||||
DELETE /project/{uuid} HTTP/1.1
|
||||
|
||||
|
||||
|
||||
HTTP/1.1 204
|
||||
CONNECTION: close
|
||||
CONTENT-LENGTH: 0
|
||||
DATE: Thu, 08 Jan 2015 16:09:15 GMT
|
||||
SERVER: Python/3.4 aiohttp/0.13.1
|
||||
X-ROUTE: /project/{uuid}
|
||||
|
@ -0,0 +1,13 @@
|
||||
curl -i -X POST 'http://localhost:8000/project/{uuid}/close' -d '{}'
|
||||
|
||||
POST /project/{uuid}/close HTTP/1.1
|
||||
{}
|
||||
|
||||
|
||||
HTTP/1.1 204
|
||||
CONNECTION: close
|
||||
CONTENT-LENGTH: 0
|
||||
DATE: Thu, 08 Jan 2015 16:09:15 GMT
|
||||
SERVER: Python/3.4 aiohttp/0.13.1
|
||||
X-ROUTE: /project/{uuid}/close
|
||||
|
@ -0,0 +1,13 @@
|
||||
curl -i -X POST 'http://localhost:8000/project/{uuid}/commit' -d '{}'
|
||||
|
||||
POST /project/{uuid}/commit HTTP/1.1
|
||||
{}
|
||||
|
||||
|
||||
HTTP/1.1 204
|
||||
CONNECTION: close
|
||||
CONTENT-LENGTH: 0
|
||||
DATE: Thu, 08 Jan 2015 16:09:15 GMT
|
||||
SERVER: Python/3.4 aiohttp/0.13.1
|
||||
X-ROUTE: /project/{uuid}/commit
|
||||
|
@ -0,0 +1,83 @@
|
||||
/project/{uuid}
|
||||
---------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
GET /project/**{uuid}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Get project informations
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: Project instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **200**: OK
|
||||
- **404**: Project instance doesn't exist
|
||||
|
||||
Output
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>location</td> <td>✔</td> <td>string</td> <td>Base directory where the project should be created on remote server</td> </tr>
|
||||
<tr><td>temporary</td> <td>✔</td> <td>boolean</td> <td>If project is a temporary project</td> </tr>
|
||||
<tr><td>uuid</td> <td>✔</td> <td>string</td> <td>Project UUID</td> </tr>
|
||||
</table>
|
||||
|
||||
|
||||
PUT /project/**{uuid}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Update a project
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: Project instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **200**: Project updated
|
||||
- **404**: Project instance doesn't exist
|
||||
|
||||
Input
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>temporary</td> <td> </td> <td>boolean</td> <td>If project is a temporary project</td> </tr>
|
||||
</table>
|
||||
|
||||
Output
|
||||
*******
|
||||
.. raw:: html
|
||||
|
||||
<table>
|
||||
<tr> <th>Name</th> <th>Mandatory</th> <th>Type</th> <th>Description</th> </tr>
|
||||
<tr><td>location</td> <td>✔</td> <td>string</td> <td>Base directory where the project should be created on remote server</td> </tr>
|
||||
<tr><td>temporary</td> <td>✔</td> <td>boolean</td> <td>If project is a temporary project</td> </tr>
|
||||
<tr><td>uuid</td> <td>✔</td> <td>string</td> <td>Project UUID</td> </tr>
|
||||
</table>
|
||||
|
||||
|
||||
DELETE /project/**{uuid}**
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Delete a project from disk
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: Project instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **404**: Project instance doesn't exist
|
||||
- **204**: Changes write on disk
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: examples/delete_projectuuid.txt
|
||||
|
@ -0,0 +1,24 @@
|
||||
/project/{uuid}/close
|
||||
---------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /project/**{uuid}**/close
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Close project
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: Project instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **404**: Project instance doesn't exist
|
||||
- **204**: Project closed
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: examples/post_projectuuidclose.txt
|
||||
|
@ -0,0 +1,24 @@
|
||||
/project/{uuid}/commit
|
||||
---------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /project/**{uuid}**/commit
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Write changes on disk
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: Project instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **404**: Project instance doesn't exist
|
||||
- **204**: Changes write on disk
|
||||
|
||||
Sample session
|
||||
***************
|
||||
|
||||
|
||||
.. literalinclude:: examples/post_projectuuidcommit.txt
|
||||
|
@ -0,0 +1,19 @@
|
||||
/virtualbox/{uuid}/reload
|
||||
---------------------------------------------
|
||||
|
||||
.. contents::
|
||||
|
||||
POST /virtualbox/**{uuid}**/reload
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Reload a VirtualBox VM instance
|
||||
|
||||
Parameters
|
||||
**********
|
||||
- **uuid**: VirtualBox VM instance UUID
|
||||
|
||||
Response status codes
|
||||
**********************
|
||||
- **400**: Invalid VirtualBox VM instance UUID
|
||||
- **404**: VirtualBox VM instance doesn't exist
|
||||
- **204**: VirtualBox VM instance reloaded
|
||||
|
Loading…
Reference in new issue