Showing virtual network details

GET /v2.0/networks/{network_id}

Shows the details of a network with the specified ID.

Source: https://docs.openstack.org/api-ref/network/v2/index.html?expanded=show-network-details-detail#show-network-details

Request

Parameters

Name In Type Description
network_id path string The ID of the network.
fields (Optional) query string The fields that you want the server to return. If no fields query parameter is specified, the networking API returns all attributes allowed by the policy settings. By using the fields parameter, the API returns only the requested set of attributes. The fields parameter can be specified multiple times. For example, if you specify fields=id&fields=name in the request URL, only the id and name attributes will be returned.

Example

# curl -ks -H 'Content-Type: application/json' -H 'X-Auth-Token: gAAAAA<...>' \
https://<node_IP_addr>:9696/v2.0/networks/c5252a20-9206-4b8e-9a0f-45bd22ee7bc8

Response

Parameters

Name In Type Description
network body object A network object.
admin_state_up body boolean The administrative state of the network, which is up (true) or down (false).
availability_zone_hints body array The availability zone candidate for the network.
availability_zones body array The availability zone for the network.
created_at body string

The date and time when the resource was created.

The date and time stamp format is ISO 8601:

CCYY-MM-DDThh:mm:ss±hh:mm

For example, 2015-08-27T09:49:58-05:00.

The ±hh:mm value, if included, is the time zone as an offset from UTC. In this example, the offset value is -05:00.

dns_domain body string A valid DNS domain.
id body string The ID of the network.
ipv4_address_scope body string The ID of the IPv4 address scope that the network is associated with.
ipv6_address_scope body string The ID of the IPv6 address scope that the network is associated with.
l2_adjacency body boolean Indicates whether L2 connectivity is available throughout the network.
mtu body integer The maximum transmission unit (MTU) value to address fragmentation. Minimum value is 68 for IPv4, and 1280 for IPv6.
name body string Human-readable name of the network.
port_security_enabled body boolean The port security status of the network. Valid values are enabled (true) and disabled (false). This value is used as the default value of port_security_enabled field of a newly created port.
project_id body string The ID of the project.
provider:network_type body string The type of physical network that this network is mapped to. For example, flat, vlan, vxlan, or gre. Valid values depend on a networking back-end.
provider:physical_network body string The physical network where this network/segment is implemented.
provider:segmentation_id body integer The ID of the isolated segment on the physical network. The network_type attribute defines the segmentation model. For example, if the network_type value is vlan, this ID is a vlan identifier. If the network_type value is gre, this ID is a gre key.
qos_policy_id body string The ID of the QoS policy associated with the network.
revision_number body integer The revision number of the network.
router:external body boolean Indicates whether the network has an external routing facility that’s not managed by the networking service. If the network is updated from external to internal the unused floating IPs of this network are automatically deleted when extension floatingip-autodelete-internal is present.
segments body array A list of provider segment objects.
shared body boolean Indicates whether this network is shared across all tenants. By default, only administrative users can change this value.
status body string The network status. Values are ACTIVE, DOWN, BUILD or ERROR.
subnets body array The associated subnets.
tenant_id body string The ID of the project.
updated_at body string

The date and time when the resource was updated. If the resource has not been updated, this field will be null.

The date and time stamp format is ISO 8601:

CCYY-MM-DDThh:mm:ss±hh:mm

For example, 2015-08-27T09:49:58-05:00.

The ±hh:mm value, if included, is the time zone as an offset from UTC. In this example, the offset value is -05:00.

vlan_transparent body boolean Indicates the VLAN transparency mode of the network, which is VLAN transparent (true) or not VLAN transparent (false).
default_vnic_type body string The default value of the vnic_type parameter for each virtual port created in this network.
description body string A human-readable description for the network.
is_default body boolean The network is default pool or not.
tags body array The list of tags on the network.

Status codes

Success

Code Reason
200 - OK Request was successful.

Error

Code Reason
401 - Unauthorized

User must authenticate before making a request.

404 - Not Found

The requested resource could not be found.

Example

{
  "network": {
    "provider:physical_network": null,
    "ipv6_address_scope": null,
    "revision_number": 2,
    "port_security_enabled": true,
    "provider:network_type": "vxlan",
    "id": "c5252a20-9206-4b8e-9a0f-45bd22ee7bc8",
    "router:external": false,
    "availability_zone_hints": [],
    "availability_zones": [
      "nova"
    ],
    "ipv4_address_scope": null,
    "shared": true,
    "project_id": "f5d834d636c642c7bfe8af86139c6f26",
    "status": "ACTIVE",
    "subnets": [
      "aa29d149-b2a4-45a0-8066-dc63fa9c9b77"
    ],
    "description": "",
    "tags": [],
    "updated_at": "2020-02-14T13:42:56Z",
    "provider:segmentation_id": 5,
    "name": "net1",
    "admin_state_up": true,
    "tenant_id": "f5d834d636c642c7bfe8af86139c6f26",
    "created_at": "2020-02-14T13:36:11Z",
    "mtu": 1450
  }
}