查詢建立服務執行個體的預估價格。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
computenest:GetServiceEstimateCost |
get |
*Service
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| RegionId |
string |
否 |
地區 ID。 |
cn-hangzhou |
| ServiceId |
string |
是 |
服務 ID。 |
service-12xxxxxx |
| ServiceVersion |
string |
否 |
服務版本。 |
1 |
| TemplateName |
string |
否 |
模板名稱。 |
模板1 |
| Parameters |
object |
否 |
部署服務執行個體輸入的參數。 |
{ \"RegionId\": \"cn-hangzhou\", \"InstanceType\": \"ecs.g5.large\"} |
| ClientToken |
string |
否 |
保證請求等冪性。從您的用戶端產生一個參數值,確保不同請求間該參數值唯一。ClientToken 只支援 ASCII 字元,且不能超過 64 個字元。 |
qwertyuiop |
| TrialType |
string |
否 |
使用類型。可選值:
|
NotTrial |
| SpecificationName |
string |
否 |
套餐規格名稱。 |
套餐一 |
| ServiceInstanceId |
string |
否 |
服務執行個體 ID。 |
si-d6ab3a63ccbb4b17xxxx |
| Commodity |
object |
否 |
購買訂單時間資訊。 |
|
| PayPeriodUnit |
string |
否 |
購買時間長度的單位,可選值:
|
Year |
| PayPeriod |
integer |
否 |
購買時間長度。 |
1 |
| CouponId |
string |
否 |
優惠券 ID |
302070970220 |
| QuotationId |
string |
否 |
雲市場 PrivateOffer Id |
17cde2e8-2f5d-xxxx-xxxx-5120dd215d66 |
| OperationName |
string |
否 |
變更配置操作名稱。 |
參數變更配置 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
Schema of Response |
||
| RequestId |
string |
請求 ID。 |
08ABBB67-39C9-5EE7-98E5-80486F75CE8D |
| Resources |
object |
資源清單。 |
{ "EcsInstance" : { "Type" : "ALIYUN::ECS::Instance", "Success" : true, "Result" : { "Order" : { "Currency" : "CNY", "RuleIds" : [ "102111101338****" ], "DetailInfos" : { "ResourcePriceModel" : [ { "OriginalPrice" : 0, "DiscountPrice" : 0, "SubRules" : { "Rule" : [ ] }, "Resource" : "bandwidth", "TradePrice" : 0 }, { "OriginalPrice" : 0, "DiscountPrice" : 0, "SubRules" : { "Rule" : [ ] }, "Resource" : "image", "TradePrice" : 0 }, { "OriginalPrice" : 0.366666, "DiscountPrice" : 0.249012, "SubRules" : { "Rule" : [ ] }, "Resource" : "instanceType", "TradePrice" : 0.117654 }, { "OriginalPrice" : 0.055555, "DiscountPrice" : 0.037729, "SubRules" : { "Rule" : [ ] }, "Resource" : "systemDisk", "TradePrice" : 0.017826 } ] }, "TradeAmount" : 0.135, "OriginalAmount" : 0.422, "Coupons" : { "Coupon" : [ ] }, "DiscountAmount" : 0.287 }, "OrderSupplement" : { "PriceUnit" : "/Hour", "ChargeType" : "PostPaid", "Quantity" : 1, "PriceType" : "Total" }, "Rules" : { "Rule" : [ { "RuleDescId" : "102111101338****", "Name" : "合約優惠_多計費項目優惠_3.208750折" } ] } } } } |
|
any |
資源清單。 |
{ "EcsInstance" : { "Type" : "ALIYUN::ECS::Instance", "Success" : true, "Result" : { "Order" : { "Currency" : "CNY", "RuleIds" : [ "102111101338****" ], "DetailInfos" : { "ResourcePriceModel" : [ { "OriginalPrice" : 0, "DiscountPrice" : 0, "SubRules" : { "Rule" : [ ] }, "Resource" : "bandwidth", "TradePrice" : 0 }, { "OriginalPrice" : 0, "DiscountPrice" : 0, "SubRules" : { "Rule" : [ ] }, "Resource" : "image", "TradePrice" : 0 }, { "OriginalPrice" : 0.366666, "DiscountPrice" : 0.249012, "SubRules" : { "Rule" : [ ] }, "Resource" : "instanceType", "TradePrice" : 0.117654 }, { "OriginalPrice" : 0.055555, "DiscountPrice" : 0.037729, "SubRules" : { "Rule" : [ ] }, "Resource" : "systemDisk", "TradePrice" : 0.017826 } ] }, "TradeAmount" : 0.135, "OriginalAmount" : 0.422, "Coupons" : { "Coupon" : [ ] }, "DiscountAmount" : 0.287 }, "OrderSupplement" : { "PriceUnit" : "/Hour", "ChargeType" : "PostPaid", "Quantity" : 1, "PriceType" : "Total" }, "Rules" : { "Rule" : [ { "RuleDescId" : "102111101338****", "Name" : "合約優惠_多計費項目優惠_3.208750折" } ] } } } } |
|
| Commodity |
object |
雲市場購買訂單資訊。 |
{'cmgj00059839': {'Result': {'InquiryType': 'Buy', 'Order': {'Currency': 'CNY', 'DiscountAmount': '0.0', 'TradeAmount': '0.01', 'OriginalAmount': '0.01'}}}} |
|
object |
雲市場購買訂單資訊。 |
||
| Result |
object |
Result 模型。 |
|
| Order |
object |
訂單資訊。 |
|
| Currency |
string |
貨幣代碼。 |
CNY |
| TradeAmount |
string |
優惠後。 |
9.99 |
| DiscountAmount |
string |
抵扣金額。 |
1.99 |
| OriginalAmount |
string |
優惠前。 |
11.98 |
| InquiryType |
string |
詢價類型,可選值:
|
Buy |
| SubOrders |
object |
訂單子項。 |
|
| SubOrder |
array<object> |
訂單子項。 |
|
|
object |
訂單子項對象。 |
||
| ModuleInstance |
array<object> |
模組(執行個體)資訊。 |
|
|
object |
模組(執行個體)對象。 |
||
| ModuleId |
integer |
模組 ID。 |
1234 |
| ModuleName |
string |
模組名稱。 |
資料庫類型 |
| ModuleCode |
string |
模組代碼。 |
rds_dbtype |
| TotalProductFee |
number |
產品原價(元)。 |
10.00 |
| DiscountFee |
number |
折計費用(元)。 |
1.99 |
| PayFee |
number |
實付金額(元)。 |
8.01 |
| PriceUnit |
string |
價格單位。 |
元/GB/小時 |
| IsPricingModule |
boolean |
是否計價項。 |
true |
| NeedOrderPay |
boolean |
在訂單中是否需要支付。 |
true |
| PriceType |
string |
定價類型。 |
hourPrice |
| ModuleAttrs |
array<object> |
模組屬性。 |
|
|
object |
模組屬性對象。 |
||
| Type |
integer |
屬性類型,可選值:
|
3 |
| Name |
string |
屬性名稱 |
20GB |
| Code |
string |
屬性代碼 |
rds_storage |
| Value |
string |
屬性值 |
20 |
| Unit |
string |
值單位 |
GB |
| ModuleNameEn |
string |
模組英文名稱。 |
資料單元 |
| PriceUnitEn |
string |
價格單位英文名稱 |
元/月 |
| Coupons |
array<object> |
優惠券。 |
|
|
object |
優惠券。 |
||
| CanPromFee |
number |
可支付金額。 |
9.99 |
| CouponDesc |
string |
優惠券描述 |
10元優惠券(有效期間至2024年9月8日) |
| CouponName |
string |
優惠券名稱 |
10元優惠券 |
| CouponOptionNo |
string |
優惠券編號。 |
50008800000xxxx |
| Selected |
boolean |
是否選中。 |
true |
樣本
正常返回樣本
JSON格式
{
"RequestId": "08ABBB67-39C9-5EE7-98E5-80486F75CE8D",
"Resources": {
"key": "{\n \"EcsInstance\" : {\n \"Type\" : \"ALIYUN::ECS::Instance\",\n \"Success\" : true,\n \"Result\" : {\n \"Order\" : {\n \"Currency\" : \"CNY\",\n \"RuleIds\" : [ \"102111101338****\" ],\n \"DetailInfos\" : {\n \"ResourcePriceModel\" : [ {\n \"OriginalPrice\" : 0,\n \"DiscountPrice\" : 0,\n \"SubRules\" : {\n \"Rule\" : [ ]\n },\n \"Resource\" : \"bandwidth\",\n \"TradePrice\" : 0\n }, {\n \"OriginalPrice\" : 0,\n \"DiscountPrice\" : 0,\n \"SubRules\" : {\n \"Rule\" : [ ]\n },\n \"Resource\" : \"image\",\n \"TradePrice\" : 0\n }, {\n \"OriginalPrice\" : 0.366666,\n \"DiscountPrice\" : 0.249012,\n \"SubRules\" : {\n \"Rule\" : [ ]\n },\n \"Resource\" : \"instanceType\",\n \"TradePrice\" : 0.117654\n }, {\n \"OriginalPrice\" : 0.055555,\n \"DiscountPrice\" : 0.037729,\n \"SubRules\" : {\n \"Rule\" : [ ]\n },\n \"Resource\" : \"systemDisk\",\n \"TradePrice\" : 0.017826\n } ]\n },\n \"TradeAmount\" : 0.135,\n \"OriginalAmount\" : 0.422,\n \"Coupons\" : {\n \"Coupon\" : [ ]\n },\n \"DiscountAmount\" : 0.287\n },\n \"OrderSupplement\" : {\n \"PriceUnit\" : \"/Hour\",\n \"ChargeType\" : \"PostPaid\",\n \"Quantity\" : 1,\n \"PriceType\" : \"Total\"\n },\n \"Rules\" : {\n \"Rule\" : [ {\n \"RuleDescId\" : \"102111101338****\",\n \"Name\" : \"合約優惠_多計費項目優惠_3.208750折\"\n } ]\n }\n }\n }\n }"
},
"Commodity": {
"key": {
"Result": {
"Order": {
"Currency": "CNY",
"TradeAmount": "9.99",
"DiscountAmount": "1.99",
"OriginalAmount": "11.98"
},
"InquiryType": "Buy",
"SubOrders": {
"SubOrder": [
{
"ModuleInstance": [
{
"ModuleId": 1234,
"ModuleName": "資料庫類型",
"ModuleCode": "rds_dbtype",
"TotalProductFee": 10,
"DiscountFee": 1.99,
"PayFee": 8.01,
"PriceUnit": "元/GB/小時",
"IsPricingModule": true,
"NeedOrderPay": true,
"PriceType": "hourPrice",
"ModuleAttrs": [
{
"Type": 3,
"Name": "20GB",
"Code": "rds_storage",
"Value": "20",
"Unit": "GB"
}
],
"ModuleNameEn": "資料單元",
"PriceUnitEn": "元/月"
}
]
}
]
},
"Coupons": [
{
"CanPromFee": 9.99,
"CouponDesc": "10元優惠券(有效期間至2024年9月8日)",
"CouponName": "10元優惠券",
"CouponOptionNo": "50008800000xxxx",
"Selected": true
}
]
}
}
}
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。