Create ULightHost - CreateULHostInstance
Overview
Create ULightHost
Definition
Public Parameters
Parameter Name | Type | Description Information | Required |
---|---|---|---|
Action | string | Corresponding API command name, the current API is CreateULHostInstance . | Yes |
PublicKey | string | The user's public key can be obtained from Console (opens in a new tab) | Yes |
Signature | string | User signature generated based on public key and API command, see Signature Algorithm | Yes |
Request Parameters
Parameter Name | Type | Description Information | Required |
---|---|---|---|
Region | string | Region. See List of Regions and Availability Zones | Yes |
ProjectId | string | Project ID. If not filled in, the default project is used, sub-accounts must be filled in. Please refer to the GetProjectList interface. | No |
ImageId | string | Image ID. Please obtain it through DescribeImage | Yes |
BundleId | string | Package ID. For example: "ulh.c1m1s40b30t800". | Yes |
Password | string | ULHost password. Please set the password according to the field specification. The password needs to be encoded with base64, as shown in the example below: # echo -n Password1 | base64 | Yes |
Name | string | Light application host name. Default: Package ID. Please set the instance name according to the field specification. | No |
ChargeType | string | Billing mode. Enumeration values: > Year, pay annually; > Month, pay monthly; Default: Month | No |
Quantity | int | Purchase duration. Default: 1. Purchase until the end of the month is not supported. | No |
VPCId | string | VPC ID. The default is the default VPC for the current region. | No |
SubnetId | string | Subnet ID. The default is the default subnet for the current region. | No |
SecurityGroupId | string | Firewall ID, default: Web recommended firewall. For how to query SecurityGroupId, please refer to DescribeFirewall. | No |
CouponId | string | Host coupon ID. Please query through the DescribeCoupon interface, or log in to the user center to view. | No |
Response Field
Field Name | Type | Description Information | Required |
---|---|---|---|
RetCode | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. | Yes |
Action | string | Operation command name. | Yes |
Message | string | Returns an error message, providing detailed description when RetCode is non-zero. | No |
ULHostId | string | Instance ID | Yes |
Example
Request Example
https://api.ucloud-global.com/?Action=CreateULHostInstance
&Region=cn-zj
&ProjectId=BiVhUqWM
&BundleId=WKrqUTuj
&ChargeType=iHquSVAk
&Password=KzuuLxoH
&Quantity=4
&Quantity=8
&ImageId=reBHwafg
&ImageId=qCkNplRb
&CouponId=JsBRKuuV
&ImageId=MmsUzsUT
&CouponId=ymmIIHOA
&BillActivityId=8
&BillActivityRuleId=6
&Name=dtIbqVbo
&VPCId=rWsGXPTF
&SubnetId=MZdVRtph
&SecurityGroupId=CsyANPJL
Response Example
{
"Action": "CreateULHostInstanceResponse",
"Message": "UQIsLeri",
"RetCode": 0,
"ULHostId": "DJCRwHar"
}