All Products
Search
Document Center

ApsaraMQ for RabbitMQ:CreateInstance

Last Updated:Aug 04, 2026

Creates an ApsaraMQ for RabbitMQ instance.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

amqp:CreateInstance

create

*All Resource

*

  • amqp:InstanceType
  • amqp:SupportEIP
  • amqp:ServerlessChargeType
None

Request parameters

Parameter

Type

Required

Description

Example

ClientToken

string

No

The client token.

c2c5d1274axxxxxxxx

PaymentType

string

Yes

The payment type. Valid values:

Valid values:

  • PayAsYouGo :

    PayAsYouGo

  • Subscription :

    Subscription

Subscription

Period

integer

No

The subscription period. Unit: periodCycle.

1

PeriodCycle

string

No

The unit of the subscription period. Valid values:

Valid values:

  • Month :

    Month

  • Year :

    Year

Month

AutoRenew

boolean

No

The renewal method. Valid values:

false

AutoRenewPeriod

integer

No

The auto-renewal epoch. The unit is specified by the RenewalDurationUnit value. Default unit: month.

1

RenewStatus

string

No

The renewal status. This parameter is equivalent to autoRenew. You only need to configure one of them. Valid values:

false

RenewalDurationUnit

string

No

The unit of the auto-renewal epoch. Valid values:

Valid values:

  • Month :

    Month

  • Year :

    Year

Month

InstanceType

string

No

The instance type.

Valid values:

  • enterprise :

    enterprise

  • vip :

    vip

  • professional :

    professional

professional

ServerlessChargeType

string

No

The billing type of the serverless instance. Valid values:

onDemand

InstanceName

string

No

The instance name. The name can be up to 64 characters in length.

amqp-xxxxx

MaxPrivateTps

integer

No

The private network TPS. Unit: transactions per second.

1000

SupportEip

boolean

No

Specifies whether public network access is supported. Valid values:

true

MaxEipTps

integer

No

The peak public network TPS. Unit: TPS.

128

QueueCapacity

integer

No

The number of queues. Unit: count.

1000

MaxConnections

integer

No

The maximum number of connections.

50000

StorageSize

integer

No

The message storage space. Unit: GB. Valid values:

7

SupportTracing

boolean

No

Specifies whether to enable the message tracing feature. Valid values:

true

TracingStorageTime

integer

No

The retention period for message traces. Unit: days. Valid values:

3

ResourceGroupId

string

No

The ID of the resource group to which the instance belongs.

rg-acfmvvajg5qkxhi

EncryptedInstance

boolean

No

This feature is available only for dedicated instances. Specifies whether to enable data storage encryption for the instance.

false

KmsKeyId

string

No

This feature is available only for dedicated instances. This parameter is required when EncryptedInstance is set to true. The ID of the KMS key used for data encryption at rest. The key must meet the following requirements:

key-xxx

ProvisionedCapacity

integer

No

The provisioned TPS capacity for reserved + elastic instances.

2000

Edition

string

No

The deployment architecture of the serverless instance. Valid values:

shared

Tags

array<object>

No

The resource tags.

object

No

The tag object.

Key

string

No

The resource tag key.

testKey

Value

string

No

The resource tag value.

testValue

VpcId

string

Yes

The VPC ID used to create a PrivateLink endpoint.

vpc-xxx

VswitchIds

array

Yes

The vSwitch IDs used to create a PrivateLink endpoint when creating an instance.

string

Yes

The vSwitch ID specified when creating the instance.

vsw-xxx

SecurityGroupId

string

Yes

The security group ID used to create a PrivateLink endpoint.

sg-xxx

ListenerMode

string

No

Specifies whether to enable only the TLS-encrypted port for the instance. This parameter is supported only for dedicated reserved + elastic and Platinum instances.

tcp_and_ssl

AuthModel

string

No

The authentication mode. Default value: RAM authentication mode.

Valid values:

  • openSource :

    openSource

  • ram :

    ram

ram

ServerlessSwitch

boolean

No

The elastic switch.

The following examples contain only required parameters. Configure other parameters as needed:

Purchase a serverless pay-as-you-go instance:

Purchase a serverless reserved + elastic (shared) instance:

>  The provisionedCapacity range is [2000, 20000] with a step size of 2000.

```json.

Purchase a serverless reserved + elastic (dedicated) instance:

> The provisionedCapacity range is [5000, 500000] with a step size of 5000.

```json.

Purchase an Enterprise instance:

> Valid values for MaxPrivateTps: 3000, 5000, 8000, 10000, 15000, 20000, 30000, 40000, 50000, 80000, 100000

```json.

Purchase a Platinum instance:

> Valid values for MaxPrivateTps: 8000, 15000, 25000, 40000, 50000, 100000, 200000, 300000, 500000, 800000, 1000000

```json.

Response elements

Element

Type

Description

Example

object

JsonResult

RequestId

string

The common parameter. Each request has a unique ID that is active for troubleshooting.

CCBB1225-C392-480E-8C7F-D09AB2CD2***

Code

integer

The response code. A value of 200 indicates success.

200

Message

string

The response message.

xxx failed,xxxx

Data

any

The ID of the created instance.

amqp-cn-xxxxx

Success

boolean

Indicates whether the request was successful.

true

Examples

Success response

JSON format

{
  "RequestId": "CCBB1225-C392-480E-8C7F-D09AB2CD2***",
  "Code": 200,
  "Message": "xxx failed,xxxx",
  "Data": "amqp-cn-xxxxx",
  "Success": true
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.