CreateIpamPool - 创建IPAM地址池

创建IPAM地址池。

接口说明

  • 每个地域每种 ISP 类型的公网 IPv6 顶级池的数量默认最多为 1 个。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。

  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。

  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:

    • 对于必选的资源类型,用前面加 * 表示。

    • 对于不支持资源级授权的操作,用全部资源表示。

  • 条件关键字:是指云产品自身定义的条件关键字。

  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。

操作

访问级别

资源类型

条件关键字

关联操作

vpc:CreateIpamPool

create

*IpamPool

acs:vpc:{#regionId}:{#accountId}:ipamscope/*

请求参数

名称

类型

必填

描述

示例值

RegionId

string

IPAM 托管地域 ID。您可以通过调用 DescribeRegions 接口获取地域 ID。

cn-hangzhou

IpamScopeId

string

IPAM 作用范围的实例 ID。

ipam-scope-glfmcyldpm8lsy****

IpamPoolName

string

IPAM 地址池的名称。

长度为 1~128 个字符,不能以http://https://开头。

abc

IpamPoolDescription

string

IPAM 地址池的描述。

长度为 1~256 个字符,必须以大小写英文字母或者中文字符开头,但不能以http://https://开头。不填则为空,默认值为空。

test description

ResourceGroupId

string

IPAM 地址池的资源组 ID。

rg-acfmxazb4ph6aiy****

PoolRegionId

string

IPAM 地址池生效地域。

cn-hangzhou

SourceIpamPoolId

string

源 IPAM 地址池的实例 ID。

说明

不输入此参数时,表示创建的地址池为父地址池。

ipam-pool-6rcq3tobayc20t****

AllocationDefaultCidrMask

integer

IPAM 地址池分配的默认网络掩码。

说明

IPv4 网络掩码取值范围为0~32位,IPv6 网络掩码取值范围为0~128位。

28

AllocationMaxCidrMask

integer

IPAM 地址池分配的最大网络掩码。

说明

IPv4 网络掩码取值范围为0~32位,IPv6 网络掩码取值范围为0~128位。

32

AllocationMinCidrMask

integer

IPAM 地址池分配的最小网络掩码。

说明

IPv4 网络掩码取值范围为0~32位,IPv6 网络掩码取值范围为0~128位。

8

DryRun

boolean

是否只预检此次请求。取值:

  • true:发送检查请求,不会创建 IPAM 地址池。检查项包括是否填写了必需参数、请求格式、实例状态。如果检查不通过,则返回对应错误。如果检查通过,则返回 DryRunOperation。

  • false(默认值):发送正常请求,通过检查后返回 HTTP 2xx 状态码并直接进行操作。

false

ClientToken

string

客户端 Token,用于保证请求的幂等性。从您的客户端生成一个参数值,确保不同请求间该参数值唯一。ClientToken 只支持 ASCII 字符。

说明

若您未指定,则系统自动使用 API 请求的 RequestId 作为 ClientToken 标识。每次 API 请求的 RequestId 不一样。

123e4567-e89b-12d3-a456-426655440000

IpVersion

string

IP 地址协议版本。取值:

  • IPv4:IPv4 协议。

  • IPv6:IPv6 协议。

IPv4

Ipv6Isp

string

IPv6 地址段类型,仅对公网 IPv6 地址池生效。取值:

  • BGP(默认值):阿里云 BGP IPv6。

  • ChinaMobile:中国移动(单线)。

  • ChinaUnicom:中国联通(单线)。

  • ChinaTelecom:中国电信(单线)。

说明

如果是开通了单线带宽白名单的用户,该字段可以设置为 ChinaTelecom(中国电信)、ChinaUnicom(中国联通)或 ChinaMobile(中国移动)。

BGP

AutoImport

boolean

地址池是否开启自动导入功能。

true

Tag

array<object>

标签列表信息。

object

标签列表信息。

Key

string

资源的标签键。最多支持 20 个标签键。一旦传入该值,则不允许为空字符串。

最多支持 64 个字符,必须以字母或中文开头,可包含数字、半角句号(.)、下划线(_)和短划线(-),不能以aliyunacs:开头,不能包含http://或者https://

说明

参数ResourceId.NTag.NTag.N.KeyTag.N.Value)至少输入一个。

FinanceDept

Value

string

资源的标签值。最多支持 20 个标签值。一旦传入该值,可以为空字符串。

