API overview
API standards and multilingual preset SDKs
The OpenAPI of this product (Dds/2015-12-01) uses the RPC signature style. We have encapsulated SDKs for common programming languages for developers. Developers can download the SDK to directly call this product's OpenAPI without worrying about technical details. If the existing SDK does not meet your needs, you can use the signature mechanism for self-signing integration. Since the details of self-signing are very complex, it may take around 5 business days. Therefore, we recommend joining our DingTalk service group (147535001692) and conducting signature integration under expert guidance.
Before using the API, you need to prepare your identity account and access key (AccessKey) to effectively access the API through client tools (such as SDK and CLI). For details, see Obtain an AccessKey.
Custom signature scenarios
If your business scenario has special requirements and you need to integrate the API through self-signing, we recommend consulting our technical support team first (DingTalk service group: 147535001692) to obtain professional guidance and ensure efficient integration.
Account and security preparation
Alibaba Cloud accounts have full administrative permissions over all resources. Once an AccessKey is compromised, all associated resources will be at risk of unauthorized access. To ensure security, it is recommended to create a RAM user with only API access permissions and configure its AccessKey, while configuring RAM policies based on the principle of least privilege (PoLP). Use the Alibaba Cloud account only in specific scenarios where Alibaba Cloud account permissions are explicitly required.
Create or clone instances
|
API |
Title |
Description |
| CreateDBInstance | Create or clone a replica set instance | Creates or clones an ApsaraDB for MongoDB replica set instance. |
| CreateShardingDBInstance | Create or clone a sharded cluster instance | Creates or clones an ApsaraDB for MongoDB sharded cluster instance. |
Modify instance configurations
|
API |
Title |
Description |
| CreateNode | Add a shard node or a mongos node | Adds a shard node or a mongos node to an ApsaraDB for MongoDB sharded cluster instance. |
| CreateNodeBatch | Create multiple nodes | Adds multiple Mongos and shard nodes to an ApsaraDB for MongoDB sharded cluster instance. |
| DeleteNode | Delete a node from a sharded cluster instance | Deletes a shard or mongos node from an ApsaraDB for MongoDB sharded cluster instance. |
| ModifyDBInstanceSpec | Modify the specifications or storage space of a standalone or replica set instance | Modifies the specifications or storage space of ApsaraDB for MongoDB standalone instances, replica set instances, and serverless instances. Serverless instances are supported only on the China site. |
| ModifyNodeSpec | Modify the specifications and storage space of nodes in a sharded cluster instance | Modifies the specifications and storage space of nodes in a MongoDB sharded cluster instance. |
| ModifyNodeSpecBatch | Batch modify node specifications | Modifies the configurations of one or more Mongos or shard nodes in an ApsaraDB for MongoDB sharded cluster instance. |
| ModifyDBInstanceDiskType | Modify the disk type of an instance | Modifies the disk type of an ApsaraDB for MongoDB instance. |
Instance management
|
API |
Title |
Description |
| DeleteDBInstance | Delete a database instance | Releases a MongoDB instance. |
| ModifyDBInstanceMaintainTime | ModifyDBInstanceMaintainTime | Modifies the maintenance window of an ApsaraDB for MongoDB instance. |
| ModifyDBInstanceDescription | ModifyDBInstanceDescription | Modifies the name of an ApsaraDB for MongoDB instance. |
| ModifyDBInstanceNetExpireTime | Extend the classic network retention period for a mongoDB instance | Extends the classic network retention period for a MongoDB instance. |
| UpgradeDBInstanceEngineVersion | UpgradeDBInstanceEngineVersion | Upgrades the database version of an ApsaraDB for MongoDB instance. |
| UpgradeDBInstanceKernelVersion | UpgradeDBInstanceKernelVersion | Upgrades the minor version of an ApsaraDB for MongoDB instance. |
| SwitchDBInstanceHA | SwitchDBInstanceHA | Switches the primary and secondary nodes for an ApsaraDB for MongoDB instance. |
| RestartDBInstance | Restart a mongoDB instance | Restarts a MongoDB instance. |
| DestroyInstance | Destroy a mongoDB instance | Destroys a MongoDB instance. |
| RestartNode | Restart a single node of a mongoDB instance | Restarts a single node of an ApsaraDB for MongoDB instance. |
Renewal management
|
API |
Title |
Description |
| ModifyInstanceAutoRenewalAttribute | ModifyInstanceAutoRenewalAttribute | Enables or disables auto-renewal for an ApsaraDB for MongoDB instance. |
| TransformInstanceChargeType | Transform the billing method of an apsaraDB for mongoDB instance | Transforms the billing method of an ApsaraDB for MongoDB database instance by converting a pay-as-you-go instance to an upfront subscription instance or a subscription instance to a pay-as-you-go instance. |
| DescribePrice | Query pricing information | Queries pricing information. |
| DescribeRenewalPrice | DescribeRenewalPrice | Get the price to renew a specific MongoDB instance for one month. |
| TransformToPrePaid | Convert a pay-as-you-go instance to a subscription instance | Converts a pay-as-you-go ApsaraDB for MongoDB instance to a subscription instance. |
| RenewDBInstance | Manually renew a subscription instance | Renews a subscription ApsaraDB for MongoDB instance. |
Query instances
|
API |
Title |
Description |
| DescribeDBInstanceSpecInfo | DescribeDBInstanceSpecInfo | Gets instance type details. |
| DescribeReplicaSetRole | DescribeReplicaSetRole | Retrieves the role information and connection details for a MongoDB instance. |
| DescribeKernelReleaseNotes | Query release notes of minor engine versions | Queries the release notes of minor engine versions for a MongoDB instance. |
| DescribeAvailableEngineVersion | DescribeAvailableEngineVersion | Queries the engine versions to which an ApsaraDB for MongoDB instance can be upgraded. |
| DescribeDBInstances | Query mongoDB instance list | Queries a list of MongoDB instances. |
| DescribeDBInstanceSwitchLog | Query primary/secondary switchover logs of an instance | Queries the primary/secondary switchover logs of an instance. |
| DescribeDBInstanceAttribute | Query apsaraDB for mongoDB instance information | Queries the details of an ApsaraDB for MongoDB instance. |
| DescribeRoleZoneInfo | Query the roles and zones of each node in an instance | Queries the roles and zones of each node in a MongoDB instance. |
| DescribeInstanceAutoRenewalAttribute | DescribeInstanceAutoRenewalAttribute | Queries the auto-renewal status of MongoDB instances. |
| DescribeActiveOperationTaskCount | DescribeActiveOperationTaskCount | Queries the number of operation and maintenance tasks on an ApsaraDB for MongoDB instance. |
| DescribeActiveOperationTasks | Query proactive O&M tasks | Queries the details of scheduled O&M tasks for MongoDB instances. |
| DescribeActiveOperationTaskType | DescribeActiveOperationTaskType | Queries the types of Operation and Maintenance tasks and the number of tasks of each type for an ApsaraDB for MongoDB instance. |
| DescribeDBInstancesOverview | Query instance overview information | Queries the overview information of one or more ApsaraDB for MongoDB instances. |
| DescribeHistoryTasks | DescribeHistoryTasks | Queries a list of tasks in the task center. |
| DescribeHistoryTasksStat | DescribeHistoryTasksStat | Queries the overview of a task in the task center. |
| ModifyTaskInfo | Modify task information in the task center | Modifies the task information in the task center. |
| ModifyActiveOperationTasks | Modify the switchover time of multiple proactive O&M tasks | Modifies the switchover time of scheduled O&M tasks for an ApsaraDB for MongoDB instance. |
Resource management
|
API |
Title |
Description |
| DescribeAvailableResource | DescribeAvailableResource | Queries the available resources in the specified zone. |
| EvaluateResource | Evaluate resource availability | Evaluates whether sufficient resources are available before you create an instance or change the specifications of an instance. |
| DescribeAvailabilityZones | View zones supported by an instance | Queries the zones supported by MongoDB instances. |
| ModifyResourceGroup | ModifyResourceGroup | Moves an ApsaraDB for MongoDB instance to a specified resource group. |
Region management
|
API |
Title |
Description |
| DescribeRegions | DescribeRegions | Queries all regions and zones supported for an ApsaraDB for MongoDB instance. |
| MigrateToOtherZone | Migrate an instance to another zone | Migrates a MongoDB instance to another zone. |
| MigrateAvailableZone | Migrate the zone of an instance | Migrates the zone of a MongoDB instance. |
Connection management
|
API |
Title |
Description |
| ModifyInstanceVpcAuthMode | ModifyInstanceVpcAuthMode | Disables password-free access over Virtual Private Cloud (VPC) for an ApsaraDB for MongoDB instance. |
| ModifyDBInstanceNetworkType | Switch the network type of an instance | Switches the network type of a MongoDB instance. |
| ModifyDBInstanceConnectionString | Modify the endpoint and port of an instance | Modifies the endpoint and port of an ApsaraDB for MongoDB instance. |
| DescribeShardingNetworkAddress | DescribeShardingNetworkAddress | Retrieves the connection information for a MongoDB sharded cluster instance. |
| AllocatePublicNetworkAddress | Allocate a public endpoint for an instance | Allocates a public endpoint. |
| ReleasePublicNetworkAddress | ReleasePublicNetworkAddress | Releases the public endpoint of an ApsaraDB for MongoDB instance. |
| AllocateNodePrivateNetworkAddress | Apply for an internal network endpoint for an ApsaraDB sharded cluster instance node | Applies for an internal network endpoint for a shard or ConfigServer node of an ApsaraDB for MongoDB database sharded cluster instance. |
| ReleaseNodePrivateNetworkAddress | Release a node or its internal endpoint | Releases the internal endpoint of a shard or ConfigServer node in a sharded cluster instance. |
Tag management
|
API |
Title |
Description |
| ListTagResources | ListTagResources | Queries the relationship between ApsaraDB for MongoDB instances and tags. |
| DescribeTags | DescribeTags | Queries all tags in a specified region. |
| TagResources | TagResources | Binds tags to ApsaraDB for MongoDB instances. |
| UntagResources | UntagResources | Removes a tag if the tag is not added to another instance. |
Account management
|
API |
Title |
Description |
| CreateAccount | Create an account | Creates a database account for a specified ApsaraDB for MongoDB instance and grants one or more database role permissions to the account. |
| ResetAccountPassword | Reset the password of the root account in an apsaraDB for mongoDB instance | Resets the password of a database account in an ApsaraDB for MongoDB instance. |
| ModifyAccountDescription | Modify account description | Modifies the description of an account in a specified ApsaraDB for MongoDB instance. |
| DescribeAccounts | Query database account information for an instance | Queries the accounts of a specified ApsaraDB for MongoDB instance, including the account name, account status, description, account type, associated database, and assigned role permissions. |
Whitelists and security groups
|
API |
Title |
Description |
| ModifySecurityIps | Set the IP whitelist for accessing an instance | Modifies the IP whitelist of a MongoDB instance. |
| ModifySecurityGroupConfiguration | ModifySecurityGroupConfiguration | Modifies the ECS security group bound to an ApsaraDB for MongoDB instance. |
| DescribeSecurityIps | DescribeSecurityIps | Retrieves the IP whitelists of an ApsaraDB for MongoDB instance. |
| DescribeSecurityGroupConfiguration | DescribeSecurityGroupConfiguration | Queries the Elastic Compute Service (ECS) security groups that are associated with an ApsaraDB for MongoDB instance. |
| ModifyGlobalSecurityIPGroup | ModifyGlobalSecurityIPGroup | Modifies the global IP whitelist template associated with an ApsaraDB for MongoDB instance. |
| DescribeGlobalSecurityIPGroup | Query global IP whitelist templates | Queries the global IP whitelist templates. |
| ModifyGlobalSecurityIPGroupName | ModifyGlobalSecurityIPGroupName | Modifies the name of a global IP whitelist template associated with an ApsaraDB for MongoDB instance. |
| DescribeGlobalSecurityIPGroupRelation | DescribeGlobalSecurityIPGroupRelation | Queries the mapping between an instance and a global IP address whitelist template. |
| CreateGlobalSecurityIPGroup | Create a global IP whitelist template | Creates a global IP whitelist template. |
| ModifyGlobalSecurityIPGroupRelation | ModifyGlobalSecurityIPGroupRelation | Modifies the mapping between a global whitelist template and an ApsaraDB for MongoDB instance. |
| DeleteGlobalSecurityIPGroup | Delete a global IP address whitelist template | Deletes a global IP address whitelist template. |
Keys
|
API |
Title |
Description |
| ModifyDBInstanceTDE | Modify the TDE status of a MongoDB instance | Modifies the Transparent Data Encryption (TDE) status of a MongoDB instance. |
| CheckCloudResourceAuthorized | Query whether a KMS key is authorized for an instance | Queries whether a Key Management Service (KMS) key is authorized for a MongoDB instance. |
| DescribeUserEncryptionKeyList | Query the custom key list of an instance | Queries the custom key list of an instance. |
| DescribeDBInstanceEncryptionKey | Query the details of a specific key for a mongoDB instance | Queries the details of a specific key for a MongoDB instance. |
| DescribeDBInstanceTDEInfo | Query whether TDE is enabled for a mongoDB instance | Queries whether Transparent Data Encryption (TDE) is enabled for an ApsaraDB for MongoDB instance. |
| DescribeKmsKeys | DescribeKmsKeys | Queries Key Management Service (KMS) keys that are available for disk encryption. |
SSL encryption
|
API |
Title |
Description |
| ModifyDBInstanceSSL | Modify the SSL configuration of a mongoDB instance | Modifies the SSL configuration of a MongoDB instance. |
| DescribeDBInstanceSSL | DescribeDBInstanceSSL | Query SSL configuration details for a MongoDB instance. |
Audit logs
|
API |
Title |
Description |
| ModifyAuditLogFilter | Modify audit log collection types for an instance | Modifies the collection types of audit logs for an ApsaraDB for MongoDB instance. |
| ModifyAuditPolicy | Set the audit log switch or log storage duration | Settings the audit log switch or log storage duration for an ApsaraDB for MongoDB instance. |
| DescribeAuditRecords | Query audit logs of an instance | Queries the audit logs of a MongoDB instance. |
| DescribeAuditPolicy | DescribeAuditPolicy | Checks whether audit logging is enabled for a MongoDB instance. |
| DescribeAuditLogFilter | DescribeAuditLogFilter | Queries the audit log types collected for a MongoDB instance. |
| DescribeMongoDBLogConfig | DescribeMongoDBLogConfig | You can view the configuration of MongoDB Log Service. |
Log management
|
API |
Title |
Description |
| DescribeSlowLogRecords | DescribeSlowLogRecords | Queries slow query log entries for a MongoDB instance. |
| DescribeErrorLogRecords | Query error logs of an instance | Queries the error logs of a MongoDB instance. |
| DescribeRunningLogRecords | Query instance running logs | Queries the running logs of an ApsaraDB for MongoDB instance. |
Performance monitoring
|
API |
Title |
Description |
| ModifyDBInstanceMonitor | ModifyDBInstanceMonitor | Set the monitoring collection granularity for a MongoDB instance. |
| DescribeDBInstancePerformance | Query instance performance data | Queries the performance data of an ApsaraDB for MongoDB instance. |
| DescribeDBInstanceMonitor | DescribeDBInstanceMonitor | Queries the collection frequency of monitoring data for an ApsaraDB for MongoDB instance. |
Parameter management
|
API |
Title |
Description |
| ModifyParameters | ModifyParameters | Modifies the parameters of an ApsaraDB for MongoDB instance. |
| DescribeParameterModificationHistory | DescribeParameterModificationHistory | Queries the parameter modification records of an ApsaraDB for MongoDB instance. |
| DescribeParameterTemplates | DescribeParameterTemplates | Queries the default parameter templates for MongoDB instances. |
| DescribeParameters | Query the parameter settings of an instance | Queries the parameter settings of a MongoDB instance. |
Backup and recovery
|
API |
Title |
Description |
| ModifyAdvancedBackupStatus | Check whether advanced backup is enabled for cloud disk replica set and sharded cluster instances | Enables advanced backup. |
| ModifyAdvancedBackupPolicy | Modify advanced backup policies | Modifies the advanced backup policy. |
| DescribeAdvancedBackupStatus | Query whether advanced backup is enabled | Queries whether advanced backup is enabled. |
| DescribeAdvancedBackupPolicy | Query advanced backup policies | Queries advanced backup policies. |
| CreateBackup | Manually back up an instance | Creates a backup for an ApsaraDB for MongoDB instance. |
| ModifyBackupPolicy | Modify the backup policy of an instance | Modifies the backup policy of a MongoDB instance. |
| DescribeBackupPolicy | View the automatic backup policy of an instance | Queries the backup policy of a MongoDB instance. |
| DescribeBackups | Query the backup list of an instance | Queries the backup list of an ApsaraDB for MongoDB instance. |
| DescribeBackupDBs | DescribeBackupDBs | Queries the databases at a specified time or the databases in a specified backup set before you restore a database for an ApsaraDB for MongoDB instance. |
| DescribeRestoreDBInstanceList | Query backup and restoration instances of a mongoDB instance | Queries the backup and restoration instances of a MongoDB instance within the last 7 days. |
| CheckRecoveryCondition | Check whether an instance meets the conditions for data restoration | Checks whether a MongoDB instance meets the conditions for data restoration. |
| TransferClusterBackup | Switch to cluster backup mode | Switches the backup mode of an ApsaraDB for MongoDB sharded cluster instance to cluster backup mode. After the switch to cluster backup mode, the instance supports high-frequency backups. |
| DescribeClusterBackups | List cluster backup sets | Queries the cluster backup sets of an ApsaraDB for MongoDB sharded cluster instance with cloud disks. |
| DescribeClusterRecoverTime | Query restorable time ranges for sharded clusters | Queries the restorable time ranges for ApsaraDB for MongoDB sharded cluster instances that use cloud disks. |
| DescribeBackupStorage | DescribeBackupStorage | Queries the backup usage for a MongoDB replica set or sharded cluster instance that uses cloud disks. |
| DescribeBackupTasks | Query ongoing backup tasks of an instance | Queries the ongoing backup tasks of ApsaraDB for MongoDB replica set or sharded cluster instances with cloud disks. |
| DescribeInstanceRecoverTime | Query the restorable time of a replica set instance | Queries the restorable time of an ApsaraDB for MongoDB replica set instance with cloud disks. |
Others
|
API |
Title |
Description |
| DescribeActiveOperationTask | Query O&M task details | Queries the details of O&M tasks. |
| AllocateDBInstanceSrvNetworkAddress | Apply for an SRV address | Applies for an SRV address for an ApsaraDB for MongoDB instance. |
| DescribeActiveOperationTaskRegion | Query maintenance task types and task quantities. | Queries the types and number of O&M tasks for a MongoDB instance. |
| DescribeActiveOperationMaintenanceConfig | Query the O&M task configuration of an instance | Queries the O&M task configuration of a MongoDB instance. |
| CheckServiceLinkedRole | Check whether a service-linked role has been created | Queries whether a service-linked role (SLR) has been created. |
| ModifyDBInstanceConfig | ModifyDBInstanceConfig | Modifies instance configuration |
| ModifyDBInstanceAttribute | ModifyDBInstanceAttribute | Modifies instance release protection configuration. |
| ModifySrvNetworkAddress | Modify the SRV endpoint of a MongoDB instance | Modifies the SRV endpoint of a MongoDB instance. |
| CancelActiveOperationTasks | Cancel O&M events | Cancels multiple O&M events in batches. |
| CreateNodeRoleTag | Create a role tag for a node | Creates a role tag for an instance node. |
| DescribeRdsVSwitchs | DescribeRdsVSwitchs | Retrieves a list of vSwitches. |
| DescribeRdsVpcs | DescribeRdsVpcs | Retrieves a list of VPCs. |
| DescribeRoleTagStatus | DescribeRoleTagStatus | Describes the status of a tag for a node. |
| DescribeVpcsForMongoDB | Retrieve a paginated list of vPCs | Retrieves a paginated list of VPCs. |
| ModifyActiveOperationMaintenanceConfig | Modify the O&M task configuration of an instance | Modifies the O&M task configuration of a MongoDB instance. |
| DescribeBinlogFiles | DescribeBinlogFiles | Query log backup files for an ApsaraDB for MongoDB instance. |
| ModifyBackupExpireTime | ModifyBackupExpireTime | Modifies the time-to-live (TTL) of a MongoDB backup set. |
| DeleteBackup | Delete a mongoDB backup set | Deletes a MongoDB backup set. |
| DescribeAccountRoles | Query custom roles for an instance | Queries the defined roles, including role names and definition databases, on a specified ApsaraDB for MongoDB instance. This serves as a data source for role selection when creating accounts or modifying account permissions. |
| DescribeDatabases | List databases on an instance | Queries the names of all existing databases on a specified ApsaraDB for MongoDB instance. |