Microsoft Azure

Azure Consumption

Consumption management client provides access to consumption resources for Azure Enterprise Subscriptions.

Developer tools#openapi

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

Consumption management client provides access to consumption resources for Azure Enterprise Subscriptions.

Endpoints 31

UsageDetails

  • GETUsageDetails_List/:scope/providers/Microsoft.Consumption/usageDetails?$expand=string&$filter=string&$skiptoken=string&$top=1&api-version=string&metric=actualcostLists the usage details for the defined scope. Usage details are available via this API only for May 1, 2014 or later. Note:Microsoft will be retiring the…

Marketplaces

  • GETMarketplaces_List/:scope/providers/Microsoft.Consumption/marketplaces?$filter=string&$top=1&$skiptoken=string&api-version=stringLists the marketplaces for a scope at the defined scope. Marketplaces are available via this API only for May 1, 2014 or later.

Budgets

  • GETBudgets_List/:scope/providers/Microsoft.Consumption/budgets?api-version=stringLists all budgets for the defined scope.
  • GETBudgets_Get/:scope/providers/Microsoft.Consumption/budgets/:budgetName?api-version=stringGets the budget for the scope by budget name.
  • PUTBudgets_CreateOrUpdate/:scope/providers/Microsoft.Consumption/budgets/:budgetName?api-version=stringThe operation to create or update a budget. You can optionally provide an eTag if desired as a form of concurrency control. To obtain the latest eTag for a…
  • DELETEBudgets_Delete/:scope/providers/Microsoft.Consumption/budgets/:budgetName?api-version=stringThe operation to delete a budget.

Tags

  • GETTags_Get/:scope/providers/Microsoft.Consumption/tags?api-version=stringGet all available tag keys for the defined scope

Charges

  • GETCharges_List/:scope/providers/Microsoft.Consumption/charges?api-version=string&startDate=string&endDate=string&$filter=string&$apply=stringLists the charges based for the defined scope.

Balances

  • GETBalances_GetByBillingAccount/providers/Microsoft.Billing/billingAccounts/:billingAccountId/providers/Microsoft.Consumption/balances?api-version=stringGets the balances for a scope by billingAccountId. Balances are available via this API only for May 1, 2014 or later.
  • GETBalances_GetForBillingPeriodByBillingAccount/providers/Microsoft.Billing/billingAccounts/:billingAccountId/billingPeriods/:billingPeriodName/providers/Microsoft.Consumption/balances?api-version=stringGets the balances for a scope by billing period and billingAccountId. Balances are available via this API only for May 1, 2014 or later.

ReservationSummaries

  • GETReservationsSummaries_ListByReservationOrder/providers/Microsoft.Capacity/reservationorders/:reservationOrderId/providers/Microsoft.Consumption/reservationSummaries?grain=daily&$filter=string&api-version=stringLists the reservations summaries for daily or monthly grain. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when the response size…
  • GETReservationsSummaries_ListByReservationOrderAndReservation/providers/Microsoft.Capacity/reservationorders/:reservationOrderId/reservations/:reservationId/providers/Microsoft.Consumption/reservationSummaries?grain=daily&$filter=string&api-version=stringLists the reservations summaries for daily or monthly grain. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when the response size…
  • GETReservationsSummaries_List/:resourceScope/providers/Microsoft.Consumption/reservationSummaries?grain=daily&startDate=string&endDate=string&$filter=string&reservationId=string&reservationOrderId=string&api-version=stringLists the reservations summaries for the defined scope daily or monthly grain. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when…

ReservationDetails

  • GETReservationsDetails_ListByReservationOrder/providers/Microsoft.Capacity/reservationorders/:reservationOrderId/providers/Microsoft.Consumption/reservationDetails?$filter=string&api-version=stringLists the reservations details for provided date range. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when the response size…
  • GETReservationsDetails_ListByReservationOrderAndReservation/providers/Microsoft.Capacity/reservationorders/:reservationOrderId/reservations/:reservationId/providers/Microsoft.Consumption/reservationDetails?$filter=string&api-version=stringLists the reservations details for provided date range. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when the response size…
  • GETReservationsDetails_List/:resourceScope/providers/Microsoft.Consumption/reservationDetails?startDate=string&endDate=string&$filter=string&reservationId=string&reservationOrderId=string&api-version=stringLists the reservations details for provided date range. Note: ARM has a payload size limit of 12MB, so currently callers get 400 when the response size…

ReservationRecommendations

  • GETReservationRecommendations_List/:resourceScope/providers/Microsoft.Consumption/reservationRecommendations?$filter=string&api-version=stringList of recommendations for purchasing reserved instances.

ReservationRecommendationDetails

  • GETReservationRecommendationDetails_Get/:resourceScope/providers/Microsoft.Consumption/reservationRecommendationDetails?api-version=string&scope=Single&region=string&term=P1Y&lookBackPeriod=Last7Days&product=string&$filter=stringDetails of a reservation recommendation for what-if analysis of reserved instances.

