DescribeNatGateways

1. API Description

This API is used to query the NAT gateway list.

2. Input Parameters

The following request parameter list only provides API request parameters.

Parameter Name
Required
Type
Description

regionId

No

String

Region ID.

vpcId

No

String

Filter by VPC network ID to which the NAT gateway belongs.

natGatewayIds

No

Array of String

NAT gateway ID list.

The maximum number of instance IDs is 100.

name

No

String

NAT gateway name.

Add * at the end to support fuzzy matching.

status

No

NAT gateway state.

pageSize

No

Integer

Number of items in the current page result.

Default value: 20; Maximum value: 1000.

pageNum

No

Integer

Page number of the current page result.

Default value: 1.

3. Output Parameters

Parameter Name
Type
Description

requestId

String

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

totalCount

Integer

The total number of NAT gateways that meet the filtering conditions.

dataSet

Array of NatGateway

The returned NAT gateway list.

4. Code Example

Query the NAT gateway list.

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

Request:
{
  "regionId" : "sample",
  "vpcId" : "sample",
  "natGatewayIds" : null,
  "name" : "sample",
  "status" : "CREATING",
  "pageSize" : null,
  "pageNum" : null
}

Response:
{
  "requestId": "TC1748D3E-452D-4F74-8485-7AA73718E453",
  "response": {
    "requestId": "TC1748D3E-452D-4F74-8485-7AA73718E453"
  }
}

5. Developer Resources

Zenlayer Cloud API 2.0 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