Azure Retail Pricing API shows different USD prices for Virtual Machines compared to the prices on azure.microsoft.com/en-us/pricing/calculator/

Anastasiia Ilina 71 Reputation points
2021-08-31T15:50:14.547+00:00

I would like to get the price of the VM via the Pricing API, but when I compare this price with the price on the pricing/calculator and on the portal - the API price is different. 127919-pricing-calculator.png

When I call the Pricing API by https://prices.azure.com/api/retail/prices?currencyCode='USD'&$filter=armSkuName eq 'Standard_D4s_v3' and armRegionName eq 'westus' and priceType eq 'Consumption'
I expect to get the same result, but it is different:
{
"BillingCurrency": "USD",
"CustomerEntityId": "Default",
"CustomerEntityType": "Retail",
"Items": [
{
"currencyCode": "USD",
"tierMinimumUnits": 0.0,
"retailPrice": 0.074786,
"unitPrice": 0.074786,
"armRegionName": "westus",
"location": "US West",
"effectiveStartDate": "2021-08-01T00:00:00Z",
"effectiveEndDate": "2021-08-31T23:59:00Z",
"meterId": "4495574c-fccf-5c8c-8190-2c822a0c7e6f",
"meterName": "D4s v3 Spot",
"productId": "DZH318Z0BQ50",
"skuId": "DZH318Z0BQ50/01T3",
"productName": "Virtual Machines DSv3 Series",
"skuName": "D4s v3 Spot",
"serviceName": "Virtual Machines",
"serviceId": "DZH313Z7MMC8",
"serviceFamily": "Compute",
"unitOfMeasure": "1 Hour",
"type": "Consumption",
"isPrimaryMeterRegion": true,
"armSkuName": "Standard_D4s_v3"
},
{
"currencyCode": "USD",
"tierMinimumUnits": 0.0,
"retailPrice": 0.187013,
"unitPrice": 0.187013,
"armRegionName": "westus",
"location": "US West",
"effectiveStartDate": "2021-08-01T00:00:00Z",
"effectiveEndDate": "2021-08-31T23:59:00Z",
"meterId": "947dfc0d-a1a2-5f28-bdbc-8e788b79185b",
"meterName": "D4s v3 Spot",
"productId": "DZH318Z0BPWD",
"skuId": "DZH318Z0BPWD/0117",
"productName": "Virtual Machines DSv3 Series Windows",
"skuName": "D4s v3 Spot",
"serviceName": "Virtual Machines",
"serviceId": "DZH313Z7MMC8",
"serviceFamily": "Compute",
"unitOfMeasure": "1 Hour",
"type": "Consumption",
"isPrimaryMeterRegion": true,
"armSkuName": "Standard_D4s_v3"
}
],
"NextPageLink": null,
"Count": 2
}

I will be grateful for your help. Thank you!

Azure Cost Management
Azure Cost Management
A Microsoft offering that enables tracking of cloud usage and expenditures for Azure and other cloud providers.
3,614 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. SadiqhAhmed-MSFT 49,331 Reputation points Microsoft Employee Moderator
    2021-09-02T06:38:13.487+00:00

    @Anastasiia Ilina - The API response you pasted above are for spot pricing (highlighted below).

    I did a quick check for the meter that has 0.234 price point in west US – and I think D4 v3 and D4s v3 both emit the same meterId. Meter Ids are reliable way to triangulate the price point for reconciliation point of view. Can you please explain what you are trying to do between the ACOM pricing experiences and the API response?

    https://prices.azure.com/api/retail/prices?currencyCode=%27USD%27&$filter=armRegionName eq %27westus%27 and priceType eq %27Consumption%27 and retailPrice eq 0.234
    {
    "BillingCurrency": "USD",
    "CustomerEntityId": "Default",
    "CustomerEntityType": "Retail",
    "Items": [
    {
    "currencyCode": "USD",
    "tierMinimumUnits": 0,
    "retailPrice": 0.234,
    "unitPrice": 0.234,
    "armRegionName": "westus",
    "location": "US West",
    "effectiveStartDate": "2017-07-21T00:00:00Z",
    "meterId": "8462aa11-a392-4ae4-87cf-2dbabe31d487",
    "meterName": "D4 v3/D4s v3",
    "productId": "DZH318Z0BQ4K",
    "skuId": "DZH318Z0BQ4K/00ST",
    "productName": "Virtual Machines Dv3 Series",
    "skuName": "D4 v3",
    "serviceName": "Virtual Machines",
    "serviceId": "DZH313Z7MMC8",
    "serviceFamily": "Compute",
    "unitOfMeasure": "1 Hour",
    "type": "Consumption",
    "isPrimaryMeterRegion": true,
    "armSkuName": "Standard_D4_v3"
    }
    ],
    "NextPageLink": null,
    "Count": 1
    }

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.