申请内网虚拟IP-AllocateVIP

根据提供信息,申请内网VIP(Virtual IP),多用于高可用程序作为漂移IP。

Request Parameters

Parameter nameTypeDescriptionRequired
Regionstring地域Yes
ProjectIdstring项目ID,例如"org-xxxxxx",默认为当前项目No
Zonestring可用区No
VPCIdstring指定vip所属的VPCYes
SubnetIdstring子网idYes
Countint申请数量,默认: 1No
Namestringvip名,默认为VIPNo
Tagstring业务组名称,默认为DefaultNo
Remarkstring备注No
BusinessIdstring业务组No

Response Elements

Parameter nameTypeDescriptionRequired
RetCodeint操作返回码Yes
Actionstring操作名称Yes
VIPSetarray申请到的VIP资源相关信息No
DataSetarray申请到的VIP地址No

VIPSet

Parameter nameTypeDescriptionRequired
VIPstring虚拟ipNo
VIPIdstring虚拟ip idNo
VPCIdstringVPC idNo

Request Example

http(s)://api.ucloud.cn/?Action=AllocateVIP
&Region=cn-bj2
&ProjectId=xxxx
&Zone=cn-bj2-04
&VPCId=xxx
&SubnetId=xxx

Response Example

{
    "Action": "AllocateVIPResponse",
    "RetCode": 0,
    "TotalCount": 1,
    "VIPSet": [
        {
            "VIP": "10.64.204.72",
            "VPCId": "vnet-xxx",
            "VIPId": "vip-xxx"
        }
    ],
    "DataSet": [
        "10.64.204.72"
    ]
}