@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,92 +3,109 @@
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 Models from "../models";
12
- import * as Mappers from "../models/operationsMappers";
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { Operations } from "../operationsInterfaces";
11
+ import * as coreClient from "@azure/core-client";
12
+ import * as Mappers from "../models/mappers";
13
13
  import * as Parameters from "../models/parameters";
14
- import { IotDpsClientContext } from "../iotDpsClientContext";
14
+ import { IotDpsClient } from "../iotDpsClient";
15
+ import {
16
+ Operation,
17
+ OperationsListNextOptionalParams,
18
+ OperationsListOptionalParams,
19
+ OperationsListResponse,
20
+ OperationsListNextResponse
21
+ } from "../models";
15
22
 
16
- /** Class representing a Operations. */
17
- export class Operations {
18
- private readonly client: IotDpsClientContext;
23
+ /// <reference lib="esnext.asynciterable" />
24
+ /** Class containing Operations operations. */
25
+ export class OperationsImpl implements Operations {
26
+ private readonly client: IotDpsClient;
19
27
 
20
28
  /**
21
- * Create a Operations.
22
- * @param {IotDpsClientContext} client Reference to the service client.
29
+ * Initialize a new instance of the class Operations class.
30
+ * @param client Reference to the service client
23
31
  */
24
- constructor(client: IotDpsClientContext) {
32
+ constructor(client: IotDpsClient) {
25
33
  this.client = client;
26
34
  }
27
35
 
28
36
  /**
29
37
  * Lists all of the available Microsoft.Devices REST API operations.
30
- * @param [options] The optional parameters
31
- * @returns Promise<Models.OperationsListResponse>
38
+ * @param options The options parameters.
32
39
  */
33
- list(options?: msRest.RequestOptionsBase): Promise<Models.OperationsListResponse>;
34
- /**
35
- * @param callback The callback
36
- */
37
- list(callback: msRest.ServiceCallback<Models.OperationListResult>): void;
38
- /**
39
- * @param options The optional parameters
40
- * @param callback The callback
41
- */
42
- list(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.OperationListResult>): void;
43
- list(options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.OperationListResult>, callback?: msRest.ServiceCallback<Models.OperationListResult>): Promise<Models.OperationsListResponse> {
44
- return this.client.sendOperationRequest(
45
- {
46
- options
40
+ public list(
41
+ options?: OperationsListOptionalParams
42
+ ): PagedAsyncIterableIterator<Operation> {
43
+ const iter = this.listPagingAll(options);
44
+ return {
45
+ next() {
46
+ return iter.next();
47
+ },
48
+ [Symbol.asyncIterator]() {
49
+ return this;
47
50
  },
48
- listOperationSpec,
49
- callback) as Promise<Models.OperationsListResponse>;
51
+ byPage: () => {
52
+ return this.listPagingPage(options);
53
+ }
54
+ };
55
+ }
56
+
57
+ private async *listPagingPage(
58
+ options?: OperationsListOptionalParams
59
+ ): AsyncIterableIterator<Operation[]> {
60
+ let result = await this._list(options);
61
+ yield result.value || [];
62
+ let continuationToken = result.nextLink;
63
+ while (continuationToken) {
64
+ result = await this._listNext(continuationToken, options);
65
+ continuationToken = result.nextLink;
66
+ yield result.value || [];
67
+ }
68
+ }
69
+
70
+ private async *listPagingAll(
71
+ options?: OperationsListOptionalParams
72
+ ): AsyncIterableIterator<Operation> {
73
+ for await (const page of this.listPagingPage(options)) {
74
+ yield* page;
75
+ }
50
76
  }
51
77
 
52
78
  /**
53
79
  * Lists all of the available Microsoft.Devices REST API operations.
54
- * @param nextPageLink The NextLink from the previous successful call to List operation.
55
- * @param [options] The optional parameters
56
- * @returns Promise<Models.OperationsListNextResponse>
57
- */
58
- listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.OperationsListNextResponse>;
59
- /**
60
- * @param nextPageLink The NextLink from the previous successful call to List operation.
61
- * @param callback The callback
80
+ * @param options The options parameters.
62
81
  */
63
- listNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.OperationListResult>): void;
82
+ private _list(
83
+ options?: OperationsListOptionalParams
84
+ ): Promise<OperationsListResponse> {
85
+ return this.client.sendOperationRequest({ options }, listOperationSpec);
86
+ }
87
+
64
88
  /**
65
- * @param nextPageLink The NextLink from the previous successful call to List operation.
66
- * @param options The optional parameters
67
- * @param callback The callback
89
+ * ListNext
90
+ * @param nextLink The nextLink from the previous successful call to the List method.
91
+ * @param options The options parameters.
68
92
  */
69
- listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.OperationListResult>): void;
70
- listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.OperationListResult>, callback?: msRest.ServiceCallback<Models.OperationListResult>): Promise<Models.OperationsListNextResponse> {
93
+ private _listNext(
94
+ nextLink: string,
95
+ options?: OperationsListNextOptionalParams
96
+ ): Promise<OperationsListNextResponse> {
71
97
  return this.client.sendOperationRequest(
72
- {
73
- nextPageLink,
74
- options
75
- },
76
- listNextOperationSpec,
77
- callback) as Promise<Models.OperationsListNextResponse>;
98
+ { nextLink, options },
99
+ listNextOperationSpec
100
+ );
78
101
  }
79
102
  }
80
-
81
103
  // Operation Specifications
82
- const serializer = new msRest.Serializer(Mappers);
83
- const listOperationSpec: msRest.OperationSpec = {
104
+ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
105
+
106
+ const listOperationSpec: coreClient.OperationSpec = {
107
+ path: "/providers/Microsoft.Devices/operations",
84
108
  httpMethod: "GET",
85
- path: "providers/Microsoft.Devices/operations",
86
- queryParameters: [
87
- Parameters.apiVersion
88
- ],
89
- headerParameters: [
90
- Parameters.acceptLanguage
91
- ],
92
109
  responses: {
93
110
  200: {
94
111
  bodyMapper: Mappers.OperationListResult
@@ -97,22 +114,14 @@ const listOperationSpec: msRest.OperationSpec = {
97
114
  bodyMapper: Mappers.ErrorDetails
98
115
  }
99
116
  },
117
+ queryParameters: [Parameters.apiVersion],
118
+ urlParameters: [Parameters.$host],
119
+ headerParameters: [Parameters.accept],
100
120
  serializer
101
121
  };
102
-
103
- const listNextOperationSpec: msRest.OperationSpec = {
104
- httpMethod: "GET",
105
- baseUrl: "https://management.azure.com",
122
+ const listNextOperationSpec: coreClient.OperationSpec = {
106
123
  path: "{nextLink}",
107
- urlParameters: [
108
- Parameters.nextPageLink
109
- ],
110
- queryParameters: [
111
- Parameters.apiVersion
112
- ],
113
- headerParameters: [
114
- Parameters.acceptLanguage
115
- ],
124
+ httpMethod: "GET",
116
125
  responses: {
117
126
  200: {
118
127
  bodyMapper: Mappers.OperationListResult
@@ -121,5 +130,8 @@ const listNextOperationSpec: msRest.OperationSpec = {
121
130
  bodyMapper: Mappers.ErrorDetails
122
131
  }
123
132
  },
133
+ queryParameters: [Parameters.apiVersion],
134
+ urlParameters: [Parameters.$host, Parameters.nextLink],
135
+ headerParameters: [Parameters.accept],
124
136
  serializer
125
137
  };
@@ -0,0 +1,118 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import {
10
+ DpsCertificateGetOptionalParams,
11
+ DpsCertificateGetResponse,
12
+ CertificateBodyDescription,
13
+ DpsCertificateCreateOrUpdateOptionalParams,
14
+ DpsCertificateCreateOrUpdateResponse,
15
+ DpsCertificateDeleteOptionalParams,
16
+ DpsCertificateListOptionalParams,
17
+ DpsCertificateListResponse,
18
+ DpsCertificateGenerateVerificationCodeOptionalParams,
19
+ DpsCertificateGenerateVerificationCodeResponse,
20
+ VerificationCodeRequest,
21
+ DpsCertificateVerifyCertificateOptionalParams,
22
+ DpsCertificateVerifyCertificateResponse
23
+ } from "../models";
24
+
25
+ /** Interface representing a DpsCertificate. */
26
+ export interface DpsCertificate {
27
+ /**
28
+ * Get the certificate from the provisioning service.
29
+ * @param certificateName Name of the certificate to retrieve.
30
+ * @param resourceGroupName Resource group identifier.
31
+ * @param provisioningServiceName Name of the provisioning service the certificate is associated with.
32
+ * @param options The options parameters.
33
+ */
34
+ get(
35
+ certificateName: string,
36
+ resourceGroupName: string,
37
+ provisioningServiceName: string,
38
+ options?: DpsCertificateGetOptionalParams
39
+ ): Promise<DpsCertificateGetResponse>;
40
+ /**
41
+ * Add new certificate or update an existing certificate.
42
+ * @param resourceGroupName Resource group identifier.
43
+ * @param provisioningServiceName The name of the provisioning service.
44
+ * @param certificateName The name of the certificate create or update.
45
+ * @param certificateDescription The certificate body.
46
+ * @param options The options parameters.
47
+ */
48
+ createOrUpdate(
49
+ resourceGroupName: string,
50
+ provisioningServiceName: string,
51
+ certificateName: string,
52
+ certificateDescription: CertificateBodyDescription,
53
+ options?: DpsCertificateCreateOrUpdateOptionalParams
54
+ ): Promise<DpsCertificateCreateOrUpdateResponse>;
55
+ /**
56
+ * Deletes the specified certificate associated with the Provisioning Service
57
+ * @param resourceGroupName Resource group identifier.
58
+ * @param ifMatch ETag of the certificate
59
+ * @param provisioningServiceName The name of the provisioning service.
60
+ * @param certificateName This is a mandatory field, and is the logical name of the certificate that
61
+ * the provisioning service will access by.
62
+ * @param options The options parameters.
63
+ */
64
+ delete(
65
+ resourceGroupName: string,
66
+ ifMatch: string,
67
+ provisioningServiceName: string,
68
+ certificateName: string,
69
+ options?: DpsCertificateDeleteOptionalParams
70
+ ): Promise<void>;
71
+ /**
72
+ * Get all the certificates tied to the provisioning service.
73
+ * @param resourceGroupName Name of resource group.
74
+ * @param provisioningServiceName Name of provisioning service to retrieve certificates for.
75
+ * @param options The options parameters.
76
+ */
77
+ list(
78
+ resourceGroupName: string,
79
+ provisioningServiceName: string,
80
+ options?: DpsCertificateListOptionalParams
81
+ ): Promise<DpsCertificateListResponse>;
82
+ /**
83
+ * Generate verification code for Proof of Possession.
84
+ * @param certificateName The mandatory logical name of the certificate, that the provisioning service
85
+ * uses to access.
86
+ * @param ifMatch ETag of the certificate. This is required to update an existing certificate, and
87
+ * ignored while creating a brand new certificate.
88
+ * @param resourceGroupName name of resource group.
89
+ * @param provisioningServiceName Name of provisioning service.
90
+ * @param options The options parameters.
91
+ */
92
+ generateVerificationCode(
93
+ certificateName: string,
94
+ ifMatch: string,
95
+ resourceGroupName: string,
96
+ provisioningServiceName: string,
97
+ options?: DpsCertificateGenerateVerificationCodeOptionalParams
98
+ ): Promise<DpsCertificateGenerateVerificationCodeResponse>;
99
+ /**
100
+ * Verifies the certificate's private key possession by providing the leaf cert issued by the verifying
101
+ * pre uploaded certificate.
102
+ * @param certificateName The mandatory logical name of the certificate, that the provisioning service
103
+ * uses to access.
104
+ * @param ifMatch ETag of the certificate.
105
+ * @param resourceGroupName Resource group name.
106
+ * @param provisioningServiceName Provisioning service name.
107
+ * @param request The name of the certificate
108
+ * @param options The options parameters.
109
+ */
110
+ verifyCertificate(
111
+ certificateName: string,
112
+ ifMatch: string,
113
+ resourceGroupName: string,
114
+ provisioningServiceName: string,
115
+ request: VerificationCodeRequest,
116
+ options?: DpsCertificateVerifyCertificateOptionalParams
117
+ ): Promise<DpsCertificateVerifyCertificateResponse>;
118
+ }
@@ -6,9 +6,6 @@
6
6
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
7
  */
8
8
 
9
- export {
10
- ErrorDetails,
11
- Operation,
12
- OperationDisplay,
13
- OperationListResult
14
- } from "../models/mappers";
9
+ export * from "./operations";
10
+ export * from "./dpsCertificate";
11
+ export * from "./iotDpsResource";
@@ -0,0 +1,351 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { PollerLike, PollOperationState } from "@azure/core-lro";
11
+ import {
12
+ ProvisioningServiceDescription,
13
+ IotDpsResourceListBySubscriptionOptionalParams,
14
+ IotDpsResourceListByResourceGroupOptionalParams,
15
+ IotDpsSkuDefinition,
16
+ IotDpsResourceListValidSkusOptionalParams,
17
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription,
18
+ IotDpsResourceListKeysOptionalParams,
19
+ IotDpsResourceGetOptionalParams,
20
+ IotDpsResourceGetResponse,
21
+ IotDpsResourceCreateOrUpdateOptionalParams,
22
+ IotDpsResourceCreateOrUpdateResponse,
23
+ TagsResource,
24
+ IotDpsResourceUpdateOptionalParams,
25
+ IotDpsResourceUpdateResponse,
26
+ IotDpsResourceDeleteOptionalParams,
27
+ IotDpsResourceGetOperationResultOptionalParams,
28
+ IotDpsResourceGetOperationResultResponse,
29
+ OperationInputs,
30
+ IotDpsResourceCheckProvisioningServiceNameAvailabilityOptionalParams,
31
+ IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse,
32
+ IotDpsResourceListKeysForKeyNameOptionalParams,
33
+ IotDpsResourceListKeysForKeyNameResponse,
34
+ IotDpsResourceListPrivateLinkResourcesOptionalParams,
35
+ IotDpsResourceListPrivateLinkResourcesResponse,
36
+ IotDpsResourceGetPrivateLinkResourcesOptionalParams,
37
+ IotDpsResourceGetPrivateLinkResourcesResponse,
38
+ IotDpsResourceListPrivateEndpointConnectionsOptionalParams,
39
+ IotDpsResourceListPrivateEndpointConnectionsResponse,
40
+ IotDpsResourceGetPrivateEndpointConnectionOptionalParams,
41
+ IotDpsResourceGetPrivateEndpointConnectionResponse,
42
+ PrivateEndpointConnection,
43
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams,
44
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse,
45
+ IotDpsResourceDeletePrivateEndpointConnectionOptionalParams,
46
+ IotDpsResourceDeletePrivateEndpointConnectionResponse
47
+ } from "../models";
48
+
49
+ /// <reference lib="esnext.asynciterable" />
50
+ /** Interface representing a IotDpsResource. */
51
+ export interface IotDpsResource {
52
+ /**
53
+ * List all the provisioning services for a given subscription id.
54
+ * @param options The options parameters.
55
+ */
56
+ listBySubscription(
57
+ options?: IotDpsResourceListBySubscriptionOptionalParams
58
+ ): PagedAsyncIterableIterator<ProvisioningServiceDescription>;
59
+ /**
60
+ * Get a list of all provisioning services in the given resource group.
61
+ * @param resourceGroupName Resource group identifier.
62
+ * @param options The options parameters.
63
+ */
64
+ listByResourceGroup(
65
+ resourceGroupName: string,
66
+ options?: IotDpsResourceListByResourceGroupOptionalParams
67
+ ): PagedAsyncIterableIterator<ProvisioningServiceDescription>;
68
+ /**
69
+ * Gets the list of valid SKUs and tiers for a provisioning service.
70
+ * @param provisioningServiceName Name of provisioning service.
71
+ * @param resourceGroupName Name of resource group.
72
+ * @param options The options parameters.
73
+ */
74
+ listValidSkus(
75
+ provisioningServiceName: string,
76
+ resourceGroupName: string,
77
+ options?: IotDpsResourceListValidSkusOptionalParams
78
+ ): PagedAsyncIterableIterator<IotDpsSkuDefinition>;
79
+ /**
80
+ * List the primary and secondary keys for a provisioning service.
81
+ * @param provisioningServiceName The provisioning service name to get the shared access keys for.
82
+ * @param resourceGroupName resource group name
83
+ * @param options The options parameters.
84
+ */
85
+ listKeys(
86
+ provisioningServiceName: string,
87
+ resourceGroupName: string,
88
+ options?: IotDpsResourceListKeysOptionalParams
89
+ ): PagedAsyncIterableIterator<
90
+ SharedAccessSignatureAuthorizationRuleAccessRightsDescription
91
+ >;
92
+ /**
93
+ * Get the metadata of the provisioning service without SAS keys.
94
+ * @param provisioningServiceName Name of the provisioning service to retrieve.
95
+ * @param resourceGroupName Resource group name.
96
+ * @param options The options parameters.
97
+ */
98
+ get(
99
+ provisioningServiceName: string,
100
+ resourceGroupName: string,
101
+ options?: IotDpsResourceGetOptionalParams
102
+ ): Promise<IotDpsResourceGetResponse>;
103
+ /**
104
+ * Create or update the metadata of the provisioning service. The usual pattern to modify a property is
105
+ * to retrieve the provisioning service metadata and security metadata, and then combine them with the
106
+ * modified values in a new body to update the provisioning service.
107
+ * @param resourceGroupName Resource group identifier.
108
+ * @param provisioningServiceName Name of provisioning service to create or update.
109
+ * @param iotDpsDescription Description of the provisioning service to create or update.
110
+ * @param options The options parameters.
111
+ */
112
+ beginCreateOrUpdate(
113
+ resourceGroupName: string,
114
+ provisioningServiceName: string,
115
+ iotDpsDescription: ProvisioningServiceDescription,
116
+ options?: IotDpsResourceCreateOrUpdateOptionalParams
117
+ ): Promise<
118
+ PollerLike<
119
+ PollOperationState<IotDpsResourceCreateOrUpdateResponse>,
120
+ IotDpsResourceCreateOrUpdateResponse
121
+ >
122
+ >;
123
+ /**
124
+ * Create or update the metadata of the provisioning service. The usual pattern to modify a property is
125
+ * to retrieve the provisioning service metadata and security metadata, and then combine them with the
126
+ * modified values in a new body to update the provisioning service.
127
+ * @param resourceGroupName Resource group identifier.
128
+ * @param provisioningServiceName Name of provisioning service to create or update.
129
+ * @param iotDpsDescription Description of the provisioning service to create or update.
130
+ * @param options The options parameters.
131
+ */
132
+ beginCreateOrUpdateAndWait(
133
+ resourceGroupName: string,
134
+ provisioningServiceName: string,
135
+ iotDpsDescription: ProvisioningServiceDescription,
136
+ options?: IotDpsResourceCreateOrUpdateOptionalParams
137
+ ): Promise<IotDpsResourceCreateOrUpdateResponse>;
138
+ /**
139
+ * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate method
140
+ * @param resourceGroupName Resource group identifier.
141
+ * @param provisioningServiceName Name of provisioning service to create or update.
142
+ * @param provisioningServiceTags Updated tag information to set into the provisioning service
143
+ * instance.
144
+ * @param options The options parameters.
145
+ */
146
+ beginUpdate(
147
+ resourceGroupName: string,
148
+ provisioningServiceName: string,
149
+ provisioningServiceTags: TagsResource,
150
+ options?: IotDpsResourceUpdateOptionalParams
151
+ ): Promise<
152
+ PollerLike<
153
+ PollOperationState<IotDpsResourceUpdateResponse>,
154
+ IotDpsResourceUpdateResponse
155
+ >
156
+ >;
157
+ /**
158
+ * Update an existing provisioning service's tags. to update other fields use the CreateOrUpdate method
159
+ * @param resourceGroupName Resource group identifier.
160
+ * @param provisioningServiceName Name of provisioning service to create or update.
161
+ * @param provisioningServiceTags Updated tag information to set into the provisioning service
162
+ * instance.
163
+ * @param options The options parameters.
164
+ */
165
+ beginUpdateAndWait(
166
+ resourceGroupName: string,
167
+ provisioningServiceName: string,
168
+ provisioningServiceTags: TagsResource,
169
+ options?: IotDpsResourceUpdateOptionalParams
170
+ ): Promise<IotDpsResourceUpdateResponse>;
171
+ /**
172
+ * Deletes the Provisioning Service.
173
+ * @param provisioningServiceName Name of provisioning service to delete.
174
+ * @param resourceGroupName Resource group identifier.
175
+ * @param options The options parameters.
176
+ */
177
+ beginDelete(
178
+ provisioningServiceName: string,
179
+ resourceGroupName: string,
180
+ options?: IotDpsResourceDeleteOptionalParams
181
+ ): Promise<PollerLike<PollOperationState<void>, void>>;
182
+ /**
183
+ * Deletes the Provisioning Service.
184
+ * @param provisioningServiceName Name of provisioning service to delete.
185
+ * @param resourceGroupName Resource group identifier.
186
+ * @param options The options parameters.
187
+ */
188
+ beginDeleteAndWait(
189
+ provisioningServiceName: string,
190
+ resourceGroupName: string,
191
+ options?: IotDpsResourceDeleteOptionalParams
192
+ ): Promise<void>;
193
+ /**
194
+ * Gets the status of a long running operation, such as create, update or delete a provisioning
195
+ * service.
196
+ * @param operationId Operation id corresponding to long running operation. Use this to poll for the
197
+ * status.
198
+ * @param resourceGroupName Resource group identifier.
199
+ * @param provisioningServiceName Name of provisioning service that the operation is running on.
200
+ * @param asyncinfo Async header used to poll on the status of the operation, obtained while creating
201
+ * the long running operation.
202
+ * @param options The options parameters.
203
+ */
204
+ getOperationResult(
205
+ operationId: string,
206
+ resourceGroupName: string,
207
+ provisioningServiceName: string,
208
+ asyncinfo: string,
209
+ options?: IotDpsResourceGetOperationResultOptionalParams
210
+ ): Promise<IotDpsResourceGetOperationResultResponse>;
211
+ /**
212
+ * Check if a provisioning service name is available. This will validate if the name is syntactically
213
+ * valid and if the name is usable
214
+ * @param argumentsParam Set the name parameter in the OperationInputs structure to the name of the
215
+ * provisioning service to check.
216
+ * @param options The options parameters.
217
+ */
218
+ checkProvisioningServiceNameAvailability(
219
+ argumentsParam: OperationInputs,
220
+ options?: IotDpsResourceCheckProvisioningServiceNameAvailabilityOptionalParams
221
+ ): Promise<IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse>;
222
+ /**
223
+ * List primary and secondary keys for a specific key name
224
+ * @param provisioningServiceName Name of the provisioning service.
225
+ * @param keyName Logical key name to get key-values for.
226
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
227
+ * @param options The options parameters.
228
+ */
229
+ listKeysForKeyName(
230
+ provisioningServiceName: string,
231
+ keyName: string,
232
+ resourceGroupName: string,
233
+ options?: IotDpsResourceListKeysForKeyNameOptionalParams
234
+ ): Promise<IotDpsResourceListKeysForKeyNameResponse>;
235
+ /**
236
+ * List private link resources for the given provisioning service
237
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
238
+ * @param resourceName The name of the provisioning service.
239
+ * @param options The options parameters.
240
+ */
241
+ listPrivateLinkResources(
242
+ resourceGroupName: string,
243
+ resourceName: string,
244
+ options?: IotDpsResourceListPrivateLinkResourcesOptionalParams
245
+ ): Promise<IotDpsResourceListPrivateLinkResourcesResponse>;
246
+ /**
247
+ * Get the specified private link resource for the given provisioning service
248
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
249
+ * @param resourceName The name of the provisioning service.
250
+ * @param groupId The name of the private link resource
251
+ * @param options The options parameters.
252
+ */
253
+ getPrivateLinkResources(
254
+ resourceGroupName: string,
255
+ resourceName: string,
256
+ groupId: string,
257
+ options?: IotDpsResourceGetPrivateLinkResourcesOptionalParams
258
+ ): Promise<IotDpsResourceGetPrivateLinkResourcesResponse>;
259
+ /**
260
+ * List private endpoint connection properties
261
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
262
+ * @param resourceName The name of the provisioning service.
263
+ * @param options The options parameters.
264
+ */
265
+ listPrivateEndpointConnections(
266
+ resourceGroupName: string,
267
+ resourceName: string,
268
+ options?: IotDpsResourceListPrivateEndpointConnectionsOptionalParams
269
+ ): Promise<IotDpsResourceListPrivateEndpointConnectionsResponse>;
270
+ /**
271
+ * Get private endpoint connection properties
272
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
273
+ * @param resourceName The name of the provisioning service.
274
+ * @param privateEndpointConnectionName The name of the private endpoint connection
275
+ * @param options The options parameters.
276
+ */
277
+ getPrivateEndpointConnection(
278
+ resourceGroupName: string,
279
+ resourceName: string,
280
+ privateEndpointConnectionName: string,
281
+ options?: IotDpsResourceGetPrivateEndpointConnectionOptionalParams
282
+ ): Promise<IotDpsResourceGetPrivateEndpointConnectionResponse>;
283
+ /**
284
+ * Create or update the status of a private endpoint connection with the specified name
285
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
286
+ * @param resourceName The name of the provisioning service.
287
+ * @param privateEndpointConnectionName The name of the private endpoint connection
288
+ * @param privateEndpointConnection The private endpoint connection with updated properties
289
+ * @param options The options parameters.
290
+ */
291
+ beginCreateOrUpdatePrivateEndpointConnection(
292
+ resourceGroupName: string,
293
+ resourceName: string,
294
+ privateEndpointConnectionName: string,
295
+ privateEndpointConnection: PrivateEndpointConnection,
296
+ options?: IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams
297
+ ): Promise<
298
+ PollerLike<
299
+ PollOperationState<
300
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse
301
+ >,
302
+ IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse
303
+ >
304
+ >;
305
+ /**
306
+ * Create or update the status of a private endpoint connection with the specified name
307
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
308
+ * @param resourceName The name of the provisioning service.
309
+ * @param privateEndpointConnectionName The name of the private endpoint connection
310
+ * @param privateEndpointConnection The private endpoint connection with updated properties
311
+ * @param options The options parameters.
312
+ */
313
+ beginCreateOrUpdatePrivateEndpointConnectionAndWait(
314
+ resourceGroupName: string,
315
+ resourceName: string,
316
+ privateEndpointConnectionName: string,
317
+ privateEndpointConnection: PrivateEndpointConnection,
318
+ options?: IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams
319
+ ): Promise<IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse>;
320
+ /**
321
+ * Delete private endpoint connection with the specified name
322
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
323
+ * @param resourceName The name of the provisioning service.
324
+ * @param privateEndpointConnectionName The name of the private endpoint connection
325
+ * @param options The options parameters.
326
+ */
327
+ beginDeletePrivateEndpointConnection(
328
+ resourceGroupName: string,
329
+ resourceName: string,
330
+ privateEndpointConnectionName: string,
331
+ options?: IotDpsResourceDeletePrivateEndpointConnectionOptionalParams
332
+ ): Promise<
333
+ PollerLike<
334
+ PollOperationState<IotDpsResourceDeletePrivateEndpointConnectionResponse>,
335
+ IotDpsResourceDeletePrivateEndpointConnectionResponse
336
+ >
337
+ >;
338
+ /**
339
+ * Delete private endpoint connection with the specified name
340
+ * @param resourceGroupName The name of the resource group that contains the provisioning service.
341
+ * @param resourceName The name of the provisioning service.
342
+ * @param privateEndpointConnectionName The name of the private endpoint connection
343
+ * @param options The options parameters.
344
+ */
345
+ beginDeletePrivateEndpointConnectionAndWait(
346
+ resourceGroupName: string,
347
+ resourceName: string,
348
+ privateEndpointConnectionName: string,
349
+ options?: IotDpsResourceDeletePrivateEndpointConnectionOptionalParams
350
+ ): Promise<IotDpsResourceDeletePrivateEndpointConnectionResponse>;
351
+ }