DescribeEipAddresses

1. API Description

This API is used to query the list of elastic IPs. You can query information on elastic IPs according to ID or IP of the elastic IP, and the pricing model.

2. Input Parameters

The following request parameter list only provides API request parameters.

Parameter NameRequiredTypeDescription

eipChargeType

No

String

Elastic IP pricing model.

PREPAID: subscription

POSTPAID: pay-as-you-go

eipIds

No

Array of String

ID list of elastic IPs.

The maximum number of elastic IPs in each request is 100.

eipStatus

No

String

instanceId

No

String

Instance ID.

instanceName

No

String

Instance name.

ipAddress

No

String

IP address.

zoneId

No

String

Zone ID to which the elastic IPs belong.

resourceGroupId

No

String

Resource group ID.

If this parameter is not passed in, all the elastic IPs in authorized resource group return.

pageNum

No

Integer

Number of pages returned.

Default value: 1

pageSize

No

Integer

Number of items in the current page result.

Default value: 20

Maximum value: 1000

3. Output Parameters

Parameter NameTypeDescription

requestId

String

The unique request ID, which is returned for each request. RequestId is required for locating a problem.

dataSet

Array of EipAddress

List of elastic IPs.

totalCount

Integer

The total number of elastic IPs.

4. Code Example

Query the list of elastic IPs according to eipChargeType

POST /api/v2/bmc HTTP/1.1
Host: console.zenlayer.com
Content-Type: application/json
X-ZC-Action: DescribeEipAddresses
<Common Request Params>

Request:
{
    "eipChargeType": "PREPAID"
}

Response:
{   
  "requestId": "T05992D0C-7E8B-4047-B0C0-780F2CD549D3",
  "response": {
     "requestId": "T98044459-95B2-477E-9A2F-00253A70CC6E"
     "dataSet": [
         {
            "eipId": "eipId1",
            "zoneId": "SEL-A",
            "ipAddress": "x.x.x.x",
            "instanceId": "instanceId1",
            "instanceName": "instanceName",
            "eipChargeType": "PREPAID",
            "period": 1,
            "createTime": "2022-09-25T16:53:38Z",
            "expiredTime": "2022-10-25T16:53:38Z",
            "eipStatus": "AVAILABLE",
            "resourceGroupId": "xx",
            "resourceGroupName": "xx"
         }
     ],
     totalCount: 1
  }
}

5. Developer Resources

Zenlayer Cloud API 2.0 integrates SDKs to make it easier for you to call APIs. More programming languages will be supported.

6. Error Codes

No error codes related to the API business logic. For other error codes, see Common Error Codes.​

Last updated