Queries address books in a batch.
Operation description
Use this API to query the details of an access control policy address book.
QPS limit
The per-user QPS limit for this API is 10. Exceeding this limit throttles your API calls and may impact your business. Plan your calls accordingly.
Try it now
Test
RAM authorization
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| Lang |
string |
No |
The language of the content in the response. Valid values:
|
zh |
| CurrentPage |
string |
No |
The page number for a paginated query. Default value: 1. |
1 |
| PageSize |
string |
No |
The number of address books per page. Default value: 10. Maximum value: 50. |
10 |
| Query |
string |
No |
The search keyword for address books. |
192.0.XX.XX |
| GroupType |
string |
No |
The type of the address book. Note
If this parameter is not specified, the query returns both IPv4 and ECS tag address books. Valid values:
|
ip |
| ContainPort |
string |
No |
Filters the query to return only address books that contain the specified port. This parameter is valid only when GroupType is set to port. |
80 |
| GroupUuid |
string |
No |
The unique identifier of the address book. |
f04ac7ce-628b-4cb7-be61-310222b7**** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| PageNo |
string |
The current page number. |
1 |
| PageSize |
string |
The number of address books returned per page. |
10 |
| RequestId |
string |
The request ID. |
B36F150A-1E27-43AA-B72C-D2AC712F09DA |
| TotalCount |
string |
The total number of address books. |
100 |
| Acls |
array<object> |
A list of address books. |
|
|
array<object> |
The details of an address book. |
||
| AddressListCount |
integer |
The number of addresses in the address book. |
2 |
| GroupUuid |
string |
The UUID of the address book. |
f04ac7ce-628b-4cb7-be61-310222b7**** |
| AutoAddTagEcs |
integer |
Indicates whether to automatically add the public IPs of tagged ECS instances to the address book. This applies to newly purchased instances and existing instances whose tags are modified to match. Valid values:
|
1 |
| Description |
string |
The description of the address book. |
DEMO |
| GroupName |
string |
The name of the address book. |
demo_address_book |
| ReferenceCount |
integer |
The number of times the address book is referenced. |
3 |
| GroupType |
string |
The type of the address book. Valid values: Valid values:
|
ip |
| TagRelation |
string |
The logical relationship among multiple ECS tags. Valid values: Valid values:
|
and |
| TagList |
array<object> |
A list of ECS tags. |
|
|
object |
An ECS tag. |
||
| TagValue |
string |
The value of the tag. |
ALL VALUE |
| TagKey |
string |
The key of the tag. |
company |
| AddressList |
array |
A list of CIDR blocks in the address book. |
|
|
string |
A CIDR block in the address book. |
[ "192.168.XX.XX/32", "192.168.XX.XX/32" ] |
|
| Addresses |
array<object> |
A list of addresses, each with a description. |
|
|
object |
An address and its description. |
||
| Address |
string |
The IP address or CIDR block. |
192.168.0.1/32 |
| Note |
string |
The note for the address. |
Single Address Description |
| AckClusterConnectorId |
string |
The ID of the ACK cluster connector. |
ac-7c1bad6c3cc84c33baab |
| AckClusterConnectorName |
string |
The name of the ACK cluster connector. |
ack-cluster-connector-name |
| AckLabels |
array<object> |
A list of ACK pod labels. |
|
|
object |
An ACK pod label. |
||
| Key |
string |
The key of the ACK pod label. |
app |
| Value |
string |
The value of the ACK pod label. |
storage-operator |
| AckNamespaces |
array |
A list of ACK namespaces. |
|
|
string |
An ACK namespace. |
default |
|
| RegionNo |
string |
The region where the ACK cluster connector is deployed. This parameter is returned only when the GroupType parameter is "ack". |
cn-beijing |
Examples
Success response
JSON format
{
"PageNo": "1",
"PageSize": "10",
"RequestId": "B36F150A-1E27-43AA-B72C-D2AC712F09DA",
"TotalCount": "100",
"Acls": [
{
"AddressListCount": 2,
"GroupUuid": "f04ac7ce-628b-4cb7-be61-310222b7****",
"AutoAddTagEcs": 1,
"Description": "DEMO",
"GroupName": "demo_address_book",
"ReferenceCount": 3,
"GroupType": "ip",
"TagRelation": "and",
"TagList": [
{
"TagValue": "ALL VALUE",
"TagKey": "company"
}
],
"AddressList": [
"[ \"192.168.XX.XX/32\", \"192.168.XX.XX/32\" ]"
],
"Addresses": [
{
"Address": "192.168.0.1/32",
"Note": "Single Address Description"
}
],
"AckClusterConnectorId": "ac-7c1bad6c3cc84c33baab",
"AckClusterConnectorName": "ack-cluster-connector-name",
"AckLabels": [
{
"Key": "app",
"Value": "storage-operator"
}
],
"AckNamespaces": [
"default"
],
"RegionNo": "cn-beijing"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | ErrorParametersGroupType | The group type is invalid. | The group type is invalid. |
| 400 | ErrorParametersUid | The aliUid parameter is invalid. | The aliUid parameter is invalid. |
| 400 | ErrorParametersPageSizeOrNo | Either pageSize or pageNo is invalid. | Either pageSize or pageNo is invalid. |
| 400 | ErrorDBSelect | An error occurred while querying database. | An error occurred while querying database. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.