@azure/arm-deviceprovisioningservices 3.0.0 → 4.0.0

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.
Files changed (137) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/LICENSE +21 -0
  3. package/LICENSE.txt +1 -1
  4. package/README.md +70 -78
  5. package/dist/index.js +3108 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/index.min.js +1 -0
  8. package/dist/index.min.js.map +1 -0
  9. package/dist-esm/src/index.d.ts +5 -0
  10. package/dist-esm/src/index.d.ts.map +1 -0
  11. package/dist-esm/src/index.js +12 -0
  12. package/dist-esm/src/index.js.map +1 -0
  13. package/dist-esm/src/iotDpsClient.d.ts +20 -0
  14. package/dist-esm/src/iotDpsClient.d.ts.map +1 -0
  15. package/dist-esm/src/iotDpsClient.js +53 -0
  16. package/dist-esm/src/iotDpsClient.js.map +1 -0
  17. package/dist-esm/src/lroImpl.d.ts +16 -0
  18. package/dist-esm/src/lroImpl.d.ts.map +1 -0
  19. package/dist-esm/src/lroImpl.js +29 -0
  20. package/dist-esm/src/lroImpl.js.map +1 -0
  21. package/dist-esm/src/models/index.d.ts +825 -0
  22. package/dist-esm/src/models/index.d.ts.map +1 -0
  23. package/dist-esm/src/models/index.js +72 -0
  24. package/dist-esm/src/models/index.js.map +1 -0
  25. package/dist-esm/src/models/mappers.d.ts +36 -0
  26. package/dist-esm/src/models/mappers.d.ts.map +1 -0
  27. package/{esm → dist-esm/src}/models/mappers.js +440 -498
  28. package/dist-esm/src/models/mappers.js.map +1 -0
  29. package/dist-esm/src/models/parameters.d.ts +34 -0
  30. package/dist-esm/src/models/parameters.d.ts.map +1 -0
  31. package/{esm → dist-esm/src}/models/parameters.js +136 -115
  32. package/dist-esm/src/models/parameters.js.map +1 -0
  33. package/dist-esm/src/operations/dpsCertificate.d.ts +70 -0
  34. package/dist-esm/src/operations/dpsCertificate.d.ts.map +1 -0
  35. package/dist-esm/src/operations/dpsCertificate.js +289 -0
  36. package/dist-esm/src/operations/dpsCertificate.js.map +1 -0
  37. package/{esm → dist-esm/src}/operations/index.d.ts +0 -0
  38. package/dist-esm/src/operations/index.d.ts.map +1 -0
  39. package/{esm → dist-esm/src}/operations/index.js +1 -2
  40. package/dist-esm/src/operations/index.js.map +1 -0
  41. package/dist-esm/src/operations/iotDpsResource.d.ts +253 -0
  42. package/dist-esm/src/operations/iotDpsResource.d.ts.map +1 -0
  43. package/dist-esm/src/operations/iotDpsResource.js +1154 -0
  44. package/dist-esm/src/operations/iotDpsResource.js.map +1 -0
  45. package/dist-esm/src/operations/operations.d.ts +32 -0
  46. package/dist-esm/src/operations/operations.d.ts.map +1 -0
  47. package/dist-esm/src/operations/operations.js +120 -0
  48. package/dist-esm/src/operations/operations.js.map +1 -0
  49. package/dist-esm/src/operationsInterfaces/dpsCertificate.d.ts +62 -0
  50. package/dist-esm/src/operationsInterfaces/dpsCertificate.d.ts.map +1 -0
  51. package/{esm/models/operationsMappers.js → dist-esm/src/operationsInterfaces/dpsCertificate.js} +2 -2
  52. package/dist-esm/src/operationsInterfaces/dpsCertificate.js.map +1 -0
  53. package/dist-esm/src/operationsInterfaces/index.d.ts +4 -0
  54. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
  55. package/dist-esm/src/operationsInterfaces/index.js +11 -0
  56. package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
  57. package/dist-esm/src/operationsInterfaces/iotDpsResource.d.ts +183 -0
  58. package/dist-esm/src/operationsInterfaces/iotDpsResource.d.ts.map +1 -0
  59. package/dist-esm/src/operationsInterfaces/iotDpsResource.js +9 -0
  60. package/dist-esm/src/operationsInterfaces/iotDpsResource.js.map +1 -0
  61. package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
  62. package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
  63. package/{esm/models/index.js → dist-esm/src/operationsInterfaces/operations.js} +2 -1
  64. package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
  65. package/dist-esm/test/sampleTest.d.ts +2 -0
  66. package/dist-esm/test/sampleTest.d.ts.map +1 -0
  67. package/dist-esm/test/sampleTest.js +40 -0
  68. package/dist-esm/test/sampleTest.js.map +1 -0
  69. package/package.json +65 -32
  70. package/review/arm-deviceprovisioningservices.api.md +690 -0
  71. package/rollup.config.js +181 -30
  72. package/src/index.ts +12 -0
  73. package/src/iotDpsClient.ts +72 -36
  74. package/src/lroImpl.ts +34 -0
  75. package/src/models/index.ts +686 -1289
  76. package/src/models/mappers.ts +449 -505
  77. package/src/models/parameters.ts +179 -116
  78. package/src/operations/dpsCertificate.ts +201 -304
  79. package/src/operations/index.ts +1 -2
  80. package/src/operations/iotDpsResource.ts +1157 -872
  81. package/src/operations/operations.ts +85 -73
  82. package/src/operationsInterfaces/dpsCertificate.ts +118 -0
  83. package/src/{models/operationsMappers.ts → operationsInterfaces/index.ts} +3 -6
  84. package/src/operationsInterfaces/iotDpsResource.ts +351 -0
  85. package/src/operationsInterfaces/operations.ts +22 -0
  86. package/tsconfig.json +3 -3
  87. package/types/arm-deviceprovisioningservices.d.ts +1205 -0
  88. package/types/tsdoc-metadata.json +11 -0
  89. package/dist/arm-deviceprovisioningservices.js +0 -2869
  90. package/dist/arm-deviceprovisioningservices.js.map +0 -1
  91. package/dist/arm-deviceprovisioningservices.min.js +0 -1
  92. package/dist/arm-deviceprovisioningservices.min.js.map +0 -1
  93. package/esm/iotDpsClient.d.ts +0 -26
  94. package/esm/iotDpsClient.d.ts.map +0 -1
  95. package/esm/iotDpsClient.js +0 -39
  96. package/esm/iotDpsClient.js.map +0 -1
  97. package/esm/iotDpsClientContext.d.ts +0 -22
  98. package/esm/iotDpsClientContext.d.ts.map +0 -1
  99. package/esm/iotDpsClientContext.js +0 -60
  100. package/esm/iotDpsClientContext.js.map +0 -1
  101. package/esm/models/dpsCertificateMappers.d.ts +0 -2
  102. package/esm/models/dpsCertificateMappers.d.ts.map +0 -1
  103. package/esm/models/dpsCertificateMappers.js +0 -9
  104. package/esm/models/dpsCertificateMappers.js.map +0 -1
  105. package/esm/models/index.d.ts +0 -1433
  106. package/esm/models/index.d.ts.map +0 -1
  107. package/esm/models/index.js.map +0 -1
  108. package/esm/models/iotDpsResourceMappers.d.ts +0 -2
  109. package/esm/models/iotDpsResourceMappers.d.ts.map +0 -1
  110. package/esm/models/iotDpsResourceMappers.js +0 -9
  111. package/esm/models/iotDpsResourceMappers.js.map +0 -1
  112. package/esm/models/mappers.d.ts +0 -38
  113. package/esm/models/mappers.d.ts.map +0 -1
  114. package/esm/models/mappers.js.map +0 -1
  115. package/esm/models/operationsMappers.d.ts +0 -2
  116. package/esm/models/operationsMappers.d.ts.map +0 -1
  117. package/esm/models/operationsMappers.js.map +0 -1
  118. package/esm/models/parameters.d.ts +0 -26
  119. package/esm/models/parameters.d.ts.map +0 -1
  120. package/esm/models/parameters.js.map +0 -1
  121. package/esm/operations/dpsCertificate.d.ts +0 -188
  122. package/esm/operations/dpsCertificate.d.ts.map +0 -1
  123. package/esm/operations/dpsCertificate.js +0 -264
  124. package/esm/operations/dpsCertificate.js.map +0 -1
  125. package/esm/operations/index.d.ts.map +0 -1
  126. package/esm/operations/index.js.map +0 -1
  127. package/esm/operations/iotDpsResource.d.ts +0 -473
  128. package/esm/operations/iotDpsResource.d.ts.map +0 -1
  129. package/esm/operations/iotDpsResource.js +0 -834
  130. package/esm/operations/iotDpsResource.js.map +0 -1
  131. package/esm/operations/operations.d.ts +0 -46
  132. package/esm/operations/operations.d.ts.map +0 -1
  133. package/esm/operations/operations.js +0 -79
  134. package/esm/operations/operations.js.map +0 -1
  135. package/src/iotDpsClientContext.ts +0 -67
  136. package/src/models/dpsCertificateMappers.ts +0 -30
  137. package/src/models/iotDpsResourceMappers.ts +0 -40
@@ -3,195 +3,662 @@
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 msRest from "@azure/ms-rest-js";
11
- import * as msRestAzure from "@azure/ms-rest-azure-js";
12
- import * as Models from "../models";
13
- import * as Mappers from "../models/iotDpsResourceMappers";
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { IotDpsResource } from "../operationsInterfaces";
11
+ import * as coreClient from "@azure/core-client";
12
+ import * as Mappers from "../models/mappers";
14
13
  import * as Parameters from "../models/parameters";
15
- import { IotDpsClientContext } from "../iotDpsClientContext";
14
+ import { IotDpsClient } from "../iotDpsClient";
15
+ import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
16
+ import { LroImpl } from "../lroImpl";
17
+ import {
18
+ ProvisioningServiceDescription,
19
+ IotDpsResourceListBySubscriptionNextOptionalParams,
20
+ IotDpsResourceListBySubscriptionOptionalParams,
21
+ IotDpsResourceListByResourceGroupNextOptionalParams,
22
+ IotDpsResourceListByResourceGroupOptionalParams,
23
+ IotDpsSkuDefinition,
24
+ IotDpsResourceListValidSkusNextOptionalParams,
25
+ IotDpsResourceListValidSkusOptionalParams,
26
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription,
27
+ IotDpsResourceListKeysNextOptionalParams,
28
+ IotDpsResourceListKeysOptionalParams,
29
+ IotDpsResourceGetOptionalParams,
30
+ IotDpsResourceGetResponse,
31
+ IotDpsResourceCreateOrUpdateOptionalParams,
32
+ IotDpsResourceCreateOrUpdateResponse,
33
+ TagsResource,
34
+ IotDpsResourceUpdateOptionalParams,
35
+ IotDpsResourceUpdateResponse,
36
+ IotDpsResourceDeleteOptionalParams,
37
+ IotDpsResourceListBySubscriptionResponse,
38
+ IotDpsResourceListByResourceGroupResponse,
39
+ IotDpsResourceGetOperationResultOptionalParams,
40
+ IotDpsResourceGetOperationResultResponse,
41
+ IotDpsResourceListValidSkusResponse,
42
+ OperationInputs,
43
+ IotDpsResourceCheckProvisioningServiceNameAvailabilityOptionalParams,
44
+ IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse,
45
+ IotDpsResourceListKeysResponse,
46
+ IotDpsResourceListKeysForKeyNameOptionalParams,
47
+ IotDpsResourceListKeysForKeyNameResponse,
48
+ IotDpsResourceListPrivateLinkResourcesOptionalParams,
49
+ IotDpsResourceListPrivateLinkResourcesResponse,
50
+ IotDpsResourceGetPrivateLinkResourcesOptionalParams,
51
+ IotDpsResourceGetPrivateLinkResourcesResponse,
52
+ IotDpsResourceListPrivateEndpointConnectionsOptionalParams,
53
+ IotDpsResourceListPrivateEndpointConnectionsResponse,
54
+ IotDpsResourceGetPrivateEndpointConnectionOptionalParams,
55
+ IotDpsResourceGetPrivateEndpointConnectionResponse,
56
+ PrivateEndpointConnection,
57
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams,
58
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse,
59
+ IotDpsResourceDeletePrivateEndpointConnectionOptionalParams,
60
+ IotDpsResourceDeletePrivateEndpointConnectionResponse,
61
+ IotDpsResourceListBySubscriptionNextResponse,
62
+ IotDpsResourceListByResourceGroupNextResponse,
63
+ IotDpsResourceListValidSkusNextResponse,
64
+ IotDpsResourceListKeysNextResponse
65
+ } from "../models";
16
66
 
