Skip to content

Commit 31c4b01

Browse files
author
SDK Automation
committed
Generated from eb835f618f791a74a3a2b85b7fcf3425229aed58
1 parent 2ecfb57 commit 31c4b01

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+15197
-576
lines changed

sdk/billing/arm-billing/LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2018 Microsoft
3+
Copyright (c) 2020 Microsoft
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

sdk/billing/arm-billing/README.md

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,24 @@ This package contains an isomorphic SDK for BillingManagementClient.
99

1010
### How to Install
1111

12-
```
12+
```bash
1313
npm install @azure/arm-billing
1414
```
1515

1616
### How to use
1717

18-
#### nodejs - Authentication, client creation and list enrollmentAccounts as an example written in TypeScript.
18+
#### nodejs - Authentication, client creation and list billingAccounts as an example written in TypeScript.
1919

2020
##### Install @azure/ms-rest-nodeauth
2121

22-
```
23-
npm install @azure/ms-rest-nodeauth
22+
- Please install minimum version of `"@azure/ms-rest-nodeauth": "^3.0.0"`.
23+
```bash
24+
npm install @azure/ms-rest-nodeauth@"^3.0.0"
2425
```
2526

2627
##### Sample code
2728

28-
```ts
29+
```typescript
2930
import * as msRest from "@azure/ms-rest-js";
3031
import * as msRestAzure from "@azure/ms-rest-azure-js";
3132
import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
@@ -34,7 +35,8 @@ const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];
3435

