2016-07-11 16:37:57 +03:00
{
"properties" : {
2016-09-27 18:15:40 +03:00
"auto_open" : {
2018-01-08 06:57:07 +02:00
"type" : "boolean" ,
"description" : "Open the topology with GNS3"
2017-03-06 15:35:39 +02:00
} ,
"version" : {
2018-01-08 06:57:07 +02:00
"type" : "string" ,
"description" : "Version of the GNS3 software which have update the file for the last time"
2017-03-06 15:35:39 +02:00
} ,
"name" : {
"type" : "string" ,
"description" : "Name of the project"
} ,
"scene_height" : {
"type" : "integer" ,
"description" : "Height of the drawing area"
} ,
2018-01-08 06:57:07 +02:00
"type" : {
"enum" : [
"topology"
] ,
"description" : "Type of file. It's always topology"
} ,
"project_id" : {
"maxLength" : 36 ,
"type" : "string" ,
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Project UUID"
2016-08-25 15:43:19 +03:00
} ,
2016-07-14 16:31:49 +03:00
"topology" : {
2016-07-11 16:37:57 +03:00
"properties" : {
2018-01-08 06:57:07 +02:00
"nodes" : {
2017-03-06 15:35:39 +02:00
"type" : "array" ,
2016-10-20 11:54:07 +03:00
"items" : {
"properties" : {
2018-01-08 06:57:07 +02:00
"z" : {
"type" : "integer" ,
"description" : "Z position of the node"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"first_port_name" : {
2016-10-20 11:54:07 +03:00
"type" : [
"string" ,
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Name of the first port"
2016-10-20 11:54:07 +03:00
} ,
2018-01-08 06:57:07 +02:00
"node_directory" : {
2016-10-20 11:54:07 +03:00
"type" : [
2018-01-08 06:57:07 +02:00
"null" ,
"string"
2016-11-03 19:20:51 +02:00
] ,
2018-01-08 06:57:07 +02:00
"description" : "Working directory of the node. Read only"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"command_line" : {
2016-10-20 11:54:07 +03:00
"type" : [
2018-01-08 06:57:07 +02:00
"null" ,
"string"
2016-11-03 19:20:51 +02:00
] ,
2018-01-08 06:57:07 +02:00
"description" : "Command line use to start the node"
2016-10-20 11:54:07 +03:00
} ,
2018-01-08 06:57:07 +02:00
"console_type" : {
"enum" : [
"vnc" ,
"telnet" ,
"http" ,
"https" ,
"spice" ,
null
2017-03-06 15:35:39 +02:00
] ,
2018-01-08 06:57:07 +02:00
"description" : "Console type"
} ,
"x" : {
"type" : "integer" ,
"description" : "X position of the node"
} ,
"compute_id" : {
"type" : "string" ,
"description" : "Compute identifier"
} ,
"node_id" : {
"maxLength" : 36 ,
"type" : "string" ,
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Node UUID"
} ,
"label" : {
2016-08-29 16:58:29 +03:00
"properties" : {
2018-01-08 06:57:07 +02:00
"style" : {
"type" : "string" ,
"description" : "SVG style attribute"
} ,
"y" : {
"type" : "integer" ,
"description" : "Relative Y position of the label"
} ,
"text" : {
"type" : "string"
} ,
"x" : {
2016-08-29 16:58:29 +03:00
"type" : [
2018-01-08 06:57:07 +02:00
"integer" ,
2016-08-29 16:58:29 +03:00
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Relative X position of the label. If null center it"
2016-10-20 11:54:07 +03:00
} ,
2018-01-08 06:57:07 +02:00
"rotation" : {
"type" : "integer" ,
"minimum" : -359 ,
"maximum" : 360 ,
"description" : "Rotation of the label"
}
} ,
"type" : "object" ,
"additionalProperties" : false ,
"required" : [
"text" ,
"x" ,
"y"
]
} ,
"port_segment_size" : {
"type" : "integer" ,
"minimum" : 0 ,
"description" : "Size of the port segment"
} ,
"properties" : {
"type" : "object" ,
"description" : "Properties specific to an emulator"
} ,
"ports" : {
"type" : "array" ,
"items" : {
"properties" : {
"short_name" : {
"type" : "string" ,
"description" : "Short version of port name"
} ,
"adapter_number" : {
"type" : "integer" ,
"description" : "Adapter slot"
} ,
"port_number" : {
"type" : "integer" ,
"description" : "Port slot"
} ,
"name" : {
"type" : "string" ,
"description" : "Port name"
} ,
"link_type" : {
2016-11-03 19:20:51 +02:00
"enum" : [
2018-01-08 06:57:07 +02:00
"ethernet" ,
"serial"
] ,
"description" : "Type of link"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"data_link_types" : {
"properties" : { } ,
"type" : "object" ,
"description" : "Available PCAP type for capture"
}
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"type" : "object" ,
"additionalProperties" : false ,
"description" : "A node port"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"description" : "List of node ports READ only"
} ,
"console" : {
"type" : [
"integer" ,
"null"
] ,
"minimum" : 1 ,
"maximum" : 65535 ,
"description" : "Console TCP port"
} ,
"name" : {
2016-11-03 19:20:51 +02:00
"type" : "string" ,
2018-01-08 06:57:07 +02:00
"minLength" : 1 ,
"description" : "Node name"
} ,
"node_type" : {
"enum" : [
"cloud" ,
"nat" ,
"ethernet_hub" ,
"ethernet_switch" ,
"frame_relay_switch" ,
"atm_switch" ,
"docker" ,
"dynamips" ,
"vpcs" ,
"virtualbox" ,
"vmware" ,
"iou" ,
"qemu"
] ,
"description" : "Type of node"
} ,
"symbol" : {
"type" : [
"string" ,
"null"
] ,
"minLength" : 1 ,
"description" : "Symbol of the node"
2016-11-03 19:20:51 +02:00
} ,
2017-03-06 15:35:39 +02:00
"project_id" : {
2018-01-08 06:57:07 +02:00
"maxLength" : 36 ,
2017-03-06 15:35:39 +02:00
"type" : "string" ,
"minLength" : 36 ,
2018-01-08 06:57:07 +02:00
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Project UUID"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"width" : {
"type" : "integer" ,
"description" : "Width of the node (Read only)"
2016-11-03 19:20:51 +02:00
} ,
"y" : {
2018-01-08 06:57:07 +02:00
"type" : "integer" ,
"description" : "Y position of the node"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"console_host" : {
"type" : "string" ,
"minLength" : 1 ,
"description" : "Console host. Warning if the host is 0.0.0.0 or :: (listen on all interfaces) you need to use the same address you use to connect to the controller."
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"status" : {
"enum" : [
"stopped" ,
"started" ,
"suspended"
] ,
"description" : "Status of the node"
} ,
"height" : {
2016-11-03 19:20:51 +02:00
"type" : "integer" ,
2018-01-08 06:57:07 +02:00
"description" : "Height of the node (Read only)"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"port_name_format" : {
"type" : "string" ,
"description" : "Formating for port name {0} will be replace by port number"
2016-11-03 19:20:51 +02:00
}
} ,
2018-01-08 06:57:07 +02:00
"additionalProperties" : false ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"required" : [
"name" ,
"node_type" ,
"compute_id"
] ,
"type" : "object" ,
"description" : "A node object"
} ,
"description" : "Nodes elements"
2016-11-03 19:20:51 +02:00
} ,
"links" : {
2017-03-06 15:35:39 +02:00
"type" : "array" ,
2016-11-03 19:20:51 +02:00
"items" : {
"properties" : {
"nodes" : {
2017-03-06 15:35:39 +02:00
"type" : "array" ,
2016-09-14 16:24:27 +03:00
"items" : {
"properties" : {
2016-11-03 19:20:51 +02:00
"label" : {
"properties" : {
2017-03-06 15:35:39 +02:00
"style" : {
2018-01-08 06:57:07 +02:00
"type" : "string" ,
"description" : "SVG style attribute"
} ,
"y" : {
"type" : "integer" ,
"description" : "Relative Y position of the label"
} ,
"text" : {
2017-03-06 15:35:39 +02:00
"type" : "string"
2016-11-03 19:20:51 +02:00
} ,
"x" : {
"type" : [
"integer" ,
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Relative X position of the label. If null center it"
2017-03-06 15:35:39 +02:00
} ,
"rotation" : {
"type" : "integer" ,
"minimum" : -359 ,
2018-01-08 06:57:07 +02:00
"maximum" : 360 ,
"description" : "Rotation of the label"
2016-11-03 19:20:51 +02:00
}
} ,
2018-01-08 06:57:07 +02:00
"type" : "object" ,
"additionalProperties" : false ,
2016-11-03 19:20:51 +02:00
"required" : [
"text" ,
"x" ,
"y"
2018-01-08 06:57:07 +02:00
]
} ,
"node_id" : {
"maxLength" : 36 ,
"type" : "string" ,
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Node UUID"
} ,
"port_number" : {
"type" : "integer" ,
"description" : "Port number"
} ,
"adapter_number" : {
"type" : "integer" ,
"description" : "Adapter number"
2016-09-14 16:24:27 +03:00
}
} ,
2018-01-08 06:57:07 +02:00
"type" : "object" ,
"additionalProperties" : false ,
2016-11-03 19:20:51 +02:00
"required" : [
"node_id" ,
"adapter_number" ,
"port_number"
2018-01-08 06:57:07 +02:00
]
} ,
"description" : "List of the VMS"
} ,
"link_id" : {
"maxLength" : 36 ,
"type" : "string" ,
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Link UUID"
2017-03-06 15:35:39 +02:00
} ,
"capturing" : {
2018-01-08 06:57:07 +02:00
"type" : "boolean" ,
"description" : "Read only property. True if a capture running on the link"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"capture_file_path" : {
2017-03-06 15:35:39 +02:00
"type" : [
"string" ,
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Read only property. The full path of the capture file if capture is running"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"capture_file_name" : {
2017-03-06 15:35:39 +02:00
"type" : [
"string" ,
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Read only property. The name of the capture file if capture is running"
} ,
"suspend" : {
"type" : "boolean" ,
"description" : "Suspend the link"
2017-03-06 15:35:39 +02:00
} ,
"link_type" : {
"enum" : [
"ethernet" ,
"serial"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Type of link"
} ,
"project_id" : {
"maxLength" : 36 ,
"type" : "string" ,
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Project UUID"
} ,
"filters" : {
"type" : "object" ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"description" : "Packet filter. This allow to simulate latency and errors"
2016-11-03 19:20:51 +02:00
}
} ,
2018-01-08 06:57:07 +02:00
"type" : "object" ,
"additionalProperties" : false ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"description" : "A link object"
} ,
"description" : "Link elements"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"drawings" : {
2017-03-06 15:35:39 +02:00
"type" : "array" ,
2016-11-03 19:20:51 +02:00
"items" : {
"properties" : {
2018-01-08 06:57:07 +02:00
"y" : {
"type" : "integer" ,
"description" : "Y property"
2016-10-20 11:54:07 +03:00
} ,
2018-01-08 06:57:07 +02:00
"x" : {
"type" : "integer" ,
"description" : "X property"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"z" : {
"type" : "integer" ,
"description" : "Z property"
} ,
"drawing_id" : {
"maxLength" : 36 ,
2017-03-06 15:35:39 +02:00
"type" : "string" ,
"minLength" : 36 ,
2018-01-08 06:57:07 +02:00
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Drawing UUID"
2016-10-20 11:54:07 +03:00
} ,
2018-01-08 06:57:07 +02:00
"svg" : {
"type" : "string" ,
"description" : "SVG content of the drawing"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"project_id" : {
"maxLength" : 36 ,
2017-03-06 15:35:39 +02:00
"type" : "string" ,
2018-01-08 06:57:07 +02:00
"minLength" : 36 ,
"pattern" : "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$" ,
"description" : "Project UUID"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"rotation" : {
"type" : "integer" ,
"minimum" : -359 ,
"maximum" : 360 ,
"description" : "Rotation of the element"
}
} ,
"type" : "object" ,
"additionalProperties" : false ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"description" : "An drawing object"
} ,
"description" : "Drawings elements"
} ,
"computes" : {
"type" : "array" ,
"items" : {
"properties" : {
"cpu_usage_percent" : {
2017-03-06 15:35:39 +02:00
"type" : [
2018-01-08 06:57:07 +02:00
"number" ,
2016-11-03 19:20:51 +02:00
"null"
2018-01-08 06:57:07 +02:00
] ,
"minimum" : 0 ,
"maximum" : 100 ,
"description" : "CPU usage of the compute. Read only"
2016-09-14 16:24:27 +03:00
} ,
2018-01-08 06:57:07 +02:00
"connected" : {
"type" : "boolean" ,
"description" : "Whether the controller is connected to the compute server or not"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"protocol" : {
2016-09-14 16:24:27 +03:00
"enum" : [
2016-10-20 11:54:07 +03:00
"http" ,
2018-01-08 06:57:07 +02:00
"https"
] ,
"description" : "Server protocol"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"capabilities" : {
2016-11-03 19:20:51 +02:00
"properties" : {
2018-01-08 06:57:07 +02:00
"platform" : {
"type" : "string" ,
"description" : "Platform where the compute is running"
2016-11-03 19:20:51 +02:00
} ,
2018-01-08 06:57:07 +02:00
"version" : {
2016-11-03 19:20:51 +02:00
"type" : [
2018-01-08 06:57:07 +02:00
"string" ,
2016-11-03 19:20:51 +02:00
"null"
2018-01-08 06:57:07 +02:00
] ,
"description" : "Version number"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"node_types" : {
"type" : "array" ,
"items" : {
"enum" : [
"cloud" ,
"nat" ,
"ethernet_hub" ,
"ethernet_switch" ,
"frame_relay_switch" ,
"atm_switch" ,
"docker" ,
"dynamips" ,
"vpcs" ,
"virtualbox" ,
"vmware" ,
"iou" ,
"qemu"
] ,
"description" : "Type of node"
} ,
"description" : "Node type supported by the compute"
2016-11-03 19:20:51 +02:00
}
} ,
2018-01-08 06:57:07 +02:00
"additionalProperties" : false ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"type" : "object" ,
"description" : "Get what a server support" ,
2016-11-03 19:20:51 +02:00
"required" : [
2018-01-08 06:57:07 +02:00
"version" ,
"node_types"
]
2016-09-27 18:15:40 +03:00
} ,
2018-01-08 06:57:07 +02:00
"name" : {
"type" : "string" ,
"description" : "Server name"
} ,
"user" : {
2016-09-27 18:15:40 +03:00
"type" : [
2017-03-06 15:35:39 +02:00
"string" ,
2016-10-20 11:54:07 +03:00
"null"
2016-09-27 18:15:40 +03:00
] ,
2018-01-08 06:57:07 +02:00
"description" : "User for authentication"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"compute_id" : {
"type" : "string" ,
"description" : "Server identifier"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"host" : {
"type" : "string" ,
"description" : "Server host"
2016-09-27 18:15:40 +03:00
} ,
2018-01-08 06:57:07 +02:00
"memory_usage_percent" : {
2017-03-06 15:35:39 +02:00
"type" : [
2018-01-08 06:57:07 +02:00
"number" ,
2017-03-06 15:35:39 +02:00
"null"
2018-01-08 06:57:07 +02:00
] ,
"minimum" : 0 ,
"maximum" : 100 ,
"description" : "RAM usage of the compute. Read only"
2017-03-06 15:35:39 +02:00
} ,
2018-01-08 06:57:07 +02:00
"port" : {
"type" : "integer" ,
"description" : "Server port"
2016-07-11 16:37:57 +03:00
}
2016-11-03 19:20:51 +02:00
} ,
2017-06-29 18:14:09 +03:00
"additionalProperties" : false ,
2018-01-08 06:57:07 +02:00
"$schema" : "http://json-schema.org/draft-04/schema#" ,
2017-06-29 18:14:09 +03:00
"required" : [
2018-01-08 06:57:07 +02:00
"compute_id" ,
"protocol" ,
"host" ,
"port" ,
"name"
] ,
"type" : "object" ,
"description" : "Request validation to a GNS3 compute object instance"
} ,
"description" : "Computes servers"
2016-07-11 16:37:57 +03:00
}
2016-07-14 16:31:49 +03:00
} ,
2018-01-08 06:57:07 +02:00
"type" : "object" ,
2016-10-20 11:54:07 +03:00
"required" : [
"nodes" ,
"links" ,
"drawings" ,
"computes"
2016-11-03 19:20:51 +02:00
] ,
2018-01-08 06:57:07 +02:00
"additionalProperties" : false ,
"description" : "The topology content"
} ,
"revision" : {
"type" : "integer" ,
"description" : "Version of the .gns3 specification."
} ,
"auto_close" : {
"type" : "boolean" ,
"description" : "Close the topology when no client is connected"
} ,
"show_layers" : {
"type" : "boolean" ,
"description" : "Show layers on the drawing area"
} ,
"snap_to_grid" : {
"type" : "boolean" ,
"description" : "Snap to grid on the drawing area"
} ,
"scene_width" : {
"type" : "integer" ,
"description" : "Width of the drawing area"
} ,
"zoom" : {
"type" : "integer" ,
"description" : "Zoom of the drawing area"
} ,
"auto_start" : {
"type" : "boolean" ,
"description" : "Start the topology when opened"
} ,
"show_interface_labels" : {
"type" : "boolean" ,
"description" : "Show interface labels on the drawing area"
} ,
"show_grid" : {
"type" : "boolean" ,
"description" : "Show the grid on the drawing area"
2016-07-11 16:37:57 +03:00
}
2016-09-27 18:15:40 +03:00
} ,
2018-01-08 06:57:07 +02:00
"additionalProperties" : false ,
"$schema" : "http://json-schema.org/draft-04/schema#" ,
"type" : "object" ,
"description" : "The topology" ,
2016-09-27 18:15:40 +03:00
"required" : [
"project_id" ,
"type" ,
"revision" ,
"version" ,
"name" ,
"topology"
2018-01-08 06:57:07 +02:00
]
2016-07-11 16:37:57 +03:00
}