[英]How do I interpret the includedQuantity in Azure's rate card API?
I am trying to calculate the cost incurred on my Azure Pay-As-You-Go subscription using the usage and rate-card API's. 我正在尝试使用使用率和价目表API计算Azure随用随付订阅产生的费用。 For this I came across this parameter includedQuantity
in the rate-card API's which, according to the documentation , refers to "The resource quantity that is included in the offer at no cost. Consumption beyond this quantity will be charged." 为此,我在价目表API中遇到了这个参数includedQuantity
,据文档所述,该参数指的是“免费包含在要约中的资源数量。将收取超出此数量的消耗量。”
Consider an example, where the usageQuantity is 700 and the rate-card is as follows: 考虑一个示例,其中usageQuantity为700,价目表如下:
0 : 20
101 : 15
501 : 10
and the includedQuantity
is 200. includedQuantity
为200。
My assumption was, the calculation would be as one of the following: 我的假设是,计算将是以下之一:
Quantity = (700 - 200) = 500
Hence, cost = 100 * 20 + 400 * 15 = 8000
Quantity = (700 - 200) = 500
因此, cost = 100 * 20 + 400 * 15 = 8000
New rate card: 新价目表:
0 : 0 101 : 0 201 : 15 501 : 10
So, cost = 300 * 15 + 200 * 10 = 6500
因此, cost = 300 * 15 + 200 * 10 = 6500
I have seen this question , but it does not clarify the includedQuantity
properly. 我已经看到了这个问题 ,但它并没有明确includedQuantity
正常。
Great question! 好问题! So I checked with Azure Billing team on this and what they told me is that they will first take off the included units (200 in your example) and then apply graduated pricing on the remaining units. 因此,我就此与Azure Billing团队进行了核对,他们告诉我的是,他们将首先取下所包含的单位(在您的示例中为200),然后对其余单位采用分级定价。
Based on this, your cost would be 4500
: 基于此,您的费用为4500
:
Total units consumed: 700 Included units: 200 Tiered pricing: {0-100 = 0; 101-200 = 0; 201-500=15; 501-No Upper Limit=10}
4500 = 0 x 100 + 0 x 100 + 15 x 300
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.