ReservationTransactions

  • GETReservationTransactions_List/providers/Microsoft.Billing/billingAccounts/:billingAccountId/providers/Microsoft.Consumption/reservationTransactions?$filter=string&api-version=string&useMarkupIfPartner=true&previewMarkupPercentage=0.0List of transactions for reserved instances on billing account scope. Note: The refund transactions are posted along with its purchase transaction (i.e. in…
  • GETReservationTransactions_ListByBillingProfile/providers/Microsoft.Billing/billingAccounts/:billingAccountId/billingProfiles/:billingProfileId/providers/Microsoft.Consumption/reservationTransactions?$filter=string&api-version=stringList of transactions for reserved instances on billing profile scope. The refund transactions are posted along with its purchase transaction (i.e. in the…

PriceSheet

  • GETPriceSheet_Get/subscriptions/:subscriptionId/providers/Microsoft.Consumption/pricesheets/default?$expand=string&$skiptoken=string&$top=1&api-version=stringGets the price sheet for a subscription. Price sheet is available via this API only for May 1, 2014 or later.
  • GETPriceSheet_GetByBillingPeriod/subscriptions/:subscriptionId/providers/Microsoft.Billing/billingPeriods/:billingPeriodName/providers/Microsoft.Consumption/pricesheets/default?$expand=string&$skiptoken=string&$top=1&api-version=stringGet the price sheet for a scope by subscriptionId and billing period. Price sheet is available via this API only for May 1, 2014 or later.

Operations

  • GETOperations_List/providers/Microsoft.Consumption/operations?api-version=stringLists all of the available consumption REST API operations.

AggregatedCost

  • GETAggregatedCost_GetByManagementGroup/providers/Microsoft.Management/managementGroups/:managementGroupId/providers/Microsoft.Consumption/aggregatedcost?api-version=string&$filter=stringProvides the aggregate cost of a management group and all child management groups by current billing period.
  • GETAggregatedCost_GetForBillingPeriodByManagementGroup/providers/Microsoft.Management/managementGroups/:managementGroupId/providers/Microsoft.Billing/billingPeriods/:billingPeriodName/providers/Microsoft.Consumption/aggregatedCost?api-version=stringProvides the aggregate cost of a management group and all child management groups by specified billing period

Events

  • GETEvents_ListByBillingProfile/providers/Microsoft.Billing/billingAccounts/:billingAccountId/billingProfiles/:billingProfileId/providers/Microsoft.Consumption/events?api-version=string&startDate=string&endDate=stringLists the events that decrements Azure credits or Microsoft Azure consumption commitment for a billing account or a billing profile for a given start and end…
  • GETEvents_ListByBillingAccount/providers/Microsoft.Billing/billingAccounts/:billingAccountId/providers/Microsoft.Consumption/events?api-version=string&$filter=stringLists the events that decrements Azure credits or Microsoft Azure consumption commitment for a billing account or a billing profile for a given start and end…

Lots

  • GETLots_ListByBillingProfile/providers/Microsoft.Billing/billingAccounts/:billingAccountId/billingProfiles/:billingProfileId/providers/Microsoft.Consumption/lots?api-version=stringLists all Azure credits for a billing account or a billing profile. The API is only supported for Microsoft Customer Agreements (MCA) billing accounts.
  • GETLots_ListByBillingAccount/providers/Microsoft.Billing/billingAccounts/:billingAccountId/providers/Microsoft.Consumption/lots?api-version=string&$filter=stringLists all Microsoft Azure consumption commitments for a billing account. The API is only supported for Microsoft Customer Agreements (MCA) and Direct…
  • GETLots_ListByCustomer/providers/Microsoft.Billing/billingAccounts/:billingAccountId/customers/:customerId/providers/Microsoft.Consumption/lots?api-version=string&$filter=stringLists all Azure credits for a customer. The API is only supported for Microsoft Partner Agreements (MPA) billing accounts.

Credits

  • GETCredits_Get/providers/Microsoft.Billing/billingAccounts/:billingAccountId/billingProfiles/:billingProfileId/providers/Microsoft.Consumption/credits/balanceSummary?api-version=stringThe credit summary by billingAccountId and billingProfileId.

API details

Base URL
https://management.azure.com
Authentication
OAuth 2.0 (implicit flow) with 1 scope
Operations
31 operations on 29 pathsGET 29PUT 1DELETE 1
Main resources
Budgets 4Lots 3ReservationDetails 3ReservationSummaries 3AggregatedCost 2Balances 2Events 2PriceSheet 2ReservationTransactions 2Charges 1
Response formats
application/json
Description format
Swagger 2.0, API version 2023-11-01

How to test the Azure Consumption in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the Azure Consumption collection, without the publisher's secrets.
  3. Add your credentialsThis API uses OAuth 2.0 (implicit flow) with 1 scope. Add yours in the collection's variables or an environment; the requests already reference it.
  4. Send a requestPick an endpoint, for example “UsageDetails_List” (GET /:scope/providers/Microsoft.Consumption/usageDetails?$expand=string&$filter=string&$skiptoken=string&$top=1&api-version=string&metric=actualcost), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the Azure Consumption?

Consumption management client provides access to consumption resources for Azure Enterprise Subscriptions. It is listed under Developer tools and has 31 endpoints.

Who publishes the Azure Consumption?

It is listed from Microsoft Azure's public API description (an OpenAPI document), not published by Microsoft Azure on Swastik Codes. Anyone who controls azure.com can claim the profile by adding a DNS TXT record.

What is the base URL of the Azure Consumption?

Requests go to https://management.azure.com. Endpoint paths are added to this base URL.

How do I authenticate with the Azure Consumption?

With OAuth 2.0 (implicit flow) with 1 scope.

How many endpoints does the Azure Consumption have?

31 operations on 29 paths (29 GET, 1 PUT, 1 DELETE). The largest groups are Budgets, Lots, ReservationDetails, ReservationSummaries.

Is forking the Azure Consumption free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.