Creates a Message Queue for RabbitMQ instance. When you call this operation, the system generates a purchase order and automatically completes the payment.
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | CreateInstance |
The operation that you want to perform. Set the value to CreateInstance. |
Parameter.N.Code | String | Yes | InstanceType |
The code of the Nth attribute configured for the instance. For each attribute that you configure, specify a unique positive integer or 0 as the value of N. If you want to configure multiple attributes for the instance, concatenate the parameter settings for the attributes. This parameter must be used together with the Parameter.N.Value parameter. For more information about how to configure more attributes to create a Message Queue for RabbitMQ instance, see Table 1. |
Parameter.N.Value | String | Yes | professional |
The value of the attribute whose code is Parameter.N.Code. For each attribute that you want to configure, specify a unique value for N that is a positive integer or 0. If you want to configure multiple attributes for the instance, concatenate the parameter settings for the attributes. |
ProductCode | String | Yes | ons | The code of the service. Set the value to ons. |
ProductType | String | Yes | ons_onsproxy_public_intl | The type of the service. Set the value to ons_onsproxy_public_intl. |
SubscriptionType | String | Yes | Subscription |
The billing method of the instance. Valid values:
Message Queue for RabbitMQ instances do not support the pay-as-you-go billing method. Set the value to Subscription. |
RenewalStatus | String | No | AutoRenewal |
The renewal method of the instance. Valid values:
|
RenewPeriod | Integer | No | 1 |
The auto-renewal period of the instance. Unit: month. Note This parameter is required if the RenewalStatus parameter is set to AutoRenewal.
|
Period | Integer | No | 1 |
The subscription period of the instance. Unit: month. If you want to create a yearly subscription instance, specify an integer multiple of 12. Note This parameter is required if you create a subscription instance.
|
ClientToken | String | No | JASIOFKVNVIXXXXXX |
The client token that is used to ensure the idempotence of the request. The server checks whether a request that uses the same client token is received. If a request with the same client token has been received, the server returns the same query result of the request. |
Parameter | Value | Required | Description |
---|---|---|---|
Parameter.0.Code | InstanceType | No | The type of the instance. Set the Parameter. 0.Value parameter to one of the following values:
|
Parameter.1.Code | Region | Yes | The region where the instance is deployed. Specify an available region such as cn-shenzhen as the value of the Parameter.1.Value parameter. |
Parameter.2.Code | SupportEip | Yes | Specifies whether the instance can be accessed over the Internet. Set the Parameter.2.Value parameter to one of the following values:
|
Parameter.3.Code | MaxEipTps | Yes | The maximum number of Internet-based transactions per second on the instance. Specify a peak TPS value for the Parameter.3.Value parameter based on the peak TPS values on the buy page in the Message Queue for RabbitMQ console. |
Parameter.4.Code | MaxTps | Yes | The maximum number of virtual private cloud (VPC)-based transactions per second on the instance. Specify a peak TPS value for the Parameter.4.Value parameter based on the peak TPS values on the buy page in the Message Queue for RabbitMQ console. |
Parameter.5.Code | QueueCapacity | Yes | The maximum number of queues that can be created in the instance. Set the Parameter.5.Value parameter to an integer value that ranges from 50 to 6000. |
Parameter.6.Code | OrderNum | Yes | The number of instances that you want to create. Set the Parameter.6.Value parameter to an integer value that ranges from 1 to 9999. |
Parameter.7.Code | StorageSize | Yes | The size of storage that can be used to store messages. Set the Parameter.7.Value parameter to one of the following values based on the edition of the instance:
|
Parameter.8.Code | support_tracing | Yes | Specifies whether to enable the message trace feature. Set the Parameter.8.Value parameter to one of the following values:
Notice The Parameter.8.Value parameter must be used together with Parameter.9.Value parameter.
|
Parameter.9.Code | tracing_storage_time | Yes | Specifies the retention period for message traces. Set the Parameter.9.Value parameter to one of the following values:
Unit: day. Notice The Parameter.9.Value parameter must be used together with the Parameter.8.Value parameter. The following rules are used:
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
Code | String | Success |
The status code. |
Data | Struct |
The returned message. |
|
InstanceId | String | amqp-cn-zvp2ajsj**** |
The ID of the instance. |
OrderId | String | 21014976059**** |
The ID of the order that was created. |
Message | String | Successful! |
The prompt message. |
RequestId | String | B62C712B-1789-5114-B0BB-80CB2AFD**** |
The ID of the request. |
Success | Boolean | true |
Indicates whether the request was successful. |
Examples
Sample requests
http(s)://business.aliyuncs.com/?Action=CreateInstance
&Parameter.0.Code=InstanceType
&Parameter.0.Value=professional
&Parameter.1.Code=Region
&Parameter.1.Value=cn-shenzhen
&Parameter.2.Code=SupportEip
&Parameter.2.Value=eip_true
&Parameter.3.Code=MaxEipTps
&Parameter.3.Value=640
&Parameter.4.Code=MaxTps
&Parameter.4.Value=1000
&Parameter.5.Code=QueueCapacity
&Parameter.5.Value=200
&Parameter.6.Code=StorageSize
&Parameter.6.Value=200
&Parameter.7.Code=OrderNum
&Parameter.7.Value=1
&Parameter.8.Code=support_tracing
&Parameter.8.Value=tracing_true
&Parameter.9.Code=tracing_storage_time
&Parameter.9.Value=3
&ProductCode=ons
&ProductType=ons_onsproxy_public_intl
&SubscriptionType=Subscription
&Period=1
&RenewPeriod=1
&RenewalStatus=AutoRenewal
&<Common request parameters>
Sample success responses
XML
format
<CreateInstanceResponse>
<RequestId>B62C712B-1789-5114-B0BB-80CB2AFD****</RequestId>
<Message>Successful!</Message>
<Data>
<InstanceId>amqp-cn-zvp2ajsj****</InstanceId>
<OrderId>21014976059****</OrderId>
</Data>
<Code>Success</Code>
<Success>true</Success>
</CreateInstanceResponse>
JSON
format
{
"RequestId": "B62C712B-1789-5114-B0BB-80CB2AFD****",
"Message": "Successful!",
"Data": {
"InstanceId": "amqp-cn-zvp2ajsj****",
"OrderId": 21014976059****
},
"Code": "Success",
"Success": true
}
Error codes
For a list of error codes, visit the API Error Center.