@azure/arm-templatespecs 1.0.0 → 2.0.1-alpha.20220106.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/{LICENSE.txt → LICENSE} +1 -1
- package/README.md +70 -84
- package/dist/index.js +1285 -0
- package/dist/index.js.map +1 -0
- package/dist/index.min.js +1 -0
- package/dist/index.min.js.map +1 -0
- package/dist-esm/src/index.d.ts +5 -0
- package/dist-esm/src/index.d.ts.map +1 -0
- package/dist-esm/src/index.js +12 -0
- package/dist-esm/src/index.js.map +1 -0
- package/dist-esm/src/models/index.d.ts +306 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +22 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +15 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/mappers.js +196 -227
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +16 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/dist-esm/src/models/parameters.js +144 -0
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/{esm → dist-esm/src}/operations/index.d.ts +0 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/{esm → dist-esm/src}/operations/index.js +1 -2
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/templateSpecVersions.d.ts +72 -0
- package/dist-esm/src/operations/templateSpecVersions.d.ts.map +1 -0
- package/dist-esm/src/operations/templateSpecVersions.js +279 -0
- package/dist-esm/src/operations/templateSpecVersions.js.map +1 -0
- package/dist-esm/src/operations/templateSpecs.d.ts +82 -0
- package/dist-esm/src/operations/templateSpecs.d.ts.map +1 -0
- package/dist-esm/src/operations/templateSpecs.js +358 -0
- package/dist-esm/src/operations/templateSpecs.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts +3 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +10 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/templateSpecVersions.d.ts +47 -0
- package/dist-esm/src/operationsInterfaces/templateSpecVersions.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/templateSpecVersions.js +9 -0
- package/dist-esm/src/operationsInterfaces/templateSpecVersions.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/templateSpecs.d.ts +46 -0
- package/dist-esm/src/operationsInterfaces/templateSpecs.d.ts.map +1 -0
- package/{esm/models/index.js → dist-esm/src/operationsInterfaces/templateSpecs.js} +2 -1
- package/dist-esm/src/operationsInterfaces/templateSpecs.js.map +1 -0
- package/dist-esm/src/templateSpecsClient.d.ts +19 -0
- package/dist-esm/src/templateSpecsClient.d.ts.map +1 -0
- package/dist-esm/src/templateSpecsClient.js +52 -0
- package/dist-esm/src/templateSpecsClient.js.map +1 -0
- package/dist-esm/test/sampleTest.d.ts +2 -0
- package/dist-esm/test/sampleTest.d.ts.map +1 -0
- package/dist-esm/test/sampleTest.js +40 -0
- package/dist-esm/test/sampleTest.js.map +1 -0
- package/package.json +63 -22
- package/review/arm-templatespecs.api.md +280 -0
- package/rollup.config.js +181 -30
- package/src/index.ts +12 -0
- package/src/models/index.ts +233 -494
- package/src/models/mappers.ts +208 -239
- package/src/models/parameters.ts +104 -45
- package/src/operations/index.ts +1 -2
- package/src/operations/templateSpecVersions.ts +222 -254
- package/src/operations/templateSpecs.ts +276 -315
- package/src/operationsInterfaces/index.ts +10 -0
- package/src/operationsInterfaces/templateSpecVersions.ts +91 -0
- package/src/operationsInterfaces/templateSpecs.ts +88 -0
- package/src/templateSpecsClient.ts +62 -34
- package/tsconfig.json +3 -3
- package/types/arm-templatespecs.d.ts +457 -0
- package/types/tsdoc-metadata.json +11 -0
- package/dist/arm-templatespecs.js +0 -1294
- package/dist/arm-templatespecs.js.map +0 -1
- package/dist/arm-templatespecs.min.js +0 -1
- package/dist/arm-templatespecs.min.js.map +0 -1
- package/esm/models/index.d.ts +0 -571
- package/esm/models/index.d.ts.map +0 -1
- package/esm/models/index.js.map +0 -1
- package/esm/models/mappers.d.ts +0 -17
- package/esm/models/mappers.d.ts.map +0 -1
- package/esm/models/mappers.js.map +0 -1
- package/esm/models/parameters.d.ts +0 -10
- package/esm/models/parameters.d.ts.map +0 -1
- package/esm/models/parameters.js +0 -107
- package/esm/models/parameters.js.map +0 -1
- package/esm/models/templateSpecVersionsMappers.d.ts +0 -2
- package/esm/models/templateSpecVersionsMappers.d.ts.map +0 -1
- package/esm/models/templateSpecVersionsMappers.js +0 -9
- package/esm/models/templateSpecVersionsMappers.js.map +0 -1
- package/esm/models/templateSpecsMappers.d.ts +0 -2
- package/esm/models/templateSpecsMappers.d.ts.map +0 -1
- package/esm/models/templateSpecsMappers.js +0 -9
- package/esm/models/templateSpecsMappers.js.map +0 -1
- package/esm/operations/index.d.ts.map +0 -1
- package/esm/operations/index.js.map +0 -1
- package/esm/operations/templateSpecVersions.d.ts +0 -152
- package/esm/operations/templateSpecVersions.d.ts.map +0 -1
- package/esm/operations/templateSpecVersions.js +0 -233
- package/esm/operations/templateSpecVersions.js.map +0 -1
- package/esm/operations/templateSpecs.d.ts +0 -170
- package/esm/operations/templateSpecs.d.ts.map +0 -1
- package/esm/operations/templateSpecs.js +0 -284
- package/esm/operations/templateSpecs.js.map +0 -1
- package/esm/templateSpecsClient.d.ts +0 -25
- package/esm/templateSpecsClient.d.ts.map +0 -1
- package/esm/templateSpecsClient.js +0 -38
- package/esm/templateSpecsClient.js.map +0 -1
- package/esm/templateSpecsClientContext.d.ts +0 -22
- package/esm/templateSpecsClientContext.d.ts.map +0 -1
- package/esm/templateSpecsClientContext.js +0 -60
- package/esm/templateSpecsClientContext.js.map +0 -1
- package/src/models/templateSpecVersionsMappers.ts +0 -23
- package/src/models/templateSpecsMappers.ts +0 -23
- package/src/templateSpecsClientContext.ts +0 -67
@@ -0,0 +1,10 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
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 * from "./templateSpecs";
|
10
|
+
export * from "./templateSpecVersions";
|
@@ -0,0 +1,91 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
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
|
+
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
10
|
+
import {
|
11
|
+
TemplateSpecVersion,
|
12
|
+
TemplateSpecVersionsListOptionalParams,
|
13
|
+
TemplateSpecVersionsCreateOrUpdateOptionalParams,
|
14
|
+
TemplateSpecVersionsCreateOrUpdateResponse,
|
15
|
+
TemplateSpecVersionsUpdateOptionalParams,
|
16
|
+
TemplateSpecVersionsUpdateResponse,
|
17
|
+
TemplateSpecVersionsGetOptionalParams,
|
18
|
+
TemplateSpecVersionsGetResponse,
|
19
|
+
TemplateSpecVersionsDeleteOptionalParams
|
20
|
+
} from "../models";
|
21
|
+
|
22
|
+
/// <reference lib="esnext.asynciterable" />
|
23
|
+
/** Interface representing a TemplateSpecVersions. */
|
24
|
+
export interface TemplateSpecVersions {
|
25
|
+
/**
|
26
|
+
* Lists all the Template Spec versions in the specified Template Spec.
|
27
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
28
|
+
* @param templateSpecName Name of the Template Spec.
|
29
|
+
* @param options The options parameters.
|
30
|
+
*/
|
31
|
+
list(
|
32
|
+
resourceGroupName: string,
|
33
|
+
templateSpecName: string,
|
34
|
+
options?: TemplateSpecVersionsListOptionalParams
|
35
|
+
): PagedAsyncIterableIterator<TemplateSpecVersion>;
|
36
|
+
/**
|
37
|
+
* Creates or updates a Template Spec version.
|
38
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
39
|
+
* @param templateSpecName Name of the Template Spec.
|
40
|
+
* @param templateSpecVersion The version of the Template Spec.
|
41
|
+
* @param templateSpecVersionModel Template Spec Version supplied to the operation.
|
42
|
+
* @param options The options parameters.
|
43
|
+
*/
|
44
|
+
createOrUpdate(
|
45
|
+
resourceGroupName: string,
|
46
|
+
templateSpecName: string,
|
47
|
+
templateSpecVersion: string,
|
48
|
+
templateSpecVersionModel: TemplateSpecVersion,
|
49
|
+
options?: TemplateSpecVersionsCreateOrUpdateOptionalParams
|
50
|
+
): Promise<TemplateSpecVersionsCreateOrUpdateResponse>;
|
51
|
+
/**
|
52
|
+
* Updates Template Spec Version tags with specified values.
|
53
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
54
|
+
* @param templateSpecName Name of the Template Spec.
|
55
|
+
* @param templateSpecVersion The version of the Template Spec.
|
56
|
+
* @param options The options parameters.
|
57
|
+
*/
|
58
|
+
update(
|
59
|
+
resourceGroupName: string,
|
60
|
+
templateSpecName: string,
|
61
|
+
templateSpecVersion: string,
|
62
|
+
options?: TemplateSpecVersionsUpdateOptionalParams
|
63
|
+
): Promise<TemplateSpecVersionsUpdateResponse>;
|
64
|
+
/**
|
65
|
+
* Gets a Template Spec version from a specific Template Spec.
|
66
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
67
|
+
* @param templateSpecName Name of the Template Spec.
|
68
|
+
* @param templateSpecVersion The version of the Template Spec.
|
69
|
+
* @param options The options parameters.
|
70
|
+
*/
|
71
|
+
get(
|
72
|
+
resourceGroupName: string,
|
73
|
+
templateSpecName: string,
|
74
|
+
templateSpecVersion: string,
|
75
|
+
options?: TemplateSpecVersionsGetOptionalParams
|
76
|
+
): Promise<TemplateSpecVersionsGetResponse>;
|
77
|
+
/**
|
78
|
+
* Deletes a specific version from a Template Spec. When operation completes, status code 200 returned
|
79
|
+
* without content.
|
80
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
81
|
+
* @param templateSpecName Name of the Template Spec.
|
82
|
+
* @param templateSpecVersion The version of the Template Spec.
|
83
|
+
* @param options The options parameters.
|
84
|
+
*/
|
85
|
+
delete(
|
86
|
+
resourceGroupName: string,
|
87
|
+
templateSpecName: string,
|
88
|
+
templateSpecVersion: string,
|
89
|
+
options?: TemplateSpecVersionsDeleteOptionalParams
|
90
|
+
): Promise<void>;
|
91
|
+
}
|
@@ -0,0 +1,88 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
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
|
+
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
10
|
+
import {
|
11
|
+
TemplateSpec,
|
12
|
+
TemplateSpecsListBySubscriptionOptionalParams,
|
13
|
+
TemplateSpecsListByResourceGroupOptionalParams,
|
14
|
+
TemplateSpecsCreateOrUpdateOptionalParams,
|
15
|
+
TemplateSpecsCreateOrUpdateResponse,
|
16
|
+
TemplateSpecsUpdateOptionalParams,
|
17
|
+
TemplateSpecsUpdateResponse,
|
18
|
+
TemplateSpecsGetOptionalParams,
|
19
|
+
TemplateSpecsGetResponse,
|
20
|
+
TemplateSpecsDeleteOptionalParams
|
21
|
+
} from "../models";
|
22
|
+
|
23
|
+
/// <reference lib="esnext.asynciterable" />
|
24
|
+
/** Interface representing a TemplateSpecs. */
|
25
|
+
export interface TemplateSpecs {
|
26
|
+
/**
|
27
|
+
* Lists all the Template Specs within the specified subscriptions.
|
28
|
+
* @param options The options parameters.
|
29
|
+
*/
|
30
|
+
listBySubscription(
|
31
|
+
options?: TemplateSpecsListBySubscriptionOptionalParams
|
32
|
+
): PagedAsyncIterableIterator<TemplateSpec>;
|
33
|
+
/**
|
34
|
+
* Lists all the Template Specs within the specified resource group.
|
35
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
36
|
+
* @param options The options parameters.
|
37
|
+
*/
|
38
|
+
listByResourceGroup(
|
39
|
+
resourceGroupName: string,
|
40
|
+
options?: TemplateSpecsListByResourceGroupOptionalParams
|
41
|
+
): PagedAsyncIterableIterator<TemplateSpec>;
|
42
|
+
/**
|
43
|
+
* Creates or updates a Template Spec.
|
44
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
45
|
+
* @param templateSpecName Name of the Template Spec.
|
46
|
+
* @param templateSpec Template Spec supplied to the operation.
|
47
|
+
* @param options The options parameters.
|
48
|
+
*/
|
49
|
+
createOrUpdate(
|
50
|
+
resourceGroupName: string,
|
51
|
+
templateSpecName: string,
|
52
|
+
templateSpec: TemplateSpec,
|
53
|
+
options?: TemplateSpecsCreateOrUpdateOptionalParams
|
54
|
+
): Promise<TemplateSpecsCreateOrUpdateResponse>;
|
55
|
+
/**
|
56
|
+
* Updates Template Spec tags with specified values.
|
57
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
58
|
+
* @param templateSpecName Name of the Template Spec.
|
59
|
+
* @param options The options parameters.
|
60
|
+
*/
|
61
|
+
update(
|
62
|
+
resourceGroupName: string,
|
63
|
+
templateSpecName: string,
|
64
|
+
options?: TemplateSpecsUpdateOptionalParams
|
65
|
+
): Promise<TemplateSpecsUpdateResponse>;
|
66
|
+
/**
|
67
|
+
* Gets a Template Spec with a given name.
|
68
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
69
|
+
* @param templateSpecName Name of the Template Spec.
|
70
|
+
* @param options The options parameters.
|
71
|
+
*/
|
72
|
+
get(
|
73
|
+
resourceGroupName: string,
|
74
|
+
templateSpecName: string,
|
75
|
+
options?: TemplateSpecsGetOptionalParams
|
76
|
+
): Promise<TemplateSpecsGetResponse>;
|
77
|
+
/**
|
78
|
+
* Deletes a Template Spec by name. When operation completes, status code 200 returned without content.
|
79
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
80
|
+
* @param templateSpecName Name of the Template Spec.
|
81
|
+
* @param options The options parameters.
|
82
|
+
*/
|
83
|
+
delete(
|
84
|
+
resourceGroupName: string,
|
85
|
+
templateSpecName: string,
|
86
|
+
options?: TemplateSpecsDeleteOptionalParams
|
87
|
+
): Promise<void>;
|
88
|
+
}
|
@@ -3,47 +3,75 @@
|
|
3
3
|
* Licensed under the MIT License.
|
4
4
|
*
|
5
5
|
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
-
* Changes may cause incorrect behavior and will be lost if the code is
|
7
|
-
* regenerated.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
8
7
|
*/
|
9
8
|
|
10
|
-
import * as
|
11
|
-
import
|
12
|
-
import
|
13
|
-
import
|
14
|
-
import
|
15
|
-
import { TemplateSpecsClientContext } from "./templateSpecsClientContext";
|
9
|
+
import * as coreClient from "@azure/core-client";
|
10
|
+
import * as coreAuth from "@azure/core-auth";
|
11
|
+
import { TemplateSpecsImpl, TemplateSpecVersionsImpl } from "./operations";
|
12
|
+
import { TemplateSpecs, TemplateSpecVersions } from "./operationsInterfaces";
|
13
|
+
import { TemplateSpecsClientOptionalParams } from "./models";
|
16
14
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
templateSpecVersions: operations.TemplateSpecVersions;
|
15
|
+
export class TemplateSpecsClient extends coreClient.ServiceClient {
|
16
|
+
$host: string;
|
17
|
+
subscriptionId: string;
|
18
|
+
apiVersion: string;
|
22
19
|
|
23
20
|
/**
|
24
21
|
* Initializes a new instance of the TemplateSpecsClient class.
|
25
|
-
* @param credentials
|
26
|
-
* implementing the TokenCredential interface from the @azure/identity package are recommended. For
|
27
|
-
* more information about these credentials, see
|
28
|
-
* {@link https://www.npmjs.com/package/@azure/identity}. Credentials implementing the
|
29
|
-
* ServiceClientCredentials interface from the older packages @azure/ms-rest-nodeauth and
|
30
|
-
* @azure/ms-rest-browserauth are also supported.
|
22
|
+
* @param credentials Subscription credentials which uniquely identify client subscription.
|
31
23
|
* @param subscriptionId Subscription Id which forms part of the URI for every service call.
|
32
|
-
* @param
|
24
|
+
* @param options The parameter options
|
33
25
|
*/
|
34
|
-
constructor(
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
26
|
+
constructor(
|
27
|
+
credentials: coreAuth.TokenCredential,
|
28
|
+
subscriptionId: string,
|
29
|
+
options?: TemplateSpecsClientOptionalParams
|
30
|
+
) {
|
31
|
+
if (credentials === undefined) {
|
32
|
+
throw new Error("'credentials' cannot be null");
|
33
|
+
}
|
34
|
+
if (subscriptionId === undefined) {
|
35
|
+
throw new Error("'subscriptionId' cannot be null");
|
36
|
+
}
|
37
|
+
|
38
|
+
// Initializing default values for options
|
39
|
+
if (!options) {
|
40
|
+
options = {};
|
41
|
+
}
|
42
|
+
const defaults: TemplateSpecsClientOptionalParams = {
|
43
|
+
requestContentType: "application/json; charset=utf-8",
|
44
|
+
credential: credentials
|
45
|
+
};
|
40
46
|
|
41
|
-
|
47
|
+
const packageDetails = `azsdk-js-arm-templatespecs/2.0.0`;
|
48
|
+
const userAgentPrefix =
|
49
|
+
options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
50
|
+
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
51
|
+
: `${packageDetails}`;
|
42
52
|
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
53
|
+
if (!options.credentialScopes) {
|
54
|
+
options.credentialScopes = ["https://management.azure.com/.default"];
|
55
|
+
}
|
56
|
+
const optionsWithDefaults = {
|
57
|
+
...defaults,
|
58
|
+
...options,
|
59
|
+
userAgentOptions: {
|
60
|
+
userAgentPrefix
|
61
|
+
},
|
62
|
+
baseUri: options.endpoint || "https://management.azure.com"
|
63
|
+
};
|
64
|
+
super(optionsWithDefaults);
|
65
|
+
// Parameter assignments
|
66
|
+
this.subscriptionId = subscriptionId;
|
67
|
+
|
68
|
+
// Assigning values to Constant parameters
|
69
|
+
this.$host = options.$host || "https://management.azure.com";
|
70
|
+
this.apiVersion = options.apiVersion || "2021-05-01";
|
71
|
+
this.templateSpecs = new TemplateSpecsImpl(this);
|
72
|
+
this.templateSpecVersions = new TemplateSpecVersionsImpl(this);
|
73
|
+
}
|
74
|
+
|
75
|
+
templateSpecs: TemplateSpecs;
|
76
|
+
templateSpecVersions: TemplateSpecVersions;
|
77
|
+
}
|
package/tsconfig.json
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
"module": "es6",
|
4
4
|
"moduleResolution": "node",
|
5
5
|
"strict": true,
|
6
|
-
"target": "
|
6
|
+
"target": "es6",
|
7
7
|
"sourceMap": true,
|
8
8
|
"declarationMap": true,
|
9
9
|
"esModuleInterop": true,
|
@@ -11,9 +11,9 @@
|
|
11
11
|
"forceConsistentCasingInFileNames": true,
|
12
12
|
"lib": ["es6", "dom"],
|
13
13
|
"declaration": true,
|
14
|
-
"outDir": "./esm",
|
14
|
+
"outDir": "./dist-esm",
|
15
15
|
"importHelpers": true
|
16
16
|
},
|
17
|
-
"include": ["./src/**/*.ts"],
|
17
|
+
"include": ["./src/**/*.ts", "./test/**/*.ts"],
|
18
18
|
"exclude": ["node_modules"]
|
19
19
|
}
|