All Products
Search
Document Center

ApsaraDB for MongoDB:DescribePrice

Last Updated:Jan 17, 2023

Queries the fees incurred when you create, upgrade, or renew an ApsaraDB for MongoDB instance.

Authorization information

The following table is the authorization information corresponding to the API, which can be found in the RAM permission policy statement.Action Used in the element to grant the RAM user or RAM role permission to call this API. The specific instructions are as follows:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All resources is used in the Resource type column of the operation.
  • Condition keyword: refers to the condition keyword defined by the cloud product itself.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operate access level Resource type conditional keyword Association operation
dds:DescribePrice READ
  • MongoDB
    acs:dds:{#regionId}:{#accountId}:dbinstance/*
  • MongoDB
    acs:dds:{#regionId}:{#accountId}:dbinstance/{#dbInstanceId}
    without
without

Request parameters

Parameter Type Required Description Example
RegionId string No

The region ID of the instance. You can call the DescribeRegions operation to query the most recent region list.

cn-hangzhou
OrderType string Yes

The type of the order. Valid values:

  • BUY: instance creation
  • UPGRADE: instance configuration change
  • RENEW: instance renewal
BUY
DBInstances string Yes

A JSON string that contains the details of the ApsaraDB for MongoDB instance. For more information, see Details of the DBInstances parameter in the DescribePrice operation.

[ { "DBInstanceId":"dds-bp1b6e54e7cc****", "RegionId":"cn-hangzhou", "ZoneId":"cn-hangzhou-h", "Engine":"MongoDB", "EngineVersion":" 5.0", "DBInstanceClass":"mdb.shard.2x.xlarge.d", "DBInstanceStorage":30, "ChargeType":"PrePaid", "Period":1, "StorageType":"cloud_essd1" } ]
CommodityCode string No

The code of the cluster. Valid values:

  • dds: a replica set instance that uses the pay-as-you-go billing method
  • badds: a replica set instance that uses the subscription billing method
  • dds_sharding: a sharded cluster instance that uses the pay-as-you-go billing method
  • badds_sharding: a sharded cluster instance that uses the subscription billing method
  • badds_sharding_intl: a sharded cluster instance that uses the subscription billing method and is available on the International site (alibabacloud.com)
  • badds_sharding_jp: a sharded cluster instance that uses the subscription billing method and is available on the Japan site (jp.alibabacloud.com)
badds
ProductCode string No

The code of the service to which the instance belongs. Default value: dds.

dds
BusinessInfo string No

The business information. This is an additional parameter.

{"AccountPassword":"Pw123456","DBInstanceDescription":"test"}
CouponNo string No

The coupon code. Default value: youhuiquan_promotion_option_id_for_blank.

youhuiquan_promotion_option_id_for_blank
OrderParamOut string No

Specifies whether to return the parameters about the order. Valid values:

  • false
  • true

Default value: false.

true
ResourceGroupId string No

The ID of the resource group. For more information, see View basic information of a resource group.

rg-acfmyiu4ekp****

Response parameters

Parameter Type Description Example
object
Order object

The list of orders.

Coupons array

Details about the coupons.

object
Description string

The description of the topic.

ceshi
IsSelected string

Indicates whether the coupon was selected.

true
CouponNo string

The coupon number.

youhuiquan_promotion_option_id_for_blank
Name string

The name of the coupon.

youhuiquan111
CanPromFee number
PromotionRuleIdList array
long
PromotionOptionCode string
TargetArticleItemCodes array
string
LackForPriceBreak number
PriceBreakThreshold number
PriceBreakReduceValue number
OptionCode string
ActivityCategory string
OriginalAmount string

The original price of the order.

322.4
DiscountAmount string

The discount amount of the order.

322.4
RuleIds array

The list of one or more promotion rule IDs.

string

The ID of the rule.

2075****
TradeAmount string

The actual price of the order.

0
Currency string

The type of the currency. Valid values:

  • USD: United States dollar
  • JPY: Japanese Yen.
USD
RequestId string

The ID of the request.

27227A3D-6B86-56F3-9E03-9E60F001CE12
SubOrders array

Details about the rules that match the coupon.

object
OriginalAmount string

The original price of the order.

322.4
DiscountAmount string

The discount amount of the order.

322.4
RuleIds array

The list of one or more promotion rule IDs.

string

The ID of the rule.

2075****
TradeAmount string

The actual price of the order.

0
InstanceId string

The ID of the instance.

dds-bp1b6e54e7cc****
TraceId string

The ID of the trace.

27227A3D-6B87-56F3-9E03-9E60F001****
OrderParams string

The order parameters. This parameter is returned if the OrderParamOut parameter is set to true.

{\"autoPay\":false}"
Rules array

Details about the promotion rules.

object
RuleDescId long

The ID of the policy.

2075****
Title string

The title of the rule.

demo
Name string

The name of the rule. Valid values

demoname

Example

Normal return example

JSONFormat

{
  "Order": {
    "Coupons": {
      "Coupon": [
        {
          "Description": "ceshi",
          "IsSelected": "true",
          "CouponNo": "youhuiquan_promotion_option_id_for_blank",
          "Name": "youhuiquan111",
          "CanPromFee": 0,
          "PromotionRuleIdList": {
            "PromotionRuleId": [
              0
            ]
          },
          "PromotionOptionCode": "",
          "TargetArticleItemCodes": {
            "TargetArticleItemCode": [
              ""
            ]
          },
          "LackForPriceBreak": 0,
          "PriceBreakThreshold": 0,
          "PriceBreakReduceValue": 0,
          "OptionCode": "",
          "ActivityCategory": ""
        }
      ]
    },
    "OriginalAmount": "322.4",
    "DiscountAmount": "322.4",
    "RuleIds": {
      "RuleId": [
        "2075****"
      ]
    },
    "TradeAmount": "0",
    "Currency": "USD"
  },
  "RequestId": "27227A3D-6B86-56F3-9E03-9E60F001CE12",
  "SubOrders": {
    "SubOrder": [
      {
        "OriginalAmount": "322.4",
        "DiscountAmount": "322.4",
        "RuleIds": {
          "RuleId": [
            "2075**** "
          ]
        },
        "TradeAmount": "0",
        "InstanceId": "dds-bp1b6e54e7cc****"
      }
    ]
  },
  "TraceId": "27227A3D-6B87-56F3-9E03-9E60F001****",
  "OrderParams": "{\\\"autoPay\\\":false}\"",
  "Rules": {
    "Rule": [
      {
        "RuleDescId": 0,
        "Title": "demo",
        "Name": "demoname"
      }
    ]
  }
}

Error codes

Http code Error code Error message
400 MissingParameter Period is mandatory for this action.
400 MissingParameter DBInstanceId is mandatory for this action.
400 InvalidParam Specified parameter Period is not valid.
400 OriginPriceError Origin price error.

For a list of error codes, visit the API error center.