• Native OpenStack API

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

Update network

Function Description

This interface is used to update network information.

Interface Format

Method

URI

Description

PUT

/v2.0/networks/{network-id)

Queries all networks accessible to the tenant submitting the request.

Restrictions

N/A

Request Parameter

Parameter

Type

Mandatory

Description

network

Dict

Yes

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

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

Response Parameter

Parameter

Type

Mandatory

Description

network

Dict

Yes

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

Request Example

PUT /v2.0/networks/60c809cb-6731-45d0-ace8-3bf5626421a9
{
  "network":
  {
    "name": "demo",
    "admin_state_up": true,
    "shared": false
  }
}

Response Example

{
    "network": {
        "status": "ACTIVE",
        "subnets": [],
"availability_zone_hints": [],
"availability_zones": [],
        "name": "demo",
        "admin_state_up": true,
        "tenant_id": "6fbe9263116a4b68818cf1edce16bc4f",
        "router:external": false,
        "shared": false,
        "port_security_enabled":true,
        "id": "60c809cb-6731-45d0-ace8-3bf5626421a9",
    }
}

Error Code

See section Return Code Processing.