Cloud Management API 1.5

IpAddressBindings

An IpAddressBinding represents an abstraction for binding an IpAddress to an instance. The IpAddress is bound immediately for a current instance, or on launch for a next instance. It also allows specifying port forwarding rules for that particular IpAddress and Instance pair.

Actions

index

Lists the ip address bindings available to this account.

URLs
GET /api/clouds/:cloud_id/ip_address_bindings
GET /api/clouds/:cloud_id/ip_addresses/:ip_address_id/ip_address_bindings
HTTP response code
200 OK
Content-type
application/vnd.rightscale.ip_address_binding;type=collection

Required roles

Parameters

name required type values regexp blank? description
filter no Array * * no See below for valid filter parameters.

Filters

name partial_match? description
instance_href no The href of the Instance to filter on.
ip_address_href no The href of the IpAddress to filter on.

Example Responses

Click on a format below to see an example response:

JSON XML
[{
  "created_at": "2023/10/09 11:06:02 +0000",
  "links": [
    {"rel":"self","href":"/api/clouds/561741340/ip_address_bindings/RESOURCE_3757541503;RAND"},
    {"rel":"instance","href":"/api/clouds/561741340/instances/RESOURCE_2891149175;RAND"},
    {"rel":"ip_address","href":"/api/clouds/888/ip_addresses/RESOURCE_881330044;RAND"}
  ],
  "recurring": false
},{
  "created_at": "2023/10/09 11:06:03 +0000",
  "links": [
    {"rel":"self","href":"/api/clouds/563222850/ip_address_bindings/RESOURCE_152771614;RAND"},
    {"rel":"instance","href":"/api/clouds/563222850/instances/RESOURCE_1819075703;RAND"},
    {"rel":"ip_address","href":"/api/clouds/888/ip_addresses/RESOURCE_3438004964;RAND"}
  ],
  "recurring": false
}]
<?xml version="1.0" encoding="UTF-8"?>
<ip_address_bindings>
  <ip_address_binding>
    <created_at>2023/10/09 11:06:02 +0000</created_at>
    <links>
      <link rel="self" href="/api/clouds/561741340/ip_address_bindings/RESOURCE_3757541503;RAND"/>
      <link rel="instance" href="/api/clouds/561741340/instances/RESOURCE_2891149175;RAND"/>
      <link rel="ip_address" href="/api/clouds/888/ip_addresses/RESOURCE_881330044;RAND"/>
    </links>
    <recurring>false</recurring>
  </ip_address_binding>
  <ip_address_binding>
    <created_at>2023/10/09 11:06:03 +0000</created_at>
    <links>
      <link rel="self" href="/api/clouds/563222850/ip_address_bindings/RESOURCE_152771614;RAND"/>
      <link rel="instance" href="/api/clouds/563222850/instances/RESOURCE_1819075703;RAND"/>
      <link rel="ip_address" href="/api/clouds/888/ip_addresses/RESOURCE_3438004964;RAND"/>
    </links>
    <recurring>false</recurring>
  </ip_address_binding>
</ip_address_bindings>

show

Show information about a single ip address binding.

URLs
GET /api/clouds/:cloud_id/ip_address_bindings/:id
GET /api/clouds/:cloud_id/ip_addresses/:ip_address_id/ip_address_bindings/:id
HTTP response code
200 OK
Content-type
application/vnd.rightscale.ip_address_binding

Required roles

Example Responses

Click on a format below to see an example response:

JSON XML
{
  "created_at": "2023/10/09 11:06:02 +0000",
  "links": [
    {"rel":"self","href":"/api/clouds/561741340/ip_address_bindings/RESOURCE_3757541503;RAND"},
    {"rel":"instance","href":"/api/clouds/561741340/instances/RESOURCE_2891149175;RAND"},
    {"rel":"ip_address","href":"/api/clouds/888/ip_addresses/RESOURCE_881330044;RAND"}
  ],
  "recurring": false
}
<?xml version="1.0" encoding="UTF-8"?>
<ip_address_binding>
  <created_at>2023/10/09 11:06:02 +0000</created_at>
  <links>
    <link rel="self" href="/api/clouds/561741340/ip_address_bindings/RESOURCE_3757541503;RAND"/>
    <link rel="instance" href="/api/clouds/561741340/instances/RESOURCE_2891149175;RAND"/>
    <link rel="ip_address" href="/api/clouds/888/ip_addresses/RESOURCE_881330044;RAND"/>
  </links>
  <recurring>false</recurring>
</ip_address_binding>

create

Creates an ip address binding which attaches a specified IpAddress resource to a specified instance, and also allows for configuration of port forwarding rules. If the instance specified is a current (running) instance, a one-time IpAddressBinding will be created. If the instance is a next instance, then a recurring IpAddressBinding is created, which will cause the IpAddress to be bound each time the incarnator boots.

URLs
POST /api/clouds/:cloud_id/ip_address_bindings
POST /api/clouds/:cloud_id/ip_addresses/:ip_address_id/ip_address_bindings
HTTP response code
201 Created

Required roles

Parameters

name required type values regexp blank? description
ip_address_binding yes Hash * * no
ip_address_binding[instance_href] no String * * no The Instance to which this IpAddress should be bound. Mutually exclusive with server_href.
ip_address_binding[private_port] no String * * no Incoming network traffic will get forwarded to this port number on the specified Instance. If not specified, will use public port. Required unless public_ip_address_href is passed.
ip_address_binding[protocol] no String UDP, TCP * no Transport layer protocol of traffic that may be forwarded from public port to private port on the Instance. Required unless public_ip_address_href is passed.
ip_address_binding[public_ip_address_href] no String * * no The IpAddress to bind to the specified instance. Required unless port forwarding rule params are passed.
ip_address_binding[public_port] no String * * no The incoming port for port forwarding. Incoming network traffic on this port will get forwarded (to the IP:Private Port of the specified Instance). Required unless public_ip_address_href is passed.
ip_address_binding[server_href] no String * * no The Server to which this IpAddress should be bound. Mutually exclusive with instance_href.Note: the Server must have a current_instance.

destroy

URLs
DELETE /api/clouds/:cloud_id/ip_address_bindings/:id
DELETE /api/clouds/:cloud_id/ip_addresses/:ip_address_id/ip_address_bindings/:id
HTTP response code
204 No Content

Required roles