• Elastic IP

eip
  1. Help Center
  2. Elastic IP
  3. API Reference
  4. OpenStack Neutron APIs
  5. Floating IP Address
  6. Updating a Floating IP Address

Updating a Floating IP Address

Function

This interface is used to update a floating IP address.

Restrictions

When you bind a floating IP address, if the floating IP address is in the error state, try unbinding the address first.

You are not allowed to bind a floating IP address that has been bound to a port to another port. You must first unbind the IP address from its original port and bind it to the required port.

URI

PUT /v2.0/floatingips/{floatingip_id}

Request Message

Table 1 Request parameter

Parameter

Type

Mandatory

Description

floatingip

Dict

Yes

Specifies the floating IP address list. For details, see Table 1.

This parameter has no mandatory fields.

Response Message

Table 2 Response parameter

Parameter

Type

Description

floatingip

Dict

Specifies the floating IP address list. For details, see Table 1.

Example:

Example request 1

PUT /v2.0/floatingips/b997e0d4-3359-4c74-8f88-bc0af81cd5a2  
{
    "floatingip": {
           "port_id": "f91f5763-c5a2-4458-979d-61e48b3c3fac"
    }
}

Example response 1

{
    "floatingip": {
        "id": "b997e0d4-3359-4c74-8f88-bc0af81cd5a2",
        "status": "DOWN",
        "router_id": null,
        "tenant_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "project_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "floating_network_id": "0a2228f2-7f8a-45f1-8e09-9039e1d09975",
        "fixed_ip_address": "192.168.10.3",
        "floating_ip_address": "88.88.215.205",
        "port_id": 00587256-27e3-489b-96bf-ea80c1da4aeb,
        "created_at": "2018-09-20T02:10:02",
        "updated_at": "2018-09-20T02:10:07"
    }
}

Example request 2

PUT /v2.0/floatingips/b997e0d4-3359-4c74-8f88-bc0af81cd5a2
{
    "floatingip": {
        "port_id": null
    }
}

Example response 2

{
    "floatingip": {
        "id": "b997e0d4-3359-4c74-8f88-bc0af81cd5a2",
        "status": "DOWN",
        "router_id": null,
        "tenant_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "project_id": "bbfe8c41dd034a07bebd592bf03b4b0c",
        "floating_network_id": "0a2228f2-7f8a-45f1-8e09-9039e1d09975",
        "fixed_ip_address": null,
        "floating_ip_address": "88.88.215.205",
        "port_id": null,
        "created_at": "2018-09-20T02:10:02",
        "updated_at": "2018-09-20T02:10:07"
    }
}

Status Codes

For details, see section Status Codes.