You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gns3-server/docs/api/examples/controller_post_appliances.txt

63 lines
1.4 KiB

curl -i -X POST 'http://localhost:3080/v2/appliances' -d '{"appliance_type": "ethernet_hub", "compute_id": "local", "name": "Ethernet hub appliance"}'
POST /v2/appliances HTTP/1.1
{
"appliance_type": "ethernet_hub",
"compute_id": "local",
"name": "Ethernet hub appliance"
}
HTTP/1.1 201
Connection: close
Content-Length: 978
Content-Type: application/json
Date: Tue, 20 Nov 2018 06:01:01 GMT
Server: Python/3.6 GNS3/2.2.0dev4
X-Route: /v2/appliances
{
"appliance_id": "a5ee20d1-1217-4c2f-93d8-eefc1fba7a92",
"appliance_type": "ethernet_hub",
"builtin": false,
"category": "switch",
"compute_id": "local",
"default_name_format": "Hub{0}",
"name": "Ethernet hub appliance",
"ports_mapping": [
{
"name": "Ethernet0",
"port_number": 0
},
{
"name": "Ethernet1",
"port_number": 1
},
{
"name": "Ethernet2",
"port_number": 2
},
{
"name": "Ethernet3",
"port_number": 3
},
{
"name": "Ethernet4",
"port_number": 4
},
{
"name": "Ethernet5",
"port_number": 5
},
{
"name": "Ethernet6",
"port_number": 6
},
{
"name": "Ethernet7",
"port_number": 7
}
],
"symbol": ":/symbols/hub.svg"
}