Server Actions

Change alias IPs of a Network

Changes the alias IPs of an already attached Network. Note that the existing aliases for the specified Network will be replaced with these provided in the request body. So if you want to add an alias IP, you have to provide the existing ones from the Network plus the new alias IP in the request body.

post/servers/{id}/actions/change_alias_ips

Request

  • Base URL: https://api.hetzner.cloud/v1
  • URL: https://api.hetzner.cloud/v1/servers/{id}/actions/change_alias_ips
  • Auth: HTTP bearer

Path parameters

idinteger required

ID of the Server.

Example:42

ID of the Server.

Request body

networkinteger required

ID of an existing Network already attached to the Server.

alias_ipsstring[] required

New alias IPs to set for this Server.

Example request

{
  "network": 4711,
  "alias_ips": [
    "10.0.1.2"
  ]
}

Response

Request succeeded.

Example response

{
  "action": {
    "id": 42,
    "command": "start_resource",
    "started": "2016-01-30T23:55:00Z",
    "finished": "2016-01-30T23:55:00Z",
    "progress": 100,
    "resources": [
      {
        "id": 42,
        "type": "server"
      }
    ],
    "error": {
      "code": "action_failed",
      "message": "Action failed"
    }
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.