You need to enable JavaScript to run this app.
文档中心
私有网络

私有网络

复制全文
下载 pdf
前缀列表
ModifyPrefixList - 更新前缀列表实例
复制全文
下载 pdf
ModifyPrefixList - 更新前缀列表实例
调用 ModifyPrefixList 接口,修改前缀列表。​
使用说明​
ModifyPrefixList 为异步接口,即返回请求ID时,系统后台仍在配置。您可调用 DescribePrefixLists 查看网卡的状态,Pending表示配置中,Available 表示修改完成。​
调试​
API Explorer
您可以通过 API Explorer 在线发起调用,无需关注签名生成过程,快速获取调用结果。
​
请求参数​
下方仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。​
Action String 必选 示例值:ModifyPrefixList​
接口名称。当前 API 的名称为ModifyPrefixList。​
​
Version String 必选 示例值:2020-04-01​
接口版本。当前 API 的版本为 2020-04-01。​
​
PrefixListId String 必选 示例值:pl-bp1fg655nh68xyz9****​
要修改的前缀列表的ID。​
您可以调用 DescribePrefixLists 接口,查询前缀列表的ID。​
​
PrefixListName String 可选 示例值:PrefixList-1​
前缀列表的名称。​
  • 长度限制为1 ~ 128个字符。​
  • 需要以字母、中文或数字开头,可包含点号(.)、下划线(_)和短划线(-)。​
​
Description String 可选 示例值:PrefixList_Common​
前缀列表的描述。​
  • 长度限制为0~ 255个字符。​
  • 需要以字母、中文或数字开头。可包含英文逗号(,)、点号(.)、下划线(_)、空格( )、等号(=)、短横线(-)、中文逗号(,)、中文句号(。)。​
​
MaxEntries Integer 可选 示例值:100​
最大条目数,即前缀列表最多可添加条目的数量。​
  • 若前缀列表未关联资源,则最大条目数不大于200条。​
  • 若前缀列表已关联资源,则最大条目数除了不大于200条外,还受已关联资源的配额限制。​
说明​
前缀列表的最大条目数会占用其关联资源的配额。修改最大条目数,可能导致待关联前缀列表的资源无法关联,请充分评估业务后,谨慎操作。​
​
AddPrefixListEntries.N.Cidr String 可选 示例值:1.XX.XX.0/24​
要添加前缀列表条目的CIDR。​
  • 参数 - N:表示前缀列表条目的序号,取值范围:1~MaxEntries,且N应按照连续的从小到大的顺序。​
  • 多个CIDR之间用&分隔。​
说明​
若添加的CIDR已存在,则仅修改AddPrefixListEntries.N.Description的值,即只修改该CIDR地址块的描述信息。​
​
AddPrefixListEntries.N.Description String 可选 示例值:CIDR_A​
要添加前缀列表条目的描述。​
  • 参数 - N:表示前缀列表条目的序号,取值范围:1~MaxEntries,且N应按照连续的从小到大的顺序。​
  • 多个描述之间用&分隔。​
  • 长度限制为0~ 255个字符。​
  • 不填默认为空字符串。​
  • 需要以字母、中文或数字开头。可包含英文逗号(,)、点号(.)、下划线(_)、空格( )、等号(=)、短横线(-)、中文逗号(,)、中文句号(。)。​
​
RemovePrefixListEntries.N.Cidr String 可选 示例值:192.168.0.0/16​
要删除的前缀列表条目。​
  • 参数 - N:表示前缀列表条目的序号,取值范围:1~MaxEntries,且N应按照连续的从小到大的顺序。​
  • 多个描述之间用&分隔。​
​
ClientToken String 可选 示例值:123e4567-e89b-12d3-a456-42665544****​
客户端Token,用于保证请求幂等性。​
  • 由客户端自动生成一个参数值,确保不同请求间该参数值唯一,避免当调用API超时或服务器内部错误时,客户端多次重试导致重复性操作。​
  • 仅支持ASCII字符,且不能超过64个字符。​
  • 若不传入ClientToken,则此次API调用不进行幂等校验。​
​
DryRun Boolean 可选 示例值:false​
是否只预检此次请求。​
请严格按照以下枚举值的大小写输入,不要传入其他取值。​
  • true:发送检查请求,不会修改前缀列表。检查项包括是否填写了必需参数、请求格式、业务限制。如果检查不通过,则返回对应错误。如果检查通过,则返回错误码DryRunOperation。​
  • false(默认值):发送正常请求,通过检查后返回HTTP 2xx状态码并直接修改前缀列表。​
