Queries the information of resources that are associated with a specific prefix list.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribePrefixListAssociations

The operation that you want to perform. Set the value to DescribePrefixListAssociations.

RegionId String Yes cn-chengdu

The region ID.

PrefixListId String Yes pl-x1j1k5ykzqlixdcy****

The ID of the prefix list.

MaxResults Integer No 10

The maximum number of entries to return on each page.

Maximum value: 100.

Default value: 10.

NextToken String No AAAAAdDWBF2****

The query token. Set the value to the NextToken value returned from a previous call of the DescribePrefixLists operation. Leave this parameter empty when you call this operation for the first time.

Response parameters

Parameter Type Example Description
RequestId String 38793DB8-A4B2-4AEC-BFD3-111234E9188D

The ID of the request.

NextToken String AAAAAdDWBF2****

The query token returned in this call. If the return value is empty, no more data is returned.

PrefixListAssociations Array of PrefixListAssociation

Details about the resources that are associated with the prefix list.

PrefixListAssociation
ResourceId String sg-bp11ujym6xsff6l0****

The ID of the resource.

ResourceType String securitygroup

The type of the resource.

Examples

Sample requests

https://ecs.aliyuncs.com/?Action=DescribePrefixListAssociations
&RegionId=cn-chengdu
&PrefixListId=pl-x1j1k5ykzqlixdcy****
&<Common request parameters>

Sample success responses

XML format

<DescribePrefixListAssociationsResponse>
      <NextToken>AAAAAdDWBF2****</NextToken>
      <RequestId>38793DB8-A4B2-4AEC-BFD3-111234E9188D</RequestId>
      <PrefixListAssociations>
            <PrefixListAssociation>
                  <ResourceId>sg-bp11ujym6xsff6l0****</ResourceId>
                  <ResourceType>securitygroup</ResourceType>
            </PrefixListAssociation>
      </PrefixListAssociations>
</DescribePrefixListAssociationsResponse>

JSON format

{
    "NextToken": "AAAAAdDWBF2****", 
    "RequestId": "38793DB8-A4B2-4AEC-BFD3-111234E9188D", 
    "PrefixListAssociations": {
        "PrefixListAssociation": [
            {
                "ResourceId": "sg-bp11ujym6xsff6l0****", 
                "ResourceType": "securitygroup"
            }
        ]
    }
}

Error codes

HTTP sta Error code Error message Description
400 InvalidParameter %s The error message returned because a specified parameter is invalid.
404 InvalidPrefixListId.NotFound The specified prefix list was not found. The error message returned because the prefix list does not exist.
400 NotSupported.ResourceType The specified resource type is not supported. The error message returned because the resource type is not supported.
404 NotSupported.GrayFunction The prefix list is a gray-scale function, not currently supported. The error message returned because this operation is not supported. The prefix list feature is in invitational preview.

For a list of error codes, visit the API Error Center.