diff --git a/sdk/consumption/arm-consumption/LICENSE.txt b/sdk/consumption/arm-consumption/LICENSE.txt
new file mode 100644
index 000000000000..b73b4a1293c3
--- /dev/null
+++ b/sdk/consumption/arm-consumption/LICENSE.txt
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2019 Microsoft
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/sdk/consumption/arm-consumption/README.md b/sdk/consumption/arm-consumption/README.md
new file mode 100644
index 000000000000..a86d6b2d28b3
--- /dev/null
+++ b/sdk/consumption/arm-consumption/README.md
@@ -0,0 +1,108 @@
+## Azure ConsumptionManagementClient SDK for JavaScript
+
+This package contains an isomorphic SDK for ConsumptionManagementClient.
+
+### Currently supported environments
+
+- Node.js version 6.x.x or higher
+- Browser JavaScript
+
+### How to Install
+
+```bash
+npm install @azure/arm-consumption
+```
+
+### How to use
+
+#### nodejs - Authentication, client creation and list usageDetails as an example written in TypeScript.
+
+##### Install @azure/ms-rest-nodeauth
+
+```bash
+npm install @azure/ms-rest-nodeauth
+```
+
+##### Sample code
+
+```typescript
+import * as msRest from "@azure/ms-rest-js";
+import * as msRestAzure from "@azure/ms-rest-azure-js";
+import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
+import { ConsumptionManagementClient, ConsumptionManagementModels, ConsumptionManagementMappers } from "@azure/arm-consumption";
+const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];
+
+msRestNodeAuth.interactiveLogin().then((creds) => {
+ const client = new ConsumptionManagementClient(creds, subscriptionId);
+ const scope = "testscope";
+ const expand = "testexpand";
+ const filter = "testfilter";
+ const skiptoken = "testskiptoken";
+ const top = 1;
+ const metric = "actualcost";
+ client.usageDetails.list(scope, expand, filter, skiptoken, top, metric).then((result) => {
+ console.log("The result is:");
+ console.log(result);
+ });
+}).catch((err) => {
+ console.error(err);
+});
+```
+
+#### browser - Authentication, client creation and list usageDetails as an example written in JavaScript.
+
+##### Install @azure/ms-rest-browserauth
+
+```bash
+npm install @azure/ms-rest-browserauth
+```
+
+##### Sample code
+
+See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to Azure in the browser.
+
+- index.html
+```html
+
+
+
+ @azure/arm-consumption sample
+
+
+
+
+
+
+
+
+```
+
+## Related projects
+
+- [Microsoft Azure SDK for Javascript](https://github.com/Azure/azure-sdk-for-js)
diff --git a/sdk/consumption/arm-consumption/lib/consumptionManagementClient.ts b/sdk/consumption/arm-consumption/lib/consumptionManagementClient.ts
new file mode 100644
index 000000000000..69cf15fc8a2e
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/consumptionManagementClient.ts
@@ -0,0 +1,66 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "./models";
+import * as Mappers from "./models/mappers";
+import * as operations from "./operations";
+import { ConsumptionManagementClientContext } from "./consumptionManagementClientContext";
+
+
+class ConsumptionManagementClient extends ConsumptionManagementClientContext {
+ // Operation groups
+ usageDetails: operations.UsageDetails;
+ marketplaces: operations.Marketplaces;
+ budgets: operations.Budgets;
+ tags: operations.Tags;
+ charges: operations.Charges;
+ balances: operations.Balances;
+ reservationsSummaries: operations.ReservationsSummaries;
+ reservationsDetails: operations.ReservationsDetails;
+ reservationRecommendations: operations.ReservationRecommendations;
+ priceSheet: operations.PriceSheet;
+ forecasts: operations.Forecasts;
+ operations: operations.Operations;
+ aggregatedCost: operations.AggregatedCost;
+
+ /**
+ * Initializes a new instance of the ConsumptionManagementClient class.
+ * @param credentials Credentials needed for the client to connect to Azure.
+ * @param subscriptionId Azure Subscription ID.
+ * @param [options] The parameter options
+ */
+ constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.ConsumptionManagementClientOptions) {
+ super(credentials, subscriptionId, options);
+ this.usageDetails = new operations.UsageDetails(this);
+ this.marketplaces = new operations.Marketplaces(this);
+ this.budgets = new operations.Budgets(this);
+ this.tags = new operations.Tags(this);
+ this.charges = new operations.Charges(this);
+ this.balances = new operations.Balances(this);
+ this.reservationsSummaries = new operations.ReservationsSummaries(this);
+ this.reservationsDetails = new operations.ReservationsDetails(this);
+ this.reservationRecommendations = new operations.ReservationRecommendations(this);
+ this.priceSheet = new operations.PriceSheet(this);
+ this.forecasts = new operations.Forecasts(this);
+ this.operations = new operations.Operations(this);
+ this.aggregatedCost = new operations.AggregatedCost(this);
+ }
+}
+
+// Operation Specifications
+
+export {
+ ConsumptionManagementClient,
+ ConsumptionManagementClientContext,
+ Models as ConsumptionManagementModels,
+ Mappers as ConsumptionManagementMappers
+};
+export * from "./operations";
diff --git a/sdk/consumption/arm-consumption/lib/consumptionManagementClientContext.ts b/sdk/consumption/arm-consumption/lib/consumptionManagementClientContext.ts
new file mode 100644
index 000000000000..273c0680ae50
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/consumptionManagementClientContext.ts
@@ -0,0 +1,62 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as Models from "./models";
+import * as msRest from "@azure/ms-rest-js";
+import * as msRestAzure from "@azure/ms-rest-azure-js";
+
+const packageName = "@azure/arm-consumption";
+const packageVersion = "6.3.0";
+
+export class ConsumptionManagementClientContext extends msRestAzure.AzureServiceClient {
+ credentials: msRest.ServiceClientCredentials;
+ apiVersion?: string;
+ subscriptionId: string;
+
+ /**
+ * Initializes a new instance of the ConsumptionManagementClient class.
+ * @param credentials Credentials needed for the client to connect to Azure.
+ * @param subscriptionId Azure Subscription ID.
+ * @param [options] The parameter options
+ */
+ constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.ConsumptionManagementClientOptions) {
+ if (credentials == undefined) {
+ throw new Error('\'credentials\' cannot be null.');
+ }
+ if (subscriptionId == undefined) {
+ throw new Error('\'subscriptionId\' cannot be null.');
+ }
+
+ if (!options) {
+ options = {};
+ }
+ if(!options.userAgent) {
+ const defaultUserAgent = msRestAzure.getDefaultUserAgentValue();
+ options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
+ }
+
+ super(credentials, options);
+
+ this.apiVersion = '2019-04-01-preview';
+ this.acceptLanguage = 'en-US';
+ this.longRunningOperationRetryTimeout = 30;
+ this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
+ this.requestContentType = "application/json; charset=utf-8";
+ this.credentials = credentials;
+ this.subscriptionId = subscriptionId;
+
+ if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
+ this.acceptLanguage = options.acceptLanguage;
+ }
+ if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
+ this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout;
+ }
+ }
+}
diff --git a/sdk/consumption/arm-consumption/lib/models/aggregatedCostMappers.ts b/sdk/consumption/arm-consumption/lib/models/aggregatedCostMappers.ts
new file mode 100644
index 000000000000..7a19056107ac
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/aggregatedCostMappers.ts
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ManagementGroupAggregatedCostResult,
+ Resource,
+ BaseResource,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/balancesMappers.ts b/sdk/consumption/arm-consumption/lib/models/balancesMappers.ts
new file mode 100644
index 000000000000..1d78daca1074
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/balancesMappers.ts
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ Balance,
+ Resource,
+ BaseResource,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/budgetsMappers.ts b/sdk/consumption/arm-consumption/lib/models/budgetsMappers.ts
new file mode 100644
index 000000000000..679b0cd9cf04
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/budgetsMappers.ts
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ BudgetsListResult,
+ Budget,
+ ProxyResource,
+ BaseResource,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification,
+ ErrorResponse,
+ ErrorDetails,
+ TagsResult,
+ Tag,
+ Resource,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/chargesMappers.ts b/sdk/consumption/arm-consumption/lib/models/chargesMappers.ts
new file mode 100644
index 000000000000..b2b53fb9c102
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/chargesMappers.ts
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ChargeSummary,
+ Resource,
+ BaseResource,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/forecastsMappers.ts b/sdk/consumption/arm-consumption/lib/models/forecastsMappers.ts
new file mode 100644
index 000000000000..9e6f0ba4b24e
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/forecastsMappers.ts
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ForecastsListResult,
+ Forecast,
+ Resource,
+ BaseResource,
+ ForecastPropertiesConfidenceLevelsItem,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/index.ts b/sdk/consumption/arm-consumption/lib/models/index.ts
new file mode 100644
index 000000000000..89e7b7867063
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/index.ts
@@ -0,0 +1,2740 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import { BaseResource, CloudError, AzureServiceClientOptions } from "@azure/ms-rest-azure-js";
+import * as msRest from "@azure/ms-rest-js";
+
+export { BaseResource, CloudError };
+
+
+/**
+ * @interface
+ * An interface representing MeterDetails.
+ * The properties of the meter detail.
+ *
+ */
+export interface MeterDetails {
+ /**
+ * @member {string} [meterName] The name of the meter, within the given meter
+ * category
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterName?: string;
+ /**
+ * @member {string} [meterCategory] The category of the meter, for example,
+ * 'Cloud services', 'Networking', etc..
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterCategory?: string;
+ /**
+ * @member {string} [meterSubCategory] The subcategory of the meter, for
+ * example, 'A6 Cloud services', 'ExpressRoute (IXP)', etc..
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterSubCategory?: string;
+ /**
+ * @member {string} [unit] The unit in which the meter consumption is
+ * charged, for example, 'Hours', 'GB', etc.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unit?: string;
+ /**
+ * @member {string} [meterLocation] The location in which the Azure service
+ * is available.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterLocation?: string;
+ /**
+ * @member {number} [totalIncludedQuantity] The total included quantity
+ * associated with the offer.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly totalIncludedQuantity?: number;
+ /**
+ * @member {number} [pretaxStandardRate] The pretax listing price.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly pretaxStandardRate?: number;
+ /**
+ * @member {string} [serviceName] The name of the service.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceName?: string;
+ /**
+ * @member {string} [serviceTier] The service tier.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceTier?: string;
+}
+
+/**
+ * @interface
+ * An interface representing MeterDetailsResponse.
+ * The properties of the meter detail.
+ *
+ */
+export interface MeterDetailsResponse {
+ /**
+ * @member {string} [meterName] The name of the meter, within the given meter
+ * category
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterName?: string;
+ /**
+ * @member {string} [meterCategory] The category of the meter, for example,
+ * 'Cloud services', 'Networking', etc..
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterCategory?: string;
+ /**
+ * @member {string} [meterSubCategory] The subcategory of the meter, for
+ * example, 'A6 Cloud services', 'ExpressRoute (IXP)', etc..
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterSubCategory?: string;
+ /**
+ * @member {string} [unitOfMeasure] The unit in which the meter consumption
+ * is charged, for example, 'Hours', 'GB', etc.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unitOfMeasure?: string;
+ /**
+ * @member {string} [serviceFamily] The service family.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceFamily?: string;
+}
+
+/**
+ * @interface
+ * An interface representing Resource.
+ * The Resource model definition.
+ *
+ * @extends BaseResource
+ */
+export interface Resource extends BaseResource {
+ /**
+ * @member {string} [id] Resource Id.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly id?: string;
+ /**
+ * @member {string} [name] Resource name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {string} [type] Resource type.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly type?: string;
+ /**
+ * @member {{ [propertyName: string]: string }} [tags] Resource tags.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly tags?: { [propertyName: string]: string };
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetail.
+ * An usage detail resource.
+ *
+ * @extends Resource
+ */
+export interface UsageDetail extends Resource {
+ /**
+ * @member {string} [billingAccountId] Billing Account identifier.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingAccountId?: string;
+ /**
+ * @member {string} [billingAccountName] Billing Account Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingAccountName?: string;
+ /**
+ * @member {Date} [billingPeriodStartDate] The billing period start date.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodStartDate?: Date;
+ /**
+ * @member {Date} [billingPeriodEndDate] The billing period end date.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodEndDate?: Date;
+ /**
+ * @member {string} [billingProfileId] Billing Profile identifier.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingProfileId?: string;
+ /**
+ * @member {string} [billingProfileName] Billing Profile Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingProfileName?: string;
+ /**
+ * @member {string} [accountOwnerId] Account Owner Id.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly accountOwnerId?: string;
+ /**
+ * @member {string} [accountName] Account Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly accountName?: string;
+ /**
+ * @member {string} [subscriptionId] Subscription guid.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly subscriptionId?: string;
+ /**
+ * @member {string} [subscriptionName] Subscription name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly subscriptionName?: string;
+ /**
+ * @member {Date} [date] Date for the usage record.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly date?: Date;
+ /**
+ * @member {string} [product] Product name for the consumed service or
+ * purchase. Not available for Marketplace.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly product?: string;
+ /**
+ * @member {string} [partNumber] Part Number of the service used. Can be used
+ * to join with the price sheet. Not available for marketplace.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly partNumber?: string;
+ /**
+ * @member {string} [meterId] The meter id (GUID). Not available for
+ * marketplace. For reserved instance this represents the primary meter for
+ * which the reservation was purchased. For the actual VM Size for which the
+ * reservation is purchased see productOrderName.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterId?: string;
+ /**
+ * @member {MeterDetailsResponse} [meterDetails] The details about the meter.
+ * By default this is not populated, unless it's specified in $expand.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterDetails?: MeterDetailsResponse;
+ /**
+ * @member {number} [quantity] The usage quantity.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly quantity?: number;
+ /**
+ * @member {number} [effectivePrice] Effective Price that’s charged for the
+ * usage.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly effectivePrice?: number;
+ /**
+ * @member {number} [cost] The amount of cost before tax.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly cost?: number;
+ /**
+ * @member {number} [unitPrice] Unit Price is the price applicable to you.
+ * (your EA or other contract price).
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unitPrice?: number;
+ /**
+ * @member {string} [billingCurrency] Billing Currency.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingCurrency?: string;
+ /**
+ * @member {string} [resourceLocation] Resource Location.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceLocation?: string;
+ /**
+ * @member {string} [consumedService] Consumed service name. Name of the
+ * azure resource provider that emits the usage or was purchased. This value
+ * is not provided for marketplace usage.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly consumedService?: string;
+ /**
+ * @member {string} [resourceId] Azure resource manager resource identifier.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceId?: string;
+ /**
+ * @member {string} [resourceName] Resource Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceName?: string;
+ /**
+ * @member {string} [serviceInfo1] Service Info 1.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceInfo1?: string;
+ /**
+ * @member {string} [serviceInfo2] Service Info 2.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceInfo2?: string;
+ /**
+ * @member {string} [additionalInfo] Additional details of this usage item.
+ * By default this is not populated, unless it's specified in $expand. Use
+ * this field to get usage line item specific details such as the actual VM
+ * Size (ServiceType) or the ratio in which the reservation discount is
+ * applied.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly additionalInfo?: string;
+ /**
+ * @member {string} [invoiceSection] Invoice Section Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly invoiceSection?: string;
+ /**
+ * @member {string} [costCenter] The cost center of this department if it is
+ * a department and a cost center is provided.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly costCenter?: string;
+ /**
+ * @member {string} [resourceGroup] Resource Group Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceGroup?: string;
+ /**
+ * @member {string} [reservationId] ARM resource id of the reservation. Only
+ * applies to records relevant to reservations.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationId?: string;
+ /**
+ * @member {string} [reservationName] User provided display name of the
+ * reservation. Last known name for a particular day is populated in the
+ * daily data. Only applies to records relevant to reservations.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationName?: string;
+ /**
+ * @member {string} [productOrderId] Product Order Id. For reservations this
+ * is the Reservation Order ID.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly productOrderId?: string;
+ /**
+ * @member {string} [productOrderName] Product Order Name. For reservations
+ * this is the SKU that was purchased.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly productOrderName?: string;
+ /**
+ * @member {string} [offerId] Offer Id. Ex: MS-AZR-0017P, MS-AZR-0148P.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly offerId?: string;
+ /**
+ * @member {boolean} [isAzureCreditEligible] Is Azure Credit Eligible.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly isAzureCreditEligible?: boolean;
+ /**
+ * @member {string} [term] Term (in months). 1 month for monthly recurring
+ * purchase. 12 months for a 1 year reservation. 36 months for a 3 year
+ * reservation.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly term?: string;
+ /**
+ * @member {string} [publisherName] Publisher Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly publisherName?: string;
+ /**
+ * @member {string} [publisherType] Publisher Type.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly publisherType?: string;
+ /**
+ * @member {string} [planName] Plan Name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly planName?: string;
+ /**
+ * @member {string} [chargeType] Indicates a charge represents credits,
+ * usage, a Marketplace purchase, a reservation fee, or a refund.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly chargeType?: string;
+ /**
+ * @member {string} [frequency] Indicates how frequently this charge will
+ * occur. OneTime for purchases which only happen once, Monthly for fees
+ * which recur every month, and UsageBased for charges based on how much a
+ * service is used.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly frequency?: string;
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetailsDownloadResponse.
+ * Download response of Usage Details.
+ *
+ * @extends Resource
+ */
+export interface UsageDetailsDownloadResponse extends Resource {
+ /**
+ * @member {string} [downloadUrl] The URL to the csv file.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly downloadUrl?: string;
+ /**
+ * @member {string} [validTill] The time in UTC at which this download URL
+ * will expire.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly validTill?: string;
+}
+
+/**
+ * @interface
+ * An interface representing Marketplace.
+ * An marketplace resource.
+ *
+ * @extends Resource
+ */
+export interface Marketplace extends Resource {
+ /**
+ * @member {string} [billingPeriodId] The id of the billing period resource
+ * that the usage belongs to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodId?: string;
+ /**
+ * @member {Date} [usageStart] The start of the date time range covered by
+ * the usage detail.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageStart?: Date;
+ /**
+ * @member {Date} [usageEnd] The end of the date time range covered by the
+ * usage detail.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageEnd?: Date;
+ /**
+ * @member {number} [resourceRate] The marketplace resource rate.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceRate?: number;
+ /**
+ * @member {string} [offerName] The type of offer.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly offerName?: string;
+ /**
+ * @member {string} [resourceGroup] The name of resource group.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resourceGroup?: string;
+ /**
+ * @member {string} [orderNumber] The order number.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly orderNumber?: string;
+ /**
+ * @member {string} [instanceName] The name of the resource instance that the
+ * usage is about.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly instanceName?: string;
+ /**
+ * @member {string} [instanceId] The uri of the resource instance that the
+ * usage is about.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly instanceId?: string;
+ /**
+ * @member {string} [currency] The ISO currency in which the meter is
+ * charged, for example, USD.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currency?: string;
+ /**
+ * @member {number} [consumedQuantity] The quantity of usage.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly consumedQuantity?: number;
+ /**
+ * @member {string} [unitOfMeasure] The unit of measure.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unitOfMeasure?: string;
+ /**
+ * @member {number} [pretaxCost] The amount of cost before tax.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly pretaxCost?: number;
+ /**
+ * @member {boolean} [isEstimated] The estimated usage is subject to change.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly isEstimated?: boolean;
+ /**
+ * @member {string} [meterId] The meter id (GUID).
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterId?: string;
+ /**
+ * @member {string} [subscriptionGuid] Subscription guid.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly subscriptionGuid?: string;
+ /**
+ * @member {string} [subscriptionName] Subscription name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly subscriptionName?: string;
+ /**
+ * @member {string} [accountName] Account name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly accountName?: string;
+ /**
+ * @member {string} [departmentName] Department name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly departmentName?: string;
+ /**
+ * @member {string} [consumedService] Consumed service name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly consumedService?: string;
+ /**
+ * @member {string} [costCenter] The cost center of this department if it is
+ * a department and a costcenter exists
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly costCenter?: string;
+ /**
+ * @member {string} [additionalProperties] Additional details of this usage
+ * item. By default this is not populated, unless it's specified in $expand.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly additionalProperties?: string;
+ /**
+ * @member {string} [publisherName] The name of publisher.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly publisherName?: string;
+ /**
+ * @member {string} [planName] The name of plan.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly planName?: string;
+ /**
+ * @member {boolean} [isRecurringCharge] Flag indicating whether this is a
+ * recurring charge or not.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly isRecurringCharge?: boolean;
+}
+
+/**
+ * @interface
+ * An interface representing BalancePropertiesNewPurchasesDetailsItem.
+ */
+export interface BalancePropertiesNewPurchasesDetailsItem {
+ /**
+ * @member {string} [name] the name of new purchase.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {number} [value] the value of new purchase.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly value?: number;
+}
+
+/**
+ * @interface
+ * An interface representing BalancePropertiesAdjustmentDetailsItem.
+ */
+export interface BalancePropertiesAdjustmentDetailsItem {
+ /**
+ * @member {string} [name] the name of new adjustment.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {number} [value] the value of new adjustment.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly value?: number;
+}
+
+/**
+ * @interface
+ * An interface representing Balance.
+ * A balance resource.
+ *
+ * @extends Resource
+ */
+export interface Balance extends Resource {
+ /**
+ * @member {string} [currency] The ISO currency in which the meter is
+ * charged, for example, USD.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currency?: string;
+ /**
+ * @member {number} [beginningBalance] The beginning balance for the billing
+ * period.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly beginningBalance?: number;
+ /**
+ * @member {number} [endingBalance] The ending balance for the billing period
+ * (for open periods this will be updated daily).
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly endingBalance?: number;
+ /**
+ * @member {number} [newPurchases] Total new purchase amount.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly newPurchases?: number;
+ /**
+ * @member {number} [adjustments] Total adjustment amount.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly adjustments?: number;
+ /**
+ * @member {number} [utilized] Total Commitment usage.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly utilized?: number;
+ /**
+ * @member {number} [serviceOverage] Overage for Azure services.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly serviceOverage?: number;
+ /**
+ * @member {number} [chargesBilledSeparately] Charges Billed separately.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly chargesBilledSeparately?: number;
+ /**
+ * @member {number} [totalOverage] serviceOverage + chargesBilledSeparately.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly totalOverage?: number;
+ /**
+ * @member {number} [totalUsage] Azure service commitment + total Overage.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly totalUsage?: number;
+ /**
+ * @member {number} [azureMarketplaceServiceCharges] Total charges for Azure
+ * Marketplace.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly azureMarketplaceServiceCharges?: number;
+ /**
+ * @member {BillingFrequency} [billingFrequency] The billing frequency.
+ * Possible values include: 'Month', 'Quarter', 'Year'
+ */
+ billingFrequency?: BillingFrequency;
+ /**
+ * @member {boolean} [priceHidden] Price is hidden or not.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly priceHidden?: boolean;
+ /**
+ * @member {BalancePropertiesNewPurchasesDetailsItem[]} [newPurchasesDetails]
+ * List of new purchases.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly newPurchasesDetails?: BalancePropertiesNewPurchasesDetailsItem[];
+ /**
+ * @member {BalancePropertiesAdjustmentDetailsItem[]} [adjustmentDetails]
+ * List of Adjustments (Promo credit, SIE credit etc.).
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly adjustmentDetails?: BalancePropertiesAdjustmentDetailsItem[];
+}
+
+/**
+ * @interface
+ * An interface representing ReservationSummary.
+ * reservation summary resource.
+ *
+ * @extends Resource
+ */
+export interface ReservationSummary extends Resource {
+ /**
+ * @member {string} [reservationOrderId] The reservation order ID is the
+ * identifier for a reservation purchase. Each reservation order ID
+ * represents a single purchase transaction. A reservation order contains
+ * reservations. The reservation order specifies the VM size and region for
+ * the reservations.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationOrderId?: string;
+ /**
+ * @member {string} [reservationId] The reservation ID is the identifier of a
+ * reservation within a reservation order. Each reservation is the grouping
+ * for applying the benefit scope and also specifies the number of instances
+ * to which the reservation benefit can be applied to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationId?: string;
+ /**
+ * @member {string} [skuName] This is the ARM Sku name. It can be used to
+ * join with the serviceType field in additional info in usage records.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly skuName?: string;
+ /**
+ * @member {number} [reservedHours] This is the total hours reserved. E.g. if
+ * reservation for 1 instance was made on 1 PM, this will be 11 hours for
+ * that day and 24 hours from subsequent days
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservedHours?: number;
+ /**
+ * @member {Date} [usageDate] Data corresponding to the utilization record.
+ * If the grain of data is monthly, it will be first day of month.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageDate?: Date;
+ /**
+ * @member {number} [usedHours] Total used hours by the reservation
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usedHours?: number;
+ /**
+ * @member {number} [minUtilizationPercentage] This is the minimum hourly
+ * utilization in the usage time (day or month). E.g. if usage record
+ * corresponds to 12/10/2017 and on that for hour 4 and 5, utilization was
+ * 10%, this field will return 10% for that day
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly minUtilizationPercentage?: number;
+ /**
+ * @member {number} [avgUtilizationPercentage] This is average utilization
+ * for the entire time range. (day or month depending on the grain)
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly avgUtilizationPercentage?: number;
+ /**
+ * @member {number} [maxUtilizationPercentage] This is the maximum hourly
+ * utilization in the usage time (day or month). E.g. if usage record
+ * corresponds to 12/10/2017 and on that for hour 4 and 5, utilization was
+ * 100%, this field will return 100% for that day.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly maxUtilizationPercentage?: number;
+}
+
+/**
+ * @interface
+ * An interface representing ReservationDetail.
+ * reservation detail resource.
+ *
+ * @extends Resource
+ */
+export interface ReservationDetail extends Resource {
+ /**
+ * @member {string} [reservationOrderId] The reservation order ID is the
+ * identifier for a reservation purchase. Each reservation order ID
+ * represents a single purchase transaction. A reservation order contains
+ * reservations. The reservation order specifies the VM size and region for
+ * the reservations.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationOrderId?: string;
+ /**
+ * @member {string} [reservationId] The reservation ID is the identifier of a
+ * reservation within a reservation order. Each reservation is the grouping
+ * for applying the benefit scope and also specifies the number of instances
+ * to which the reservation benefit can be applied to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservationId?: string;
+ /**
+ * @member {string} [skuName] This is the ARM Sku name. It can be used to
+ * join with the serviceType field in additional info in usage records.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly skuName?: string;
+ /**
+ * @member {number} [reservedHours] This is the total hours reserved for the
+ * day. E.g. if reservation for 1 instance was made on 1 PM, this will be 11
+ * hours for that day and 24 hours from subsequent days.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly reservedHours?: number;
+ /**
+ * @member {Date} [usageDate] The date on which consumption occurred.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageDate?: Date;
+ /**
+ * @member {number} [usedHours] This is the total hours used by the instance.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usedHours?: number;
+ /**
+ * @member {string} [instanceId] This identifier is the name of the resource
+ * or the fully qualified Resource ID.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly instanceId?: string;
+ /**
+ * @member {number} [totalReservedQuantity] This is the total count of
+ * instances that are reserved for the reservationId.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly totalReservedQuantity?: number;
+}
+
+/**
+ * @interface
+ * An interface representing ReservationRecommendation.
+ * Reservation recommendation resource.
+ *
+ */
+export interface ReservationRecommendation {
+ /**
+ * @member {string} [id] Resource Id.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly id?: string;
+ /**
+ * @member {string} [name] Resource name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {string} [type] Resource type.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly type?: string;
+ /**
+ * @member {{ [propertyName: string]: string }} [tags] Resource tags.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly tags?: { [propertyName: string]: string };
+ /**
+ * @member {string} [location] Resource location
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly location?: string;
+ /**
+ * @member {string} [sku] Resource sku
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly sku?: string;
+ /**
+ * @member {string} [lookBackPeriod] The number of days of usage to look back
+ * for recommendation.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly lookBackPeriod?: string;
+ /**
+ * @member {string} [meterId] The meter id (GUID)
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterId?: string;
+ /**
+ * @member {string} [term] RI recommendations in one or three year terms.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly term?: string;
+ /**
+ * @member {number} [costWithNoReservedInstances] The total amount of cost
+ * without reserved instances.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly costWithNoReservedInstances?: number;
+ /**
+ * @member {number} [recommendedQuantity] Recommended quality for reserved
+ * instances.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly recommendedQuantity?: number;
+ /**
+ * @member {number} [totalCostWithReservedInstances] The total amount of cost
+ * with reserved instances.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly totalCostWithReservedInstances?: number;
+ /**
+ * @member {number} [netSavings] Total estimated savings with reserved
+ * instances.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly netSavings?: number;
+ /**
+ * @member {Date} [firstUsageDate] The usage date for looking back.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly firstUsageDate?: Date;
+ /**
+ * @member {string} [scope] Shared or single recommendation.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly scope?: string;
+}
+
+/**
+ * @interface
+ * An interface representing Tag.
+ * The tag resource.
+ *
+ */
+export interface Tag {
+ /**
+ * @member {string} [key] Tag key.
+ */
+ key?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ProxyResource.
+ * The Resource model definition.
+ *
+ * @extends BaseResource
+ */
+export interface ProxyResource extends BaseResource {
+ /**
+ * @member {string} [id] Resource Id.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly id?: string;
+ /**
+ * @member {string} [name] Resource name.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {string} [type] Resource type.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly type?: string;
+ /**
+ * @member {string} [eTag] eTag of the resource. To handle concurrent update
+ * scenario, this field will be used to determine whether the user is
+ * updating the latest version or not.
+ */
+ eTag?: string;
+}
+
+/**
+ * @interface
+ * An interface representing TagsResult.
+ * A resource listing all tags.
+ *
+ * @extends ProxyResource
+ */
+export interface TagsResult extends ProxyResource {
+ /**
+ * @member {Tag[]} [tags] A list of Tag.
+ */
+ tags?: Tag[];
+}
+
+/**
+ * @interface
+ * An interface representing BudgetTimePeriod.
+ * The start and end date for a budget.
+ *
+ */
+export interface BudgetTimePeriod {
+ /**
+ * @member {Date} startDate The start date for the budget.
+ */
+ startDate: Date;
+ /**
+ * @member {Date} [endDate] The end date for the budget. If not provided, we
+ * default this to 10 years from the start date.
+ */
+ endDate?: Date;
+}
+
+/**
+ * @interface
+ * An interface representing Filters.
+ * May be used to filter budgets by resource group, resource, or meter.
+ *
+ */
+export interface Filters {
+ /**
+ * @member {string[]} [resourceGroups] The list of filters on resource
+ * groups, allowed at subscription level only.
+ */
+ resourceGroups?: string[];
+ /**
+ * @member {string[]} [resources] The list of filters on resources.
+ */
+ resources?: string[];
+ /**
+ * @member {string[]} [meters] The list of filters on meters (GUID),
+ * mandatory for budgets of usage category.
+ */
+ meters?: string[];
+ /**
+ * @member {{ [propertyName: string]: string[] }} [tags] The dictionary of
+ * filters on tags.
+ */
+ tags?: { [propertyName: string]: string[] };
+}
+
+/**
+ * @interface
+ * An interface representing CurrentSpend.
+ * The current amount of cost which is being tracked for a budget.
+ *
+ */
+export interface CurrentSpend {
+ /**
+ * @member {number} [amount] The total amount of cost which is being tracked
+ * by the budget.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly amount?: number;
+ /**
+ * @member {string} [unit] The unit of measure for the budget amount.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unit?: string;
+}
+
+/**
+ * @interface
+ * An interface representing Notification.
+ * The notification associated with a budget.
+ *
+ */
+export interface Notification {
+ /**
+ * @member {boolean} enabled The notification is enabled or not.
+ */
+ enabled: boolean;
+ /**
+ * @member {OperatorType} operator The comparison operator. Possible values
+ * include: 'EqualTo', 'GreaterThan', 'GreaterThanOrEqualTo'
+ */
+ operator: OperatorType;
+ /**
+ * @member {number} threshold Threshold value associated with a notification.
+ * Notification is sent when the cost exceeded the threshold. It is always
+ * percent and has to be between 0 and 1000.
+ */
+ threshold: number;
+ /**
+ * @member {string[]} contactEmails Email addresses to send the budget
+ * notification to when the threshold is exceeded.
+ */
+ contactEmails: string[];
+ /**
+ * @member {string[]} [contactRoles] Contact roles to send the budget
+ * notification to when the threshold is exceeded.
+ */
+ contactRoles?: string[];
+ /**
+ * @member {string[]} [contactGroups] Action groups to send the budget
+ * notification to when the threshold is exceeded.
+ */
+ contactGroups?: string[];
+}
+
+/**
+ * @interface
+ * An interface representing Budget.
+ * A budget resource.
+ *
+ * @extends ProxyResource
+ */
+export interface Budget extends ProxyResource {
+ /**
+ * @member {CategoryType} category The category of the budget, whether the
+ * budget tracks cost or usage. Possible values include: 'Cost', 'Usage'
+ */
+ category: CategoryType;
+ /**
+ * @member {number} amount The total amount of cost to track with the budget
+ */
+ amount: number;
+ /**
+ * @member {TimeGrainType} timeGrain The time covered by a budget. Tracking
+ * of the amount will be reset based on the time grain. Possible values
+ * include: 'Monthly', 'Quarterly', 'Annually'
+ */
+ timeGrain: TimeGrainType;
+ /**
+ * @member {BudgetTimePeriod} timePeriod Has start and end date of the
+ * budget. The start date must be first of the month and should be less than
+ * the end date. Budget start date must be on or after June 1, 2017. Future
+ * start date should not be more than three months. Past start date should
+ * be selected within the timegrain period. There are no restrictions on the
+ * end date.
+ */
+ timePeriod: BudgetTimePeriod;
+ /**
+ * @member {Filters} [filters] May be used to filter budgets by resource
+ * group, resource, or meter.
+ */
+ filters?: Filters;
+ /**
+ * @member {CurrentSpend} [currentSpend] The current amount of cost which is
+ * being tracked for a budget.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currentSpend?: CurrentSpend;
+ /**
+ * @member {{ [propertyName: string]: Notification }} [notifications]
+ * Dictionary of notifications associated with the budget. Budget can have up
+ * to five notifications.
+ */
+ notifications?: { [propertyName: string]: Notification };
+}
+
+/**
+ * @interface
+ * An interface representing PriceSheetProperties.
+ * The properties of the price sheet.
+ *
+ */
+export interface PriceSheetProperties {
+ /**
+ * @member {string} [billingPeriodId] The id of the billing period resource
+ * that the usage belongs to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodId?: string;
+ /**
+ * @member {string} [meterId] The meter id (GUID)
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterId?: string;
+ /**
+ * @member {MeterDetails} [meterDetails] The details about the meter. By
+ * default this is not populated, unless it's specified in $expand.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly meterDetails?: MeterDetails;
+ /**
+ * @member {string} [unitOfMeasure] Unit of measure
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unitOfMeasure?: string;
+ /**
+ * @member {number} [includedQuantity] Included quality for an offer
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly includedQuantity?: number;
+ /**
+ * @member {string} [partNumber] Part Number
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly partNumber?: string;
+ /**
+ * @member {number} [unitPrice] Unit Price
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly unitPrice?: number;
+ /**
+ * @member {string} [currencyCode] Currency Code
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currencyCode?: string;
+ /**
+ * @member {string} [offerId] Offer Id
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly offerId?: string;
+}
+
+/**
+ * @interface
+ * An interface representing PriceSheetResult.
+ * An pricesheet resource.
+ *
+ * @extends Resource
+ */
+export interface PriceSheetResult extends Resource {
+ /**
+ * @member {PriceSheetProperties[]} [pricesheets] Price sheet
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly pricesheets?: PriceSheetProperties[];
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ForecastPropertiesConfidenceLevelsItem.
+ */
+export interface ForecastPropertiesConfidenceLevelsItem {
+ /**
+ * @member {number} [percentage] The percentage level of the confidence
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly percentage?: number;
+ /**
+ * @member {Bound} [bound] The boundary of the percentage, values could be
+ * 'Upper' or 'Lower'. Possible values include: 'Upper', 'Lower'
+ */
+ bound?: Bound;
+ /**
+ * @member {number} [value] The amount of forecast within the percentage
+ * level
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly value?: number;
+}
+
+/**
+ * @interface
+ * An interface representing Forecast.
+ * A forecast resource.
+ *
+ * @extends Resource
+ */
+export interface Forecast extends Resource {
+ /**
+ * @member {string} [usageDate] The usage date of the forecast.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageDate?: string;
+ /**
+ * @member {Grain} [grain] The granularity of forecast. Possible values
+ * include: 'Daily', 'Monthly', 'Yearly'
+ */
+ grain?: Grain;
+ /**
+ * @member {number} [charge] The amount of charge
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly charge?: number;
+ /**
+ * @member {string} [currency] The ISO currency in which the meter is
+ * charged, for example, USD.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currency?: string;
+ /**
+ * @member {ChargeType} [chargeType] The type of the charge. Could be actual
+ * or forecast. Possible values include: 'Actual', 'Forecast'
+ */
+ chargeType?: ChargeType;
+ /**
+ * @member {ForecastPropertiesConfidenceLevelsItem[]} [confidenceLevels] The
+ * details about the forecast confidence levels. This is populated only when
+ * chargeType is Forecast.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly confidenceLevels?: ForecastPropertiesConfidenceLevelsItem[];
+}
+
+/**
+ * @interface
+ * An interface representing ManagementGroupAggregatedCostResult.
+ * A management group aggregated cost resource.
+ *
+ * @extends Resource
+ */
+export interface ManagementGroupAggregatedCostResult extends Resource {
+ /**
+ * @member {string} [billingPeriodId] The id of the billing period resource
+ * that the aggregated cost belongs to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodId?: string;
+ /**
+ * @member {Date} [usageStart] The start of the date time range covered by
+ * aggregated cost.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageStart?: Date;
+ /**
+ * @member {Date} [usageEnd] The end of the date time range covered by the
+ * aggregated cost.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageEnd?: Date;
+ /**
+ * @member {number} [azureCharges] Azure Charges.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly azureCharges?: number;
+ /**
+ * @member {number} [marketplaceCharges] Marketplace Charges.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly marketplaceCharges?: number;
+ /**
+ * @member {number} [chargesBilledSeparately] Charges Billed Separately.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly chargesBilledSeparately?: number;
+ /**
+ * @member {string} [currency] The ISO currency in which the meter is
+ * charged, for example, USD.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currency?: string;
+ /**
+ * @member {ManagementGroupAggregatedCostResult[]} [children] Children of a
+ * management group
+ */
+ children?: ManagementGroupAggregatedCostResult[];
+ /**
+ * @member {string[]} [includedSubscriptions] List of subscription Guids
+ * included in the calculation of aggregated cost
+ */
+ includedSubscriptions?: string[];
+ /**
+ * @member {string[]} [excludedSubscriptions] List of subscription Guids
+ * excluded from the calculation of aggregated cost
+ */
+ excludedSubscriptions?: string[];
+}
+
+/**
+ * @interface
+ * An interface representing ChargeSummary.
+ * A charge summary resource.
+ *
+ * @extends Resource
+ */
+export interface ChargeSummary extends Resource {
+ /**
+ * @member {string} [billingPeriodId] The id of the billing period resource
+ * that the charge belongs to.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly billingPeriodId?: string;
+ /**
+ * @member {string} [usageStart] Usage start date.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageStart?: string;
+ /**
+ * @member {string} [usageEnd] Usage end date.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly usageEnd?: string;
+ /**
+ * @member {number} [azureCharges] Azure Charges.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly azureCharges?: number;
+ /**
+ * @member {number} [chargesBilledSeparately] Charges Billed separately.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly chargesBilledSeparately?: number;
+ /**
+ * @member {number} [marketplaceCharges] Marketplace Charges.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly marketplaceCharges?: number;
+ /**
+ * @member {string} [currency] Currency Code
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly currency?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ChargesListResult.
+ * Result of listing charge summary.
+ *
+ */
+export interface ChargesListResult {
+ /**
+ * @member {ChargeSummary[]} [value] The list of charge summary
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly value?: ChargeSummary[];
+}
+
+/**
+ * @interface
+ * An interface representing ErrorDetails.
+ * The details of the error.
+ *
+ */
+export interface ErrorDetails {
+ /**
+ * @member {string} [code] Error code.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly code?: string;
+ /**
+ * @member {string} [message] Error message indicating why the operation
+ * failed.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly message?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ErrorResponse.
+ * Error response indicates that the service is not able to process the
+ * incoming request. The reason is provided in the error message.
+ *
+ */
+export interface ErrorResponse {
+ /**
+ * @member {ErrorDetails} [error] The details of the error.
+ */
+ error?: ErrorDetails;
+}
+
+/**
+ * @interface
+ * An interface representing OperationDisplay.
+ * The object that represents the operation.
+ *
+ */
+export interface OperationDisplay {
+ /**
+ * @member {string} [provider] Service provider: Microsoft.Consumption.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly provider?: string;
+ /**
+ * @member {string} [resource] Resource on which the operation is performed:
+ * UsageDetail, etc.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly resource?: string;
+ /**
+ * @member {string} [operation] Operation type: Read, write, delete, etc.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly operation?: string;
+}
+
+/**
+ * @interface
+ * An interface representing Operation.
+ * A Consumption REST API operation.
+ *
+ */
+export interface Operation {
+ /**
+ * @member {string} [name] Operation name: {provider}/{resource}/{operation}.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly name?: string;
+ /**
+ * @member {OperationDisplay} [display] The object that represents the
+ * operation.
+ */
+ display?: OperationDisplay;
+}
+
+/**
+ * @interface
+ * An interface representing ResourceAttributes.
+ * The Resource model definition.
+ *
+ */
+export interface ResourceAttributes {
+ /**
+ * @member {string} [location] Resource location
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly location?: string;
+ /**
+ * @member {string} [sku] Resource sku
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly sku?: string;
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetailsListOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface UsageDetailsListOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [expand] May be used to expand the
+ * properties/additionalInfo or properties/meterDetails within a list of
+ * usage details. By default, these fields are not included when listing
+ * usage details.
+ */
+ expand?: string;
+ /**
+ * @member {string} [filter] May be used to filter usageDetails by
+ * properties/resourceGroup, properties/resourceName, properties/resourceId,
+ * properties/chargeType, properties/reservationId or tags. The filter
+ * supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. It does not currently
+ * support 'ne', 'or', or 'not'. Tag filter is a key value pair string where
+ * key and value is separated by a colon (:).
+ */
+ filter?: string;
+ /**
+ * @member {string} [skiptoken] Skiptoken is only used if a previous
+ * operation returned a partial result. If a previous response contains a
+ * nextLink element, the value of the nextLink element will include a
+ * skiptoken parameter that specifies a starting point to use for subsequent
+ * calls.
+ */
+ skiptoken?: string;
+ /**
+ * @member {number} [top] May be used to limit the number of results to the
+ * most recent N usageDetails.
+ */
+ top?: number;
+ /**
+ * @member {Metrictype} [metric] Allows to select different type of
+ * cost/usage records. Possible values include: 'ActualCostMetricType',
+ * 'AmortizedCostMetricType', 'UsageMetricType'
+ */
+ metric?: Metrictype;
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetailsDownloadOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface UsageDetailsDownloadOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {Metrictype} [metric] Allows to select different type of
+ * cost/usage records. Possible values include: 'ActualCostMetricType',
+ * 'AmortizedCostMetricType', 'UsageMetricType'
+ */
+ metric?: Metrictype;
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetailsBeginDownloadOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface UsageDetailsBeginDownloadOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {Metrictype} [metric] Allows to select different type of
+ * cost/usage records. Possible values include: 'ActualCostMetricType',
+ * 'AmortizedCostMetricType', 'UsageMetricType'
+ */
+ metric?: Metrictype;
+}
+
+/**
+ * @interface
+ * An interface representing MarketplacesListOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface MarketplacesListOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] May be used to filter marketplaces by
+ * properties/usageEnd (Utc time), properties/usageStart (Utc time),
+ * properties/resourceGroup, properties/instanceName or
+ * properties/instanceId. The filter supports 'eq', 'lt', 'gt', 'le', 'ge',
+ * and 'and'. It does not currently support 'ne', 'or', or 'not'.
+ */
+ filter?: string;
+ /**
+ * @member {number} [top] May be used to limit the number of results to the
+ * most recent N marketplaces.
+ */
+ top?: number;
+ /**
+ * @member {string} [skiptoken] Skiptoken is only used if a previous
+ * operation returned a partial result. If a previous response contains a
+ * nextLink element, the value of the nextLink element will include a
+ * skiptoken parameter that specifies a starting point to use for subsequent
+ * calls.
+ */
+ skiptoken?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ChargesListByScopeOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface ChargesListByScopeOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] May be used to filter charges by
+ * properties/usageEnd (Utc time), properties/usageStart (Utc time). The
+ * filter supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. It does not
+ * currently support 'ne', 'or', or 'not'. Tag filter is a key value pair
+ * string where key and value is separated by a colon (:).
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ReservationsSummariesListByReservationOrderOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface ReservationsSummariesListByReservationOrderOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] Required only for daily grain. The
+ * properties/UsageDate for start date and end date. The filter supports 'le'
+ * and 'ge'
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ReservationsSummariesListByReservationOrderAndReservationOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface ReservationsSummariesListByReservationOrderAndReservationOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] Required only for daily grain. The
+ * properties/UsageDate for start date and end date. The filter supports 'le'
+ * and 'ge'
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ReservationRecommendationsListOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface ReservationRecommendationsListOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] May be used to filter reservationRecommendations
+ * by properties/scope and properties/lookBackPeriod.
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing PriceSheetGetOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface PriceSheetGetOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [expand] May be used to expand the
+ * properties/meterDetails within a price sheet. By default, these fields are
+ * not included when returning price sheet.
+ */
+ expand?: string;
+ /**
+ * @member {string} [skiptoken] Skiptoken is only used if a previous
+ * operation returned a partial result. If a previous response contains a
+ * nextLink element, the value of the nextLink element will include a
+ * skiptoken parameter that specifies a starting point to use for subsequent
+ * calls.
+ */
+ skiptoken?: string;
+ /**
+ * @member {number} [top] May be used to limit the number of results to the
+ * top N results.
+ */
+ top?: number;
+}
+
+/**
+ * @interface
+ * An interface representing PriceSheetGetByBillingPeriodOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface PriceSheetGetByBillingPeriodOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [expand] May be used to expand the
+ * properties/meterDetails within a price sheet. By default, these fields are
+ * not included when returning price sheet.
+ */
+ expand?: string;
+ /**
+ * @member {string} [skiptoken] Skiptoken is only used if a previous
+ * operation returned a partial result. If a previous response contains a
+ * nextLink element, the value of the nextLink element will include a
+ * skiptoken parameter that specifies a starting point to use for subsequent
+ * calls.
+ */
+ skiptoken?: string;
+ /**
+ * @member {number} [top] May be used to limit the number of results to the
+ * top N results.
+ */
+ top?: number;
+}
+
+/**
+ * @interface
+ * An interface representing ForecastsListOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface ForecastsListOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] May be used to filter forecasts by
+ * properties/usageDate (Utc time), properties/chargeType or
+ * properties/grain. The filter supports 'eq', 'lt', 'gt', 'le', 'ge', and
+ * 'and'. It does not currently support 'ne', 'or', or 'not'.
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing AggregatedCostGetByManagementGroupOptionalParams.
+ * Optional Parameters.
+ *
+ * @extends RequestOptionsBase
+ */
+export interface AggregatedCostGetByManagementGroupOptionalParams extends msRest.RequestOptionsBase {
+ /**
+ * @member {string} [filter] May be used to filter aggregated cost by
+ * properties/usageStart (Utc time), properties/usageEnd (Utc time). The
+ * filter supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. It does not
+ * currently support 'ne', 'or', or 'not'. Tag filter is a key value pair
+ * string where key and value is separated by a colon (:).
+ */
+ filter?: string;
+}
+
+/**
+ * @interface
+ * An interface representing ConsumptionManagementClientOptions.
+ * @extends AzureServiceClientOptions
+ */
+export interface ConsumptionManagementClientOptions extends AzureServiceClientOptions {
+ /**
+ * @member {string} [baseUri]
+ */
+ baseUri?: string;
+}
+
+/**
+ * @interface
+ * An interface representing UsageDetailsDownloadHeaders.
+ * Defines headers for Download operation.
+ *
+ */
+export interface UsageDetailsDownloadHeaders {
+ /**
+ * @member {string} [location] GET this URL to retrieve the status of the
+ * asynchronous operation.
+ */
+ location: string;
+ /**
+ * @member {string} [retryAfter] The amount of delay to use while the status
+ * of the operation is checked. The value is expressed in seconds.
+ */
+ retryAfter: string;
+ /**
+ * @member {string} [azureAsyncOperation] To get the progress of the
+ * operation, call GET operation on the URL in Azure-AsyncOperation header
+ * field.
+ */
+ azureAsyncOperation: string;
+}
+
+
+/**
+ * @interface
+ * An interface representing the UsageDetailsListResult.
+ * Result of listing usage details. It contains a list of available usage
+ * details in reverse chronological order by billing period.
+ *
+ * @extends Array
+ */
+export interface UsageDetailsListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the MarketplacesListResult.
+ * Result of listing marketplaces. It contains a list of available marketplaces
+ * in reverse chronological order by billing period.
+ *
+ * @extends Array
+ */
+export interface MarketplacesListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the BudgetsListResult.
+ * Result of listing budgets. It contains a list of available budgets in the
+ * scope provided.
+ *
+ * @extends Array
+ */
+export interface BudgetsListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the ReservationSummariesListResult.
+ * Result of listing reservation summaries.
+ *
+ * @extends Array
+ */
+export interface ReservationSummariesListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the ReservationDetailsListResult.
+ * Result of listing reservation details.
+ *
+ * @extends Array
+ */
+export interface ReservationDetailsListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the ReservationRecommendationsListResult.
+ * Result of listing reservation recommendations.
+ *
+ * @extends Array
+ */
+export interface ReservationRecommendationsListResult extends Array {
+ /**
+ * @member {string} [nextLink] The link (url) to the next page of results.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * @interface
+ * An interface representing the ForecastsListResult.
+ * Result of listing forecasts. It contains a list of available forecasts.
+ *
+ * @extends Array
+ */
+export interface ForecastsListResult extends Array {
+}
+
+/**
+ * @interface
+ * An interface representing the OperationListResult.
+ * Result of listing consumption operations. It contains a list of operations
+ * and a URL link to get the next set of results.
+ *
+ * @extends Array
+ */
+export interface OperationListResult extends Array {
+ /**
+ * @member {string} [nextLink] URL to get the next set of operation list
+ * results if there are any.
+ * **NOTE: This property will not be serialized. It can only be populated by
+ * the server.**
+ */
+ readonly nextLink?: string;
+}
+
+/**
+ * Defines values for BillingFrequency.
+ * Possible values include: 'Month', 'Quarter', 'Year'
+ * @readonly
+ * @enum {string}
+ */
+export type BillingFrequency = 'Month' | 'Quarter' | 'Year';
+
+/**
+ * Defines values for CategoryType.
+ * Possible values include: 'Cost', 'Usage'
+ * @readonly
+ * @enum {string}
+ */
+export type CategoryType = 'Cost' | 'Usage';
+
+/**
+ * Defines values for TimeGrainType.
+ * Possible values include: 'Monthly', 'Quarterly', 'Annually'
+ * @readonly
+ * @enum {string}
+ */
+export type TimeGrainType = 'Monthly' | 'Quarterly' | 'Annually';
+
+/**
+ * Defines values for OperatorType.
+ * Possible values include: 'EqualTo', 'GreaterThan', 'GreaterThanOrEqualTo'
+ * @readonly
+ * @enum {string}
+ */
+export type OperatorType = 'EqualTo' | 'GreaterThan' | 'GreaterThanOrEqualTo';
+
+/**
+ * Defines values for Grain.
+ * Possible values include: 'Daily', 'Monthly', 'Yearly'
+ * @readonly
+ * @enum {string}
+ */
+export type Grain = 'Daily' | 'Monthly' | 'Yearly';
+
+/**
+ * Defines values for ChargeType.
+ * Possible values include: 'Actual', 'Forecast'
+ * @readonly
+ * @enum {string}
+ */
+export type ChargeType = 'Actual' | 'Forecast';
+
+/**
+ * Defines values for Bound.
+ * Possible values include: 'Upper', 'Lower'
+ * @readonly
+ * @enum {string}
+ */
+export type Bound = 'Upper' | 'Lower';
+
+/**
+ * Defines values for Datagrain.
+ * Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @readonly
+ * @enum {string}
+ */
+export type Datagrain = 'daily' | 'monthly';
+
+/**
+ * Defines values for Metrictype.
+ * Possible values include: 'ActualCostMetricType', 'AmortizedCostMetricType', 'UsageMetricType'
+ * @readonly
+ * @enum {string}
+ */
+export type Metrictype = 'actualcost' | 'amortizedcost' | 'usage';
+
+/**
+ * Contains response data for the list operation.
+ */
+export type UsageDetailsListResponse = UsageDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: UsageDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the download operation.
+ */
+export type UsageDetailsDownloadResponse2 = UsageDetailsDownloadResponse & UsageDetailsDownloadHeaders & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The parsed HTTP response headers.
+ */
+ parsedHeaders: UsageDetailsDownloadHeaders;
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: UsageDetailsDownloadResponse;
+ };
+};
+
+/**
+ * Contains response data for the listNext operation.
+ */
+export type UsageDetailsListNextResponse = UsageDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: UsageDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the list operation.
+ */
+export type MarketplacesListResponse = MarketplacesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: MarketplacesListResult;
+ };
+};
+
+/**
+ * Contains response data for the listNext operation.
+ */
+export type MarketplacesListNextResponse = MarketplacesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: MarketplacesListResult;
+ };
+};
+
+/**
+ * Contains response data for the list operation.
+ */
+export type BudgetsListResponse = BudgetsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: BudgetsListResult;
+ };
+};
+
+/**
+ * Contains response data for the get operation.
+ */
+export type BudgetsGetResponse = Budget & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: Budget;
+ };
+};
+
+/**
+ * Contains response data for the createOrUpdate operation.
+ */
+export type BudgetsCreateOrUpdateResponse = Budget & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: Budget;
+ };
+};
+
+/**
+ * Contains response data for the listNext operation.
+ */
+export type BudgetsListNextResponse = BudgetsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: BudgetsListResult;
+ };
+};
+
+/**
+ * Contains response data for the get operation.
+ */
+export type TagsGetResponse = TagsResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: TagsResult;
+ };
+};
+
+/**
+ * Contains response data for the listByScope operation.
+ */
+export type ChargesListByScopeResponse = ChargeSummary & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ChargeSummary;
+ };
+};
+
+/**
+ * Contains response data for the getByBillingAccount operation.
+ */
+export type BalancesGetByBillingAccountResponse = Balance & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: Balance;
+ };
+};
+
+/**
+ * Contains response data for the getForBillingPeriodByBillingAccount operation.
+ */
+export type BalancesGetForBillingPeriodByBillingAccountResponse = Balance & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: Balance;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrder operation.
+ */
+export type ReservationsSummariesListByReservationOrderResponse = ReservationSummariesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationSummariesListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderAndReservation operation.
+ */
+export type ReservationsSummariesListByReservationOrderAndReservationResponse = ReservationSummariesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationSummariesListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderNext operation.
+ */
+export type ReservationsSummariesListByReservationOrderNextResponse = ReservationSummariesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationSummariesListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderAndReservationNext operation.
+ */
+export type ReservationsSummariesListByReservationOrderAndReservationNextResponse = ReservationSummariesListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationSummariesListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrder operation.
+ */
+export type ReservationsDetailsListByReservationOrderResponse = ReservationDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderAndReservation operation.
+ */
+export type ReservationsDetailsListByReservationOrderAndReservationResponse = ReservationDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderNext operation.
+ */
+export type ReservationsDetailsListByReservationOrderNextResponse = ReservationDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the listByReservationOrderAndReservationNext operation.
+ */
+export type ReservationsDetailsListByReservationOrderAndReservationNextResponse = ReservationDetailsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationDetailsListResult;
+ };
+};
+
+/**
+ * Contains response data for the list operation.
+ */
+export type ReservationRecommendationsListResponse = ReservationRecommendationsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationRecommendationsListResult;
+ };
+};
+
+/**
+ * Contains response data for the listNext operation.
+ */
+export type ReservationRecommendationsListNextResponse = ReservationRecommendationsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ReservationRecommendationsListResult;
+ };
+};
+
+/**
+ * Contains response data for the get operation.
+ */
+export type PriceSheetGetResponse = PriceSheetResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: PriceSheetResult;
+ };
+};
+
+/**
+ * Contains response data for the getByBillingPeriod operation.
+ */
+export type PriceSheetGetByBillingPeriodResponse = PriceSheetResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: PriceSheetResult;
+ };
+};
+
+/**
+ * Contains response data for the list operation.
+ */
+export type ForecastsListResponse = ForecastsListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ForecastsListResult;
+ };
+};
+
+/**
+ * Contains response data for the list operation.
+ */
+export type OperationsListResponse = OperationListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: OperationListResult;
+ };
+};
+
+/**
+ * Contains response data for the listNext operation.
+ */
+export type OperationsListNextResponse = OperationListResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: OperationListResult;
+ };
+};
+
+/**
+ * Contains response data for the getByManagementGroup operation.
+ */
+export type AggregatedCostGetByManagementGroupResponse = ManagementGroupAggregatedCostResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ManagementGroupAggregatedCostResult;
+ };
+};
+
+/**
+ * Contains response data for the getForBillingPeriodByManagementGroup operation.
+ */
+export type AggregatedCostGetForBillingPeriodByManagementGroupResponse = ManagementGroupAggregatedCostResult & {
+ /**
+ * The underlying HTTP response.
+ */
+ _response: msRest.HttpResponse & {
+ /**
+ * The response body as text (string format)
+ */
+ bodyAsText: string;
+ /**
+ * The response body as parsed JSON or XML
+ */
+ parsedBody: ManagementGroupAggregatedCostResult;
+ };
+};
diff --git a/sdk/consumption/arm-consumption/lib/models/mappers.ts b/sdk/consumption/arm-consumption/lib/models/mappers.ts
new file mode 100644
index 000000000000..fc02afb7b59c
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/mappers.ts
@@ -0,0 +1,2213 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import { CloudErrorMapper, BaseResourceMapper } from "@azure/ms-rest-azure-js";
+import * as msRest from "@azure/ms-rest-js";
+
+export const CloudError = CloudErrorMapper;
+export const BaseResource = BaseResourceMapper;
+
+export const MeterDetails: msRest.CompositeMapper = {
+ serializedName: "MeterDetails",
+ type: {
+ name: "Composite",
+ className: "MeterDetails",
+ modelProperties: {
+ meterName: {
+ readOnly: true,
+ serializedName: "meterName",
+ type: {
+ name: "String"
+ }
+ },
+ meterCategory: {
+ readOnly: true,
+ serializedName: "meterCategory",
+ type: {
+ name: "String"
+ }
+ },
+ meterSubCategory: {
+ readOnly: true,
+ serializedName: "meterSubCategory",
+ type: {
+ name: "String"
+ }
+ },
+ unit: {
+ readOnly: true,
+ serializedName: "unit",
+ type: {
+ name: "String"
+ }
+ },
+ meterLocation: {
+ readOnly: true,
+ serializedName: "meterLocation",
+ type: {
+ name: "String"
+ }
+ },
+ totalIncludedQuantity: {
+ readOnly: true,
+ serializedName: "totalIncludedQuantity",
+ type: {
+ name: "Number"
+ }
+ },
+ pretaxStandardRate: {
+ readOnly: true,
+ serializedName: "pretaxStandardRate",
+ type: {
+ name: "Number"
+ }
+ },
+ serviceName: {
+ readOnly: true,
+ serializedName: "serviceName",
+ type: {
+ name: "String"
+ }
+ },
+ serviceTier: {
+ readOnly: true,
+ serializedName: "serviceTier",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const MeterDetailsResponse: msRest.CompositeMapper = {
+ serializedName: "MeterDetailsResponse",
+ type: {
+ name: "Composite",
+ className: "MeterDetailsResponse",
+ modelProperties: {
+ meterName: {
+ readOnly: true,
+ serializedName: "meterName",
+ type: {
+ name: "String"
+ }
+ },
+ meterCategory: {
+ readOnly: true,
+ serializedName: "meterCategory",
+ type: {
+ name: "String"
+ }
+ },
+ meterSubCategory: {
+ readOnly: true,
+ serializedName: "meterSubCategory",
+ type: {
+ name: "String"
+ }
+ },
+ unitOfMeasure: {
+ readOnly: true,
+ serializedName: "unitOfMeasure",
+ type: {
+ name: "String"
+ }
+ },
+ serviceFamily: {
+ readOnly: true,
+ serializedName: "serviceFamily",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const Resource: msRest.CompositeMapper = {
+ serializedName: "Resource",
+ type: {
+ name: "Composite",
+ className: "Resource",
+ modelProperties: {
+ id: {
+ readOnly: true,
+ serializedName: "id",
+ type: {
+ name: "String"
+ }
+ },
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ type: {
+ readOnly: true,
+ serializedName: "type",
+ type: {
+ name: "String"
+ }
+ },
+ tags: {
+ readOnly: true,
+ serializedName: "tags",
+ type: {
+ name: "Dictionary",
+ value: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const UsageDetail: msRest.CompositeMapper = {
+ serializedName: "UsageDetail",
+ type: {
+ name: "Composite",
+ className: "UsageDetail",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ billingAccountId: {
+ readOnly: true,
+ serializedName: "properties.billingAccountId",
+ type: {
+ name: "String"
+ }
+ },
+ billingAccountName: {
+ readOnly: true,
+ serializedName: "properties.billingAccountName",
+ type: {
+ name: "String"
+ }
+ },
+ billingPeriodStartDate: {
+ readOnly: true,
+ serializedName: "properties.billingPeriodStartDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ billingPeriodEndDate: {
+ readOnly: true,
+ serializedName: "properties.billingPeriodEndDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ billingProfileId: {
+ readOnly: true,
+ serializedName: "properties.billingProfileId",
+ type: {
+ name: "String"
+ }
+ },
+ billingProfileName: {
+ readOnly: true,
+ serializedName: "properties.billingProfileName",
+ type: {
+ name: "String"
+ }
+ },
+ accountOwnerId: {
+ readOnly: true,
+ serializedName: "properties.accountOwnerId",
+ type: {
+ name: "String"
+ }
+ },
+ accountName: {
+ readOnly: true,
+ serializedName: "properties.accountName",
+ type: {
+ name: "String"
+ }
+ },
+ subscriptionId: {
+ readOnly: true,
+ serializedName: "properties.subscriptionId",
+ type: {
+ name: "String"
+ }
+ },
+ subscriptionName: {
+ readOnly: true,
+ serializedName: "properties.subscriptionName",
+ type: {
+ name: "String"
+ }
+ },
+ date: {
+ readOnly: true,
+ serializedName: "properties.date",
+ type: {
+ name: "DateTime"
+ }
+ },
+ product: {
+ readOnly: true,
+ serializedName: "properties.product",
+ type: {
+ name: "String"
+ }
+ },
+ partNumber: {
+ readOnly: true,
+ serializedName: "properties.partNumber",
+ type: {
+ name: "String"
+ }
+ },
+ meterId: {
+ readOnly: true,
+ serializedName: "properties.meterId",
+ type: {
+ name: "Uuid"
+ }
+ },
+ meterDetails: {
+ readOnly: true,
+ serializedName: "properties.meterDetails",
+ type: {
+ name: "Composite",
+ className: "MeterDetailsResponse"
+ }
+ },
+ quantity: {
+ readOnly: true,
+ serializedName: "properties.quantity",
+ type: {
+ name: "Number"
+ }
+ },
+ effectivePrice: {
+ readOnly: true,
+ serializedName: "properties.effectivePrice",
+ type: {
+ name: "Number"
+ }
+ },
+ cost: {
+ readOnly: true,
+ serializedName: "properties.cost",
+ type: {
+ name: "Number"
+ }
+ },
+ unitPrice: {
+ readOnly: true,
+ serializedName: "properties.unitPrice",
+ type: {
+ name: "Number"
+ }
+ },
+ billingCurrency: {
+ readOnly: true,
+ serializedName: "properties.billingCurrency",
+ type: {
+ name: "String"
+ }
+ },
+ resourceLocation: {
+ readOnly: true,
+ serializedName: "properties.resourceLocation",
+ type: {
+ name: "String"
+ }
+ },
+ consumedService: {
+ readOnly: true,
+ serializedName: "properties.consumedService",
+ type: {
+ name: "String"
+ }
+ },
+ resourceId: {
+ readOnly: true,
+ serializedName: "properties.resourceId",
+ type: {
+ name: "String"
+ }
+ },
+ resourceName: {
+ readOnly: true,
+ serializedName: "properties.resourceName",
+ type: {
+ name: "String"
+ }
+ },
+ serviceInfo1: {
+ readOnly: true,
+ serializedName: "properties.serviceInfo1",
+ type: {
+ name: "String"
+ }
+ },
+ serviceInfo2: {
+ readOnly: true,
+ serializedName: "properties.serviceInfo2",
+ type: {
+ name: "String"
+ }
+ },
+ additionalInfo: {
+ readOnly: true,
+ serializedName: "properties.additionalInfo",
+ type: {
+ name: "String"
+ }
+ },
+ invoiceSection: {
+ readOnly: true,
+ serializedName: "properties.invoiceSection",
+ type: {
+ name: "String"
+ }
+ },
+ costCenter: {
+ readOnly: true,
+ serializedName: "properties.costCenter",
+ type: {
+ name: "String"
+ }
+ },
+ resourceGroup: {
+ readOnly: true,
+ serializedName: "properties.resourceGroup",
+ type: {
+ name: "String"
+ }
+ },
+ reservationId: {
+ readOnly: true,
+ serializedName: "properties.reservationId",
+ type: {
+ name: "String"
+ }
+ },
+ reservationName: {
+ readOnly: true,
+ serializedName: "properties.reservationName",
+ type: {
+ name: "String"
+ }
+ },
+ productOrderId: {
+ readOnly: true,
+ serializedName: "properties.productOrderId",
+ type: {
+ name: "String"
+ }
+ },
+ productOrderName: {
+ readOnly: true,
+ serializedName: "properties.productOrderName",
+ type: {
+ name: "String"
+ }
+ },
+ offerId: {
+ readOnly: true,
+ serializedName: "properties.offerId",
+ type: {
+ name: "String"
+ }
+ },
+ isAzureCreditEligible: {
+ readOnly: true,
+ serializedName: "properties.isAzureCreditEligible",
+ type: {
+ name: "Boolean"
+ }
+ },
+ term: {
+ readOnly: true,
+ serializedName: "properties.term",
+ type: {
+ name: "String"
+ }
+ },
+ publisherName: {
+ readOnly: true,
+ serializedName: "properties.publisherName",
+ type: {
+ name: "String"
+ }
+ },
+ publisherType: {
+ readOnly: true,
+ serializedName: "properties.publisherType",
+ type: {
+ name: "String"
+ }
+ },
+ planName: {
+ readOnly: true,
+ serializedName: "properties.planName",
+ type: {
+ name: "String"
+ }
+ },
+ chargeType: {
+ readOnly: true,
+ serializedName: "properties.chargeType",
+ type: {
+ name: "String"
+ }
+ },
+ frequency: {
+ readOnly: true,
+ serializedName: "properties.frequency",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const UsageDetailsDownloadResponse: msRest.CompositeMapper = {
+ serializedName: "UsageDetailsDownloadResponse",
+ type: {
+ name: "Composite",
+ className: "UsageDetailsDownloadResponse",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ downloadUrl: {
+ readOnly: true,
+ serializedName: "properties.downloadUrl",
+ type: {
+ name: "String"
+ }
+ },
+ validTill: {
+ readOnly: true,
+ serializedName: "properties.validTill",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const Marketplace: msRest.CompositeMapper = {
+ serializedName: "Marketplace",
+ type: {
+ name: "Composite",
+ className: "Marketplace",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ billingPeriodId: {
+ readOnly: true,
+ serializedName: "properties.billingPeriodId",
+ type: {
+ name: "String"
+ }
+ },
+ usageStart: {
+ readOnly: true,
+ serializedName: "properties.usageStart",
+ type: {
+ name: "DateTime"
+ }
+ },
+ usageEnd: {
+ readOnly: true,
+ serializedName: "properties.usageEnd",
+ type: {
+ name: "DateTime"
+ }
+ },
+ resourceRate: {
+ readOnly: true,
+ serializedName: "properties.resourceRate",
+ type: {
+ name: "Number"
+ }
+ },
+ offerName: {
+ readOnly: true,
+ serializedName: "properties.offerName",
+ type: {
+ name: "String"
+ }
+ },
+ resourceGroup: {
+ readOnly: true,
+ serializedName: "properties.resourceGroup",
+ type: {
+ name: "String"
+ }
+ },
+ orderNumber: {
+ readOnly: true,
+ serializedName: "properties.orderNumber",
+ type: {
+ name: "String"
+ }
+ },
+ instanceName: {
+ readOnly: true,
+ serializedName: "properties.instanceName",
+ type: {
+ name: "String"
+ }
+ },
+ instanceId: {
+ readOnly: true,
+ serializedName: "properties.instanceId",
+ type: {
+ name: "String"
+ }
+ },
+ currency: {
+ readOnly: true,
+ serializedName: "properties.currency",
+ type: {
+ name: "String"
+ }
+ },
+ consumedQuantity: {
+ readOnly: true,
+ serializedName: "properties.consumedQuantity",
+ type: {
+ name: "Number"
+ }
+ },
+ unitOfMeasure: {
+ readOnly: true,
+ serializedName: "properties.unitOfMeasure",
+ type: {
+ name: "String"
+ }
+ },
+ pretaxCost: {
+ readOnly: true,
+ serializedName: "properties.pretaxCost",
+ type: {
+ name: "Number"
+ }
+ },
+ isEstimated: {
+ readOnly: true,
+ serializedName: "properties.isEstimated",
+ type: {
+ name: "Boolean"
+ }
+ },
+ meterId: {
+ readOnly: true,
+ serializedName: "properties.meterId",
+ type: {
+ name: "Uuid"
+ }
+ },
+ subscriptionGuid: {
+ readOnly: true,
+ serializedName: "properties.subscriptionGuid",
+ type: {
+ name: "Uuid"
+ }
+ },
+ subscriptionName: {
+ readOnly: true,
+ serializedName: "properties.subscriptionName",
+ type: {
+ name: "String"
+ }
+ },
+ accountName: {
+ readOnly: true,
+ serializedName: "properties.accountName",
+ type: {
+ name: "String"
+ }
+ },
+ departmentName: {
+ readOnly: true,
+ serializedName: "properties.departmentName",
+ type: {
+ name: "String"
+ }
+ },
+ consumedService: {
+ readOnly: true,
+ serializedName: "properties.consumedService",
+ type: {
+ name: "String"
+ }
+ },
+ costCenter: {
+ readOnly: true,
+ serializedName: "properties.costCenter",
+ type: {
+ name: "String"
+ }
+ },
+ additionalProperties: {
+ readOnly: true,
+ serializedName: "properties.additionalProperties",
+ type: {
+ name: "String"
+ }
+ },
+ publisherName: {
+ readOnly: true,
+ serializedName: "properties.publisherName",
+ type: {
+ name: "String"
+ }
+ },
+ planName: {
+ readOnly: true,
+ serializedName: "properties.planName",
+ type: {
+ name: "String"
+ }
+ },
+ isRecurringCharge: {
+ readOnly: true,
+ serializedName: "properties.isRecurringCharge",
+ type: {
+ name: "Boolean"
+ }
+ }
+ }
+ }
+};
+
+export const BalancePropertiesNewPurchasesDetailsItem: msRest.CompositeMapper = {
+ serializedName: "BalanceProperties_newPurchasesDetailsItem",
+ type: {
+ name: "Composite",
+ className: "BalancePropertiesNewPurchasesDetailsItem",
+ modelProperties: {
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ value: {
+ readOnly: true,
+ serializedName: "value",
+ type: {
+ name: "Number"
+ }
+ }
+ }
+ }
+};
+
+export const BalancePropertiesAdjustmentDetailsItem: msRest.CompositeMapper = {
+ serializedName: "BalanceProperties_adjustmentDetailsItem",
+ type: {
+ name: "Composite",
+ className: "BalancePropertiesAdjustmentDetailsItem",
+ modelProperties: {
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ value: {
+ readOnly: true,
+ serializedName: "value",
+ type: {
+ name: "Number"
+ }
+ }
+ }
+ }
+};
+
+export const Balance: msRest.CompositeMapper = {
+ serializedName: "Balance",
+ type: {
+ name: "Composite",
+ className: "Balance",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ currency: {
+ readOnly: true,
+ serializedName: "properties.currency",
+ type: {
+ name: "String"
+ }
+ },
+ beginningBalance: {
+ readOnly: true,
+ serializedName: "properties.beginningBalance",
+ type: {
+ name: "Number"
+ }
+ },
+ endingBalance: {
+ readOnly: true,
+ serializedName: "properties.endingBalance",
+ type: {
+ name: "Number"
+ }
+ },
+ newPurchases: {
+ readOnly: true,
+ serializedName: "properties.newPurchases",
+ type: {
+ name: "Number"
+ }
+ },
+ adjustments: {
+ readOnly: true,
+ serializedName: "properties.adjustments",
+ type: {
+ name: "Number"
+ }
+ },
+ utilized: {
+ readOnly: true,
+ serializedName: "properties.utilized",
+ type: {
+ name: "Number"
+ }
+ },
+ serviceOverage: {
+ readOnly: true,
+ serializedName: "properties.serviceOverage",
+ type: {
+ name: "Number"
+ }
+ },
+ chargesBilledSeparately: {
+ readOnly: true,
+ serializedName: "properties.chargesBilledSeparately",
+ type: {
+ name: "Number"
+ }
+ },
+ totalOverage: {
+ readOnly: true,
+ serializedName: "properties.totalOverage",
+ type: {
+ name: "Number"
+ }
+ },
+ totalUsage: {
+ readOnly: true,
+ serializedName: "properties.totalUsage",
+ type: {
+ name: "Number"
+ }
+ },
+ azureMarketplaceServiceCharges: {
+ readOnly: true,
+ serializedName: "properties.azureMarketplaceServiceCharges",
+ type: {
+ name: "Number"
+ }
+ },
+ billingFrequency: {
+ serializedName: "properties.billingFrequency",
+ type: {
+ name: "String"
+ }
+ },
+ priceHidden: {
+ readOnly: true,
+ serializedName: "properties.priceHidden",
+ type: {
+ name: "Boolean"
+ }
+ },
+ newPurchasesDetails: {
+ readOnly: true,
+ serializedName: "properties.newPurchasesDetails",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "BalancePropertiesNewPurchasesDetailsItem"
+ }
+ }
+ }
+ },
+ adjustmentDetails: {
+ readOnly: true,
+ serializedName: "properties.adjustmentDetails",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "BalancePropertiesAdjustmentDetailsItem"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const ReservationSummary: msRest.CompositeMapper = {
+ serializedName: "ReservationSummary",
+ type: {
+ name: "Composite",
+ className: "ReservationSummary",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ reservationOrderId: {
+ readOnly: true,
+ serializedName: "properties.reservationOrderId",
+ type: {
+ name: "String"
+ }
+ },
+ reservationId: {
+ readOnly: true,
+ serializedName: "properties.reservationId",
+ type: {
+ name: "String"
+ }
+ },
+ skuName: {
+ readOnly: true,
+ serializedName: "properties.skuName",
+ type: {
+ name: "String"
+ }
+ },
+ reservedHours: {
+ readOnly: true,
+ serializedName: "properties.reservedHours",
+ type: {
+ name: "Number"
+ }
+ },
+ usageDate: {
+ readOnly: true,
+ serializedName: "properties.usageDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ usedHours: {
+ readOnly: true,
+ serializedName: "properties.usedHours",
+ type: {
+ name: "Number"
+ }
+ },
+ minUtilizationPercentage: {
+ readOnly: true,
+ serializedName: "properties.minUtilizationPercentage",
+ type: {
+ name: "Number"
+ }
+ },
+ avgUtilizationPercentage: {
+ readOnly: true,
+ serializedName: "properties.avgUtilizationPercentage",
+ type: {
+ name: "Number"
+ }
+ },
+ maxUtilizationPercentage: {
+ readOnly: true,
+ serializedName: "properties.maxUtilizationPercentage",
+ type: {
+ name: "Number"
+ }
+ }
+ }
+ }
+};
+
+export const ReservationDetail: msRest.CompositeMapper = {
+ serializedName: "ReservationDetail",
+ type: {
+ name: "Composite",
+ className: "ReservationDetail",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ reservationOrderId: {
+ readOnly: true,
+ serializedName: "properties.reservationOrderId",
+ type: {
+ name: "String"
+ }
+ },
+ reservationId: {
+ readOnly: true,
+ serializedName: "properties.reservationId",
+ type: {
+ name: "String"
+ }
+ },
+ skuName: {
+ readOnly: true,
+ serializedName: "properties.skuName",
+ type: {
+ name: "String"
+ }
+ },
+ reservedHours: {
+ readOnly: true,
+ serializedName: "properties.reservedHours",
+ type: {
+ name: "Number"
+ }
+ },
+ usageDate: {
+ readOnly: true,
+ serializedName: "properties.usageDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ usedHours: {
+ readOnly: true,
+ serializedName: "properties.usedHours",
+ type: {
+ name: "Number"
+ }
+ },
+ instanceId: {
+ readOnly: true,
+ serializedName: "properties.instanceId",
+ type: {
+ name: "String"
+ }
+ },
+ totalReservedQuantity: {
+ readOnly: true,
+ serializedName: "properties.totalReservedQuantity",
+ type: {
+ name: "Number"
+ }
+ }
+ }
+ }
+};
+
+export const ReservationRecommendation: msRest.CompositeMapper = {
+ serializedName: "ReservationRecommendation",
+ type: {
+ name: "Composite",
+ className: "ReservationRecommendation",
+ modelProperties: {
+ id: {
+ readOnly: true,
+ serializedName: "id",
+ type: {
+ name: "String"
+ }
+ },
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ type: {
+ readOnly: true,
+ serializedName: "type",
+ type: {
+ name: "String"
+ }
+ },
+ tags: {
+ readOnly: true,
+ serializedName: "tags",
+ type: {
+ name: "Dictionary",
+ value: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ location: {
+ readOnly: true,
+ serializedName: "location",
+ type: {
+ name: "String"
+ }
+ },
+ sku: {
+ readOnly: true,
+ serializedName: "sku",
+ type: {
+ name: "String"
+ }
+ },
+ lookBackPeriod: {
+ readOnly: true,
+ serializedName: "properties.lookBackPeriod",
+ type: {
+ name: "String"
+ }
+ },
+ meterId: {
+ readOnly: true,
+ serializedName: "properties.meterId",
+ type: {
+ name: "Uuid"
+ }
+ },
+ term: {
+ readOnly: true,
+ serializedName: "properties.term",
+ type: {
+ name: "String"
+ }
+ },
+ costWithNoReservedInstances: {
+ readOnly: true,
+ serializedName: "properties.costWithNoReservedInstances",
+ type: {
+ name: "Number"
+ }
+ },
+ recommendedQuantity: {
+ readOnly: true,
+ serializedName: "properties.recommendedQuantity",
+ type: {
+ name: "Number"
+ }
+ },
+ totalCostWithReservedInstances: {
+ readOnly: true,
+ serializedName: "properties.totalCostWithReservedInstances",
+ type: {
+ name: "Number"
+ }
+ },
+ netSavings: {
+ readOnly: true,
+ serializedName: "properties.netSavings",
+ type: {
+ name: "Number"
+ }
+ },
+ firstUsageDate: {
+ readOnly: true,
+ serializedName: "properties.firstUsageDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ scope: {
+ readOnly: true,
+ serializedName: "properties.scope",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const Tag: msRest.CompositeMapper = {
+ serializedName: "Tag",
+ type: {
+ name: "Composite",
+ className: "Tag",
+ modelProperties: {
+ key: {
+ serializedName: "key",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ProxyResource: msRest.CompositeMapper = {
+ serializedName: "ProxyResource",
+ type: {
+ name: "Composite",
+ className: "ProxyResource",
+ modelProperties: {
+ id: {
+ readOnly: true,
+ serializedName: "id",
+ type: {
+ name: "String"
+ }
+ },
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ type: {
+ readOnly: true,
+ serializedName: "type",
+ type: {
+ name: "String"
+ }
+ },
+ eTag: {
+ serializedName: "eTag",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const TagsResult: msRest.CompositeMapper = {
+ serializedName: "TagsResult",
+ type: {
+ name: "Composite",
+ className: "TagsResult",
+ modelProperties: {
+ ...ProxyResource.type.modelProperties,
+ tags: {
+ serializedName: "properties.tags",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "Tag"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const BudgetTimePeriod: msRest.CompositeMapper = {
+ serializedName: "BudgetTimePeriod",
+ type: {
+ name: "Composite",
+ className: "BudgetTimePeriod",
+ modelProperties: {
+ startDate: {
+ required: true,
+ serializedName: "startDate",
+ type: {
+ name: "DateTime"
+ }
+ },
+ endDate: {
+ serializedName: "endDate",
+ type: {
+ name: "DateTime"
+ }
+ }
+ }
+ }
+};
+
+export const Filters: msRest.CompositeMapper = {
+ serializedName: "Filters",
+ type: {
+ name: "Composite",
+ className: "Filters",
+ modelProperties: {
+ resourceGroups: {
+ serializedName: "resourceGroups",
+ constraints: {
+ MaxItems: 10,
+ MinItems: 0
+ },
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ resources: {
+ serializedName: "resources",
+ constraints: {
+ MaxItems: 10,
+ MinItems: 0
+ },
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ meters: {
+ serializedName: "meters",
+ constraints: {
+ MaxItems: 10,
+ MinItems: 0
+ },
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Uuid"
+ }
+ }
+ }
+ },
+ tags: {
+ serializedName: "tags",
+ type: {
+ name: "Dictionary",
+ value: {
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const CurrentSpend: msRest.CompositeMapper = {
+ serializedName: "CurrentSpend",
+ type: {
+ name: "Composite",
+ className: "CurrentSpend",
+ modelProperties: {
+ amount: {
+ readOnly: true,
+ serializedName: "amount",
+ type: {
+ name: "Number"
+ }
+ },
+ unit: {
+ readOnly: true,
+ serializedName: "unit",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const Notification: msRest.CompositeMapper = {
+ serializedName: "Notification",
+ type: {
+ name: "Composite",
+ className: "Notification",
+ modelProperties: {
+ enabled: {
+ required: true,
+ serializedName: "enabled",
+ type: {
+ name: "Boolean"
+ }
+ },
+ operator: {
+ required: true,
+ serializedName: "operator",
+ type: {
+ name: "String"
+ }
+ },
+ threshold: {
+ required: true,
+ serializedName: "threshold",
+ type: {
+ name: "Number"
+ }
+ },
+ contactEmails: {
+ required: true,
+ serializedName: "contactEmails",
+ constraints: {
+ MaxItems: 50,
+ MinItems: 1
+ },
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ contactRoles: {
+ serializedName: "contactRoles",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ contactGroups: {
+ serializedName: "contactGroups",
+ constraints: {
+ MaxItems: 50,
+ MinItems: 0
+ },
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const Budget: msRest.CompositeMapper = {
+ serializedName: "Budget",
+ type: {
+ name: "Composite",
+ className: "Budget",
+ modelProperties: {
+ ...ProxyResource.type.modelProperties,
+ category: {
+ required: true,
+ serializedName: "properties.category",
+ type: {
+ name: "String"
+ }
+ },
+ amount: {
+ required: true,
+ serializedName: "properties.amount",
+ type: {
+ name: "Number"
+ }
+ },
+ timeGrain: {
+ required: true,
+ serializedName: "properties.timeGrain",
+ type: {
+ name: "String"
+ }
+ },
+ timePeriod: {
+ required: true,
+ serializedName: "properties.timePeriod",
+ type: {
+ name: "Composite",
+ className: "BudgetTimePeriod"
+ }
+ },
+ filters: {
+ serializedName: "properties.filters",
+ type: {
+ name: "Composite",
+ className: "Filters"
+ }
+ },
+ currentSpend: {
+ readOnly: true,
+ serializedName: "properties.currentSpend",
+ type: {
+ name: "Composite",
+ className: "CurrentSpend"
+ }
+ },
+ notifications: {
+ serializedName: "properties.notifications",
+ type: {
+ name: "Dictionary",
+ value: {
+ type: {
+ name: "Composite",
+ className: "Notification"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const PriceSheetProperties: msRest.CompositeMapper = {
+ serializedName: "PriceSheetProperties",
+ type: {
+ name: "Composite",
+ className: "PriceSheetProperties",
+ modelProperties: {
+ billingPeriodId: {
+ readOnly: true,
+ serializedName: "billingPeriodId",
+ type: {
+ name: "String"
+ }
+ },
+ meterId: {
+ readOnly: true,
+ serializedName: "meterId",
+ type: {
+ name: "Uuid"
+ }
+ },
+ meterDetails: {
+ readOnly: true,
+ serializedName: "meterDetails",
+ type: {
+ name: "Composite",
+ className: "MeterDetails"
+ }
+ },
+ unitOfMeasure: {
+ readOnly: true,
+ serializedName: "unitOfMeasure",
+ type: {
+ name: "String"
+ }
+ },
+ includedQuantity: {
+ readOnly: true,
+ serializedName: "includedQuantity",
+ type: {
+ name: "Number"
+ }
+ },
+ partNumber: {
+ readOnly: true,
+ serializedName: "partNumber",
+ type: {
+ name: "String"
+ }
+ },
+ unitPrice: {
+ readOnly: true,
+ serializedName: "unitPrice",
+ type: {
+ name: "Number"
+ }
+ },
+ currencyCode: {
+ readOnly: true,
+ serializedName: "currencyCode",
+ type: {
+ name: "String"
+ }
+ },
+ offerId: {
+ readOnly: true,
+ serializedName: "offerId",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const PriceSheetResult: msRest.CompositeMapper = {
+ serializedName: "PriceSheetResult",
+ type: {
+ name: "Composite",
+ className: "PriceSheetResult",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ pricesheets: {
+ readOnly: true,
+ serializedName: "properties.pricesheets",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "PriceSheetProperties"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "properties.nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ForecastPropertiesConfidenceLevelsItem: msRest.CompositeMapper = {
+ serializedName: "ForecastProperties_confidenceLevelsItem",
+ type: {
+ name: "Composite",
+ className: "ForecastPropertiesConfidenceLevelsItem",
+ modelProperties: {
+ percentage: {
+ readOnly: true,
+ serializedName: "percentage",
+ type: {
+ name: "Number"
+ }
+ },
+ bound: {
+ serializedName: "bound",
+ type: {
+ name: "String"
+ }
+ },
+ value: {
+ readOnly: true,
+ serializedName: "value",
+ type: {
+ name: "Number"
+ }
+ }
+ }
+ }
+};
+
+export const Forecast: msRest.CompositeMapper = {
+ serializedName: "Forecast",
+ type: {
+ name: "Composite",
+ className: "Forecast",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ usageDate: {
+ readOnly: true,
+ serializedName: "properties.usageDate",
+ type: {
+ name: "String"
+ }
+ },
+ grain: {
+ serializedName: "properties.grain",
+ type: {
+ name: "String"
+ }
+ },
+ charge: {
+ readOnly: true,
+ serializedName: "properties.charge",
+ type: {
+ name: "Number"
+ }
+ },
+ currency: {
+ readOnly: true,
+ serializedName: "properties.currency",
+ type: {
+ name: "String"
+ }
+ },
+ chargeType: {
+ serializedName: "properties.chargeType",
+ type: {
+ name: "String"
+ }
+ },
+ confidenceLevels: {
+ readOnly: true,
+ serializedName: "properties.confidenceLevels",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ForecastPropertiesConfidenceLevelsItem"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const ManagementGroupAggregatedCostResult: msRest.CompositeMapper = {
+ serializedName: "ManagementGroupAggregatedCostResult",
+ type: {
+ name: "Composite",
+ className: "ManagementGroupAggregatedCostResult",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ billingPeriodId: {
+ readOnly: true,
+ serializedName: "properties.billingPeriodId",
+ type: {
+ name: "String"
+ }
+ },
+ usageStart: {
+ readOnly: true,
+ serializedName: "properties.usageStart",
+ type: {
+ name: "DateTime"
+ }
+ },
+ usageEnd: {
+ readOnly: true,
+ serializedName: "properties.usageEnd",
+ type: {
+ name: "DateTime"
+ }
+ },
+ azureCharges: {
+ readOnly: true,
+ serializedName: "properties.azureCharges",
+ type: {
+ name: "Number"
+ }
+ },
+ marketplaceCharges: {
+ readOnly: true,
+ serializedName: "properties.marketplaceCharges",
+ type: {
+ name: "Number"
+ }
+ },
+ chargesBilledSeparately: {
+ readOnly: true,
+ serializedName: "properties.chargesBilledSeparately",
+ type: {
+ name: "Number"
+ }
+ },
+ currency: {
+ readOnly: true,
+ serializedName: "properties.currency",
+ type: {
+ name: "String"
+ }
+ },
+ children: {
+ serializedName: "properties.children",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ManagementGroupAggregatedCostResult"
+ }
+ }
+ }
+ },
+ includedSubscriptions: {
+ serializedName: "properties.includedSubscriptions",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ },
+ excludedSubscriptions: {
+ serializedName: "properties.excludedSubscriptions",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const ChargeSummary: msRest.CompositeMapper = {
+ serializedName: "ChargeSummary",
+ type: {
+ name: "Composite",
+ className: "ChargeSummary",
+ modelProperties: {
+ ...Resource.type.modelProperties,
+ billingPeriodId: {
+ readOnly: true,
+ serializedName: "properties.billingPeriodId",
+ type: {
+ name: "String"
+ }
+ },
+ usageStart: {
+ readOnly: true,
+ serializedName: "properties.usageStart",
+ type: {
+ name: "String"
+ }
+ },
+ usageEnd: {
+ readOnly: true,
+ serializedName: "properties.usageEnd",
+ type: {
+ name: "String"
+ }
+ },
+ azureCharges: {
+ readOnly: true,
+ serializedName: "properties.azureCharges",
+ type: {
+ name: "Number"
+ }
+ },
+ chargesBilledSeparately: {
+ readOnly: true,
+ serializedName: "properties.chargesBilledSeparately",
+ type: {
+ name: "Number"
+ }
+ },
+ marketplaceCharges: {
+ readOnly: true,
+ serializedName: "properties.marketplaceCharges",
+ type: {
+ name: "Number"
+ }
+ },
+ currency: {
+ readOnly: true,
+ serializedName: "properties.currency",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ChargesListResult: msRest.CompositeMapper = {
+ serializedName: "ChargesListResult",
+ type: {
+ name: "Composite",
+ className: "ChargesListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "value",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ChargeSummary"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const ErrorDetails: msRest.CompositeMapper = {
+ serializedName: "ErrorDetails",
+ type: {
+ name: "Composite",
+ className: "ErrorDetails",
+ modelProperties: {
+ code: {
+ readOnly: true,
+ serializedName: "code",
+ type: {
+ name: "String"
+ }
+ },
+ message: {
+ readOnly: true,
+ serializedName: "message",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ErrorResponse: msRest.CompositeMapper = {
+ serializedName: "ErrorResponse",
+ type: {
+ name: "Composite",
+ className: "ErrorResponse",
+ modelProperties: {
+ error: {
+ serializedName: "error",
+ type: {
+ name: "Composite",
+ className: "ErrorDetails"
+ }
+ }
+ }
+ }
+};
+
+export const OperationDisplay: msRest.CompositeMapper = {
+ serializedName: "Operation_display",
+ type: {
+ name: "Composite",
+ className: "OperationDisplay",
+ modelProperties: {
+ provider: {
+ readOnly: true,
+ serializedName: "provider",
+ type: {
+ name: "String"
+ }
+ },
+ resource: {
+ readOnly: true,
+ serializedName: "resource",
+ type: {
+ name: "String"
+ }
+ },
+ operation: {
+ readOnly: true,
+ serializedName: "operation",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const Operation: msRest.CompositeMapper = {
+ serializedName: "Operation",
+ type: {
+ name: "Composite",
+ className: "Operation",
+ modelProperties: {
+ name: {
+ readOnly: true,
+ serializedName: "name",
+ type: {
+ name: "String"
+ }
+ },
+ display: {
+ serializedName: "display",
+ type: {
+ name: "Composite",
+ className: "OperationDisplay"
+ }
+ }
+ }
+ }
+};
+
+export const ResourceAttributes: msRest.CompositeMapper = {
+ serializedName: "ResourceAttributes",
+ type: {
+ name: "Composite",
+ className: "ResourceAttributes",
+ modelProperties: {
+ location: {
+ readOnly: true,
+ serializedName: "location",
+ type: {
+ name: "String"
+ }
+ },
+ sku: {
+ readOnly: true,
+ serializedName: "sku",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const UsageDetailsDownloadHeaders: msRest.CompositeMapper = {
+ serializedName: "usagedetails-download-headers",
+ type: {
+ name: "Composite",
+ className: "UsageDetailsDownloadHeaders",
+ modelProperties: {
+ location: {
+ serializedName: "location",
+ type: {
+ name: "String"
+ }
+ },
+ retryAfter: {
+ serializedName: "retry-after",
+ type: {
+ name: "String"
+ }
+ },
+ azureAsyncOperation: {
+ serializedName: "azure-asyncoperation",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const UsageDetailsListResult: msRest.CompositeMapper = {
+ serializedName: "UsageDetailsListResult",
+ type: {
+ name: "Composite",
+ className: "UsageDetailsListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "UsageDetail"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const MarketplacesListResult: msRest.CompositeMapper = {
+ serializedName: "MarketplacesListResult",
+ type: {
+ name: "Composite",
+ className: "MarketplacesListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "Marketplace"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const BudgetsListResult: msRest.CompositeMapper = {
+ serializedName: "BudgetsListResult",
+ type: {
+ name: "Composite",
+ className: "BudgetsListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "Budget"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ReservationSummariesListResult: msRest.CompositeMapper = {
+ serializedName: "ReservationSummariesListResult",
+ type: {
+ name: "Composite",
+ className: "ReservationSummariesListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ReservationSummary"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ReservationDetailsListResult: msRest.CompositeMapper = {
+ serializedName: "ReservationDetailsListResult",
+ type: {
+ name: "Composite",
+ className: "ReservationDetailsListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ReservationDetail"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ReservationRecommendationsListResult: msRest.CompositeMapper = {
+ serializedName: "ReservationRecommendationsListResult",
+ type: {
+ name: "Composite",
+ className: "ReservationRecommendationsListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "ReservationRecommendation"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
+
+export const ForecastsListResult: msRest.CompositeMapper = {
+ serializedName: "ForecastsListResult",
+ type: {
+ name: "Composite",
+ className: "ForecastsListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "Forecast"
+ }
+ }
+ }
+ }
+ }
+ }
+};
+
+export const OperationListResult: msRest.CompositeMapper = {
+ serializedName: "OperationListResult",
+ type: {
+ name: "Composite",
+ className: "OperationListResult",
+ modelProperties: {
+ value: {
+ readOnly: true,
+ serializedName: "",
+ type: {
+ name: "Sequence",
+ element: {
+ type: {
+ name: "Composite",
+ className: "Operation"
+ }
+ }
+ }
+ },
+ nextLink: {
+ readOnly: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ }
+ }
+ }
+};
diff --git a/sdk/consumption/arm-consumption/lib/models/marketplacesMappers.ts b/sdk/consumption/arm-consumption/lib/models/marketplacesMappers.ts
new file mode 100644
index 000000000000..5bd0fac6b8ea
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/marketplacesMappers.ts
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ MarketplacesListResult,
+ Marketplace,
+ Resource,
+ BaseResource,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/operationsMappers.ts b/sdk/consumption/arm-consumption/lib/models/operationsMappers.ts
new file mode 100644
index 000000000000..22478f5be09f
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/operationsMappers.ts
@@ -0,0 +1,18 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ OperationListResult,
+ Operation,
+ OperationDisplay,
+ ErrorResponse,
+ ErrorDetails
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/parameters.ts b/sdk/consumption/arm-consumption/lib/models/parameters.ts
new file mode 100644
index 000000000000..53a562490137
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/parameters.ts
@@ -0,0 +1,208 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+
+export const acceptLanguage: msRest.OperationParameter = {
+ parameterPath: "acceptLanguage",
+ mapper: {
+ serializedName: "accept-language",
+ defaultValue: 'en-US',
+ type: {
+ name: "String"
+ }
+ }
+};
+export const apiVersion: msRest.OperationQueryParameter = {
+ parameterPath: "apiVersion",
+ mapper: {
+ required: true,
+ serializedName: "api-version",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const billingAccountId: msRest.OperationURLParameter = {
+ parameterPath: "billingAccountId",
+ mapper: {
+ required: true,
+ serializedName: "billingAccountId",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const billingPeriodName: msRest.OperationURLParameter = {
+ parameterPath: "billingPeriodName",
+ mapper: {
+ required: true,
+ serializedName: "billingPeriodName",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const budgetName: msRest.OperationURLParameter = {
+ parameterPath: "budgetName",
+ mapper: {
+ required: true,
+ serializedName: "budgetName",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const expand: msRest.OperationQueryParameter = {
+ parameterPath: [
+ "options",
+ "expand"
+ ],
+ mapper: {
+ serializedName: "$expand",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const filter0: msRest.OperationQueryParameter = {
+ parameterPath: [
+ "options",
+ "filter"
+ ],
+ mapper: {
+ serializedName: "$filter",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const filter1: msRest.OperationQueryParameter = {
+ parameterPath: "filter",
+ mapper: {
+ required: true,
+ serializedName: "$filter",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const grain: msRest.OperationQueryParameter = {
+ parameterPath: "grain",
+ mapper: {
+ required: true,
+ serializedName: "grain",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const managementGroupId: msRest.OperationURLParameter = {
+ parameterPath: "managementGroupId",
+ mapper: {
+ required: true,
+ serializedName: "managementGroupId",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const metric: msRest.OperationQueryParameter = {
+ parameterPath: [
+ "options",
+ "metric"
+ ],
+ mapper: {
+ serializedName: "metric",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const nextPageLink: msRest.OperationURLParameter = {
+ parameterPath: "nextPageLink",
+ mapper: {
+ required: true,
+ serializedName: "nextLink",
+ type: {
+ name: "String"
+ }
+ },
+ skipEncoding: true
+};
+export const reservationId: msRest.OperationURLParameter = {
+ parameterPath: "reservationId",
+ mapper: {
+ required: true,
+ serializedName: "reservationId",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const reservationOrderId: msRest.OperationURLParameter = {
+ parameterPath: "reservationOrderId",
+ mapper: {
+ required: true,
+ serializedName: "reservationOrderId",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const scope: msRest.OperationURLParameter = {
+ parameterPath: "scope",
+ mapper: {
+ required: true,
+ serializedName: "scope",
+ type: {
+ name: "String"
+ }
+ },
+ skipEncoding: true
+};
+export const skiptoken: msRest.OperationQueryParameter = {
+ parameterPath: [
+ "options",
+ "skiptoken"
+ ],
+ mapper: {
+ serializedName: "$skiptoken",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const subscriptionId: msRest.OperationURLParameter = {
+ parameterPath: "subscriptionId",
+ mapper: {
+ required: true,
+ serializedName: "subscriptionId",
+ type: {
+ name: "String"
+ }
+ }
+};
+export const top: msRest.OperationQueryParameter = {
+ parameterPath: [
+ "options",
+ "top"
+ ],
+ mapper: {
+ serializedName: "$top",
+ constraints: {
+ InclusiveMaximum: 1000,
+ InclusiveMinimum: 1
+ },
+ type: {
+ name: "Number"
+ }
+ }
+};
diff --git a/sdk/consumption/arm-consumption/lib/models/priceSheetMappers.ts b/sdk/consumption/arm-consumption/lib/models/priceSheetMappers.ts
new file mode 100644
index 000000000000..0fc388696abf
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/priceSheetMappers.ts
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ PriceSheetResult,
+ Resource,
+ BaseResource,
+ PriceSheetProperties,
+ MeterDetails,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/reservationRecommendationsMappers.ts b/sdk/consumption/arm-consumption/lib/models/reservationRecommendationsMappers.ts
new file mode 100644
index 000000000000..14979c923c67
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/reservationRecommendationsMappers.ts
@@ -0,0 +1,17 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ReservationRecommendationsListResult,
+ ReservationRecommendation,
+ ErrorResponse,
+ ErrorDetails
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/reservationsDetailsMappers.ts b/sdk/consumption/arm-consumption/lib/models/reservationsDetailsMappers.ts
new file mode 100644
index 000000000000..a13941b60a82
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/reservationsDetailsMappers.ts
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ReservationDetailsListResult,
+ ReservationDetail,
+ Resource,
+ BaseResource,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/reservationsSummariesMappers.ts b/sdk/consumption/arm-consumption/lib/models/reservationsSummariesMappers.ts
new file mode 100644
index 000000000000..19708859edda
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/reservationsSummariesMappers.ts
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ ReservationSummariesListResult,
+ ReservationSummary,
+ Resource,
+ BaseResource,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/tagsMappers.ts b/sdk/consumption/arm-consumption/lib/models/tagsMappers.ts
new file mode 100644
index 000000000000..d49367c048e7
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/tagsMappers.ts
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ TagsResult,
+ ProxyResource,
+ BaseResource,
+ Tag,
+ ErrorResponse,
+ ErrorDetails,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification,
+ Resource,
+ UsageDetail,
+ MeterDetailsResponse,
+ UsageDetailsDownloadResponse,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/models/usageDetailsMappers.ts b/sdk/consumption/arm-consumption/lib/models/usageDetailsMappers.ts
new file mode 100644
index 000000000000..4754b90ab231
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/models/usageDetailsMappers.ts
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export {
+ UsageDetailsListResult,
+ UsageDetail,
+ Resource,
+ BaseResource,
+ MeterDetailsResponse,
+ ErrorResponse,
+ ErrorDetails,
+ UsageDetailsDownloadResponse,
+ UsageDetailsDownloadHeaders,
+ Marketplace,
+ Balance,
+ BalancePropertiesNewPurchasesDetailsItem,
+ BalancePropertiesAdjustmentDetailsItem,
+ ReservationSummary,
+ ReservationDetail,
+ PriceSheetResult,
+ PriceSheetProperties,
+ MeterDetails,
+ Forecast,
+ ForecastPropertiesConfidenceLevelsItem,
+ ManagementGroupAggregatedCostResult,
+ ChargeSummary,
+ ProxyResource,
+ TagsResult,
+ Tag,
+ Budget,
+ BudgetTimePeriod,
+ Filters,
+ CurrentSpend,
+ Notification
+} from "../models/mappers";
+
diff --git a/sdk/consumption/arm-consumption/lib/operations/aggregatedCost.ts b/sdk/consumption/arm-consumption/lib/operations/aggregatedCost.ts
new file mode 100644
index 000000000000..b3747dd1e77e
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/aggregatedCost.ts
@@ -0,0 +1,140 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/aggregatedCostMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a AggregatedCost. */
+export class AggregatedCost {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a AggregatedCost.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Provides the aggregate cost of a management group and all child management groups by current
+ * billing period.
+ * @param managementGroupId Azure Management Group ID.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ getByManagementGroup(managementGroupId: string, options?: Models.AggregatedCostGetByManagementGroupOptionalParams): Promise;
+ /**
+ * @param managementGroupId Azure Management Group ID.
+ * @param callback The callback
+ */
+ getByManagementGroup(managementGroupId: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param managementGroupId Azure Management Group ID.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ getByManagementGroup(managementGroupId: string, options: Models.AggregatedCostGetByManagementGroupOptionalParams, callback: msRest.ServiceCallback): void;
+ getByManagementGroup(managementGroupId: string, options?: Models.AggregatedCostGetByManagementGroupOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ managementGroupId,
+ options
+ },
+ getByManagementGroupOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Provides the aggregate cost of a management group and all child management groups by specified
+ * billing period
+ * @param managementGroupId Azure Management Group ID.
+ * @param billingPeriodName Billing Period Name.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ getForBillingPeriodByManagementGroup(managementGroupId: string, billingPeriodName: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param managementGroupId Azure Management Group ID.
+ * @param billingPeriodName Billing Period Name.
+ * @param callback The callback
+ */
+ getForBillingPeriodByManagementGroup(managementGroupId: string, billingPeriodName: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param managementGroupId Azure Management Group ID.
+ * @param billingPeriodName Billing Period Name.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ getForBillingPeriodByManagementGroup(managementGroupId: string, billingPeriodName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ getForBillingPeriodByManagementGroup(managementGroupId: string, billingPeriodName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ managementGroupId,
+ billingPeriodName,
+ options
+ },
+ getForBillingPeriodByManagementGroupOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const getByManagementGroupOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Consumption/aggregatedcost",
+ urlParameters: [
+ Parameters.managementGroupId
+ ],
+ queryParameters: [
+ Parameters.apiVersion,
+ Parameters.filter0
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ManagementGroupAggregatedCostResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const getForBillingPeriodByManagementGroupOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}/Microsoft.Consumption/aggregatedcost",
+ urlParameters: [
+ Parameters.managementGroupId,
+ Parameters.billingPeriodName
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ManagementGroupAggregatedCostResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/balances.ts b/sdk/consumption/arm-consumption/lib/operations/balances.ts
new file mode 100644
index 000000000000..2bce5d1e065c
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/balances.ts
@@ -0,0 +1,139 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/balancesMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Balances. */
+export class Balances {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Balances.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Gets the balances for a scope by billingAccountId. Balances are available via this API only for
+ * May 1, 2014 or later.
+ * @param billingAccountId BillingAccount ID
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ getByBillingAccount(billingAccountId: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param billingAccountId BillingAccount ID
+ * @param callback The callback
+ */
+ getByBillingAccount(billingAccountId: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param billingAccountId BillingAccount ID
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ getByBillingAccount(billingAccountId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ getByBillingAccount(billingAccountId: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ billingAccountId,
+ options
+ },
+ getByBillingAccountOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Gets the balances for a scope by billing period and billingAccountId. Balances are available via
+ * this API only for May 1, 2014 or later.
+ * @param billingAccountId BillingAccount ID
+ * @param billingPeriodName Billing Period Name.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ getForBillingPeriodByBillingAccount(billingAccountId: string, billingPeriodName: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param billingAccountId BillingAccount ID
+ * @param billingPeriodName Billing Period Name.
+ * @param callback The callback
+ */
+ getForBillingPeriodByBillingAccount(billingAccountId: string, billingPeriodName: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param billingAccountId BillingAccount ID
+ * @param billingPeriodName Billing Period Name.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ getForBillingPeriodByBillingAccount(billingAccountId: string, billingPeriodName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ getForBillingPeriodByBillingAccount(billingAccountId: string, billingPeriodName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ billingAccountId,
+ billingPeriodName,
+ options
+ },
+ getForBillingPeriodByBillingAccountOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const getByBillingAccountOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Billing/billingAccounts/{billingAccountId}/providers/Microsoft.Consumption/balances",
+ urlParameters: [
+ Parameters.billingAccountId
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.Balance
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const getForBillingPeriodByBillingAccountOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Billing/billingAccounts/{billingAccountId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}/providers/Microsoft.Consumption/balances",
+ urlParameters: [
+ Parameters.billingAccountId,
+ Parameters.billingPeriodName
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.Balance
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/budgets.ts b/sdk/consumption/arm-consumption/lib/operations/budgets.ts
new file mode 100644
index 000000000000..445f41c5ee03
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/budgets.ts
@@ -0,0 +1,468 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/budgetsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Budgets. */
+export class Budgets {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Budgets.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists all budgets for the defined scope.
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(scope: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param callback The callback
+ */
+ list(scope: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(scope: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ list(scope: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Gets the budget for the scope by budget name.
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ get(scope: string, budgetName: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param callback The callback
+ */
+ get(scope: string, budgetName: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ get(scope: string, budgetName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ get(scope: string, budgetName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ budgetName,
+ options
+ },
+ getOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * The operation to create or update a budget. Update operation requires latest eTag to be set in
+ * the request mandatorily. You may obtain the latest eTag by performing a get operation. Create
+ * operation does not require eTag.
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param parameters Parameters supplied to the Create Budget operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ createOrUpdate(scope: string, budgetName: string, parameters: Models.Budget, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param parameters Parameters supplied to the Create Budget operation.
+ * @param callback The callback
+ */
+ createOrUpdate(scope: string, budgetName: string, parameters: Models.Budget, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param parameters Parameters supplied to the Create Budget operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ createOrUpdate(scope: string, budgetName: string, parameters: Models.Budget, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ createOrUpdate(scope: string, budgetName: string, parameters: Models.Budget, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ budgetName,
+ parameters,
+ options
+ },
+ createOrUpdateOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * The operation to delete a budget.
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ deleteMethod(scope: string, budgetName: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param callback The callback
+ */
+ deleteMethod(scope: string, budgetName: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with budget operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope,
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}'
+ * for billingProfile scope,
+ * 'providers/Microsoft.Billing/billingAccounts/{billingAccountId}/invoiceSections/{invoiceSectionId}'
+ * for invoiceSection scope.
+ * @param budgetName Budget Name.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ deleteMethod(scope: string, budgetName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ deleteMethod(scope: string, budgetName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ budgetName,
+ options
+ },
+ deleteMethodOperationSpec,
+ callback);
+ }
+
+ /**
+ * Lists all budgets for the defined scope.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "{scope}/providers/Microsoft.Consumption/budgets",
+ urlParameters: [
+ Parameters.scope
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.BudgetsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const getOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "{scope}/providers/Microsoft.Consumption/budgets/{budgetName}",
+ urlParameters: [
+ Parameters.scope,
+ Parameters.budgetName
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.Budget
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const createOrUpdateOperationSpec: msRest.OperationSpec = {
+ httpMethod: "PUT",
+ path: "{scope}/providers/Microsoft.Consumption/budgets/{budgetName}",
+ urlParameters: [
+ Parameters.scope,
+ Parameters.budgetName
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ requestBody: {
+ parameterPath: "parameters",
+ mapper: {
+ ...Mappers.Budget,
+ required: true
+ }
+ },
+ responses: {
+ 200: {
+ bodyMapper: Mappers.Budget
+ },
+ 201: {
+ bodyMapper: Mappers.Budget
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const deleteMethodOperationSpec: msRest.OperationSpec = {
+ httpMethod: "DELETE",
+ path: "{scope}/providers/Microsoft.Consumption/budgets/{budgetName}",
+ urlParameters: [
+ Parameters.scope,
+ Parameters.budgetName
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {},
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.BudgetsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/charges.ts b/sdk/consumption/arm-consumption/lib/operations/charges.ts
new file mode 100644
index 000000000000..5017ce264f26
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/charges.ts
@@ -0,0 +1,103 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/chargesMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Charges. */
+export class Charges {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Charges.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the charges based for the defined scope.
+ * @param scope The scope associated with usage details operations. This includes
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope and
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope. For department and enrollment accounts, you can also add billing
+ * period to the scope using '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For
+ * e.g. to specify billing period at department scope use
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByScope(scope: string, options?: Models.ChargesListByScopeOptionalParams): Promise;
+ /**
+ * @param scope The scope associated with usage details operations. This includes
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope and
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope. For department and enrollment accounts, you can also add billing
+ * period to the scope using '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For
+ * e.g. to specify billing period at department scope use
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param callback The callback
+ */
+ listByScope(scope: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with usage details operations. This includes
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope and
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope. For department and enrollment accounts, you can also add billing
+ * period to the scope using '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For
+ * e.g. to specify billing period at department scope use
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByScope(scope: string, options: Models.ChargesListByScopeOptionalParams, callback: msRest.ServiceCallback): void;
+ listByScope(scope: string, options?: Models.ChargesListByScopeOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ options
+ },
+ listByScopeOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listByScopeOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "{scope}/providers/Microsoft.Consumption/charges",
+ urlParameters: [
+ Parameters.scope
+ ],
+ queryParameters: [
+ Parameters.apiVersion,
+ Parameters.filter0
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ChargeSummary
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/forecasts.ts b/sdk/consumption/arm-consumption/lib/operations/forecasts.ts
new file mode 100644
index 000000000000..cffd25eed466
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/forecasts.ts
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/forecastsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Forecasts. */
+export class Forecasts {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Forecasts.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the forecast charges by subscriptionId.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(options?: Models.ForecastsListOptionalParams): Promise;
+ /**
+ * @param callback The callback
+ */
+ list(callback: msRest.ServiceCallback): void;
+ /**
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(options: Models.ForecastsListOptionalParams, callback: msRest.ServiceCallback): void;
+ list(options?: Models.ForecastsListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "subscriptions/{subscriptionId}/providers/Microsoft.Consumption/forecasts",
+ urlParameters: [
+ Parameters.subscriptionId
+ ],
+ queryParameters: [
+ Parameters.filter0,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ForecastsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/index.ts b/sdk/consumption/arm-consumption/lib/operations/index.ts
new file mode 100644
index 000000000000..b4213dfbf677
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/index.ts
@@ -0,0 +1,23 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+export * from "./usageDetails";
+export * from "./marketplaces";
+export * from "./budgets";
+export * from "./tags";
+export * from "./charges";
+export * from "./balances";
+export * from "./reservationsSummaries";
+export * from "./reservationsDetails";
+export * from "./reservationRecommendations";
+export * from "./priceSheet";
+export * from "./forecasts";
+export * from "./operations";
+export * from "./aggregatedCost";
diff --git a/sdk/consumption/arm-consumption/lib/operations/marketplaces.ts b/sdk/consumption/arm-consumption/lib/operations/marketplaces.ts
new file mode 100644
index 000000000000..e423551d66c6
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/marketplaces.ts
@@ -0,0 +1,168 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/marketplacesMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Marketplaces. */
+export class Marketplaces {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Marketplaces.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the marketplaces for a scope at the defined scope. Marketplaces are available via this API
+ * only for May 1, 2014 or later.
+ * @param scope The scope associated with marketplace operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and
+ * ManagementGroup, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(scope: string, options?: Models.MarketplacesListOptionalParams): Promise;
+ /**
+ * @param scope The scope associated with marketplace operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and
+ * ManagementGroup, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param callback The callback
+ */
+ list(scope: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with marketplace operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and
+ * ManagementGroup, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(scope: string, options: Models.MarketplacesListOptionalParams, callback: msRest.ServiceCallback): void;
+ list(scope: string, options?: Models.MarketplacesListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the marketplaces for a scope at the defined scope. Marketplaces are available via this API
+ * only for May 1, 2014 or later.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "{scope}/providers/Microsoft.Consumption/marketplaces",
+ urlParameters: [
+ Parameters.scope
+ ],
+ queryParameters: [
+ Parameters.filter0,
+ Parameters.top,
+ Parameters.skiptoken,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.MarketplacesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.MarketplacesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/operations.ts b/sdk/consumption/arm-consumption/lib/operations/operations.ts
new file mode 100644
index 000000000000..f5d1f7c74f7e
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/operations.ts
@@ -0,0 +1,123 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/operationsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Operations. */
+export class Operations {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Operations.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists all of the available consumption REST API operations.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param callback The callback
+ */
+ list(callback: msRest.ServiceCallback): void;
+ /**
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ list(options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists all of the available consumption REST API operations.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Consumption/operations",
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.OperationListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.OperationListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/priceSheet.ts b/sdk/consumption/arm-consumption/lib/operations/priceSheet.ts
new file mode 100644
index 000000000000..acc62419b42a
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/priceSheet.ts
@@ -0,0 +1,137 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/priceSheetMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a PriceSheet. */
+export class PriceSheet {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a PriceSheet.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Gets the price sheet for a scope by subscriptionId. Price sheet is available via this API only
+ * for May 1, 2014 or later.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ get(options?: Models.PriceSheetGetOptionalParams): Promise;
+ /**
+ * @param callback The callback
+ */
+ get(callback: msRest.ServiceCallback): void;
+ /**
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ get(options: Models.PriceSheetGetOptionalParams, callback: msRest.ServiceCallback): void;
+ get(options?: Models.PriceSheetGetOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ options
+ },
+ getOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Get 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.
+ * @param billingPeriodName Billing Period Name.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ getByBillingPeriod(billingPeriodName: string, options?: Models.PriceSheetGetByBillingPeriodOptionalParams): Promise;
+ /**
+ * @param billingPeriodName Billing Period Name.
+ * @param callback The callback
+ */
+ getByBillingPeriod(billingPeriodName: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param billingPeriodName Billing Period Name.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ getByBillingPeriod(billingPeriodName: string, options: Models.PriceSheetGetByBillingPeriodOptionalParams, callback: msRest.ServiceCallback): void;
+ getByBillingPeriod(billingPeriodName: string, options?: Models.PriceSheetGetByBillingPeriodOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ billingPeriodName,
+ options
+ },
+ getByBillingPeriodOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const getOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "subscriptions/{subscriptionId}/providers/Microsoft.Consumption/pricesheets/default",
+ urlParameters: [
+ Parameters.subscriptionId
+ ],
+ queryParameters: [
+ Parameters.expand,
+ Parameters.skiptoken,
+ Parameters.top,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.PriceSheetResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const getByBillingPeriodOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "subscriptions/{subscriptionId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}/providers/Microsoft.Consumption/pricesheets/default",
+ urlParameters: [
+ Parameters.subscriptionId,
+ Parameters.billingPeriodName
+ ],
+ queryParameters: [
+ Parameters.expand,
+ Parameters.skiptoken,
+ Parameters.top,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.PriceSheetResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/reservationRecommendations.ts b/sdk/consumption/arm-consumption/lib/operations/reservationRecommendations.ts
new file mode 100644
index 000000000000..861bbe4243b1
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/reservationRecommendations.ts
@@ -0,0 +1,127 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/reservationRecommendationsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a ReservationRecommendations. */
+export class ReservationRecommendations {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a ReservationRecommendations.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * List of recommendations for purchasing reserved instances.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(options?: Models.ReservationRecommendationsListOptionalParams): Promise;
+ /**
+ * @param callback The callback
+ */
+ list(callback: msRest.ServiceCallback): void;
+ /**
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(options: Models.ReservationRecommendationsListOptionalParams, callback: msRest.ServiceCallback): void;
+ list(options?: Models.ReservationRecommendationsListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * List of recommendations for purchasing reserved instances.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "subscriptions/{subscriptionId}/providers/Microsoft.Consumption/reservationRecommendations",
+ urlParameters: [
+ Parameters.subscriptionId
+ ],
+ queryParameters: [
+ Parameters.filter0,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationRecommendationsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationRecommendationsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/reservationsDetails.ts b/sdk/consumption/arm-consumption/lib/operations/reservationsDetails.ts
new file mode 100644
index 000000000000..c712a50bbfcc
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/reservationsDetails.ts
@@ -0,0 +1,251 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/reservationsDetailsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a ReservationsDetails. */
+export class ReservationsDetails {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a ReservationsDetails.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the reservations details for provided date range.
+ * @param reservationOrderId Order Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrder(reservationOrderId: string, filter: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param callback The callback
+ */
+ listByReservationOrder(reservationOrderId: string, filter: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrder(reservationOrderId: string, filter: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrder(reservationOrderId: string, filter: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ reservationOrderId,
+ filter,
+ options
+ },
+ listByReservationOrderOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations details for provided date range.
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, filter: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, filter: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param filter Filter reservation details by date range. The properties/UsageDate for start date
+ * and end date. The filter supports 'le' and 'ge'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, filter: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, filter: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ reservationOrderId,
+ reservationId,
+ filter,
+ options
+ },
+ listByReservationOrderAndReservationOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations details for provided date range.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listByReservationOrderNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrderNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listByReservationOrderNextOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations details for provided date range.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrderAndReservationNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listByReservationOrderAndReservationNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listByReservationOrderOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Capacity/reservationorders/{reservationOrderId}/providers/Microsoft.Consumption/reservationDetails",
+ urlParameters: [
+ Parameters.reservationOrderId
+ ],
+ queryParameters: [
+ Parameters.filter1,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationDetailsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderAndReservationOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Capacity/reservationorders/{reservationOrderId}/reservations/{reservationId}/providers/Microsoft.Consumption/reservationDetails",
+ urlParameters: [
+ Parameters.reservationOrderId,
+ Parameters.reservationId
+ ],
+ queryParameters: [
+ Parameters.filter1,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationDetailsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationDetailsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderAndReservationNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationDetailsListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/reservationsSummaries.ts b/sdk/consumption/arm-consumption/lib/operations/reservationsSummaries.ts
new file mode 100644
index 000000000000..47d212f52431
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/reservationsSummaries.ts
@@ -0,0 +1,247 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/reservationsSummariesMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a ReservationsSummaries. */
+export class ReservationsSummaries {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a ReservationsSummaries.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the reservations summaries for daily or monthly grain.
+ * @param reservationOrderId Order Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrder(reservationOrderId: string, grain: Models.Datagrain, options?: Models.ReservationsSummariesListByReservationOrderOptionalParams): Promise;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param callback The callback
+ */
+ listByReservationOrder(reservationOrderId: string, grain: Models.Datagrain, callback: msRest.ServiceCallback): void;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrder(reservationOrderId: string, grain: Models.Datagrain, options: Models.ReservationsSummariesListByReservationOrderOptionalParams, callback: msRest.ServiceCallback): void;
+ listByReservationOrder(reservationOrderId: string, grain: Models.Datagrain, options?: Models.ReservationsSummariesListByReservationOrderOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ reservationOrderId,
+ grain,
+ options
+ },
+ listByReservationOrderOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations summaries for daily or monthly grain.
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, grain: Models.Datagrain, options?: Models.ReservationsSummariesListByReservationOrderAndReservationOptionalParams): Promise;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, grain: Models.Datagrain, callback: msRest.ServiceCallback): void;
+ /**
+ * @param reservationOrderId Order Id of the reservation
+ * @param reservationId Id of the reservation
+ * @param grain Can be daily or monthly. Possible values include: 'DailyGrain', 'MonthlyGrain'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, grain: Models.Datagrain, options: Models.ReservationsSummariesListByReservationOrderAndReservationOptionalParams, callback: msRest.ServiceCallback): void;
+ listByReservationOrderAndReservation(reservationOrderId: string, reservationId: string, grain: Models.Datagrain, options?: Models.ReservationsSummariesListByReservationOrderAndReservationOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ reservationOrderId,
+ reservationId,
+ grain,
+ options
+ },
+ listByReservationOrderAndReservationOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations summaries for daily or monthly grain.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listByReservationOrderNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrderNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listByReservationOrderNextOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Lists the reservations summaries for daily or monthly grain.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ listByReservationOrderAndReservationNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ listByReservationOrderAndReservationNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ nextPageLink,
+ options
+ },
+ listByReservationOrderAndReservationNextOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const listByReservationOrderOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Capacity/reservationorders/{reservationOrderId}/providers/Microsoft.Consumption/reservationSummaries",
+ urlParameters: [
+ Parameters.reservationOrderId
+ ],
+ queryParameters: [
+ Parameters.grain,
+ Parameters.filter0,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationSummariesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderAndReservationOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "providers/Microsoft.Capacity/reservationorders/{reservationOrderId}/reservations/{reservationId}/providers/Microsoft.Consumption/reservationSummaries",
+ urlParameters: [
+ Parameters.reservationOrderId,
+ Parameters.reservationId
+ ],
+ queryParameters: [
+ Parameters.grain,
+ Parameters.filter0,
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationSummariesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationSummariesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
+
+const listByReservationOrderAndReservationNextOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ baseUrl: "https://management.azure.com",
+ path: "{nextLink}",
+ urlParameters: [
+ Parameters.nextPageLink
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.ReservationSummariesListResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/tags.ts b/sdk/consumption/arm-consumption/lib/operations/tags.ts
new file mode 100644
index 000000000000..3d2b5a4046e1
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/tags.ts
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as Models from "../models";
+import * as Mappers from "../models/tagsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a Tags. */
+export class Tags {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a Tags.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Get all available tag keys for the defined scope
+ * @param scope The scope associated with tags operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope and
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope..
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ get(scope: string, options?: msRest.RequestOptionsBase): Promise;
+ /**
+ * @param scope The scope associated with tags operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope and
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope..
+ * @param callback The callback
+ */
+ get(scope: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with tags operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for
+ * Department scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}'
+ * for EnrollmentAccount scope and
+ * '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management Group
+ * scope..
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ get(scope: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void;
+ get(scope: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ options
+ },
+ getOperationSpec,
+ callback) as Promise;
+ }
+}
+
+// Operation Specifications
+const serializer = new msRest.Serializer(Mappers);
+const getOperationSpec: msRest.OperationSpec = {
+ httpMethod: "GET",
+ path: "{scope}/providers/Microsoft.Consumption/tags",
+ urlParameters: [
+ Parameters.scope
+ ],
+ queryParameters: [
+ Parameters.apiVersion
+ ],
+ headerParameters: [
+ Parameters.acceptLanguage
+ ],
+ responses: {
+ 200: {
+ bodyMapper: Mappers.TagsResult
+ },
+ default: {
+ bodyMapper: Mappers.ErrorResponse
+ }
+ },
+ serializer
+};
diff --git a/sdk/consumption/arm-consumption/lib/operations/usageDetails.ts b/sdk/consumption/arm-consumption/lib/operations/usageDetails.ts
new file mode 100644
index 000000000000..c422a93f3e48
--- /dev/null
+++ b/sdk/consumption/arm-consumption/lib/operations/usageDetails.ts
@@ -0,0 +1,248 @@
+/*
+ * Copyright (c) Microsoft Corporation. All rights reserved.
+ * Licensed under the MIT License. See License.txt in the project root for
+ * license information.
+ *
+ * Code generated by Microsoft (R) AutoRest Code Generator.
+ * Changes may cause incorrect behavior and will be lost if the code is
+ * regenerated.
+ */
+
+import * as msRest from "@azure/ms-rest-js";
+import * as msRestAzure from "@azure/ms-rest-azure-js";
+import * as Models from "../models";
+import * as Mappers from "../models/usageDetailsMappers";
+import * as Parameters from "../models/parameters";
+import { ConsumptionManagementClientContext } from "../consumptionManagementClientContext";
+
+/** Class representing a UsageDetails. */
+export class UsageDetails {
+ private readonly client: ConsumptionManagementClientContext;
+
+ /**
+ * Create a UsageDetails.
+ * @param {ConsumptionManagementClientContext} client Reference to the service client.
+ */
+ constructor(client: ConsumptionManagementClientContext) {
+ this.client = client;
+ }
+
+ /**
+ * Lists the usage details for the defined scope. Usage details are available via this API only for
+ * May 1, 2014 or later.
+ * @param scope The scope associated with usage details operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and management
+ * group, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ list(scope: string, options?: Models.UsageDetailsListOptionalParams): Promise;
+ /**
+ * @param scope The scope associated with usage details operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and management
+ * group, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param callback The callback
+ */
+ list(scope: string, callback: msRest.ServiceCallback): void;
+ /**
+ * @param scope The scope associated with usage details operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and management
+ * group, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param options The optional parameters
+ * @param callback The callback
+ */
+ list(scope: string, options: Models.UsageDetailsListOptionalParams, callback: msRest.ServiceCallback): void;
+ list(scope: string, options?: Models.UsageDetailsListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise {
+ return this.client.sendOperationRequest(
+ {
+ scope,
+ options
+ },
+ listOperationSpec,
+ callback) as Promise;
+ }
+
+ /**
+ * Download usage details data.
+ * @param scope The scope associated with usage details operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and management
+ * group, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ download(scope: string, options?: Models.UsageDetailsDownloadOptionalParams): Promise {
+ return this.beginDownload(scope,options)
+ .then(lroPoller => lroPoller.pollUntilFinished()) as Promise;
+ }
+
+ /**
+ * Download usage details data.
+ * @param scope The scope associated with usage details operations. This includes
+ * '/subscriptions/{subscriptionId}/' for subscription scope,
+ * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope,
+ * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope,
+ * '/providers/Microsoft.Billing/departments/{departmentId}' for Department scope,
+ * '/providers/Microsoft.Billing/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount
+ * scope and '/providers/Microsoft.Management/managementGroups/{managementGroupId}' for Management
+ * Group scope. For subscription, billing account, department, enrollment account and management
+ * group, you can also add billing period to the scope using
+ * '/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'. For e.g. to specify billing
+ * period at department scope use
+ * '/providers/Microsoft.Billing/departments/{departmentId}/providers/Microsoft.Billing/billingPeriods/{billingPeriodName}'
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ beginDownload(scope: string, options?: Models.UsageDetailsBeginDownloadOptionalParams): Promise {
+ return this.client.sendLRORequest(
+ {
+ scope,
+ options
+ },
+ beginDownloadOperationSpec,
+ options);
+ }
+
+ /**
+ * Lists the usage details for the defined scope. Usage details are available via this API only for
+ * May 1, 2014 or later.
+ * @param nextPageLink The NextLink from the previous successful call to List operation.
+ * @param [options] The optional parameters
+ * @returns Promise
+ */
+ listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise