edit-icon download-icon

CreateDBInstance

Last Updated: Jul 04, 2018

Description

  • This API supports replica set instances only.
  • This API supports both data restoration and instance clone functions.

Input parameters

NameTypeRequiredDescription
ActionStringYesRequired parameter; value: CreateDBInstance.
RegionIdStringYes- Region ID, no longer than 50 characters.
- You can use the DescribeRegions function to view IDs of available regions.
ZoneIdStringNoZone ID. You can use the DescribeRegions function to view available zones.
EngineStringYesDatabase type; value: ApsaraDB for MongoDB.
EngineVersionStringYesDatabase version number; optional values: 3.2 or 3.4.
StorageEngineStringNoStorage engine; optional values: WiredTiger or RocksDB. Default value: WiredTiger. For a cloned instance, the value must be the same as that of the master instance.
DBInstanceClassStringYesInstance specification. For optional values, see Instance specifications.
DBInstanceStorageIntegerYes- Custom storage space; value range: [10,2000] for ApsaraDB for MongoDB.
- 10-GB increments. Unit: GB.
DBInstanceDescriptionStringNo- Instance description or remarks, with a length of 2 to 256 characters.
- It must start with a Chinese character or an English letter and can consist of Chinese and English characters, underlines (), hyphens (-), and numbers.
SecurityIPListStringNo- List of IP addresses allowed to access all databases in this instance. IP addresses are separated by commas (,) and no duplicate is allowed. The list can contain a maximum of 1,000 IP addresses.
- Supported formats are as follows: %, 0.0.0.0/0, 10.23.12.24 (IP), or 10.23.12.24/24 (CIDR mode; classless inter-domain routing; /24 indicates the length of the prefix in the IP address; the prefix length ranges from 1 to 32). 0.0.0.0/0 indicates no restriction. By default, no access restriction is applied.
AccountPasswordStringNoPassword of the root account. It is a string of 6 to 32 characters and is composed of letters, numbers, and underlines ().
ChargeTypeStringNoPayment mode: PrePaid and PostPaid. PrePaid indicates yearly/monthly subscription and PostPaid indicates Pay-As-You-Go. Default value: PostPaid.
PeriodIntegerNoExpiration time of yearly/monthly subscription instances. If the charge type is set to PrePaid, the optional values are as follows: 1-9, 12, 24, and 36. Unit: months.
ClientTokenStringYes- It is used to guarantee the idempotence of the request. The value is generated by the client. It must be unique among all requests and contain a maximum of 64 ASCII characters.
- For more information, see the Appendix: How to Guarantee Idempotence.
NetworkType StringNoNetwork type of an instance. Optional values: Classic and VPC. Default value: Classic.
VpcIdStringNoVirtual private cloud (VPC) ID. If NetworkType is set to VPC, this parameter is required.
VSwitchIdStringNoVSwitch ID. If NetworkType is set to VPC, this parameter is required.
DBInstanceIdStringNoThis parameter must be specified when a paid instance is created based on an instance backup set.Buy pages of the first stage support Pay-As-You-Go only.
BackupIdStringNoSpecific backup set ID
RestoreTimeStringNoTime point when a cloned instance is restored.

Response parameters

NameTypeDescription
Public response parameters-For more information, see public response parameters.
DBInstanceIdStringInstance ID
OrderIdStringOrder ID
Thank you! We've received your feedback.