All Products
Search
Document Center

Virtual Private Cloud:ListIpamResourceCidrs

Last Updated:Jan 23, 2026

Lists the CIDR blocks of resources in an IPAM scope.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

vpc:ListIpamResourceCidrs

list

*IpamScope

acs:vpc:{#regionId}:{#accountId}:ipamscope/{#IpamScopeId}

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The ID of the region where the IPAM is deployed.

Call the DescribeRegions operation to get the region ID.

cn-hangzhou

IpamScopeId

string

No

The instance ID of the IPAM scope.

ipam-scope-glfmcyldpm8lsy****

IpamPoolId

string

No

The instance ID of the IPAM pool.

Note

IpamPoolId cannot be the ID of a shared IPAM pool.

ipam-pool-6rcq3tobayc20t****

ResourceId

string

No

The resource ID.

vpc-bp16qjewdsunr41m1****

ResourceType

string

No

The resource type. Valid values:

  • VPC

  • VSwitch

VPC

NextToken

string

No

The token that is used for the next query. Valid values:

  • Do not specify this parameter for the first request.

  • For subsequent queries, set this parameter to the NextToken value returned from the previous query.

FFmyTO70tTpLG6I3FmYAXGKPd****

MaxResults

integer

No

The maximum number of entries to return on each page. Valid values: 1 to 100. Default value: 10.

10

VpcId

string

No

The ID of the VPC to which the resource belongs.

vpc-bp1fjfnrg3av6zb9e****

Response elements

Element

Type

Description

Example

object

The list of returned information.

IpamResourceCidrs

array<object>

The list of resource information.

array<object>

The list of resource information.

AliUid

integer

The ID of the Alibaba Cloud account.

132193271328****

ResourceType

string

The resource type. Valid values:

  • VPC

  • VSwitch

VPC

ResourceId

string

The resource ID.

vpc-bp16qjewdsunr41m1****

ResourceOwnerId

integer

The ID of the Alibaba Cloud account to which the resource belongs.

132193271328****

ResourceRegionId

string

The ID of the region where the resource is deployed.

cn-hangzhou

Cidr

string

The CIDR block of the resource.

192.168.1.0/24

SourceCidr

string

The source CIDR block.

192.168.1.0/24

Status

string

The status of the resource in the IPAM pool. Valid values:

  • Created

  • Deleted

Created

ManagementStatus

string

The management status of the resource.

  • Managed: The resource has a CIDR block allocated from an IPAM pool. IPAM is monitoring the CIDR block for overlaps and compliance with the allocation rules of the pool.

  • Unmanaged: The resource does not have a CIDR block allocated from an IPAM pool. IPAM is monitoring the resource for CIDR blocks that meet the allocation rules of the pool and for CIDR block overlaps.

  • Ignored: The resource is ignored. IPAM does not evaluate the resource for overlaps or compliance with allocation rules. When you ignore a resource, any space allocated to it from an IPAM pool is returned to the pool. The resource is not automatically imported into the pool again if an auto-import allocation rule is configured for the pool.

Managed

ComplianceStatus

string

The compliance status of the resource.

  • Compliant: The CIDR block of the managed resource complies with the allocation rules of the IPAM pool.

  • Noncompliant: The CIDR block of the managed resource does not comply with one or more allocation rules of the IPAM pool.

  • Ignored: The resource is ignored. IPAM does not evaluate the resource for overlaps or compliance with allocation rules.

  • Unmanaged: The resource does not have a CIDR block allocated from an IPAM pool. IPAM does not monitor the compliance status of the resource's CIDR block, but monitors the CIDR block for overlaps.

Compliant

OverlapStatus

string

The overlap status of the resource.

  • Nonoverlapping: The CIDR block of the resource does not overlap with other CIDR blocks in the same scope.

  • Overlapping: The CIDR block of the resource overlaps with another CIDR block in the same scope.

  • Ignored: The resource is ignored. IPAM does not evaluate the resource for overlaps or compliance with allocation rules.

Nonoverlapping

IpUsage

string

The IP address usage. The value is a decimal.

0

IpCountDetail

object

The details about the number of IP addresses in the resource.

FreeIpCount

string

The number of available IP addresses.

252

TotalIpCount

string

The total number of IP addresses.

256

UsedIpCount

string

The number of used IP addresses.

4

IpamId

string

The instance ID of the IPAM.

ipam-uq5dcfc2eqhpf4****

IpamScopeId

string

The instance ID of the IPAM scope.

ipam-scope-glfmcyldpm8lsy****

IpamPoolId

string

The instance ID of the IPAM pool.

ipam-pool-6rcq3tobayc20t***

IpamAllocationId

string

The ID of the IPAM pool CIDR block allocation.

ipam-pool-alloc-112za33e4****

VpcId

string

The ID of the VPC to which the resource belongs.

vpc-bp1fjfnrg3av6zb9e****

OverlapDetail

array<object>

A list of resources that overlap with the current resource.

object

OverlapResourceId

string

The ID of the overlapping resource.

vpc-aq3fjgnig5av6jb8d****

OverlapResourceRegion

string

The region of the overlapping resource.

cn-hangzhou

OverlapResourceCidr

string

The CIDR block of the overlapping resource.

192.168.1.0/24

NextToken

string

A pagination token. It is used to retrieve the next page of results. Valid values:

  • If NextToken is empty, no more results are returned.

  • If a value is returned for NextToken, it is the token that you can use in the next request to retrieve the next page of results.

FFmyTO70tTpLG6I3FmYAXGKPd****

TotalCount

integer

The total number of entries that meet the query conditions.

1000

MaxResults

integer

The maximum number of entries returned on each page. Valid values: 1 to 100. Default value: 10.

10

Count

integer

The number of entries returned on the current page.

10

RequestId

string

The request ID.

49A9DE56-B68C-5FFC-BC06-509D086F287C

Examples

Success response

JSON format

{
  "IpamResourceCidrs": [
    {
      "AliUid": 0,
      "ResourceType": "VPC",
      "ResourceId": "vpc-bp16qjewdsunr41m1****",
      "ResourceOwnerId": 0,
      "ResourceRegionId": "cn-hangzhou",
      "Cidr": "192.168.1.0/24",
      "SourceCidr": "192.168.1.0/24",
      "Status": "Created",
      "ManagementStatus": "Managed",
      "ComplianceStatus": "Compliant",
      "OverlapStatus": "Nonoverlapping",
      "IpUsage": "0",
      "IpCountDetail": {
        "FreeIpCount": "252",
        "TotalIpCount": "256",
        "UsedIpCount": "4"
      },
      "IpamId": "ipam-uq5dcfc2eqhpf4****",
      "IpamScopeId": "ipam-scope-glfmcyldpm8lsy****",
      "IpamPoolId": "ipam-pool-6rcq3tobayc20t***",
      "IpamAllocationId": "ipam-pool-alloc-112za33e4****",
      "VpcId": "vpc-bp1fjfnrg3av6zb9e****",
      "OverlapDetail": [
        {
          "OverlapResourceId": "vpc-aq3fjgnig5av6jb8d****",
          "OverlapResourceRegion": "cn-hangzhou",
          "OverlapResourceCidr": "192.168.1.0/24"
        }
      ]
    }
  ],
  "NextToken": "FFmyTO70tTpLG6I3FmYAXGKPd****",
  "TotalCount": 1000,
  "MaxResults": 10,
  "Count": 10,
  "RequestId": "49A9DE56-B68C-5FFC-BC06-509D086F287C"
}

Error codes

HTTP status code

Error code

Error message

Description

400 Forbidden.QueryShareResource Authentication is failed for querying a shared IPAM pool. Authentication is failed for querying a shared IPAM pool.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.