3536
msRestNodeAuth.interactiveLogin().then((creds) => {
3637
const client = new BillingManagementClient(creds, subscriptionId);
37-
client.enrollmentAccounts.list().then((result) => {
38+
const expand = "testexpand";
39+
client.billingAccounts.list(expand).then((result) => {
3840
console.log("The result is:");
3941
console.log(result);
4042
});
@@ -43,11 +45,11 @@ msRestNodeAuth.interactiveLogin().then((creds) => {
4345
});
4446
```
4547

46-
#### browser - Authentication, client creation and list enrollmentAccounts as an example written in JavaScript.
48+
#### browser - Authentication, client creation and list billingAccounts as an example written in JavaScript.
4749

4850
##### Install @azure/ms-rest-browserauth
4951

50-
```
52+
```bash
5153
npm install @azure/ms-rest-browserauth
5254
```
5355

@@ -77,7 +79,8 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
7779
authManager.login();
7880
}
7981
const client = new Azure.ArmBilling.BillingManagementClient(res.creds, subscriptionId);
80-
client.enrollmentAccounts.list().then((result) => {
82+
const expand = "testexpand";
83+
client.billingAccounts.list(expand).then((result) => {
8184
console.log("The result is:");
8285
console.log(result);
8386
}).catch((err) => {
@@ -95,5 +98,4 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
9598

9699
- [Microsoft Azure SDK for Javascript](https://github.com/Azure/azure-sdk-for-js)
97100

98-
99-
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Fbilling%2Farm-billing%2FREADME.png)
101+
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js/sdk/billing/arm-billing/README.png)

sdk/billing/arm-billing/package.json

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
"description": "BillingManagementClient Library with typescript type definitions for node.js and browser.",
55
"version": "2.2.0",
66
"dependencies": {
7-
"@azure/ms-rest-azure-js": "^1.1.0",
8-
"@azure/ms-rest-js": "^1.1.0",
9-
"tslib": "^1.9.3"
7+
"@azure/ms-rest-azure-js": "^2.0.1",
8+
"@azure/ms-rest-js": "^2.0.4",
9+
"tslib": "^1.10.0"
1010
},
1111
"keywords": [
1212
"node",
@@ -20,18 +20,19 @@
2020
"module": "./esm/billingManagementClient.js",
2121
"types": "./esm/billingManagementClient.d.ts",
2222
"devDependencies": {
23-
"typescript": "^3.1.1",
24-
"rollup": "^0.66.2",
25-
"rollup-plugin-node-resolve": "^3.4.0",
26-
"uglify-js": "^3.4.9"
23+
"typescript": "^3.5.3",
24+
"rollup": "^1.18.0",
25+
"rollup-plugin-node-resolve": "^5.2.0",
26+
"rollup-plugin-sourcemaps": "^0.4.2",
27+
"uglify-js": "^3.6.0"
2728
},
28-
"homepage": "https://github.com/azure/azure-sdk-for-js/tree/master/sdk/billing/arm-billing",
29+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/billing/arm-billing",
2930
"repository": {
3031
"type": "git",
31-
"url": "https://github.com/azure/azure-sdk-for-js.git"
32+
"url": "https://github.com/Azure/azure-sdk-for-js.git"
3233
},
3334
"bugs": {
34-
"url": "https://github.com/azure/azure-sdk-for-js/issues"
35+
"url": "https://github.com/Azure/azure-sdk-for-js/issues"
3536
},
3637
"files": [
3738
"dist/**/*.js",
@@ -43,6 +44,7 @@
4344
"esm/**/*.d.ts",
4445
"esm/**/*.d.ts.map",
4546
"src/**/*.ts",
47+
"README.md",
4648
"rollup.config.js",
4749
"tsconfig.json"
4850
],
Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
1+
import rollup from "rollup";
12
import nodeResolve from "rollup-plugin-node-resolve";
3+
import sourcemaps from "rollup-plugin-sourcemaps";
4+
25
/**
3-
* @type {import('rollup').RollupFileOptions}
6+
* @type {rollup.RollupFileOptions}
47
*/
58
const config = {
6-
input: './esm/billingManagementClient.js',
7-
external: ["@azure/ms-rest-js", "@azure/ms-rest-azure-js"],
9+
input: "./esm/billingManagementClient.js",
10+
external: [
11+
"@azure/ms-rest-js",
12+
"@azure/ms-rest-azure-js"
13+
],
814
output: {
915
file: "./dist/arm-billing.js",
1016
format: "umd",
@@ -16,16 +22,16 @@ const config = {
1622
},
1723
banner: `/*
1824
* Copyright (c) Microsoft Corporation. All rights reserved.
19-
* Licensed under the MIT License. See License.txt in the project root for
20-
* license information.
25+
* Licensed under the MIT License. See License.txt in the project root for license information.
2126
*
2227
* Code generated by Microsoft (R) AutoRest Code Generator.
23-
* Changes may cause incorrect behavior and will be lost if the code is
24-
* regenerated.
28+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
2529
*/`
2630
},
2731
plugins: [
28-
nodeResolve({ module: true })
32+
nodeResolve({ mainFields: ['module', 'main'] }),
33+
sourcemaps()
2934
]
3035
};
36+
3137
export default config;

sdk/billing/arm-billing/src/billingManagementClient.ts

Lines changed: 37 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,23 +17,55 @@ import { BillingManagementClientContext } from "./billingManagementClientContext
1717

1818
class BillingManagementClient extends BillingManagementClientContext {
1919
// Operation groups
20-
enrollmentAccounts: operations.EnrollmentAccounts;
21-
billingPeriods: operations.BillingPeriods;
20+
billingAccounts: operations.BillingAccounts;
21+
address: operations.Address;
22+
availableBalances: operations.AvailableBalances;
23+
instructions: operations.Instructions;
24+
billingProfiles: operations.BillingProfiles;
25+
customers: operations.Customers;
26+
invoiceSections: operations.InvoiceSections;
27+
billingPermissions: operations.BillingPermissions;
28+
billingSubscriptions: operations.BillingSubscriptions;
29+
products: operations.Products;
2230
invoices: operations.Invoices;
31+
transactions: operations.Transactions;
32+
policies: operations.Policies;
33+
billingProperty: operations.BillingPropertyOperations;
2334
operations: operations.Operations;
35+
billingRoleDefinitions: operations.BillingRoleDefinitions;
36+
billingRoleAssignments: operations.BillingRoleAssignments;
37+
agreements: operations.Agreements;
38+
enrollmentAccounts: operations.EnrollmentAccounts;
39+
billingPeriods: operations.BillingPeriods;
2440

2541
/**
2642
* Initializes a new instance of the BillingManagementClient class.
2743
* @param credentials Credentials needed for the client to connect to Azure.
28-
* @param subscriptionId Azure Subscription ID.
44+
* @param subscriptionId The ID that uniquely identifies an Azure subscription.
2945
* @param [options] The parameter options
3046
*/
3147
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.BillingManagementClientOptions) {
3248
super(credentials, subscriptionId, options);
33-
this.enrollmentAccounts = new operations.EnrollmentAccounts(this);
34-
this.billingPeriods = new operations.BillingPeriods(this);
49+
this.billingAccounts = new operations.BillingAccounts(this);
50+
this.address = new operations.Address(this);
51+
this.availableBalances = new operations.AvailableBalances(this);
52+
this.instructions = new operations.Instructions(this);
53+
this.billingProfiles = new operations.BillingProfiles(this);
54+
this.customers = new operations.Customers(this);
55+
this.invoiceSections = new operations.InvoiceSections(this);
56+
this.billingPermissions = new operations.BillingPermissions(this);
57+
this.billingSubscriptions = new operations.BillingSubscriptions(this);
58+
this.products = new operations.Products(this);
3559
this.invoices = new operations.Invoices(this);
60+
this.transactions = new operations.Transactions(this);
61+
this.policies = new operations.Policies(this);
62+
this.billingProperty = new operations.BillingPropertyOperations(this);
3663
this.operations = new operations.Operations(this);
64+
this.billingRoleDefinitions = new operations.BillingRoleDefinitions(this);
65+
this.billingRoleAssignments = new operations.BillingRoleAssignments(this);
66+
this.agreements = new operations.Agreements(this);
67+
this.enrollmentAccounts = new operations.EnrollmentAccounts(this);
68+
this.billingPeriods = new operations.BillingPeriods(this);
3769
}
3870
}
3971

sdk/billing/arm-billing/src/billingManagementClientContext.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,16 @@ import * as msRest from "@azure/ms-rest-js";
1313
import * as msRestAzure from "@azure/ms-rest-azure-js";
1414

1515
const packageName = "@azure/arm-billing";
16-
const packageVersion = "0.1.0";
16+
const packageVersion = "2.2.0";
1717

1818
export class BillingManagementClientContext extends msRestAzure.AzureServiceClient {
1919
credentials: msRest.ServiceClientCredentials;
20-
apiVersion?: string;
2120
subscriptionId: string;
2221

2322
/**
2423
* Initializes a new instance of the BillingManagementClient class.
2524
* @param credentials Credentials needed for the client to connect to Azure.
26-
* @param subscriptionId Azure Subscription ID.
25+
* @param subscriptionId The ID that uniquely identifies an Azure subscription.
2726
* @param [options] The parameter options
2827
*/
2928
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.BillingManagementClientOptions) {
@@ -44,7 +43,6 @@ export class BillingManagementClientContext extends msRestAzure.AzureServiceClie
4443

4544
super(credentials, options);
4645

47-
this.apiVersion = '2018-03-01-preview';
4846
this.acceptLanguage = 'en-US';
4947
this.longRunningOperationRetryTimeout = 30;
5048
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License. See License.txt in the project root for license information.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
AddressDetails,
11+
ErrorDetails,
12+
ErrorResponse,
13+
ErrorSubDetailsItem,
14+
ValidateAddressResponse
15+
} from "../models/mappers";
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License. See License.txt in the project root for license information.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
AddressDetails,
11+
Agreement,
12+
AgreementListResult,
13+
Amount,
14+
AvailableBalance,
15+
AzurePlan,
16+
BaseResource,
17+
BillingAccount,
18+
BillingPeriod,
19+
BillingPermissionsProperties,
20+
BillingProfile,
21+
BillingProfilesOnExpand,
22+
BillingProperty,
23+
BillingRoleAssignment,
24+
BillingRoleDefinition,
25+
BillingSubscription,
26+
Customer,
27+
CustomerPolicy,
28+
Department,
29+
Document,
30+
Enrollment,
31+
EnrollmentAccount,
32+
EnrollmentAccountSummary,
33+
EnrollmentPolicies,
34+
ErrorDetails,
35+
ErrorResponse,
36+
ErrorSubDetailsItem,
37+
IndirectRelationshipInfo,
38+
Instruction,
39+
Invoice,
40+
InvoiceSection,
41+
InvoiceSectionsOnExpand,
42+
Participants,
43+
PaymentProperties,
44+
Policy,
45+
Product,
46+
RebillDetails,
47+
Reseller,
48+
Resource,
49+
Transaction
50+
} from "../models/mappers";
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License. See License.txt in the project root for license information.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
AddressDetails,
11+
Agreement,
12+
Amount,
13+
AvailableBalance,
14+
AzurePlan,
15+
BaseResource,
16+
BillingAccount,
17+
BillingPeriod,
18+
BillingPermissionsProperties,
19+
BillingProfile,
20+
BillingProfilesOnExpand,
21+
BillingProperty,
22+
BillingRoleAssignment,
23+
BillingRoleDefinition,
24+
BillingSubscription,
25+
Customer,
26+
CustomerPolicy,
27+
Department,
28+
Document,
29+
Enrollment,
30+
EnrollmentAccount,
31+
EnrollmentAccountSummary,
32+
EnrollmentPolicies,
33+
ErrorDetails,
34+
ErrorResponse,
35+
ErrorSubDetailsItem,
36+
IndirectRelationshipInfo,
37+
Instruction,
38+
Invoice,
39+
InvoiceSection,
40+
InvoiceSectionsOnExpand,
41+
Participants,
42+
PaymentProperties,
43+
Policy,
44+
Product,
45+
RebillDetails,
46+
Reseller,
47+
Resource,
48+
Transaction
49+
} from "../models/mappers";

0 commit comments

Comments
 (0)