You can call this operation to create an access control address book. Supported address book types are IP address books, Elastic Compute Service (ECS) tag address books, port address books, and domain address books.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | AddAddressBook |
The operation that you want to perform. Set the value to AddAddressBook. |
Description | String | Yes | DEMO address book |
The description of the address book. |
GroupName | String | Yes | demo_address_book |
The name of the address book. |
GroupType | String | Yes | ip |
The type of the address book. Valid values:
|
AddressList | String | No | 1.2.3.4/32, 1.2.3.0/24 |
The addresses to specify in the address book. Separate multiple addresses with commas (,). Note If the GroupType parameter is set to ip, port or domain, this parameter is required.
|
AutoAddTagEcs | String | No | 1 |
Specifies whether to automatically add ECS public IP addresses to the address book if they match the specified tags. Valid values:
|
Lang | String | No | zh |
The language of the request and response. Valid values:
|
SourceIp | String | No | 1.2.3.4 |
The source IP address of the request. |
TagList.N.TagKey | String | No | key1 |
The key of the ECS tag. |
TagList.N.TagValue | String | No | value1 |
The value of the ECS tag. |
TagRelation | String | No | and |
The logical relation among ECS tags. Valid values:
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
GroupUuid | String | f04ac7ce-628b-4cb7-be61-310222b718e8 |
The unique ID of the address book returned. |
RequestId | String | CBF1E9B7-D6A0-4E9E-AD3E-2B47E6C2837D |
The ID of the request. |
Examples
Sample requests
http(s)://[Endpoint]/? Action=AddAddressBook
&Description=DEMO address book
&GroupName=demo_address_book
&GroupType=ip
&AddressList=1.2.3.4/32,1.2.3.0/24
&<Common request parameters>
Sample success responses
XML
format
<AddAddressBook>
<RequestId>B2841452-CB8D-4F7D-B247-38E1CF7334F8</RequestId>
<GroupUuid>0580bbd0-24cd-47ae-9e5a-f5a099251e32</GroupUuid>
</AddAddressBook>
JSON
format
{
"RequestId":"B2841452-CB8D-4F7D-B247-38E1CF7334F8",
"GroupUuid":"0580bbd0-24cd-47ae-9e5a-f5a099251e32"
}
Error codes
For a list of error codes, visit the API Error Center.