Skip to content
This repository was archived by the owner on May 5, 2023. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/services/billingManagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft
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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ export default class BillingManagementClient extends AzureServiceClient {
enrollmentAccounts: operations.EnrollmentAccounts;
billingPeriods: operations.BillingPeriods;
invoices: operations.Invoices;
products: operations.Products;
operations: operations.Operations;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class BillingManagementClient extends ServiceClient {

super(credentials, options);

this.apiVersion = '2018-03-01-preview';
this.apiVersion = '2018-11-01-preview';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.generateClientRequestId = true;
Expand All @@ -75,6 +75,7 @@ class BillingManagementClient extends ServiceClient {
this.enrollmentAccounts = new operations.EnrollmentAccounts(this);
this.billingPeriods = new operations.BillingPeriods(this);
this.invoices = new operations.Invoices(this);
this.products = new operations.Products(this);
this.operations = new operations.Operations(this);
this.models = models;
msRest.addSerializationMixin(this);
Expand Down
13 changes: 13 additions & 0 deletions lib/services/billingManagement/lib/models/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,19 @@ export { BaseResource } from 'ms-rest-azure';
export { CloudError } from 'ms-rest-azure';


/**
* @class
* Initializes a new instance of the TransferProductProperties class.
* @constructor
* The properties of the product to initiate a transfer.
*
* @member {string} [destinationInvoiceSectionId] Destination invoice section
* id.
*/
export interface TransferProductProperties {
destinationInvoiceSectionId?: string;
}

/**
* @class
* Initializes a new instance of the Resource class.
Expand Down
1 change: 1 addition & 0 deletions lib/services/billingManagement/lib/models/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ var msRestAzure = require('ms-rest-azure');

exports.BaseResource = msRestAzure.BaseResource;
exports.CloudError = msRestAzure.CloudError;
exports.TransferProductProperties = require('./transferProductProperties');
exports.Resource = require('./resource');
exports.EnrollmentAccount = require('./enrollmentAccount');
exports.BillingPeriod = require('./billingPeriod');
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* 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.
*/

'use strict';

/**
* The properties of the product to initiate a transfer.
*
*/
class TransferProductProperties {
/**
* Create a TransferProductProperties.
* @member {string} [destinationInvoiceSectionId] Destination invoice section
* id.
*/
constructor() {
}

/**
* Defines the metadata of TransferProductProperties
*
* @returns {object} metadata of TransferProductProperties
*
*/
mapper() {
return {
required: false,
serializedName: 'TransferProductProperties',
type: {
name: 'Composite',
className: 'TransferProductProperties',
modelProperties: {
destinationInvoiceSectionId: {
required: false,
serializedName: 'destinationInvoiceSectionId',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = TransferProductProperties;
77 changes: 77 additions & 0 deletions lib/services/billingManagement/lib/operations/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,83 @@ export interface Invoices {
listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.InvoicesListResult>): void;
}

/**
* @class
* Products
* __NOTE__: An instance of this class is automatically created for an
* instance of the BillingManagementClient.
*/
export interface Products {


/**
* The operation to transfer a Product to another InvoiceSection.
*
* @param {string} billingAccountId billing Account Id.
*
* @param {string} invoiceSectionId Invoice Id.
*
* @param {string} productName Product Id.
*
* @param {object} [options] Optional Parameters.
*
* @param {string} [options.destinationInvoiceSectionId] Destination invoice
* section id.
*
* @param {object} [options.customHeaders] Headers that will be added to the
* request
*
* @returns {Promise} A promise is returned
*
* @resolve {HttpOperationResponse<null>} - The deserialized result object.
*
* @reject {Error|ServiceError} - The error object.
*/
transferWithHttpOperationResponse(billingAccountId: string, invoiceSectionId: string, productName: string, options?: { destinationInvoiceSectionId? : string, customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<void>>;

/**
* The operation to transfer a Product to another InvoiceSection.
*
* @param {string} billingAccountId billing Account Id.
*
* @param {string} invoiceSectionId Invoice Id.
*
* @param {string} productName Product Id.
*
* @param {object} [options] Optional Parameters.
*
* @param {string} [options.destinationInvoiceSectionId] Destination invoice
* section id.
*
* @param {object} [options.customHeaders] Headers that will be added to the
* request
*
* @param {ServiceCallback} [optionalCallback] - The optional callback.
*
* @returns {ServiceCallback|Promise} If a callback was passed as the last
* parameter then it returns the callback else returns a Promise.
*
* {Promise} A promise is returned.
*
* @resolve {null} - The deserialized result object.
*
* @reject {Error|ServiceError} - The error object.
*
* {ServiceCallback} optionalCallback(err, result, request, response)
*
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise.
*
* {null} [result] - The deserialized result object if an error did not occur.
*
* {WebResource} [request] - The HTTP Request object if an error did not occur.
*
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur.
*/
transfer(billingAccountId: string, invoiceSectionId: string, productName: string, options?: { destinationInvoiceSectionId? : string, customHeaders? : { [headerName: string]: string; } }): Promise<void>;
transfer(billingAccountId: string, invoiceSectionId: string, productName: string, callback: ServiceCallback<void>): void;
transfer(billingAccountId: string, invoiceSectionId: string, productName: string, options: { destinationInvoiceSectionId? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void;
}

/**
* @class
* Operations
Expand Down
1 change: 1 addition & 0 deletions lib/services/billingManagement/lib/operations/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@
exports.EnrollmentAccounts = require('./enrollmentAccounts');
exports.BillingPeriods = require('./billingPeriods');
exports.Invoices = require('./invoices');
exports.Products = require('./products');
exports.Operations = require('./operations');
Loading