Modifies the name, description, or entries of a specific prefix list.
Operation description
Description
-
The specified CIDR block must be valid. For example, 10.0.0.0/8 is a valid CIDR block while 10.0.0.1/8 is not. For more information, see the What is CIDR? section in Network FAQ.
-
When you add or delete an entry, you cannot specify duplicate CIDR blocks. Examples:
- For IPv4 CIDR blocks, you cannot specify the 10.0.0.0/8 CIDR block in two entries. You cannot specify the 10.0.0.1/32 CIDR block in one entry and the 10.0.0.1 CIDR block in another entry. These two CIDR blocks are the same.
- For IPv6 CIDR blocks, you cannot specify the 2001:fd01:0:0:0:0:0:0/32 CIDR block in one entry and the 2001:fd01::/32 CIDR block in another entry. These two CIDR blocks are the same.
-
The CIDR block in an entry to be added cannot the same as that in an entry to be deleted. For example, when you add an entry in which the 10.0.0.0/8 CIDR block is specified, the entry to be deleted cannot have the 10.0.0.0/8 CIDR block specified.
-
If you want to modify the description of an entry, you must specify the CIDR block (
AddEntry.N.Cidr
) and new description (AddEntry.N.Description
) in the entry.
Debugging
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID of the prefix list. You can call the DescribeRegions operation to query the most recent region list. | cn-chengdu |
PrefixListId | string | Yes | The ID of the prefix list. | pl-x1j1k5ykzqlixdcy**** |
PrefixListName | string | No | The name of the prefix list. The name must be 2 to 128 characters in length. It must start with a letter and cannot start with | PrefixListNameSample |
Description | string | No | The description of the prefix list. The description must be 2 to 256 characters in length and cannot start with | This is description. |
AddEntry | object [] | No | The entries that to be added to the prefix list. | |
Description | string | No | The description in entry N. The description must be 2 to 32 characters in length and cannot start with | Description Sample 01 |
Cidr | string | Yes | The CIDR block of entry N to be added to the prefix list. Valid values of N: 0 to 200. Take note of the following items when you add the entries:
| 192.168.2.0/24 |
RemoveEntry | object [] | No | The entries that to be deleted from the prefix list. | |
Cidr | string | Yes | The CIDR block of entry N to be deleted from the prefix list. Valid values of N: 0 to 200. Take note of the following items when you delete the entries:
| 192.168.1.0/24 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "38793DB8-A4B2-4AEC-BFD3-111234E9188D"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | MissingParameter | %s | A parameter is not specified. |
400 | InvalidParameter.PrefixListName | The parameter PrefixListName is not valid. | The prefix list name is invalid. |
400 | InvalidDescription.Malformed | The specified Description is wrongly formed. | The resource description is invalid. The description must be 2 to 256 characters in length and cannot start with http:// or https://. |
400 | InvalidParameter.CidrDuplicated | %s | Duplicate CIDR blocks are specified. |
400 | InvalidParameter.CidrMalformed | %s | The specified CIDR block is invalid. |
400 | LimitExceed.MaxEntries | The number of entries exceeds the MaxEntries of the specified prefix list. | The number of specified entries exceeds the MaxEntries value. |
400 | LimitExceed.Entry | The number of entries added or removed exceeds the limit. | The number of entries to add or remove at a time exceeds the upper limit. |
404 | InvalidPrefixListId.NotFound | The specified prefix list was not found. | The prefix list does not exist. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||
---|---|---|---|---|---|---|---|---|
2023-11-13 | The Error code has changed | see changesets | ||||||
|