docs
api
Cloud MongoDB Database(UDB NVMe)
CreateUMongoDBReplSet

Create Replica Set - CreateUMongoDBReplSet

Overview

Create a Mongodb replica set cluster

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is CreateUMongoDBReplSet.Yes
PublicKeystringThe user's public key can be obtained from Console (opens in a new tab)Yes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
RegionstringRegion. See List of Regions and Availability ZonesYes
ZonestringAvailability Zone. See Availability Zone ListYes
ProjectIdstringProject ID. If not filled in, the default project is used, sub-accounts must be filled in. Please refer to the GetProjectList interface.No
NamestringReplica set instance name, at least 6 charactersYes
DBVersionstringVersion of Mongodb's replica set, such as MongoDB_3_6, MongoDB_4_2Yes
AdminPasswordstringAdministrator PasswordYes
DiskSpaceintDisk Space (GB)Yes
MachineTypeIdstringMachine ConfigurationYes
NodeCountintNumber of Replica Set NodesYes
ListenPortintMongo service portNo
SubnetIdstringSubnet IDNo
VPCIdstringID of VPCNo
TagstringThe name of the business group where the instance is locatedNo
ChargeTypestringPayment methods: Yearly, Monthly, Dynamic, Trial, Default: MonthlyNo
QuantityintPurchase duration, default value 1No

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No

Example

Request Example

https://api.surfercloud.com/?Action=CreateUMongoDBReplSet
&Region=cn-zj
&Zone=cn-zj-01
&ProjectId=dHsclqIa
&Name=FtgAKIEl
&DBVersion=wqUloOJO
&AdminPassword=wpDUSWbu
&DiskSpace=uDHddgoU
&MachineTypeId=HDnfeFgp
&NodeCount=8
&SubnetId=QmISYYRw
&VPCId=SvxLSwuj
&Tag=wDGWVOqD
&ChargeType=Year
&Quantity=6
&ListenPort=3

Response Example

{
  "Action": "CreateUMongoDBReplSetResponse",
  "RetCode": 0
}
  • Company
  • ContactUs
  • Blog
Copyright © 2024 SurferCloud All Rights Reserved