最多支持 128 个字符,不能包含http://或者https://

说明

参数ResourceId.NTag.NTag.N.KeyTag.N.Value)至少输入一个。

FinanceJoshua

返回参数

名称

类型

描述

示例值

object

返回的信息列表。

RequestId

string

请求 ID。

BB2C39DE-CEB8-595A-981A-F2EFCBE7324E

IpamPoolId

string

IPAM 地址池的实例 ID。

ipam-pool-6rcq3tobayc20t****

示例

正常返回示例

JSON格式

{
  "RequestId": "BB2C39DE-CEB8-595A-981A-F2EFCBE7324E",
  "IpamPoolId": "ipam-pool-6rcq3tobayc20t****"
}

错误码

HTTP status code

错误码

错误信息

描述

400 ResourceNotFound.IpamScope The specified resource of IPAM scope is not found. 输入的IPAM作用范围不存在。
400 ResourceNotFound.SourceIpamPool The dependent source IPAM pool is not found. 依赖资源源IPAM Pool不存在。
400 UnsupportedFeature.PublicIpamScopeType The feature of PublicIpamScopeType is not supported. 您指定的IPAM暂不支持创建Public类型的作用范围。
400 IllegalParam.AllocationDefaultNetmask The specified AllocationDefaultNetmask is illegal. AllocationDefaultNetmask参数不合法。
400 IllegalParam.AllocationMaxNetmask The specified AllocationMaxNetmask is illegal. AllocationMaxNetmask参数不合法。
400 IllegalParam.AllocationMinNetmask The specified AllocationMinNetmask is illegal. AllocationMinNetmask参数不合法。
400 IllegalParam.IpVersion The specified IpVersion is illegal. IpVersion参数不合法。
400 QuotaExceeded.IpamPoolQuotaDepth The quota of IpamPoolQuotaDepth count is exceeded. IPAM地址池深度允许的最大数量超过限制。
400 ResourceNotFound.Ipam The specified resource of ipam is not found. 输入的IPAM不存在。
400 IllegalParam.PoolRegionId The specified PoolRegionId is illegal. PoolRegionId参数不合法。
400 QuotaExceeded.IpamSubPoolQuotaPerIpamPool The quota of ipamSubPoolQuotaPerIpamPool count is exceeded. 单个IPAM地址池允许创建的子池数量超过限额。
400 DryRunOperation Request validation has been passed with DryRun flag set. DryRun校验通过。
400 IncorrectStatus.IpamPool The status of the IPAM pool is incorrect. IPAM地址池的状态不正确。
400 OperationDenied.OperateShareResource The operation is not allowed because the instance is a shared resource. 该实例是共享资源,不允许操作。
400 UnsupportedFeature.IpamPublicIpv4Pool The feature of public IPv4 pool is not supported in IPAM. IPAM暂不支持创建公网IPv4地址池。
400 OperationDenied.IpamPublicIpv6PoolNeedPoolRegion The public IPv6 pool cannot be created in IPAM when its pool region is empty. 不支持创建生效地域为空的公网IPv6地址池。
400 IllegalParam.Ipv6Isp The specified Ipv6Isp is illegal. 指定的Ipv6Isp参数不合法。
400 UnsupportedFeature.Ipv6Isp The Ipv6Isp feature is not supported. 指定的Ipv6Isp特性不支持。
400 UnsupportedRegion.Ipv6Isp The current region does not support this feature. 当前Region未支持该特性。
400 QuotaExceeded.IpamPublicIpv6TopPoolQuotaPerRegionIsp The number of public IPv6 top pool in IPAM for this ISP owned by the user in this region exceeds the limit. 对于当前的ISP类型,用户在当前地域创建的IPAM公网IPv6顶级地址池数量超过限额。
400 Mismatch.IpamScopeAndSourceIpamPool The input source IPAM pool is not in the input IPAM scope. 输入的IPAM父池不在输入的IPAM作用范围内。
400 Mismatch.Ipv6IspAndSourceIpamPool The input Ipv6Isp is inconsistent with the Ipv6Isp of the input source IPAM pool. 输入的Ipv6Isp和父池的Ipv6Isp不一致。
400 UnsupportedFeature.IpamIpv6 The feature of IPv6 is not supported in this region. 该地域不支持在IPAM中使用IPv6功能。

访问错误中心查看更多错误码。

变更历史

更多信息,参考变更详情