​
​
​
返回参数​
下方仅列出本接口特有的返回参数。更多信息请参见返回结构。​
RequestId String 示例值:2021062415303301022514515207C4****​
请求ID。​
​
​
​
请求示例​
​
GET /?Action=ModifyPrefixList&Version=2020-04-01&PrefixListId=pl-bp1fg655nh68xyz9****&AddPrefixListEntries.1.Cidr=1.XX.XX.0/24&AddPrefixListEntries.2.Cidr=2.XX.XX.0/24 HTTP/1.1​
Host: vpc.cn-beijing.volcengineapi.com​
X-Date: 20251121T094038Z​
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20251121/cn-beijing/vpc/request, SignedHeaders=host;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f​
​
返回示例​
​
{​
"ResponseMetadata": {​
"RequestId": "20230604110420****100232280022D31",​
"Action": "ModifyPrefixList",​
"Version": "2020-04-01",​
"Service": "vpc",​
"Region": "cn-beijing"​
},​
"Result": {​
"RequestId": "2021062415303301022514515207C4****"​
}​
}​
​
错误码​
​
状态码​
错误码​
错误信息​
说明​
400​
DryRunOperation​
Exception raised to indicate a successfully authorized action when the DryRun flag is set to true.​
该请求设置为DryRun操作,操作授权已获得许可,但未被实际执行。​
400​
IdempotentParameterMismatch​
Arguments on this idempotent request are inconsistent with arguments used in previous request(s).​
此幂等请求的参数与前一个请求中使用的参数不一致。​
400​
InvalidCidr.Malformed​
The specified cidr block is malformed.​
指定的网段格式不合法。​
400​
InvalidCidr.ProtocolMismatch​
The specified cidr block mismatch the protocol type.​
指定的网段格式和协议类型不匹配。​
400​
InvalidDescription.Malformed​
The specified description is malformed.​
指定的描述格式不合法。请修复描述格式后重试。​
400​
InvalidDescription.Malformed​
The specified description is malformed. Ensure the maximum length of description is 255.​
指定的描述格式不合法。描述长度不能超过255个字符。​
400​
InvalidMaxEntries.Malformed​
The maximum number of entries is malformed.​
最大条目数格式错误。​
400​
InvalidName.Malformed​
The specified name is malformed.​
指定的名称格式不合法。请修复名称格式后重试。​
400​
InvalidName.Malformed​
The specified name is malformed. Ensure the maximum length of name is 128.​
指定的名称格式不合法。名称长度不能超过128个字符。​
400​
InvalidParameter.CidrCountExceedMaxCount​
The number of CIDR blocks exceeded the maximum number of entries allowed.​
网段数量超过前缀列表的最大条目数。​
400​
InvalidParameter.ClientTokenMalformed​
The specified parameter ClientToken is malformed.​
指定的参数ClientToken格式不合法,长度不能超过64个ASCII字符。​
400​
InvalidPrefixList.InvalidStatus​
The specified prefix list is not in the correct status for the request.​
指定的前缀列表所处状态无法响应该请求。​
400​
InvalidPrefixListEntry.Conflict​
The specified CIDR block conflicts with another one in the specified prefix list.​
指定的前缀列表条目中存在重复的CIDR地址块。​
400​
InvalidSecurityGroup.InvalidStatus​
The specified security group is not in the correct status for the request.​
指定的安全组所处的状态无法响应该请求。​
400​
InvalidVpc.InvalidStatus​
The specified VPC is not in the correct status for the request.​
指定的VPC所处状态无法响应该请求。​
400​
LimitExceeded.MaxEntries​
You've reached the limit on the number of MaxEntries per prefix list that you can assign.​
已达到前缀列表支持配置的最大CIDR地址块条目数。​
400​
QuotaExceeded.RouteEntry​
Route entry of a route table number exceeded quota.​
已达到可创建路由条目的数量上限。​
400​
QuotaExceeded.SecurityGroupRule​
You've reached the limit on the number of egress security rules that you can create.​
已达到安全组可创建的出项规则的数量上限。​
400​
QuotaExceeded.SecurityGroupRule​
You've reached the limit on the number of ingress security rules that you can create.​
已达到安全组可创建的入项规则的数量上限。​
400​
QuotaExceeded.Vpc​
VPC number exceeded quota.​
已达到可创建私有网络的数量上限。​
404​
InvalidPrefixList.NotFound​
The specified prefix list does not exist.​
指定的前缀列表不存在。​
409​
InvalidPrefixList.Conflict​
The specified prefix list modification conflicts with the associated transit routers.​
指定的前缀列表变更与关联的中转路由器冲突。​
409​
InvalidRouteCidr.Conflict​
The specified CIDR block conflicts with that of another route in your route table.​
指定的CIDR地址块与所属路由表中另一个规则CIDR地址块冲突。​
412​
IdempotentProcessing​
The request uses the same client token as a previous one that is still in process.​
幂等请求处理中。​
​
​
最近更新时间:2026.02.09 16:06:06
这个页面对您有帮助吗?
有用
有用
无用
无用