17
- /** Class representing a IotDpsResource. */
18
- export class IotDpsResource {
19
- private readonly client: IotDpsClientContext;
67
+ /// <reference lib="esnext.asynciterable" />
68
+ /** Class containing IotDpsResource operations. */
69
+ export class IotDpsResourceImpl implements IotDpsResource {
70
+ private readonly client: IotDpsClient;
20
71
 
21
72
  /**
22
- * Create a IotDpsResource.
23
- * @param {IotDpsClientContext} client Reference to the service client.
73
+ * Initialize a new instance of the class IotDpsResource class.
74
+ * @param client Reference to the service client
24
75
  */
25
- constructor(client: IotDpsClientContext) {
76
+ constructor(client: IotDpsClient) {
26
77
  this.client = client;
27
78
  }
28
79
 
29
80
  /**
30
- * Get the metadata of the provisioning service without SAS keys.
31
- * @summary Get the non-security related metadata of the provisioning service.
32
- * @param provisioningServiceName Name of the provisioning service to retrieve.
33
- * @param resourceGroupName Resource group name.
34
- * @param [options] The optional parameters
35
- * @returns Promise<Models.IotDpsResourceGetResponse>
81
+ * List all the provisioning services for a given subscription id.
82
+ * @param options The options parameters.
36
83
  */
37
- get(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceGetResponse>;
84
+ public listBySubscription(
85
+ options?: IotDpsResourceListBySubscriptionOptionalParams
86
+ ): PagedAsyncIterableIterator<ProvisioningServiceDescription> {
87
+ const iter = this.listBySubscriptionPagingAll(options);
88
+ return {
89
+ next() {
90
+ return iter.next();
91
+ },
92
+ [Symbol.asyncIterator]() {
93
+ return this;
94
+ },
95
+ byPage: () => {
96
+ return this.listBySubscriptionPagingPage(options);
97
+ }
98
+ };
99
+ }
100
+
101
+ private async *listBySubscriptionPagingPage(
102
+ options?: IotDpsResourceListBySubscriptionOptionalParams
103
+ ): AsyncIterableIterator<ProvisioningServiceDescription[]> {
104
+ let result = await this._listBySubscription(options);
105
+ yield result.value || [];
106
+ let continuationToken = result.nextLink;
107
+ while (continuationToken) {
108
+ result = await this._listBySubscriptionNext(continuationToken, options);
109
+ continuationToken = result.nextLink;
110
+ yield result.value || [];
111
+ }
112
+ }
113
+
114
+ private async *listBySubscriptionPagingAll(
115
+ options?: IotDpsResourceListBySubscriptionOptionalParams
116
+ ): AsyncIterableIterator<ProvisioningServiceDescription> {
117
+ for await (const page of this.listBySubscriptionPagingPage(options)) {
118
+ yield* page;
119
+ }
120
+ }
121
+
38
122
  /**
39
- * @param provisioningServiceName Name of the provisioning service to retrieve.
40
- * @param resourceGroupName Resource group name.
41
- * @param callback The callback
123
+ * Get a list of all provisioning services in the given resource group.
124
+ * @param resourceGroupName Resource group identifier.
125
+ * @param options The options parameters.
42
126
  */
43
- get(provisioningServiceName: string, resourceGroupName: string, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescription>): void;
127
+ public listByResourceGroup(
128
+ resourceGroupName: string,
129
+ options?: IotDpsResourceListByResourceGroupOptionalParams
130
+ ): PagedAsyncIterableIterator<ProvisioningServiceDescription> {
131
+ const iter = this.listByResourceGroupPagingAll(resourceGroupName, options);
132
+ return {
133
+ next() {
134
+ return iter.next();
135
+ },
136
+ [Symbol.asyncIterator]() {
137
+ return this;
138
+ },
139
+ byPage: () => {
140
+ return this.listByResourceGroupPagingPage(resourceGroupName, options);
141
+ }
142
+ };
143
+ }
144
+
145
+ private async *listByResourceGroupPagingPage(
146
+ resourceGroupName: string,
147
+ options?: IotDpsResourceListByResourceGroupOptionalParams
148
+ ): AsyncIterableIterator<ProvisioningServiceDescription[]> {
149
+ let result = await this._listByResourceGroup(resourceGroupName, options);
150
+ yield result.value || [];
151
+ let continuationToken = result.nextLink;
152
+ while (continuationToken) {
153
+ result = await this._listByResourceGroupNext(
154
+ resourceGroupName,
155
+ continuationToken,
156
+ options
157
+ );
158
+ continuationToken = result.nextLink;
159
+ yield result.value || [];
160
+ }
161
+ }
162
+
163
+ private async *listByResourceGroupPagingAll(
164
+ resourceGroupName: string,
165
+ options?: IotDpsResourceListByResourceGroupOptionalParams
166
+ ): AsyncIterableIterator<ProvisioningServiceDescription> {
167
+ for await (const page of this.listByResourceGroupPagingPage(
168
+ resourceGroupName,
169
+ options
170
+ )) {
171
+ yield* page;
172
+ }
173
+ }
174
+
44
175
  /**
176
+ * Gets the list of valid SKUs and tiers for a provisioning service.
177
+ * @param provisioningServiceName Name of provisioning service.
178
+ * @param resourceGroupName Name of resource group.
179
+ * @param options The options parameters.
180
+ */
181
+ public listValidSkus(
182
+ provisioningServiceName: string,
183
+ resourceGroupName: string,
184
+ options?: IotDpsResourceListValidSkusOptionalParams
185
+ ): PagedAsyncIterableIterator<IotDpsSkuDefinition> {
186
+ const iter = this.listValidSkusPagingAll(
187
+ provisioningServiceName,
188
+ resourceGroupName,
189
+ options
190
+ );
191
+ return {
192
+ next() {
193
+ return iter.next();
194
+ },
195
+ [Symbol.asyncIterator]() {
196
+ return this;
197
+ },
198
+ byPage: () => {
199
+ return this.listValidSkusPagingPage(
200
+ provisioningServiceName,
201
+ resourceGroupName,
202
+ options
203
+ );
204
+ }
205
+ };
206
+ }
207
+
208
+ private async *listValidSkusPagingPage(
209
+ provisioningServiceName: string,
210
+ resourceGroupName: string,
211
+ options?: IotDpsResourceListValidSkusOptionalParams
212
+ ): AsyncIterableIterator<IotDpsSkuDefinition[]> {
213
+ let result = await this._listValidSkus(
214
+ provisioningServiceName,
215
+ resourceGroupName,
216
+ options
217
+ );
218
+ yield result.value || [];
219
+ let continuationToken = result.nextLink;
220
+ while (continuationToken) {
221
+ result = await this._listValidSkusNext(
222
+ provisioningServiceName,
223
+ resourceGroupName,
224
+ continuationToken,
225
+ options
226
+ );
227
+ continuationToken = result.nextLink;
228
+ yield result.value || [];
229
+ }
230
+ }
231
+
232
+ private async *listValidSkusPagingAll(
233
+ provisioningServiceName: string,
234
+ resourceGroupName: string,
235
+ options?: IotDpsResourceListValidSkusOptionalParams
236
+ ): AsyncIterableIterator<IotDpsSkuDefinition> {
237
+ for await (const page of this.listValidSkusPagingPage(
238
+ provisioningServiceName,
239
+ resourceGroupName,
240
+ options
241
+ )) {
242
+ yield* page;
243
+ }
244
+ }
245
+
246
+ /**
247
+ * List the primary and secondary keys for a provisioning service.
248
+ * @param provisioningServiceName The provisioning service name to get the shared access keys for.
249
+ * @param resourceGroupName resource group name
250
+ * @param options The options parameters.
251
+ */
252
+ public listKeys(
253
+ provisioningServiceName: string,
254
+ resourceGroupName: string,
255
+ options?: IotDpsResourceListKeysOptionalParams
256
+ ): PagedAsyncIterableIterator<
257
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription
258
+ > {
259
+ const iter = this.listKeysPagingAll(
260
+ provisioningServiceName,
261
+ resourceGroupName,
262
+ options
263
+ );
264
+ return {
265
+ next() {
266
+ return iter.next();
267
+ },
268
+ [Symbol.asyncIterator]() {
269
+ return this;
270
+ },
271
+ byPage: () => {
272
+ return this.listKeysPagingPage(
273
+ provisioningServiceName,
274
+ resourceGroupName,
275
+ options
276
+ );
277
+ }
278
+ };
279
+ }
280
+
281
+ private async *listKeysPagingPage(
282
+ provisioningServiceName: string,
283
+ resourceGroupName: string,
284
+ options?: IotDpsResourceListKeysOptionalParams
285
+ ): AsyncIterableIterator<
286
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription[]
287
+ > {
288
+ let result = await this._listKeys(
289
+ provisioningServiceName,
290
+ resourceGroupName,
291
+ options
292
+ );
293
+ yield result.value || [];
294
+ let continuationToken = result.nextLink;
295
+ while (continuationToken) {
296
+ result = await this._listKeysNext(
297
+ provisioningServiceName,
298
+ resourceGroupName,
299
+ continuationToken,
300
+ options
301
+ );
302
+ continuationToken = result.nextLink;
303
+ yield result.value || [];
304
+ }
305
+ }
306
+
307
+ private async *listKeysPagingAll(
308
+ provisioningServiceName: string,
309
+ resourceGroupName: string,
310
+ options?: IotDpsResourceListKeysOptionalParams
311
+ ): AsyncIterableIterator<
312
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription
313
+ > {
314
+ for await (const page of this.listKeysPagingPage(
315
+ provisioningServiceName,
316
+ resourceGroupName,
317
+ options
318
+ )) {
319
+ yield* page;
320
+ }
321
+ }
322
+
323
+ /**
324
+ * Get the metadata of the provisioning service without SAS keys.
45
325
  * @param provisioningServiceName Name of the provisioning service to retrieve.
46
326
  * @param resourceGroupName Resource group name.
47
- * @param options The optional parameters
48
- * @param callback The callback
327
+ * @param options The options parameters.
49
328
  */
50
- get(provisioningServiceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescription>): void;
51
- get(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.ProvisioningServiceDescription>, callback?: msRest.ServiceCallback<Models.ProvisioningServiceDescription>): Promise<Models.IotDpsResourceGetResponse> {
329
+ get(
330
+ provisioningServiceName: string,
331
+ resourceGroupName: string,
332
+ options?: IotDpsResourceGetOptionalParams
333
+ ): Promise<IotDpsResourceGetResponse> {
52
334
  return this.client.sendOperationRequest(
335
+ { provisioningServiceName, resourceGroupName, options },
336
+ getOperationSpec
337
+ );
338
+ }
339
+
340
+ /**
341
+ * Create or update the metadata of the provisioning service. The usual pattern to modify a property is
342
+ * to retrieve the provisioning service metadata and security metadata, and then combine them with the
343
+ * modified values in a new body to update the provisioning service.
344
+ * @param resourceGroupName Resource group identifier.
345
+ * @param provisioningServiceName Name of provisioning service to create or update.
346
+ * @param iotDpsDescription Description of the provisioning service to create or update.
347
+ * @param options The options parameters.
348
+ */
349
+ async beginCreateOrUpdate(
350
+ resourceGroupName: string,
351
+ provisioningServiceName: string,
352
+ iotDpsDescription: ProvisioningServiceDescription,
353
+ options?: IotDpsResourceCreateOrUpdateOptionalParams
354
+ ): Promise<
355
+ PollerLike<
356
+ PollOperationState<IotDpsResourceCreateOrUpdateResponse>,
357
+ IotDpsResourceCreateOrUpdateResponse
358
+ >
359
+ > {
360
+ const directSendOperation = async (
361
+ args: coreClient.OperationArguments,
362
+ spec: coreClient.OperationSpec
363
+ ): Promise<IotDpsResourceCreateOrUpdateResponse> => {
364
+ return this.client.sendOperationRequest(args, spec);
365
+ };
366
+ const sendOperation = async (
367
+ args: coreClient.OperationArguments,
368
+ spec: coreClient.OperationSpec
369
+ ) => {
370
+ let currentRawResponse:
371
+ | coreClient.FullOperationResponse
372
+ | undefined = undefined;
373
+ const providedCallback = args.options?.onResponse;
374
+ const callback: coreClient.RawResponseCallback = (
375
+ rawResponse: coreClient.FullOperationResponse,
376
+ flatResponse: unknown
377
+ ) => {
378
+ currentRawResponse = rawResponse;
379
+ providedCallback?.(rawResponse, flatResponse);
380
+ };
381
+ const updatedArgs = {
382
+ ...args,
383
+ options: {
384
+ ...args.options,
385
+ onResponse: callback
386
+ }
387
+ };
388
+ const flatResponse = await directSendOperation(updatedArgs, spec);
389
+ return {
390
+ flatResponse,
391
+ rawResponse: {
392
+ statusCode: currentRawResponse!.status,
393
+ body: currentRawResponse!.parsedBody,
394
+ headers: currentRawResponse!.headers.toJSON()
395
+ }
396
+ };
397
+ };
398
+
399
+ const lro = new LroImpl(
400
+ sendOperation,
53
401
  {
54
- provisioningServiceName,
55
402
  resourceGroupName,
403
+ provisioningServiceName,
404
+ iotDpsDescription,
56
405
  options
57
406
  },
58
- getOperationSpec,
59
- callback) as Promise<Models.IotDpsResourceGetResponse>;
407
+ createOrUpdateOperationSpec
408
+ );
409
+ return new LroEngine(lro, {
410
+ resumeFrom: options?.resumeFrom,
411
+ intervalInMs: options?.updateIntervalInMs
412
+ });
60
413
  }
61
414
 
62
415
  /**
63
- * Create or update the metadata of the provisioning service. The usual pattern to modify a
64
- * property is to retrieve the provisioning service metadata and security metadata, and then
65
- * combine them with the modified values in a new body to update the provisioning service.
66
- * @summary Create or update the metadata of the provisioning service.
416
+ * Create or update the metadata of the provisioning service. The usual pattern to modify a property is
417
+ * to retrieve the provisioning service metadata and security metadata, and then combine them with the
418
+ * modified values in a new body to update the provisioning service.
67
419
  * @param resourceGroupName Resource group identifier.
68
420
  * @param provisioningServiceName Name of provisioning service to create or update.
69
421
  * @param iotDpsDescription Description of the provisioning service to create or update.
70
- * @param [options] The optional parameters
71
- * @returns Promise<Models.IotDpsResourceCreateOrUpdateResponse>
422
+ * @param options The options parameters.
72
423
  */
73
- createOrUpdate(resourceGroupName: string, provisioningServiceName: string, iotDpsDescription: Models.ProvisioningServiceDescription, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceCreateOrUpdateResponse> {
74
- return this.beginCreateOrUpdate(resourceGroupName,provisioningServiceName,iotDpsDescription,options)
75
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.IotDpsResourceCreateOrUpdateResponse>;
424
+ async beginCreateOrUpdateAndWait(
425
+ resourceGroupName: string,
426
+ provisioningServiceName: string,
427
+ iotDpsDescription: ProvisioningServiceDescription,
428
+ options?: IotDpsResourceCreateOrUpdateOptionalParams
429
+ ): Promise<IotDpsResourceCreateOrUpdateResponse> {
430
+ const poller = await this.beginCreateOrUpdate(
431
+ resourceGroupName,
432
+ provisioningServiceName,
433
+ iotDpsDescription,
434
+ options
435
+ );
436
+ return poller.pollUntilDone();
76
437
  }
77
438
 
78
439
  /**
79
- * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate
80
- * method
81
- * @summary Update an existing provisioning service's tags.
440
+ * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate method
82
441
  * @param resourceGroupName Resource group identifier.
83
442
  * @param provisioningServiceName Name of provisioning service to create or update.
84
443
  * @param provisioningServiceTags Updated tag information to set into the provisioning service
85
- * instance.
86
- * @param [options] The optional parameters
87
- * @returns Promise<Models.IotDpsResourceUpdateResponse>
444
+ * instance.
445
+ * @param options The options parameters.
88
446
  */
89
- update(resourceGroupName: string, provisioningServiceName: string, provisioningServiceTags: Models.TagsResource, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceUpdateResponse> {
90
- return this.beginUpdate(resourceGroupName,provisioningServiceName,provisioningServiceTags,options)
91
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.IotDpsResourceUpdateResponse>;
447
+ async beginUpdate(
448
+ resourceGroupName: string,
449
+ provisioningServiceName: string,
450
+ provisioningServiceTags: TagsResource,
451
+ options?: IotDpsResourceUpdateOptionalParams
452
+ ): Promise<
453
+ PollerLike<
454
+ PollOperationState<IotDpsResourceUpdateResponse>,
455
+ IotDpsResourceUpdateResponse
456
+ >
457
+ > {
458
+ const directSendOperation = async (
459
+ args: coreClient.OperationArguments,
460
+ spec: coreClient.OperationSpec
461
+ ): Promise<IotDpsResourceUpdateResponse> => {
462
+ return this.client.sendOperationRequest(args, spec);
463
+ };
464
+ const sendOperation = async (
465
+ args: coreClient.OperationArguments,
466
+ spec: coreClient.OperationSpec
467
+ ) => {
468
+ let currentRawResponse:
469
+ | coreClient.FullOperationResponse
470
+ | undefined = undefined;
471
+ const providedCallback = args.options?.onResponse;
472
+ const callback: coreClient.RawResponseCallback = (
473
+ rawResponse: coreClient.FullOperationResponse,
474
+ flatResponse: unknown
475
+ ) => {
476
+ currentRawResponse = rawResponse;
477
+ providedCallback?.(rawResponse, flatResponse);
478
+ };
479
+ const updatedArgs = {
480
+ ...args,
481
+ options: {
482
+ ...args.options,
483
+ onResponse: callback
484
+ }
485
+ };
486
+ const flatResponse = await directSendOperation(updatedArgs, spec);
487
+ return {
488
+ flatResponse,
489
+ rawResponse: {
490
+ statusCode: currentRawResponse!.status,
491
+ body: currentRawResponse!.parsedBody,
492
+ headers: currentRawResponse!.headers.toJSON()
493
+ }
494
+ };
495
+ };
496
+
497
+ const lro = new LroImpl(
498
+ sendOperation,
499
+ {
500
+ resourceGroupName,
501
+ provisioningServiceName,
502
+ provisioningServiceTags,
503
+ options
504
+ },
505
+ updateOperationSpec
506
+ );
507
+ return new LroEngine(lro, {
508
+ resumeFrom: options?.resumeFrom,
509
+ intervalInMs: options?.updateIntervalInMs
510
+ });
92
511
  }
93
512
 
94
513
  /**
95
- * Deletes the Provisioning Service.
96
- * @summary Delete the Provisioning Service
97
- * @param provisioningServiceName Name of provisioning service to delete.
514
+ * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate method
98
515
  * @param resourceGroupName Resource group identifier.
99
- * @param [options] The optional parameters
100
- * @returns Promise<msRest.RestResponse>
516
+ * @param provisioningServiceName Name of provisioning service to create or update.
517
+ * @param provisioningServiceTags Updated tag information to set into the provisioning service
518
+ * instance.
519
+ * @param options The options parameters.
101
520
  */
102
- deleteMethod(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<msRest.RestResponse> {
103
- return this.beginDeleteMethod(provisioningServiceName,resourceGroupName,options)
104
- .then(lroPoller => lroPoller.pollUntilFinished());
521
+ async beginUpdateAndWait(
522
+ resourceGroupName: string,
523
+ provisioningServiceName: string,
524
+ provisioningServiceTags: TagsResource,
525
+ options?: IotDpsResourceUpdateOptionalParams
526
+ ): Promise<IotDpsResourceUpdateResponse> {
527
+ const poller = await this.beginUpdate(
528
+ resourceGroupName,
529
+ provisioningServiceName,
530
+ provisioningServiceTags,
531
+ options
532
+ );
533
+ return poller.pollUntilDone();
105
534
  }
106
535
 
107
536
  /**
108
- * List all the provisioning services for a given subscription id.
109
- * @summary Get all the provisioning services in a subscription.
110
- * @param [options] The optional parameters
111
- * @returns Promise<Models.IotDpsResourceListBySubscriptionResponse>
537
+ * Deletes the Provisioning Service.
538
+ * @param provisioningServiceName Name of provisioning service to delete.
539
+ * @param resourceGroupName Resource group identifier.
540
+ * @param options The options parameters.
112
541
  */
113
- listBySubscription(options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListBySubscriptionResponse>;
542
+ async beginDelete(
543
+ provisioningServiceName: string,
544
+ resourceGroupName: string,
545
+ options?: IotDpsResourceDeleteOptionalParams
546
+ ): Promise<PollerLike<PollOperationState<void>, void>> {
547
+ const directSendOperation = async (
548
+ args: coreClient.OperationArguments,
549
+ spec: coreClient.OperationSpec
550
+ ): Promise<void> => {
551
+ return this.client.sendOperationRequest(args, spec);
552
+ };
553
+ const sendOperation = async (
554
+ args: coreClient.OperationArguments,
555
+ spec: coreClient.OperationSpec
556
+ ) => {
557
+ let currentRawResponse:
558
+ | coreClient.FullOperationResponse
559
+ | undefined = undefined;
560
+ const providedCallback = args.options?.onResponse;
561
+ const callback: coreClient.RawResponseCallback = (
562
+ rawResponse: coreClient.FullOperationResponse,
563
+ flatResponse: unknown
564
+ ) => {
565
+ currentRawResponse = rawResponse;
566
+ providedCallback?.(rawResponse, flatResponse);
567
+ };
568
+ const updatedArgs = {
569
+ ...args,
570
+ options: {
571
+ ...args.options,
572
+ onResponse: callback
573
+ }
574
+ };
575
+ const flatResponse = await directSendOperation(updatedArgs, spec);
576
+ return {
577
+ flatResponse,
578
+ rawResponse: {
579
+ statusCode: currentRawResponse!.status,
580
+ body: currentRawResponse!.parsedBody,
581
+ headers: currentRawResponse!.headers.toJSON()
582
+ }
583
+ };
584
+ };
585
+
586
+ const lro = new LroImpl(
587
+ sendOperation,
588
+ { provisioningServiceName, resourceGroupName, options },
589
+ deleteOperationSpec
590
+ );
591
+ return new LroEngine(lro, {
592
+ resumeFrom: options?.resumeFrom,
593
+ intervalInMs: options?.updateIntervalInMs
594
+ });
595
+ }
596
+
114
597
  /**
115
- * @param callback The callback
598
+ * Deletes the Provisioning Service.
599
+ * @param provisioningServiceName Name of provisioning service to delete.
600
+ * @param resourceGroupName Resource group identifier.
601
+ * @param options The options parameters.
116
602
  */
117
- listBySubscription(callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
603
+ async beginDeleteAndWait(
604
+ provisioningServiceName: string,
605
+ resourceGroupName: string,
606
+ options?: IotDpsResourceDeleteOptionalParams
607
+ ): Promise<void> {
608
+ const poller = await this.beginDelete(
609
+ provisioningServiceName,
610
+ resourceGroupName,
611
+ options
612
+ );
613
+ return poller.pollUntilDone();
614
+ }
615
+
118
616
  /**
119
- * @param options The optional parameters
120
- * @param callback The callback
617
+ * List all the provisioning services for a given subscription id.
618
+ * @param options The options parameters.
121
619
  */
122
- listBySubscription(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
123
- listBySubscription(options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>, callback?: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): Promise<Models.IotDpsResourceListBySubscriptionResponse> {
620
+ private _listBySubscription(
621
+ options?: IotDpsResourceListBySubscriptionOptionalParams
622
+ ): Promise<IotDpsResourceListBySubscriptionResponse> {
124
623
  return this.client.sendOperationRequest(
125
- {
126
- options
127
- },
128
- listBySubscriptionOperationSpec,
129
- callback) as Promise<Models.IotDpsResourceListBySubscriptionResponse>;
624
+ { options },
625
+ listBySubscriptionOperationSpec
626
+ );
130
627
  }
131
628
 
132
629
  /**
133
630
  * Get a list of all provisioning services in the given resource group.
134
631
  * @param resourceGroupName Resource group identifier.
135
- * @param [options] The optional parameters
136
- * @returns Promise<Models.IotDpsResourceListByResourceGroupResponse>
137
- */
138
- listByResourceGroup(resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListByResourceGroupResponse>;
139
- /**
140
- * @param resourceGroupName Resource group identifier.
141
- * @param callback The callback
632
+ * @param options The options parameters.
142
633
  */
143
- listByResourceGroup(resourceGroupName: string, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
144
- /**
145
- * @param resourceGroupName Resource group identifier.
146
- * @param options The optional parameters
147
- * @param callback The callback
148
- */
149
- listByResourceGroup(resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
150
- listByResourceGroup(resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>, callback?: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): Promise<Models.IotDpsResourceListByResourceGroupResponse> {
634
+ private _listByResourceGroup(
635
+ resourceGroupName: string,
636
+ options?: IotDpsResourceListByResourceGroupOptionalParams
637
+ ): Promise<IotDpsResourceListByResourceGroupResponse> {
151
638
  return this.client.sendOperationRequest(
152
- {
153
- resourceGroupName,
154
- options
155
- },
156
- listByResourceGroupOperationSpec,
157
- callback) as Promise<Models.IotDpsResourceListByResourceGroupResponse>;
639
+ { resourceGroupName, options },
640
+ listByResourceGroupOperationSpec
641
+ );
158
642
  }
159
643
 
160
644
  /**
161
645
  * Gets the status of a long running operation, such as create, update or delete a provisioning
162
646
  * service.
163
- * @param operationId Operation id corresponding to long running operation. Use this to poll for
164
- * the status.
647
+ * @param operationId Operation id corresponding to long running operation. Use this to poll for the
648
+ * status.
165
649
  * @param resourceGroupName Resource group identifier.
166
650
  * @param provisioningServiceName Name of provisioning service that the operation is running on.
167
- * @param asyncinfo Async header used to poll on the status of the operation, obtained while
168
- * creating the long running operation.
169
- * @param [options] The optional parameters
170
- * @returns Promise<Models.IotDpsResourceGetOperationResultResponse>
651
+ * @param asyncinfo Async header used to poll on the status of the operation, obtained while creating
652
+ * the long running operation.
653
+ * @param options The options parameters.
171
654
  */
172
- getOperationResult(operationId: string, resourceGroupName: string, provisioningServiceName: string, asyncinfo: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceGetOperationResultResponse>;
173
- /**
174
- * @param operationId Operation id corresponding to long running operation. Use this to poll for
175
- * the status.
176
- * @param resourceGroupName Resource group identifier.
177
- * @param provisioningServiceName Name of provisioning service that the operation is running on.
178
- * @param asyncinfo Async header used to poll on the status of the operation, obtained while
179
- * creating the long running operation.
180
- * @param callback The callback
181
- */
182
- getOperationResult(operationId: string, resourceGroupName: string, provisioningServiceName: string, asyncinfo: string, callback: msRest.ServiceCallback<Models.AsyncOperationResult>): void;
183
- /**
184
- * @param operationId Operation id corresponding to long running operation. Use this to poll for
185
- * the status.
186
- * @param resourceGroupName Resource group identifier.
187
- * @param provisioningServiceName Name of provisioning service that the operation is running on.
188
- * @param asyncinfo Async header used to poll on the status of the operation, obtained while
189
- * creating the long running operation.
190
- * @param options The optional parameters
191
- * @param callback The callback
192
- */
193
- getOperationResult(operationId: string, resourceGroupName: string, provisioningServiceName: string, asyncinfo: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.AsyncOperationResult>): void;
194
- getOperationResult(operationId: string, resourceGroupName: string, provisioningServiceName: string, asyncinfo: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.AsyncOperationResult>, callback?: msRest.ServiceCallback<Models.AsyncOperationResult>): Promise<Models.IotDpsResourceGetOperationResultResponse> {
655
+ getOperationResult(
656
+ operationId: string,
657
+ resourceGroupName: string,
658
+ provisioningServiceName: string,
659
+ asyncinfo: string,
660
+ options?: IotDpsResourceGetOperationResultOptionalParams
661
+ ): Promise<IotDpsResourceGetOperationResultResponse> {
195
662
  return this.client.sendOperationRequest(
196
663
  {
197
664
  operationId,
@@ -200,275 +667,146 @@ export class IotDpsResource {
200
667
  asyncinfo,
201
668
  options
202
669
  },
203
- getOperationResultOperationSpec,
204
- callback) as Promise<Models.IotDpsResourceGetOperationResultResponse>;
670
+ getOperationResultOperationSpec
671
+ );
205
672
  }
206
673
 
207
674
  /**
208
675
  * Gets the list of valid SKUs and tiers for a provisioning service.
209
- * @summary Get the list of valid SKUs for a provisioning service.
210
- * @param provisioningServiceName Name of provisioning service.
211
- * @param resourceGroupName Name of resource group.
212
- * @param [options] The optional parameters
213
- * @returns Promise<Models.IotDpsResourceListValidSkusResponse>
214
- */
215
- listValidSkus(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListValidSkusResponse>;
216
- /**
217
676
  * @param provisioningServiceName Name of provisioning service.
218
677
  * @param resourceGroupName Name of resource group.
219
- * @param callback The callback
678
+ * @param options The options parameters.
220
679
  */
221
- listValidSkus(provisioningServiceName: string, resourceGroupName: string, callback: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): void;
222
- /**
223
- * @param provisioningServiceName Name of provisioning service.
224
- * @param resourceGroupName Name of resource group.
225
- * @param options The optional parameters
226
- * @param callback The callback
227
- */
228
- listValidSkus(provisioningServiceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): void;
229
- listValidSkus(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>, callback?: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): Promise<Models.IotDpsResourceListValidSkusResponse> {
680
+ private _listValidSkus(
681
+ provisioningServiceName: string,
682
+ resourceGroupName: string,
683
+ options?: IotDpsResourceListValidSkusOptionalParams
684
+ ): Promise<IotDpsResourceListValidSkusResponse> {
230
685
  return this.client.sendOperationRequest(
231
- {
232
- provisioningServiceName,
233
- resourceGroupName,
234
- options
235
- },
236
- listValidSkusOperationSpec,
237
- callback) as Promise<Models.IotDpsResourceListValidSkusResponse>;
686
+ { provisioningServiceName, resourceGroupName, options },
687
+ listValidSkusOperationSpec
688
+ );
238
689
  }
239
690
 
240
691
  /**
241
- * Check if a provisioning service name is available. This will validate if the name is
242
- * syntactically valid and if the name is usable
243
- * @summary Check if a provisioning service name is available.
244
- * @param argumentsParameter Set the name parameter in the OperationInputs structure to the name of
245
- * the provisioning service to check.
246
- * @param [options] The optional parameters
247
- * @returns Promise<Models.IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse>
692
+ * Check if a provisioning service name is available. This will validate if the name is syntactically
693
+ * valid and if the name is usable
694
+ * @param argumentsParam Set the name parameter in the OperationInputs structure to the name of the
695
+ * provisioning service to check.
696
+ * @param options The options parameters.
248
697
  */
249
- checkProvisioningServiceNameAvailability(argumentsParameter: Models.OperationInputs, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse>;
250
- /**
251
- * @param argumentsParameter Set the name parameter in the OperationInputs structure to the name of
252
- * the provisioning service to check.
253
- * @param callback The callback
254
- */
255
- checkProvisioningServiceNameAvailability(argumentsParameter: Models.OperationInputs, callback: msRest.ServiceCallback<Models.NameAvailabilityInfo>): void;
256
- /**
257
- * @param argumentsParameter Set the name parameter in the OperationInputs structure to the name of
258
- * the provisioning service to check.
259
- * @param options The optional parameters
260
- * @param callback The callback
261
- */
262
- checkProvisioningServiceNameAvailability(argumentsParameter: Models.OperationInputs, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.NameAvailabilityInfo>): void;
263
- checkProvisioningServiceNameAvailability(argumentsParameter: Models.OperationInputs, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.NameAvailabilityInfo>, callback?: msRest.ServiceCallback<Models.NameAvailabilityInfo>): Promise<Models.IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse> {
698
+ checkProvisioningServiceNameAvailability(
699
+ argumentsParam: OperationInputs,
700
+ options?: IotDpsResourceCheckProvisioningServiceNameAvailabilityOptionalParams
701
+ ): Promise<IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse> {
264
702
  return this.client.sendOperationRequest(
265
- {
266
- argumentsParameter,
267
- options
268
- },
269
- checkProvisioningServiceNameAvailabilityOperationSpec,
270
- callback) as Promise<Models.IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse>;
703
+ { argumentsParam, options },
704
+ checkProvisioningServiceNameAvailabilityOperationSpec
705
+ );
271
706
  }
272
707
 
273
708
  /**
274
709
  * List the primary and secondary keys for a provisioning service.
275
- * @summary Get the security metadata for a provisioning service.
276
710
  * @param provisioningServiceName The provisioning service name to get the shared access keys for.
277
711
  * @param resourceGroupName resource group name
278
- * @param [options] The optional parameters
279
- * @returns Promise<Models.IotDpsResourceListKeysResponse>
712
+ * @param options The options parameters.
280
713
  */
281
- listKeys(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListKeysResponse>;
282
- /**
283
- * @param provisioningServiceName The provisioning service name to get the shared access keys for.
284
- * @param resourceGroupName resource group name
285
- * @param callback The callback
286
- */
287
- listKeys(provisioningServiceName: string, resourceGroupName: string, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): void;
288
- /**
289
- * @param provisioningServiceName The provisioning service name to get the shared access keys for.
290
- * @param resourceGroupName resource group name
291
- * @param options The optional parameters
292
- * @param callback The callback
293
- */
294
- listKeys(provisioningServiceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): void;
295
- listKeys(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>, callback?: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): Promise<Models.IotDpsResourceListKeysResponse> {
714
+ private _listKeys(
715
+ provisioningServiceName: string,
716
+ resourceGroupName: string,
717
+ options?: IotDpsResourceListKeysOptionalParams
718
+ ): Promise<IotDpsResourceListKeysResponse> {
296
719
  return this.client.sendOperationRequest(
297
- {
298
- provisioningServiceName,
299
- resourceGroupName,
300
- options
301
- },
302
- listKeysOperationSpec,
303
- callback) as Promise<Models.IotDpsResourceListKeysResponse>;
720
+ { provisioningServiceName, resourceGroupName, options },
721
+ listKeysOperationSpec
722
+ );
304
723
  }
305
724
 
306
725
  /**
307
726
  * List primary and secondary keys for a specific key name
308
- * @summary Get a shared access policy by name from a provisioning service.
309
- * @param provisioningServiceName Name of the provisioning service.
310
- * @param keyName Logical key name to get key-values for.
311
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
312
- * @param [options] The optional parameters
313
- * @returns Promise<Models.IotDpsResourceListKeysForKeyNameResponse>
314
- */
315
- listKeysForKeyName(provisioningServiceName: string, keyName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListKeysForKeyNameResponse>;
316
- /**
317
727
  * @param provisioningServiceName Name of the provisioning service.
318
728
  * @param keyName Logical key name to get key-values for.
319
729
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
320
- * @param callback The callback
730
+ * @param options The options parameters.
321
731
  */
322
- listKeysForKeyName(provisioningServiceName: string, keyName: string, resourceGroupName: string, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleAccessRightsDescription>): void;
323
- /**
324
- * @param provisioningServiceName Name of the provisioning service.
325
- * @param keyName Logical key name to get key-values for.
326
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
327
- * @param options The optional parameters
328
- * @param callback The callback
329
- */
330
- listKeysForKeyName(provisioningServiceName: string, keyName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleAccessRightsDescription>): void;
331
- listKeysForKeyName(provisioningServiceName: string, keyName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleAccessRightsDescription>, callback?: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleAccessRightsDescription>): Promise<Models.IotDpsResourceListKeysForKeyNameResponse> {
732
+ listKeysForKeyName(
733
+ provisioningServiceName: string,
734
+ keyName: string,
735
+ resourceGroupName: string,
736
+ options?: IotDpsResourceListKeysForKeyNameOptionalParams
737
+ ): Promise<IotDpsResourceListKeysForKeyNameResponse> {
332
738
  return this.client.sendOperationRequest(
333
- {
334
- provisioningServiceName,
335
- keyName,
336
- resourceGroupName,
337
- options
338
- },
339
- listKeysForKeyNameOperationSpec,
340
- callback) as Promise<Models.IotDpsResourceListKeysForKeyNameResponse>;
739
+ { provisioningServiceName, keyName, resourceGroupName, options },
740
+ listKeysForKeyNameOperationSpec
741
+ );
341
742
  }
342
743
 
343
744
  /**
344
745
  * List private link resources for the given provisioning service
345
- * @summary List private link resources
346
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
347
- * @param resourceName The name of the provisioning service.
348
- * @param [options] The optional parameters
349
- * @returns Promise<Models.IotDpsResourceListPrivateLinkResourcesResponse>
350
- */
351
- listPrivateLinkResources(resourceGroupName: string, resourceName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListPrivateLinkResourcesResponse>;
352
- /**
353
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
354
- * @param resourceName The name of the provisioning service.
355
- * @param callback The callback
356
- */
357
- listPrivateLinkResources(resourceGroupName: string, resourceName: string, callback: msRest.ServiceCallback<Models.PrivateLinkResources>): void;
358
- /**
359
746
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
360
747
  * @param resourceName The name of the provisioning service.
361
- * @param options The optional parameters
362
- * @param callback The callback
748
+ * @param options The options parameters.
363
749
  */
364
- listPrivateLinkResources(resourceGroupName: string, resourceName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.PrivateLinkResources>): void;
365
- listPrivateLinkResources(resourceGroupName: string, resourceName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.PrivateLinkResources>, callback?: msRest.ServiceCallback<Models.PrivateLinkResources>): Promise<Models.IotDpsResourceListPrivateLinkResourcesResponse> {
750
+ listPrivateLinkResources(
751
+ resourceGroupName: string,
752
+ resourceName: string,
753
+ options?: IotDpsResourceListPrivateLinkResourcesOptionalParams
754
+ ): Promise<IotDpsResourceListPrivateLinkResourcesResponse> {
366
755
  return this.client.sendOperationRequest(
367
- {
368
- resourceGroupName,
369
- resourceName,
370
- options
371
- },
372
- listPrivateLinkResourcesOperationSpec,
373
- callback) as Promise<Models.IotDpsResourceListPrivateLinkResourcesResponse>;
756
+ { resourceGroupName, resourceName, options },
757
+ listPrivateLinkResourcesOperationSpec
758
+ );
374
759
  }
375
760
 
376
761
  /**
377
762
  * Get the specified private link resource for the given provisioning service
378
- * @summary Get the specified private link resource
379
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
380
- * @param resourceName The name of the provisioning service.
381
- * @param groupId The name of the private link resource
382
- * @param [options] The optional parameters
383
- * @returns Promise<Models.IotDpsResourceGetPrivateLinkResourcesResponse>
384
- */
385
- getPrivateLinkResources(resourceGroupName: string, resourceName: string, groupId: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceGetPrivateLinkResourcesResponse>;
386
- /**
387
763
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
388
764
  * @param resourceName The name of the provisioning service.
389
765
  * @param groupId The name of the private link resource
390
- * @param callback The callback
766
+ * @param options The options parameters.
391
767
  */
392
- getPrivateLinkResources(resourceGroupName: string, resourceName: string, groupId: string, callback: msRest.ServiceCallback<Models.GroupIdInformation>): void;
393
- /**
394
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
395
- * @param resourceName The name of the provisioning service.
396
- * @param groupId The name of the private link resource
397
- * @param options The optional parameters
398
- * @param callback The callback
399
- */
400
- getPrivateLinkResources(resourceGroupName: string, resourceName: string, groupId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.GroupIdInformation>): void;
401
- getPrivateLinkResources(resourceGroupName: string, resourceName: string, groupId: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.GroupIdInformation>, callback?: msRest.ServiceCallback<Models.GroupIdInformation>): Promise<Models.IotDpsResourceGetPrivateLinkResourcesResponse> {
768
+ getPrivateLinkResources(
769
+ resourceGroupName: string,
770
+ resourceName: string,
771
+ groupId: string,
772
+ options?: IotDpsResourceGetPrivateLinkResourcesOptionalParams
773
+ ): Promise<IotDpsResourceGetPrivateLinkResourcesResponse> {
402
774
  return this.client.sendOperationRequest(
403
- {
404
- resourceGroupName,
405
- resourceName,
406
- groupId,
407
- options
408
- },
409
- getPrivateLinkResourcesOperationSpec,
410
- callback) as Promise<Models.IotDpsResourceGetPrivateLinkResourcesResponse>;
775
+ { resourceGroupName, resourceName, groupId, options },
776
+ getPrivateLinkResourcesOperationSpec
777
+ );
411
778
  }
412
779
 
413
780
  /**
414
781
  * List private endpoint connection properties
415
- * @summary List private endpoint connections
416
782
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
417
783
  * @param resourceName The name of the provisioning service.
418
- * @param [options] The optional parameters
419
- * @returns Promise<Models.IotDpsResourceListPrivateEndpointConnectionsResponse>
784
+ * @param options The options parameters.
420
785
  */
421
- listPrivateEndpointConnections(resourceGroupName: string, resourceName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListPrivateEndpointConnectionsResponse>;
422
- /**
423
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
424
- * @param resourceName The name of the provisioning service.
425
- * @param callback The callback
426
- */
427
- listPrivateEndpointConnections(resourceGroupName: string, resourceName: string, callback: msRest.ServiceCallback<Models.PrivateEndpointConnection[]>): void;
428
- /**
429
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
430
- * @param resourceName The name of the provisioning service.
431
- * @param options The optional parameters
432
- * @param callback The callback
433
- */
434
- listPrivateEndpointConnections(resourceGroupName: string, resourceName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.PrivateEndpointConnection[]>): void;
435
- listPrivateEndpointConnections(resourceGroupName: string, resourceName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.PrivateEndpointConnection[]>, callback?: msRest.ServiceCallback<Models.PrivateEndpointConnection[]>): Promise<Models.IotDpsResourceListPrivateEndpointConnectionsResponse> {
786
+ listPrivateEndpointConnections(
787
+ resourceGroupName: string,
788
+ resourceName: string,
789
+ options?: IotDpsResourceListPrivateEndpointConnectionsOptionalParams
790
+ ): Promise<IotDpsResourceListPrivateEndpointConnectionsResponse> {
436
791
  return this.client.sendOperationRequest(
437
- {
438
- resourceGroupName,
439
- resourceName,
440
- options
441
- },
442
- listPrivateEndpointConnectionsOperationSpec,
443
- callback) as Promise<Models.IotDpsResourceListPrivateEndpointConnectionsResponse>;
792
+ { resourceGroupName, resourceName, options },
793
+ listPrivateEndpointConnectionsOperationSpec
794
+ );
444
795
  }
445
796
 
446
797
  /**
447
798
  * Get private endpoint connection properties
448
- * @summary Get private endpoint connection
449
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
450
- * @param resourceName The name of the provisioning service.
451
- * @param privateEndpointConnectionName The name of the private endpoint connection
452
- * @param [options] The optional parameters
453
- * @returns Promise<Models.IotDpsResourceGetPrivateEndpointConnectionResponse>
454
- */
455
- getPrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceGetPrivateEndpointConnectionResponse>;
456
- /**
457
799
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
458
800
  * @param resourceName The name of the provisioning service.
459
801
  * @param privateEndpointConnectionName The name of the private endpoint connection
460
- * @param callback The callback
802
+ * @param options The options parameters.
461
803
  */
462
- getPrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, callback: msRest.ServiceCallback<Models.PrivateEndpointConnection>): void;
463
- /**
464
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
465
- * @param resourceName The name of the provisioning service.
466
- * @param privateEndpointConnectionName The name of the private endpoint connection
467
- * @param options The optional parameters
468
- * @param callback The callback
469
- */
470
- getPrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.PrivateEndpointConnection>): void;
471
- getPrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.PrivateEndpointConnection>, callback?: msRest.ServiceCallback<Models.PrivateEndpointConnection>): Promise<Models.IotDpsResourceGetPrivateEndpointConnectionResponse> {
804
+ getPrivateEndpointConnection(
805
+ resourceGroupName: string,
806
+ resourceName: string,
807
+ privateEndpointConnectionName: string,
808
+ options?: IotDpsResourceGetPrivateEndpointConnectionOptionalParams
809
+ ): Promise<IotDpsResourceGetPrivateEndpointConnectionResponse> {
472
810
  return this.client.sendOperationRequest(
473
811
  {
474
812
  resourceGroupName,
@@ -476,303 +814,393 @@ export class IotDpsResource {
476
814
  privateEndpointConnectionName,
477
815
  options
478
816
  },
479
- getPrivateEndpointConnectionOperationSpec,
480
- callback) as Promise<Models.IotDpsResourceGetPrivateEndpointConnectionResponse>;
817
+ getPrivateEndpointConnectionOperationSpec
818
+ );
481
819
  }
482
820
 
483
821
  /**
484
822
  * Create or update the status of a private endpoint connection with the specified name
485
- * @summary Create or update private endpoint connection
486
823
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
487
824
  * @param resourceName The name of the provisioning service.
488
825
  * @param privateEndpointConnectionName The name of the private endpoint connection
489
826
  * @param privateEndpointConnection The private endpoint connection with updated properties
490
- * @param [options] The optional parameters
491
- * @returns Promise<Models.IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse>
827
+ * @param options The options parameters.
492
828
  */
493
- createOrUpdatePrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, privateEndpointConnection: Models.PrivateEndpointConnection, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse> {
494
- return this.beginCreateOrUpdatePrivateEndpointConnection(resourceGroupName,resourceName,privateEndpointConnectionName,privateEndpointConnection,options)
495
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse>;
496
- }
497
-
498
- /**
499
- * Delete private endpoint connection with the specified name
500
- * @summary Delete private endpoint connection
501
- * @param resourceGroupName The name of the resource group that contains the provisioning service.
502
- * @param resourceName The name of the provisioning service.
503
- * @param privateEndpointConnectionName The name of the private endpoint connection
504
- * @param [options] The optional parameters
505
- * @returns Promise<Models.IotDpsResourceDeletePrivateEndpointConnectionResponse>
506
- */
507
- deletePrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceDeletePrivateEndpointConnectionResponse> {
508
- return this.beginDeletePrivateEndpointConnection(resourceGroupName,resourceName,privateEndpointConnectionName,options)
509
- .then(lroPoller => lroPoller.pollUntilFinished()) as Promise<Models.IotDpsResourceDeletePrivateEndpointConnectionResponse>;
510
- }
511
-
512
- /**
513
- * Create or update the metadata of the provisioning service. The usual pattern to modify a
514
- * property is to retrieve the provisioning service metadata and security metadata, and then
515
- * combine them with the modified values in a new body to update the provisioning service.
516
- * @summary Create or update the metadata of the provisioning service.
517
- * @param resourceGroupName Resource group identifier.
518
- * @param provisioningServiceName Name of provisioning service to create or update.
519
- * @param iotDpsDescription Description of the provisioning service to create or update.
520
- * @param [options] The optional parameters
521
- * @returns Promise<msRestAzure.LROPoller>
522
- */
523
- beginCreateOrUpdate(resourceGroupName: string, provisioningServiceName: string, iotDpsDescription: Models.ProvisioningServiceDescription, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
524
- return this.client.sendLRORequest(
525
- {
526
- resourceGroupName,
527
- provisioningServiceName,
528
- iotDpsDescription,
529
- options
530
- },
531
- beginCreateOrUpdateOperationSpec,
532
- options);
533
- }
829
+ async beginCreateOrUpdatePrivateEndpointConnection(
830
+ resourceGroupName: string,
831
+ resourceName: string,
832
+ privateEndpointConnectionName: string,
833
+ privateEndpointConnection: PrivateEndpointConnection,
834
+ options?: IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams
835
+ ): Promise<
836
+ PollerLike<
837
+ PollOperationState<
838
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse
839
+ >,
840
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse
841
+ >
842
+ > {
843
+ const directSendOperation = async (
844
+ args: coreClient.OperationArguments,
845
+ spec: coreClient.OperationSpec
846
+ ): Promise<IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse> => {
847
+ return this.client.sendOperationRequest(args, spec);
848
+ };
849
+ const sendOperation = async (
850
+ args: coreClient.OperationArguments,
851
+ spec: coreClient.OperationSpec
852
+ ) => {
853
+ let currentRawResponse:
854
+ | coreClient.FullOperationResponse
855
+ | undefined = undefined;
856
+ const providedCallback = args.options?.onResponse;
857
+ const callback: coreClient.RawResponseCallback = (
858
+ rawResponse: coreClient.FullOperationResponse,
859
+ flatResponse: unknown
860
+ ) => {
861
+ currentRawResponse = rawResponse;
862
+ providedCallback?.(rawResponse, flatResponse);
863
+ };
864
+ const updatedArgs = {
865
+ ...args,
866
+ options: {
867
+ ...args.options,
868
+ onResponse: callback
869
+ }
870
+ };
871
+ const flatResponse = await directSendOperation(updatedArgs, spec);
872
+ return {
873
+ flatResponse,
874
+ rawResponse: {
875
+ statusCode: currentRawResponse!.status,
876
+ body: currentRawResponse!.parsedBody,
877
+ headers: currentRawResponse!.headers.toJSON()
878
+ }
879
+ };
880
+ };
534
881
 
535
- /**
536
- * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate
537
- * method
538
- * @summary Update an existing provisioning service's tags.
539
- * @param resourceGroupName Resource group identifier.
540
- * @param provisioningServiceName Name of provisioning service to create or update.
541
- * @param provisioningServiceTags Updated tag information to set into the provisioning service
542
- * instance.
543
- * @param [options] The optional parameters
544
- * @returns Promise<msRestAzure.LROPoller>
545
- */
546
- beginUpdate(resourceGroupName: string, provisioningServiceName: string, provisioningServiceTags: Models.TagsResource, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
547
- return this.client.sendLRORequest(
882
+ const lro = new LroImpl(
883
+ sendOperation,
548
884
  {
549
885
  resourceGroupName,
550
- provisioningServiceName,
551
- provisioningServiceTags,
552
- options
553
- },
554
- beginUpdateOperationSpec,
555
- options);
556
- }
557
-
558
- /**
559
- * Deletes the Provisioning Service.
560
- * @summary Delete the Provisioning Service
561
- * @param provisioningServiceName Name of provisioning service to delete.
562
- * @param resourceGroupName Resource group identifier.
563
- * @param [options] The optional parameters
564
- * @returns Promise<msRestAzure.LROPoller>
565
- */
566
- beginDeleteMethod(provisioningServiceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
567
- return this.client.sendLRORequest(
568
- {
569
- provisioningServiceName,
570
- resourceGroupName,
886
+ resourceName,
887
+ privateEndpointConnectionName,
888
+ privateEndpointConnection,
571
889
  options
572
890
  },
573
- beginDeleteMethodOperationSpec,
574
- options);
891
+ createOrUpdatePrivateEndpointConnectionOperationSpec
892
+ );
893
+ return new LroEngine(lro, {
894
+ resumeFrom: options?.resumeFrom,
895
+ intervalInMs: options?.updateIntervalInMs
896
+ });
575
897
  }
576
898
 
577
899
  /**
578
900
  * Create or update the status of a private endpoint connection with the specified name
579
- * @summary Create or update private endpoint connection
580
901
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
581
902
  * @param resourceName The name of the provisioning service.
582
903
  * @param privateEndpointConnectionName The name of the private endpoint connection
583
904
  * @param privateEndpointConnection The private endpoint connection with updated properties
584
- * @param [options] The optional parameters
585
- * @returns Promise<msRestAzure.LROPoller>
905
+ * @param options The options parameters.
586
906
  */
587
- beginCreateOrUpdatePrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, privateEndpointConnection: Models.PrivateEndpointConnection, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
588
- return this.client.sendLRORequest(
589
- {
590
- resourceGroupName,
591
- resourceName,
592
- privateEndpointConnectionName,
593
- privateEndpointConnection,
594
- options
595
- },
596
- beginCreateOrUpdatePrivateEndpointConnectionOperationSpec,
597
- options);
907
+ async beginCreateOrUpdatePrivateEndpointConnectionAndWait(
908
+ resourceGroupName: string,
909
+ resourceName: string,
910
+ privateEndpointConnectionName: string,
911
+ privateEndpointConnection: PrivateEndpointConnection,
912
+ options?: IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams
913
+ ): Promise<IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse> {
914
+ const poller = await this.beginCreateOrUpdatePrivateEndpointConnection(
915
+ resourceGroupName,
916
+ resourceName,
917
+ privateEndpointConnectionName,
918
+ privateEndpointConnection,
919
+ options
920
+ );
921
+ return poller.pollUntilDone();
598
922
  }
599
923
 
600
924
  /**
601
925
  * Delete private endpoint connection with the specified name
602
- * @summary Delete private endpoint connection
603
926
  * @param resourceGroupName The name of the resource group that contains the provisioning service.
604
927
  * @param resourceName The name of the provisioning service.
605
928
  * @param privateEndpointConnectionName The name of the private endpoint connection
606
- * @param [options] The optional parameters
607
- * @returns Promise<msRestAzure.LROPoller>
929
+ * @param options The options parameters.
608
930
  */
609
- beginDeletePrivateEndpointConnection(resourceGroupName: string, resourceName: string, privateEndpointConnectionName: string, options?: msRest.RequestOptionsBase): Promise<msRestAzure.LROPoller> {
610
- return this.client.sendLRORequest(
931
+ async beginDeletePrivateEndpointConnection(
932
+ resourceGroupName: string,
933
+ resourceName: string,
934
+ privateEndpointConnectionName: string,
935
+ options?: IotDpsResourceDeletePrivateEndpointConnectionOptionalParams
936
+ ): Promise<
937
+ PollerLike<
938
+ PollOperationState<IotDpsResourceDeletePrivateEndpointConnectionResponse>,
939
+ IotDpsResourceDeletePrivateEndpointConnectionResponse
940
+ >
941
+ > {
942
+ const directSendOperation = async (
943
+ args: coreClient.OperationArguments,
944
+ spec: coreClient.OperationSpec
945
+ ): Promise<IotDpsResourceDeletePrivateEndpointConnectionResponse> => {
946
+ return this.client.sendOperationRequest(args, spec);
947
+ };
948
+ const sendOperation = async (
949
+ args: coreClient.OperationArguments,
950
+ spec: coreClient.OperationSpec
951
+ ) => {
952
+ let currentRawResponse:
953
+ | coreClient.FullOperationResponse
954
+ | undefined = undefined;
955
+ const providedCallback = args.options?.onResponse;
956
+ const callback: coreClient.RawResponseCallback = (
957
+ rawResponse: coreClient.FullOperationResponse,
958
+ flatResponse: unknown
959
+ ) => {
960
+ currentRawResponse = rawResponse;
961
+ providedCallback?.(rawResponse, flatResponse);
962
+ };
963
+ const updatedArgs = {
964
+ ...args,
965
+ options: {
966
+ ...args.options,
967
+ onResponse: callback
968
+ }
969
+ };
970
+ const flatResponse = await directSendOperation(updatedArgs, spec);
971
+ return {
972
+ flatResponse,
973
+ rawResponse: {
974
+ statusCode: currentRawResponse!.status,
975
+ body: currentRawResponse!.parsedBody,
976
+ headers: currentRawResponse!.headers.toJSON()
977
+ }
978
+ };
979
+ };
980
+
981
+ const lro = new LroImpl(
982
+ sendOperation,
611
983
  {
612
984
  resourceGroupName,
613
985
  resourceName,
614
986
  privateEndpointConnectionName,
615
987
  options
616
988
  },
617
- beginDeletePrivateEndpointConnectionOperationSpec,
618
- options);
989
+ deletePrivateEndpointConnectionOperationSpec
990
+ );
991
+ return new LroEngine(lro, {
992
+ resumeFrom: options?.resumeFrom,
993
+ intervalInMs: options?.updateIntervalInMs
994
+ });
619
995
  }
620
996
 
621
997
  /**
622
- * List all the provisioning services for a given subscription id.
623
- * @summary Get all the provisioning services in a subscription.
624
- * @param nextPageLink The NextLink from the previous successful call to List operation.
625
- * @param [options] The optional parameters
626
- * @returns Promise<Models.IotDpsResourceListBySubscriptionNextResponse>
627
- */
628
- listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListBySubscriptionNextResponse>;
629
- /**
630
- * @param nextPageLink The NextLink from the previous successful call to List operation.
631
- * @param callback The callback
998
+ * Delete private endpoint connection with the specified name
999
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
1000
+ * @param resourceName The name of the provisioning service.
1001
+ * @param privateEndpointConnectionName The name of the private endpoint connection
1002
+ * @param options The options parameters.
632
1003
  */
633
- listBySubscriptionNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
1004
+ async beginDeletePrivateEndpointConnectionAndWait(
1005
+ resourceGroupName: string,
1006
+ resourceName: string,
1007
+ privateEndpointConnectionName: string,
1008
+ options?: IotDpsResourceDeletePrivateEndpointConnectionOptionalParams
1009
+ ): Promise<IotDpsResourceDeletePrivateEndpointConnectionResponse> {
1010
+ const poller = await this.beginDeletePrivateEndpointConnection(
1011
+ resourceGroupName,
1012
+ resourceName,
1013
+ privateEndpointConnectionName,
1014
+ options
1015
+ );
1016
+ return poller.pollUntilDone();
1017
+ }
1018
+
634
1019
  /**
635
- * @param nextPageLink The NextLink from the previous successful call to List operation.
636
- * @param options The optional parameters
637
- * @param callback The callback
1020
+ * ListBySubscriptionNext
1021
+ * @param nextLink The nextLink from the previous successful call to the ListBySubscription method.
1022
+ * @param options The options parameters.
638
1023
  */
639
- listBySubscriptionNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
640
- listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>, callback?: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): Promise<Models.IotDpsResourceListBySubscriptionNextResponse> {
1024
+ private _listBySubscriptionNext(
1025
+ nextLink: string,
1026
+ options?: IotDpsResourceListBySubscriptionNextOptionalParams
1027
+ ): Promise<IotDpsResourceListBySubscriptionNextResponse> {
641
1028
  return this.client.sendOperationRequest(
642
- {
643
- nextPageLink,
644
- options
645
- },
646
- listBySubscriptionNextOperationSpec,
647
- callback) as Promise<Models.IotDpsResourceListBySubscriptionNextResponse>;
1029
+ { nextLink, options },
1030
+ listBySubscriptionNextOperationSpec
1031
+ );
648
1032
  }
649
1033
 
650
1034
  /**
651
- * Get a list of all provisioning services in the given resource group.
652
- * @param nextPageLink The NextLink from the previous successful call to List operation.
653
- * @param [options] The optional parameters
654
- * @returns Promise<Models.IotDpsResourceListByResourceGroupNextResponse>
655
- */
656
- listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListByResourceGroupNextResponse>;
657
- /**
658
- * @param nextPageLink The NextLink from the previous successful call to List operation.
659
- * @param callback The callback
660
- */
661
- listByResourceGroupNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
662
- /**
663
- * @param nextPageLink The NextLink from the previous successful call to List operation.
664
- * @param options The optional parameters
665
- * @param callback The callback
1035
+ * ListByResourceGroupNext
1036
+ * @param resourceGroupName Resource group identifier.
1037
+ * @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method.
1038
+ * @param options The options parameters.
666
1039
  */
667
- listByResourceGroupNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): void;
668
- listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>, callback?: msRest.ServiceCallback<Models.ProvisioningServiceDescriptionListResult>): Promise<Models.IotDpsResourceListByResourceGroupNextResponse> {
1040
+ private _listByResourceGroupNext(
1041
+ resourceGroupName: string,
1042
+ nextLink: string,
1043
+ options?: IotDpsResourceListByResourceGroupNextOptionalParams
1044
+ ): Promise<IotDpsResourceListByResourceGroupNextResponse> {
669
1045
  return this.client.sendOperationRequest(
670
- {
671
- nextPageLink,
672
- options
673
- },
674
- listByResourceGroupNextOperationSpec,
675
- callback) as Promise<Models.IotDpsResourceListByResourceGroupNextResponse>;
1046
+ { resourceGroupName, nextLink, options },
1047
+ listByResourceGroupNextOperationSpec
1048
+ );
676
1049
  }
677
1050
 
678
1051
  /**
679
- * Gets the list of valid SKUs and tiers for a provisioning service.
680
- * @summary Get the list of valid SKUs for a provisioning service.
681
- * @param nextPageLink The NextLink from the previous successful call to List operation.
682
- * @param [options] The optional parameters
683
- * @returns Promise<Models.IotDpsResourceListValidSkusNextResponse>
684
- */
685
- listValidSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListValidSkusNextResponse>;
686
- /**
687
- * @param nextPageLink The NextLink from the previous successful call to List operation.
688
- * @param callback The callback
689
- */
690
- listValidSkusNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): void;
691
- /**
692
- * @param nextPageLink The NextLink from the previous successful call to List operation.
693
- * @param options The optional parameters
694
- * @param callback The callback
1052
+ * ListValidSkusNext
1053
+ * @param provisioningServiceName Name of provisioning service.
1054
+ * @param resourceGroupName Name of resource group.
1055
+ * @param nextLink The nextLink from the previous successful call to the ListValidSkus method.
1056
+ * @param options The options parameters.
695
1057
  */
696
- listValidSkusNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): void;
697
- listValidSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>, callback?: msRest.ServiceCallback<Models.IotDpsSkuDefinitionListResult>): Promise<Models.IotDpsResourceListValidSkusNextResponse> {
1058
+ private _listValidSkusNext(
1059
+ provisioningServiceName: string,
1060
+ resourceGroupName: string,
1061
+ nextLink: string,
1062
+ options?: IotDpsResourceListValidSkusNextOptionalParams
1063
+ ): Promise<IotDpsResourceListValidSkusNextResponse> {
698
1064
  return this.client.sendOperationRequest(
699
- {
700
- nextPageLink,
701
- options
702
- },
703
- listValidSkusNextOperationSpec,
704
- callback) as Promise<Models.IotDpsResourceListValidSkusNextResponse>;
1065
+ { provisioningServiceName, resourceGroupName, nextLink, options },
1066
+ listValidSkusNextOperationSpec
1067
+ );
705
1068
  }
706
1069
 
707
1070
  /**
708
- * List the primary and secondary keys for a provisioning service.
709
- * @summary Get the security metadata for a provisioning service.
710
- * @param nextPageLink The NextLink from the previous successful call to List operation.
711
- * @param [options] The optional parameters
712
- * @returns Promise<Models.IotDpsResourceListKeysNextResponse>
713
- */
714
- listKeysNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.IotDpsResourceListKeysNextResponse>;
715
- /**
716
- * @param nextPageLink The NextLink from the previous successful call to List operation.
717
- * @param callback The callback
718
- */
719
- listKeysNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): void;
720
- /**
721
- * @param nextPageLink The NextLink from the previous successful call to List operation.
722
- * @param options The optional parameters
723
- * @param callback The callback
1071
+ * ListKeysNext
1072
+ * @param provisioningServiceName The provisioning service name to get the shared access keys for.
1073
+ * @param resourceGroupName resource group name
1074
+ * @param nextLink The nextLink from the previous successful call to the ListKeys method.
1075
+ * @param options The options parameters.
724
1076
  */
725
- listKeysNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): void;
726
- listKeysNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>, callback?: msRest.ServiceCallback<Models.SharedAccessSignatureAuthorizationRuleListResult>): Promise<Models.IotDpsResourceListKeysNextResponse> {
1077
+ private _listKeysNext(
1078
+ provisioningServiceName: string,
1079
+ resourceGroupName: string,
1080
+ nextLink: string,
1081
+ options?: IotDpsResourceListKeysNextOptionalParams
1082
+ ): Promise<IotDpsResourceListKeysNextResponse> {
727
1083
  return this.client.sendOperationRequest(
728
- {
729
- nextPageLink,
730
- options
731
- },
732
- listKeysNextOperationSpec,
733
- callback) as Promise<Models.IotDpsResourceListKeysNextResponse>;
1084
+ { provisioningServiceName, resourceGroupName, nextLink, options },
1085
+ listKeysNextOperationSpec
1086
+ );
734
1087
  }
735
1088
  }
736
-
737
1089
  // Operation Specifications
738
- const serializer = new msRest.Serializer(Mappers);
739
- const getOperationSpec: msRest.OperationSpec = {
1090
+ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
1091
+
1092
+ const getOperationSpec: coreClient.OperationSpec = {
1093
+ path:
1094
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
740
1095
  httpMethod: "GET",
741
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1096
+ responses: {
1097
+ 200: {
1098
+ bodyMapper: Mappers.ProvisioningServiceDescription
1099
+ },
1100
+ default: {
1101
+ bodyMapper: Mappers.ErrorDetails
1102
+ }
1103
+ },
1104
+ queryParameters: [Parameters.apiVersion],
742
1105
  urlParameters: [
743
- Parameters.provisioningServiceName,
1106
+ Parameters.$host,
744
1107
  Parameters.subscriptionId,
745
- Parameters.resourceGroupName
746
- ],
747
- queryParameters: [
748
- Parameters.apiVersion
749
- ],
750
- headerParameters: [
751
- Parameters.acceptLanguage
1108
+ Parameters.resourceGroupName,
1109
+ Parameters.provisioningServiceName
752
1110
  ],
1111
+ headerParameters: [Parameters.accept],
1112
+ serializer
1113
+ };
1114
+ const createOrUpdateOperationSpec: coreClient.OperationSpec = {
1115
+ path:
1116
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1117
+ httpMethod: "PUT",
753
1118
  responses: {
754
1119
  200: {
755
1120
  bodyMapper: Mappers.ProvisioningServiceDescription
756
1121
  },
1122
+ 201: {
1123
+ bodyMapper: Mappers.ProvisioningServiceDescription
1124
+ },
1125
+ 202: {
1126
+ bodyMapper: Mappers.ProvisioningServiceDescription
1127
+ },
1128
+ 204: {
1129
+ bodyMapper: Mappers.ProvisioningServiceDescription
1130
+ },
757
1131
  default: {
758
1132
  bodyMapper: Mappers.ErrorDetails
759
1133
  }
760
1134
  },
1135
+ requestBody: Parameters.iotDpsDescription,
1136
+ queryParameters: [Parameters.apiVersion],
1137
+ urlParameters: [
1138
+ Parameters.$host,
1139
+ Parameters.subscriptionId,
1140
+ Parameters.resourceGroupName,
1141
+ Parameters.provisioningServiceName
1142
+ ],
1143
+ headerParameters: [Parameters.accept, Parameters.contentType],
1144
+ mediaType: "json",
761
1145
  serializer
762
1146
  };
763
-
764
- const listBySubscriptionOperationSpec: msRest.OperationSpec = {
765
- httpMethod: "GET",
766
- path: "subscriptions/{subscriptionId}/providers/Microsoft.Devices/provisioningServices",
1147
+ const updateOperationSpec: coreClient.OperationSpec = {
1148
+ path:
1149
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1150
+ httpMethod: "PATCH",
1151
+ responses: {
1152
+ 200: {
1153
+ bodyMapper: Mappers.ProvisioningServiceDescription
1154
+ },
1155
+ 201: {
1156
+ bodyMapper: Mappers.ProvisioningServiceDescription
1157
+ },
1158
+ 202: {
1159
+ bodyMapper: Mappers.ProvisioningServiceDescription
1160
+ },
1161
+ 204: {
1162
+ bodyMapper: Mappers.ProvisioningServiceDescription
1163
+ }
1164
+ },
1165
+ requestBody: Parameters.provisioningServiceTags,
1166
+ queryParameters: [Parameters.apiVersion],
767
1167
  urlParameters: [
768
- Parameters.subscriptionId
769
- ],
770
- queryParameters: [
771
- Parameters.apiVersion
1168
+ Parameters.$host,
1169
+ Parameters.subscriptionId,
1170
+ Parameters.resourceGroupName,
1171
+ Parameters.provisioningServiceName
772
1172
  ],
773
- headerParameters: [
774
- Parameters.acceptLanguage
1173
+ headerParameters: [Parameters.accept, Parameters.contentType],
1174
+ mediaType: "json",
1175
+ serializer
1176
+ };
1177
+ const deleteOperationSpec: coreClient.OperationSpec = {
1178
+ path:
1179
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1180
+ httpMethod: "DELETE",
1181
+ responses: {
1182
+ 200: {},
1183
+ 201: {},
1184
+ 202: {},
1185
+ 204: {},
1186
+ default: {
1187
+ bodyMapper: Mappers.ErrorDetails
1188
+ }
1189
+ },
1190
+ queryParameters: [Parameters.apiVersion],
1191
+ urlParameters: [
1192
+ Parameters.$host,
1193
+ Parameters.subscriptionId,
1194
+ Parameters.resourceGroupName,
1195
+ Parameters.provisioningServiceName
775
1196
  ],
1197
+ headerParameters: [Parameters.accept],
1198
+ serializer
1199
+ };
1200
+ const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
1201
+ path:
1202
+ "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/provisioningServices",
1203
+ httpMethod: "GET",
776
1204
  responses: {
777
1205
  200: {
778
1206
  bodyMapper: Mappers.ProvisioningServiceDescriptionListResult
@@ -781,22 +1209,15 @@ const listBySubscriptionOperationSpec: msRest.OperationSpec = {
781
1209
  bodyMapper: Mappers.ErrorDetails
782
1210
  }
783
1211
  },
1212
+ queryParameters: [Parameters.apiVersion],
1213
+ urlParameters: [Parameters.$host, Parameters.subscriptionId],
1214
+ headerParameters: [Parameters.accept],
784
1215
  serializer
785
1216
  };
786
-
787
- const listByResourceGroupOperationSpec: msRest.OperationSpec = {
1217
+ const listByResourceGroupOperationSpec: coreClient.OperationSpec = {
1218
+ path:
1219
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices",
788
1220
  httpMethod: "GET",
789
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices",
790
- urlParameters: [
791
- Parameters.subscriptionId,
792
- Parameters.resourceGroupName
793
- ],
794
- queryParameters: [
795
- Parameters.apiVersion
796
- ],
797
- headerParameters: [
798
- Parameters.acceptLanguage
799
- ],
800
1221
  responses: {
801
1222
  200: {
802
1223
  bodyMapper: Mappers.ProvisioningServiceDescriptionListResult
@@ -805,25 +1226,19 @@ const listByResourceGroupOperationSpec: msRest.OperationSpec = {
805
1226
  bodyMapper: Mappers.ErrorDetails
806
1227
  }
807
1228
  },
808
- serializer
809
- };
810
-
811
- const getOperationResultOperationSpec: msRest.OperationSpec = {
812
- httpMethod: "GET",
813
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/operationresults/{operationId}",
1229
+ queryParameters: [Parameters.apiVersion],
814
1230
  urlParameters: [
815
- Parameters.operationId,
1231
+ Parameters.$host,
816
1232
  Parameters.subscriptionId,
817
- Parameters.resourceGroupName,
818
- Parameters.provisioningServiceName
819
- ],
820
- queryParameters: [
821
- Parameters.asyncinfo,
822
- Parameters.apiVersion
823
- ],
824
- headerParameters: [
825
- Parameters.acceptLanguage
1233
+ Parameters.resourceGroupName
826
1234
  ],
1235
+ headerParameters: [Parameters.accept],
1236
+ serializer
1237
+ };
1238
+ const getOperationResultOperationSpec: coreClient.OperationSpec = {
1239
+ path:
1240
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/operationresults/{operationId}",
1241
+ httpMethod: "GET",
827
1242
  responses: {
828
1243
  200: {
829
1244
  bodyMapper: Mappers.AsyncOperationResult
@@ -832,23 +1247,21 @@ const getOperationResultOperationSpec: msRest.OperationSpec = {
832
1247
  bodyMapper: Mappers.ErrorDetails
833
1248
  }
834
1249
  },
835
- serializer
836
- };
837
-
838
- const listValidSkusOperationSpec: msRest.OperationSpec = {
839
- httpMethod: "GET",
840
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/skus",
1250
+ queryParameters: [Parameters.apiVersion, Parameters.asyncinfo],
841
1251
  urlParameters: [
842
- Parameters.provisioningServiceName,
1252
+ Parameters.$host,
843
1253
  Parameters.subscriptionId,
844
- Parameters.resourceGroupName
845
- ],
846
- queryParameters: [
847
- Parameters.apiVersion
848
- ],
849
- headerParameters: [
850
- Parameters.acceptLanguage
1254
+ Parameters.resourceGroupName,
1255
+ Parameters.provisioningServiceName,
1256
+ Parameters.operationId
851
1257
  ],
1258
+ headerParameters: [Parameters.accept],
1259
+ serializer
1260
+ };
1261
+ const listValidSkusOperationSpec: coreClient.OperationSpec = {
1262
+ path:
1263
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/skus",
1264
+ httpMethod: "GET",
852
1265
  responses: {
853
1266
  200: {
854
1267
  bodyMapper: Mappers.IotDpsSkuDefinitionListResult
@@ -857,28 +1270,20 @@ const listValidSkusOperationSpec: msRest.OperationSpec = {
857
1270
  bodyMapper: Mappers.ErrorDetails
858
1271
  }
859
1272
  },
1273
+ queryParameters: [Parameters.apiVersion],
1274
+ urlParameters: [
1275
+ Parameters.$host,
1276
+ Parameters.subscriptionId,
1277
+ Parameters.resourceGroupName,
1278
+ Parameters.provisioningServiceName
1279
+ ],
1280
+ headerParameters: [Parameters.accept],
860
1281
  serializer
861
1282
  };
862
-
863
- const checkProvisioningServiceNameAvailabilityOperationSpec: msRest.OperationSpec = {
1283
+ const checkProvisioningServiceNameAvailabilityOperationSpec: coreClient.OperationSpec = {
1284
+ path:
1285
+ "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/checkProvisioningServiceNameAvailability",
864
1286
  httpMethod: "POST",
865
- path: "subscriptions/{subscriptionId}/providers/Microsoft.Devices/checkProvisioningServiceNameAvailability",
866
- urlParameters: [
867
- Parameters.subscriptionId
868
- ],
869
- queryParameters: [
870
- Parameters.apiVersion
871
- ],
872
- headerParameters: [
873
- Parameters.acceptLanguage
874
- ],
875
- requestBody: {
876
- parameterPath: "argumentsParameter",
877
- mapper: {
878
- ...Mappers.OperationInputs,
879
- required: true
880
- }
881
- },
882
1287
  responses: {
883
1288
  200: {
884
1289
  bodyMapper: Mappers.NameAvailabilityInfo
@@ -887,23 +1292,17 @@ const checkProvisioningServiceNameAvailabilityOperationSpec: msRest.OperationSpe
887
1292
  bodyMapper: Mappers.ErrorDetails
888
1293
  }
889
1294
  },
1295
+ requestBody: Parameters.argumentsParam,
1296
+ queryParameters: [Parameters.apiVersion],
1297
+ urlParameters: [Parameters.$host, Parameters.subscriptionId],
1298
+ headerParameters: [Parameters.accept, Parameters.contentType],
1299
+ mediaType: "json",
890
1300
  serializer
891
1301
  };
892
-
893
- const listKeysOperationSpec: msRest.OperationSpec = {
1302
+ const listKeysOperationSpec: coreClient.OperationSpec = {
1303
+ path:
1304
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/listkeys",
894
1305
  httpMethod: "POST",
895
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/listkeys",
896
- urlParameters: [
897
- Parameters.provisioningServiceName,
898
- Parameters.subscriptionId,
899
- Parameters.resourceGroupName
900
- ],
901
- queryParameters: [
902
- Parameters.apiVersion
903
- ],
904
- headerParameters: [
905
- Parameters.acceptLanguage
906
- ],
907
1306
  responses: {
908
1307
  200: {
909
1308
  bodyMapper: Mappers.SharedAccessSignatureAuthorizationRuleListResult
@@ -912,49 +1311,44 @@ const listKeysOperationSpec: msRest.OperationSpec = {
912
1311
  bodyMapper: Mappers.ErrorDetails
913
1312
  }
914
1313
  },
915
- serializer
916
- };
917
-
918
- const listKeysForKeyNameOperationSpec: msRest.OperationSpec = {
919
- httpMethod: "POST",
920
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/keys/{keyName}/listkeys",
1314
+ queryParameters: [Parameters.apiVersion],
921
1315
  urlParameters: [
922
- Parameters.provisioningServiceName,
923
- Parameters.keyName,
1316
+ Parameters.$host,
924
1317
  Parameters.subscriptionId,
925
- Parameters.resourceGroupName
926
- ],
927
- queryParameters: [
928
- Parameters.apiVersion
929
- ],
930
- headerParameters: [
931
- Parameters.acceptLanguage
1318
+ Parameters.resourceGroupName,
1319
+ Parameters.provisioningServiceName
932
1320
  ],
1321
+ headerParameters: [Parameters.accept],
1322
+ serializer
1323
+ };
1324
+ const listKeysForKeyNameOperationSpec: coreClient.OperationSpec = {
1325
+ path:
1326
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/keys/{keyName}/listkeys",
1327
+ httpMethod: "POST",
933
1328
  responses: {
934
1329
  200: {
935
- bodyMapper: Mappers.SharedAccessSignatureAuthorizationRuleAccessRightsDescription
1330
+ bodyMapper:
1331
+ Mappers.SharedAccessSignatureAuthorizationRuleAccessRightsDescription
936
1332
  },
937
1333
  default: {
938
1334
  bodyMapper: Mappers.ErrorDetails
939
1335
  }
940
1336
  },
941
- serializer
942
- };
943
-
944
- const listPrivateLinkResourcesOperationSpec: msRest.OperationSpec = {
945
- httpMethod: "GET",
946
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources",
1337
+ queryParameters: [Parameters.apiVersion],
947
1338
  urlParameters: [
1339
+ Parameters.$host,
948
1340
  Parameters.subscriptionId,
949
1341
  Parameters.resourceGroupName,
950
- Parameters.resourceName
951
- ],
952
- queryParameters: [
953
- Parameters.apiVersion
954
- ],
955
- headerParameters: [
956
- Parameters.acceptLanguage
1342
+ Parameters.provisioningServiceName,
1343
+ Parameters.keyName
957
1344
  ],
1345
+ headerParameters: [Parameters.accept],
1346
+ serializer
1347
+ };
1348
+ const listPrivateLinkResourcesOperationSpec: coreClient.OperationSpec = {
1349
+ path:
1350
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources",
1351
+ httpMethod: "GET",
958
1352
  responses: {
959
1353
  200: {
960
1354
  bodyMapper: Mappers.PrivateLinkResources
@@ -963,24 +1357,20 @@ const listPrivateLinkResourcesOperationSpec: msRest.OperationSpec = {
963
1357
  bodyMapper: Mappers.ErrorDetails
964
1358
  }
965
1359
  },
966
- serializer
967
- };
968
-
969
- const getPrivateLinkResourcesOperationSpec: msRest.OperationSpec = {
970
- httpMethod: "GET",
971
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources/{groupId}",
1360
+ queryParameters: [Parameters.apiVersion],
972
1361
  urlParameters: [
1362
+ Parameters.$host,
973
1363
  Parameters.subscriptionId,
974
1364
  Parameters.resourceGroupName,
975
- Parameters.resourceName,
976
- Parameters.groupId
977
- ],
978
- queryParameters: [
979
- Parameters.apiVersion
980
- ],
981
- headerParameters: [
982
- Parameters.acceptLanguage
1365
+ Parameters.resourceName
983
1366
  ],
1367
+ headerParameters: [Parameters.accept],
1368
+ serializer
1369
+ };
1370
+ const getPrivateLinkResourcesOperationSpec: coreClient.OperationSpec = {
1371
+ path:
1372
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources/{groupId}",
1373
+ httpMethod: "GET",
984
1374
  responses: {
985
1375
  200: {
986
1376
  bodyMapper: Mappers.GroupIdInformation
@@ -989,34 +1379,28 @@ const getPrivateLinkResourcesOperationSpec: msRest.OperationSpec = {
989
1379
  bodyMapper: Mappers.ErrorDetails
990
1380
  }
991
1381
  },
992
- serializer
993
- };
994
-
995
- const listPrivateEndpointConnectionsOperationSpec: msRest.OperationSpec = {
996
- httpMethod: "GET",
997
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections",
1382
+ queryParameters: [Parameters.apiVersion],
998
1383
  urlParameters: [
1384
+ Parameters.$host,
999
1385
  Parameters.subscriptionId,
1000
1386
  Parameters.resourceGroupName,
1001
- Parameters.resourceName
1002
- ],
1003
- queryParameters: [
1004
- Parameters.apiVersion
1005
- ],
1006
- headerParameters: [
1007
- Parameters.acceptLanguage
1387
+ Parameters.resourceName,
1388
+ Parameters.groupId
1008
1389
  ],
1390
+ headerParameters: [Parameters.accept],
1391
+ serializer
1392
+ };
1393
+ const listPrivateEndpointConnectionsOperationSpec: coreClient.OperationSpec = {
1394
+ path:
1395
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections",
1396
+ httpMethod: "GET",
1009
1397
  responses: {
1010
1398
  200: {
1011
1399
  bodyMapper: {
1012
- serializedName: "parsedResponse",
1013
1400
  type: {
1014
1401
  name: "Sequence",
1015
1402
  element: {
1016
- type: {
1017
- name: "Composite",
1018
- className: "PrivateEndpointConnection"
1019
- }
1403
+ type: { name: "Composite", className: "PrivateEndpointConnection" }
1020
1404
  }
1021
1405
  }
1022
1406
  }
@@ -1025,24 +1409,20 @@ const listPrivateEndpointConnectionsOperationSpec: msRest.OperationSpec = {
1025
1409
  bodyMapper: Mappers.ErrorDetails
1026
1410
  }
1027
1411
  },
1028
- serializer
1029
- };
1030
-
1031
- const getPrivateEndpointConnectionOperationSpec: msRest.OperationSpec = {
1032
- httpMethod: "GET",
1033
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1412
+ queryParameters: [Parameters.apiVersion],
1034
1413
  urlParameters: [
1414
+ Parameters.$host,
1035
1415
  Parameters.subscriptionId,
1036
1416
  Parameters.resourceGroupName,
1037
- Parameters.resourceName,
1038
- Parameters.privateEndpointConnectionName
1039
- ],
1040
- queryParameters: [
1041
- Parameters.apiVersion
1042
- ],
1043
- headerParameters: [
1044
- Parameters.acceptLanguage
1417
+ Parameters.resourceName
1045
1418
  ],
1419
+ headerParameters: [Parameters.accept],
1420
+ serializer
1421
+ };
1422
+ const getPrivateEndpointConnectionOperationSpec: coreClient.OperationSpec = {
1423
+ path:
1424
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1425
+ httpMethod: "GET",
1046
1426
  responses: {
1047
1427
  200: {
1048
1428
  bodyMapper: Mappers.PrivateEndpointConnection
@@ -1051,124 +1431,55 @@ const getPrivateEndpointConnectionOperationSpec: msRest.OperationSpec = {
1051
1431
  bodyMapper: Mappers.ErrorDetails
1052
1432
  }
1053
1433
  },
1054
- serializer
1055
- };
1056
-
1057
- const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = {
1058
- httpMethod: "PUT",
1059
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1434
+ queryParameters: [Parameters.apiVersion],
1060
1435
  urlParameters: [
1436
+ Parameters.$host,
1061
1437
  Parameters.subscriptionId,
1062
1438
  Parameters.resourceGroupName,
1063
- Parameters.provisioningServiceName
1064
- ],
1065
- queryParameters: [
1066
- Parameters.apiVersion
1067
- ],
1068
- headerParameters: [
1069
- Parameters.acceptLanguage
1439
+ Parameters.resourceName,
1440
+ Parameters.privateEndpointConnectionName
1070
1441
  ],
1071
- requestBody: {
1072
- parameterPath: "iotDpsDescription",
1073
- mapper: {
1074
- ...Mappers.ProvisioningServiceDescription,
1075
- required: true
1076
- }
1077
- },
1442
+ headerParameters: [Parameters.accept],
1443
+ serializer
1444
+ };
1445
+ const createOrUpdatePrivateEndpointConnectionOperationSpec: coreClient.OperationSpec = {
1446
+ path:
1447
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1448
+ httpMethod: "PUT",
1078
1449
  responses: {
1079
1450
  200: {
1080
- bodyMapper: Mappers.ProvisioningServiceDescription
1451
+ bodyMapper: Mappers.PrivateEndpointConnection
1081
1452
  },
1082
1453
  201: {
1083
- bodyMapper: Mappers.ProvisioningServiceDescription
1454
+ bodyMapper: Mappers.PrivateEndpointConnection
1084
1455
  },
1085
- default: {
1086
- bodyMapper: Mappers.ErrorDetails
1087
- }
1088
- },
1089
- serializer
1090
- };
1091
-
1092
- const beginUpdateOperationSpec: msRest.OperationSpec = {
1093
- httpMethod: "PATCH",
1094
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1095
- urlParameters: [
1096
- Parameters.subscriptionId,
1097
- Parameters.resourceGroupName,
1098
- Parameters.provisioningServiceName
1099
- ],
1100
- queryParameters: [
1101
- Parameters.apiVersion
1102
- ],
1103
- headerParameters: [
1104
- Parameters.acceptLanguage
1105
- ],
1106
- requestBody: {
1107
- parameterPath: "provisioningServiceTags",
1108
- mapper: {
1109
- ...Mappers.TagsResource,
1110
- required: true
1111
- }
1112
- },
1113
- responses: {
1114
- 200: {
1115
- bodyMapper: Mappers.ProvisioningServiceDescription
1456
+ 202: {
1457
+ bodyMapper: Mappers.PrivateEndpointConnection
1458
+ },
1459
+ 204: {
1460
+ bodyMapper: Mappers.PrivateEndpointConnection
1116
1461
  },
1117
- default: {
1118
- bodyMapper: Mappers.CloudError
1119
- }
1120
- },
1121
- serializer
1122
- };
1123
-
1124
- const beginDeleteMethodOperationSpec: msRest.OperationSpec = {
1125
- httpMethod: "DELETE",
1126
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}",
1127
- urlParameters: [
1128
- Parameters.provisioningServiceName,
1129
- Parameters.subscriptionId,
1130
- Parameters.resourceGroupName
1131
- ],
1132
- queryParameters: [
1133
- Parameters.apiVersion
1134
- ],
1135
- headerParameters: [
1136
- Parameters.acceptLanguage
1137
- ],
1138
- responses: {
1139
- 200: {},
1140
- 202: {},
1141
- 204: {},
1142
- 404: {},
1143
1462
  default: {
1144
1463
  bodyMapper: Mappers.ErrorDetails
1145
1464
  }
1146
1465
  },
1147
- serializer
1148
- };
1149
-
1150
- const beginCreateOrUpdatePrivateEndpointConnectionOperationSpec: msRest.OperationSpec = {
1151
- httpMethod: "PUT",
1152
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1466
+ requestBody: Parameters.privateEndpointConnection,
1467
+ queryParameters: [Parameters.apiVersion],
1153
1468
  urlParameters: [
1469
+ Parameters.$host,
1154
1470
  Parameters.subscriptionId,
1155
1471
  Parameters.resourceGroupName,
1156
1472
  Parameters.resourceName,
1157
1473
  Parameters.privateEndpointConnectionName
1158
1474
  ],
1159
- queryParameters: [
1160
- Parameters.apiVersion
1161
- ],
1162
- headerParameters: [
1163
- Parameters.acceptLanguage
1164
- ],
1165
- requestBody: {
1166
- parameterPath: "privateEndpointConnection",
1167
- mapper: {
1168
- ...Mappers.PrivateEndpointConnection,
1169
- required: true
1170
- }
1171
- },
1475
+ headerParameters: [Parameters.accept, Parameters.contentType],
1476
+ mediaType: "json",
1477
+ serializer
1478
+ };
1479
+ const deletePrivateEndpointConnectionOperationSpec: coreClient.OperationSpec = {
1480
+ path:
1481
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1482
+ httpMethod: "DELETE",
1172
1483
  responses: {
1173
1484
  200: {
1174
1485
  bodyMapper: Mappers.PrivateEndpointConnection
@@ -1176,56 +1487,30 @@ const beginCreateOrUpdatePrivateEndpointConnectionOperationSpec: msRest.Operatio
1176
1487
  201: {
1177
1488
  bodyMapper: Mappers.PrivateEndpointConnection
1178
1489
  },
1490
+ 202: {
1491
+ bodyMapper: Mappers.PrivateEndpointConnection
1492
+ },
1493
+ 204: {
1494
+ bodyMapper: Mappers.PrivateEndpointConnection
1495
+ },
1179
1496
  default: {
1180
1497
  bodyMapper: Mappers.ErrorDetails
1181
1498
  }
1182
1499
  },
1183
- serializer
1184
- };
1185
-
1186
- const beginDeletePrivateEndpointConnectionOperationSpec: msRest.OperationSpec = {
1187
- httpMethod: "DELETE",
1188
- path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}",
1500
+ queryParameters: [Parameters.apiVersion],
1189
1501
  urlParameters: [
1502
+ Parameters.$host,
1190
1503
  Parameters.subscriptionId,
1191
1504
  Parameters.resourceGroupName,
1192
1505
  Parameters.resourceName,
1193
1506
  Parameters.privateEndpointConnectionName
1194
1507
  ],
1195
- queryParameters: [
1196
- Parameters.apiVersion
1197
- ],
1198
- headerParameters: [
1199
- Parameters.acceptLanguage
1200
- ],
1201
- responses: {
1202
- 200: {
1203
- bodyMapper: Mappers.PrivateEndpointConnection
1204
- },
1205
- 202: {
1206
- bodyMapper: Mappers.PrivateEndpointConnection
1207
- },
1208
- 204: {},
1209
- default: {
1210
- bodyMapper: Mappers.ErrorDetails
1211
- }
1212
- },
1508
+ headerParameters: [Parameters.accept],
1213
1509
  serializer
1214
1510
  };
1215
-
1216
- const listBySubscriptionNextOperationSpec: msRest.OperationSpec = {
1217
- httpMethod: "GET",
1218
- baseUrl: "https://management.azure.com",
1511
+ const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = {
1219
1512
  path: "{nextLink}",
1220
- urlParameters: [
1221
- Parameters.nextPageLink
1222
- ],
1223
- queryParameters: [
1224
- Parameters.apiVersion
1225
- ],
1226
- headerParameters: [
1227
- Parameters.acceptLanguage
1228
- ],
1513
+ httpMethod: "GET",
1229
1514
  responses: {
1230
1515
  200: {
1231
1516
  bodyMapper: Mappers.ProvisioningServiceDescriptionListResult
@@ -1234,22 +1519,18 @@ const listBySubscriptionNextOperationSpec: msRest.OperationSpec = {
1234
1519
  bodyMapper: Mappers.ErrorDetails
1235
1520
  }
1236
1521
  },
1522
+ queryParameters: [Parameters.apiVersion],
1523
+ urlParameters: [
1524
+ Parameters.$host,
1525
+ Parameters.nextLink,
1526
+ Parameters.subscriptionId
1527
+ ],
1528
+ headerParameters: [Parameters.accept],
1237
1529
  serializer
1238
1530
  };
1239
-
1240
- const listByResourceGroupNextOperationSpec: msRest.OperationSpec = {
1241
- httpMethod: "GET",
1242
- baseUrl: "https://management.azure.com",
1531
+ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = {
1243
1532
  path: "{nextLink}",
1244
- urlParameters: [
1245
- Parameters.nextPageLink
1246
- ],
1247
- queryParameters: [
1248
- Parameters.apiVersion
1249
- ],
1250
- headerParameters: [
1251
- Parameters.acceptLanguage
1252
- ],
1533
+ httpMethod: "GET",
1253
1534
  responses: {
1254
1535
  200: {
1255
1536
  bodyMapper: Mappers.ProvisioningServiceDescriptionListResult
@@ -1258,22 +1539,19 @@ const listByResourceGroupNextOperationSpec: msRest.OperationSpec = {
1258
1539
  bodyMapper: Mappers.ErrorDetails
1259
1540
  }
1260
1541
  },
1542
+ queryParameters: [Parameters.apiVersion],
1543
+ urlParameters: [
1544
+ Parameters.$host,
1545
+ Parameters.nextLink,
1546
+ Parameters.subscriptionId,
1547
+ Parameters.resourceGroupName
1548
+ ],
1549
+ headerParameters: [Parameters.accept],
1261
1550
  serializer
1262
1551
  };
1263
-
1264
- const listValidSkusNextOperationSpec: msRest.OperationSpec = {
1265
- httpMethod: "GET",
1266
- baseUrl: "https://management.azure.com",
1552
+ const listValidSkusNextOperationSpec: coreClient.OperationSpec = {
1267
1553
  path: "{nextLink}",
1268
- urlParameters: [
1269
- Parameters.nextPageLink
1270
- ],
1271
- queryParameters: [
1272
- Parameters.apiVersion
1273
- ],
1274
- headerParameters: [
1275
- Parameters.acceptLanguage
1276
- ],
1554
+ httpMethod: "GET",
1277
1555
  responses: {
1278
1556
  200: {
1279
1557
  bodyMapper: Mappers.IotDpsSkuDefinitionListResult
@@ -1282,22 +1560,20 @@ const listValidSkusNextOperationSpec: msRest.OperationSpec = {
1282
1560
  bodyMapper: Mappers.ErrorDetails
1283
1561
  }
1284
1562
  },
1563
+ queryParameters: [Parameters.apiVersion],
1564
+ urlParameters: [
1565
+ Parameters.$host,
1566
+ Parameters.nextLink,
1567
+ Parameters.subscriptionId,
1568
+ Parameters.resourceGroupName,
1569
+ Parameters.provisioningServiceName
1570
+ ],
1571
+ headerParameters: [Parameters.accept],
1285
1572
  serializer
1286
1573
  };
1287
-
1288
- const listKeysNextOperationSpec: msRest.OperationSpec = {
1289
- httpMethod: "POST",
1290
- baseUrl: "https://management.azure.com",
1574
+ const listKeysNextOperationSpec: coreClient.OperationSpec = {
1291
1575
  path: "{nextLink}",
1292
- urlParameters: [
1293
- Parameters.nextPageLink
1294
- ],
1295
- queryParameters: [
1296
- Parameters.apiVersion
1297
- ],
1298
- headerParameters: [
1299
- Parameters.acceptLanguage
1300
- ],
1576
+ httpMethod: "GET",
1301
1577
  responses: {
1302
1578
  200: {
1303
1579
  bodyMapper: Mappers.SharedAccessSignatureAuthorizationRuleListResult
@@ -1306,5 +1582,14 @@ const listKeysNextOperationSpec: msRest.OperationSpec = {
1306
1582
  bodyMapper: Mappers.ErrorDetails
1307
1583
  }
1308
1584
  },
1585
+ queryParameters: [Parameters.apiVersion],
1586
+ urlParameters: [
1587
+ Parameters.$host,
1588
+ Parameters.nextLink,
1589
+ Parameters.subscriptionId,
1590
+ Parameters.resourceGroupName,
1591
+ Parameters.provisioningServiceName
1592
+ ],
1593
+ headerParameters: [Parameters.accept],
1309
1594
  serializer
1310
1595
  };