Creates and starts multiple Elastic Cloud Phone (ECP) instances at a time.
Operation description
Preparations:
- The real-name verification is complete. For more information, see Real-name verification.
Precautions:
- You can create up to 100 ECP instances at a time.
- You can call this operation to create and start ECP instances.
- If an ECP instance fails to be created due to force majeure factors, such as insufficient inventory, the ECP instance is automatically rolled back and released.
Debugging
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The ID of the region. | cn-hangzhou |
InstanceName | string | No | The name of the ECP instance. The name must be 2 to 128 characters in length. It must start with a letter but cannot start with | instance |
Description | string | No | The description of the ECP instance. The description must be 2 to 256 characters in length and cannot start with | cloudphone instance |
InstanceType | string | Yes | The specifications of the ECP instance. | ecp.ce.large |
ImageId | string | Yes | The ID of the image. | cpm-xxxx |
SecurityGroupId | string | Yes | The ID of the security group that the ECP instance uses. The security group is the same as that of the Elastic Compute Service (ECS) instance that you use. | sg-xxxxx |
VSwitchId | string | Yes | The ID of the vSwitch. | vsw-xxxx |
EipBandwidth | integer | No | The bandwidth of the elastic IP address (EIP). Valid values: 1 to 200. If you specify this parameter, an ECP instance that uses an EIP with specified bandwidth is automatically created and associated with the ECP instance. If the ECP instance is released, the EIP is also released. | 2 |
Resolution | string | No | The resolution that you want to select for the ECP instance. You can query the resolutions that are supported by the current instance by calling the DescribeInstanceTypes operation and select an appropriate resolution. | 1920*1080 |
Amount | integer | No | The number of ECS instances that you want to create. Valid values: 1 to 100. Default value: 1. | 10 |
KeyPairName | string | No | The name of the key pair that you want to use to connect to the instance. You can call the ImportKeyPair operation to import a key pair for cloud phones. | keypair |
ClientToken | string | No | The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length. For more information, see How to ensure idempotence. | 473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
ChargeType | string | No | The billing method of the ECP instance. Valid values:
| PostPaid |
PeriodUnit | string | No | The unit of the subscription duration. Valid values:
| Month |
AutoRenew | boolean | No | Specifies whether to enable the auto-renewal feature. This parameter takes effect only if you set InstanceChargeType to PrePaid. Valid values:
| true |
AutoPay | boolean | No | Specifies whether to enable the auto-payment feature. Default value: true. | true |
Period | long | No | The subscription duration. Default value: 1.
| 1 |
Tag | object [] | No | The tags of the ECP instance. | |
Key | string | No | The tag key of the ECP instance. Valid values of N: 1 to 20. | TestKey |
Value | string | No | The tag value of the ECP instance. Valid values of N: 1 to 20. | TestValue |
PrivateIpAddress | string | No | The private IP address of the cloud phone. When you configure a private IP address for an ECP instance, you must select an idle CIDR block from the CIDR blocks of the vSwitch (VSwitchId). When you specify this parameter, take note of the following items: After you specify the PrivateIpAddress parameter, you must set Amount to 1, which indicates that a cloud phone with a specific private IP address is created. | 192.168.157.224 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E",
"OrderId": "9611111323245",
"TradePrice": 133.32,
"InstanceIds": {
"InstanceId": [
"cp-xxxxx"
]
}
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
403 | QuotaExceed | Instance quota exceed. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
2022-06-10 | The Error code has changed. The request parameters of the API has changed | see changesets | ||||||||
|