• Native OpenStack API

noa
  1. Help Center
  2. Native OpenStack API
  3. API Reference
  4. Neutron
  5. Network
  6. Updating a Network

Updating a Network

Function

This interface is used to update a network.

URI

PUT /v2.0/networks/{network_id}

Request Message

Table 1 Request parameter

Parameter

Type

Mandatory

Description

networks

Dict

Yes

Specifies the network list. For details, see Table 1.

This parameter has no mandatory fields. You must specify at least one attribute when updating the port.

Response Message

Table 2 Response parameter

Parameter

Type

Description

networks

Dict

Specifies the network metadata. For details, see Table 1.

Example:

Example request

PUT /v2.0/networks/c360322d-5315-45d7-b7d2-481f98c56edb  
{
  "network": {
    "name": "network-test02"
  }
}

Example response

{
    "network": {
        "id": "c360322d-5315-45d7-b7d2-481f98c56edb",
        "name": "network-test02",
        "status": "ACTIVE",
        "shared": false,
        "subnets": [],
        "availability_zone_hints": [],
        "availability_zones": [
            "az2.dc2",
            "az5.dc5"
        ],
        "admin_state_up": true,
        "tenant_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "project_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "provider:network_type": "vxlan",
        "router:external": false,
        "port_security_enabled": true,
        "created_at": "2018-09-20T01:53:18",
        "updated_at": "2018-09-20T01:55:47"
    }
}

Status Codes

For details, see section Status Codes.