1
0
mirror of https://github.com/GNS3/gns3-server synced 2025-01-01 03:30:55 +00:00
gns3-server/docs/api/examples/_post_projectsprojectidvms.txt

34 lines
945 B
Plaintext
Raw Normal View History

curl -i -X POST 'http://localhost:8000/v2/projects/bfb7af51-0213-4a66-b348-b0c9465dd8fd/vms' -d '{"hypervisor_id": "example.com", "name": "test", "properties": {"startup_script": "echo test"}, "vm_type": "vpcs"}'
2016-03-11 14:21:21 +00:00
POST /v2/projects/bfb7af51-0213-4a66-b348-b0c9465dd8fd/vms HTTP/1.1
2016-03-11 14:21:21 +00:00
{
"hypervisor_id": "example.com",
"name": "test",
"properties": {
"startup_script": "echo test"
},
"vm_type": "vpcs"
}
HTTP/1.1 201
ACCESS-CONTROL-ALLOW-ORIGIN: *
2016-03-11 14:49:28 +00:00
CONTENT-LENGTH: 308
2016-03-11 14:21:21 +00:00
CONTENT-TYPE: application/json
DATE: Thu, 08 Jan 2015 16:09:15 GMT
SERVER: Python/3.5 GNS3/1.5.0dev1
X-ROUTE: /v2/projects/{project_id}/vms
2016-03-11 14:21:21 +00:00
{
"console": null,
"console_type": "telnet",
"hypervisor_id": "example.com",
"name": "test",
"project_id": "bfb7af51-0213-4a66-b348-b0c9465dd8fd",
2016-03-11 14:21:21 +00:00
"properties": {
2016-03-11 14:49:28 +00:00
"startup_script": "echo test"
2016-03-11 14:21:21 +00:00
},
"vm_id": "b3dd162f-c0f8-49f4-bfdc-9c1892734fb3",
2016-03-11 14:21:21 +00:00
"vm_type": "vpcs"
}