简体   繁体   中英

How to get a public rate card from Azure using REST API if I have a CSP based subscription?

I tried using the below API for fetching the rate card:

https://management.azure.com/subscriptions/YOUR_SUBSCRIPTION_ID/providers/Microsoft.Commerce/RateCard?api-version=2016-08-31-preview&%24filter=OfferDurableId+eq+'MS-AZR-0003P'+and+Currency+eq+'USD'+and+Locale+eq+'en-US'+and+RegionInfo+eq+'US'"

But I was getting this error:

The operation is not permitted for namespace Microsoft.Commerce

If anyone could advise on how to fetch a public rate card from Azure using REST API, it would be really great.

Just make sure, you have registered Microsoft.Commerce (Resource provider) on your Subscription.

Follow the below link to register the resource provider:

https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/resource-providers-and-types

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM