@azure/arm-appcomplianceautomation 1.0.0-alpha.20221102.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (143) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/LICENSE +21 -0
  3. package/README.md +109 -0
  4. package/dist/index.js +2463 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/index.min.js +1 -0
  7. package/dist/index.min.js.map +1 -0
  8. package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
  9. package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
  10. package/dist-esm/samples-dev/operationsListSample.js +42 -0
  11. package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
  12. package/dist-esm/samples-dev/reportCreateOrUpdateSample.d.ts +2 -0
  13. package/dist-esm/samples-dev/reportCreateOrUpdateSample.d.ts.map +1 -0
  14. package/dist-esm/samples-dev/reportCreateOrUpdateSample.js +42 -0
  15. package/dist-esm/samples-dev/reportCreateOrUpdateSample.js.map +1 -0
  16. package/dist-esm/samples-dev/reportDeleteSample.d.ts +2 -0
  17. package/dist-esm/samples-dev/reportDeleteSample.d.ts.map +1 -0
  18. package/dist-esm/samples-dev/reportDeleteSample.js +29 -0
  19. package/dist-esm/samples-dev/reportDeleteSample.js.map +1 -0
  20. package/dist-esm/samples-dev/reportGetSample.d.ts +2 -0
  21. package/dist-esm/samples-dev/reportGetSample.d.ts.map +1 -0
  22. package/dist-esm/samples-dev/reportGetSample.js +29 -0
  23. package/dist-esm/samples-dev/reportGetSample.js.map +1 -0
  24. package/dist-esm/samples-dev/reportUpdateSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/reportUpdateSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/reportUpdateSample.js +42 -0
  27. package/dist-esm/samples-dev/reportUpdateSample.js.map +1 -0
  28. package/dist-esm/samples-dev/reportsListSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/reportsListSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/reportsListSample.js +52 -0
  31. package/dist-esm/samples-dev/reportsListSample.js.map +1 -0
  32. package/dist-esm/samples-dev/snapshotDownloadSample.d.ts +2 -0
  33. package/dist-esm/samples-dev/snapshotDownloadSample.d.ts.map +1 -0
  34. package/dist-esm/samples-dev/snapshotDownloadSample.js +101 -0
  35. package/dist-esm/samples-dev/snapshotDownloadSample.js.map +1 -0
  36. package/dist-esm/samples-dev/snapshotGetSample.d.ts +2 -0
  37. package/dist-esm/samples-dev/snapshotGetSample.d.ts.map +1 -0
  38. package/dist-esm/samples-dev/snapshotGetSample.js +30 -0
  39. package/dist-esm/samples-dev/snapshotGetSample.js.map +1 -0
  40. package/dist-esm/samples-dev/snapshotsListSample.d.ts +2 -0
  41. package/dist-esm/samples-dev/snapshotsListSample.d.ts.map +1 -0
  42. package/dist-esm/samples-dev/snapshotsListSample.js +53 -0
  43. package/dist-esm/samples-dev/snapshotsListSample.js.map +1 -0
  44. package/dist-esm/src/appComplianceAutomationToolForMicrosoft365.d.ts +22 -0
  45. package/dist-esm/src/appComplianceAutomationToolForMicrosoft365.d.ts.map +1 -0
  46. package/dist-esm/src/appComplianceAutomationToolForMicrosoft365.js +101 -0
  47. package/dist-esm/src/appComplianceAutomationToolForMicrosoft365.js.map +1 -0
  48. package/dist-esm/src/index.d.ts +5 -0
  49. package/dist-esm/src/index.d.ts.map +1 -0
  50. package/dist-esm/src/index.js +12 -0
  51. package/dist-esm/src/index.js.map +1 -0
  52. package/dist-esm/src/lroImpl.d.ts +16 -0
  53. package/dist-esm/src/lroImpl.d.ts.map +1 -0
  54. package/dist-esm/src/lroImpl.js +29 -0
  55. package/dist-esm/src/lroImpl.js.map +1 -0
  56. package/dist-esm/src/models/index.d.ts +1046 -0
  57. package/dist-esm/src/models/index.d.ts.map +1 -0
  58. package/dist-esm/src/models/index.js +166 -0
  59. package/dist-esm/src/models/index.js.map +1 -0
  60. package/dist-esm/src/models/mappers.d.ts +33 -0
  61. package/dist-esm/src/models/mappers.d.ts.map +1 -0
  62. package/dist-esm/src/models/mappers.js +1167 -0
  63. package/dist-esm/src/models/mappers.js.map +1 -0
  64. package/dist-esm/src/models/parameters.d.ts +17 -0
  65. package/dist-esm/src/models/parameters.d.ts.map +1 -0
  66. package/dist-esm/src/models/parameters.js +157 -0
  67. package/dist-esm/src/models/parameters.js.map +1 -0
  68. package/dist-esm/src/operations/index.d.ts +6 -0
  69. package/dist-esm/src/operations/index.d.ts.map +1 -0
  70. package/dist-esm/src/operations/index.js +13 -0
  71. package/dist-esm/src/operations/index.js.map +1 -0
  72. package/dist-esm/src/operations/operations.d.ts +32 -0
  73. package/dist-esm/src/operations/operations.d.ts.map +1 -0
  74. package/dist-esm/src/operations/operations.js +120 -0
  75. package/dist-esm/src/operations/operations.js.map +1 -0
  76. package/dist-esm/src/operations/report.d.ts +60 -0
  77. package/dist-esm/src/operations/report.d.ts.map +1 -0
  78. package/dist-esm/src/operations/report.js +275 -0
  79. package/dist-esm/src/operations/report.js.map +1 -0
  80. package/dist-esm/src/operations/reports.d.ts +32 -0
  81. package/dist-esm/src/operations/reports.d.ts.map +1 -0
  82. package/dist-esm/src/operations/reports.js +134 -0
  83. package/dist-esm/src/operations/reports.js.map +1 -0
  84. package/dist-esm/src/operations/snapshot.d.ts +37 -0
  85. package/dist-esm/src/operations/snapshot.d.ts.map +1 -0
  86. package/dist-esm/src/operations/snapshot.js +140 -0
  87. package/dist-esm/src/operations/snapshot.js.map +1 -0
  88. package/dist-esm/src/operations/snapshots.d.ts +35 -0
  89. package/dist-esm/src/operations/snapshots.d.ts.map +1 -0
  90. package/dist-esm/src/operations/snapshots.js +137 -0
  91. package/dist-esm/src/operations/snapshots.js.map +1 -0
  92. package/dist-esm/src/operationsInterfaces/index.d.ts +6 -0
  93. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
  94. package/dist-esm/src/operationsInterfaces/index.js +13 -0
  95. package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
  96. package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
  97. package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
  98. package/dist-esm/src/operationsInterfaces/operations.js +9 -0
  99. package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
  100. package/dist-esm/src/operationsInterfaces/report.d.ts +52 -0
  101. package/dist-esm/src/operationsInterfaces/report.d.ts.map +1 -0
  102. package/dist-esm/src/operationsInterfaces/report.js +9 -0
  103. package/dist-esm/src/operationsInterfaces/report.js.map +1 -0
  104. package/dist-esm/src/operationsInterfaces/reports.d.ts +11 -0
  105. package/dist-esm/src/operationsInterfaces/reports.d.ts.map +1 -0
  106. package/dist-esm/src/operationsInterfaces/reports.js +9 -0
  107. package/dist-esm/src/operationsInterfaces/reports.js.map +1 -0
  108. package/dist-esm/src/operationsInterfaces/snapshot.d.ts +29 -0
  109. package/dist-esm/src/operationsInterfaces/snapshot.d.ts.map +1 -0
  110. package/dist-esm/src/operationsInterfaces/snapshot.js +9 -0
  111. package/dist-esm/src/operationsInterfaces/snapshot.js.map +1 -0
  112. package/dist-esm/src/operationsInterfaces/snapshots.d.ts +12 -0
  113. package/dist-esm/src/operationsInterfaces/snapshots.d.ts.map +1 -0
  114. package/dist-esm/src/operationsInterfaces/snapshots.js +9 -0
  115. package/dist-esm/src/operationsInterfaces/snapshots.js.map +1 -0
  116. package/dist-esm/test/sampleTest.d.ts +2 -0
  117. package/dist-esm/test/sampleTest.d.ts.map +1 -0
  118. package/dist-esm/test/sampleTest.js +38 -0
  119. package/dist-esm/test/sampleTest.js.map +1 -0
  120. package/package.json +122 -0
  121. package/review/arm-appcomplianceautomation.api.md +588 -0
  122. package/rollup.config.js +122 -0
  123. package/src/appComplianceAutomationToolForMicrosoft365.ts +153 -0
  124. package/src/index.ts +12 -0
  125. package/src/lroImpl.ts +34 -0
  126. package/src/models/index.ts +1144 -0
  127. package/src/models/mappers.ts +1207 -0
  128. package/src/models/parameters.ts +181 -0
  129. package/src/operations/index.ts +13 -0
  130. package/src/operations/operations.ts +137 -0
  131. package/src/operations/report.ts +388 -0
  132. package/src/operations/reports.ts +151 -0
  133. package/src/operations/snapshot.ts +201 -0
  134. package/src/operations/snapshots.ts +163 -0
  135. package/src/operationsInterfaces/index.ts +13 -0
  136. package/src/operationsInterfaces/operations.ts +22 -0
  137. package/src/operationsInterfaces/report.ts +102 -0
  138. package/src/operationsInterfaces/reports.ts +22 -0
  139. package/src/operationsInterfaces/snapshot.ts +62 -0
  140. package/src/operationsInterfaces/snapshots.ts +24 -0
  141. package/tsconfig.json +33 -0
  142. package/types/arm-appcomplianceautomation.d.ts +1261 -0
  143. package/types/tsdoc-metadata.json +11 -0
package/dist/index.js ADDED
@@ -0,0 +1,2463 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var tslib = require('tslib');
6
+ var coreClient = require('@azure/core-client');
7
+ var coreRestPipeline = require('@azure/core-rest-pipeline');
8
+ var coreLro = require('@azure/core-lro');
9
+
10
+ function _interopNamespace(e) {
11
+ if (e && e.__esModule) return e;
12
+ var n = Object.create(null);
13
+ if (e) {
14
+ Object.keys(e).forEach(function (k) {
15
+ if (k !== 'default') {
16
+ var d = Object.getOwnPropertyDescriptor(e, k);
17
+ Object.defineProperty(n, k, d.get ? d : {
18
+ enumerable: true,
19
+ get: function () { return e[k]; }
20
+ });
21
+ }
22
+ });
23
+ }
24
+ n["default"] = e;
25
+ return Object.freeze(n);
26
+ }
27
+
28
+ var coreClient__namespace = /*#__PURE__*/_interopNamespace(coreClient);
29
+ var coreRestPipeline__namespace = /*#__PURE__*/_interopNamespace(coreRestPipeline);
30
+
31
+ /*
32
+ * Copyright (c) Microsoft Corporation.
33
+ * Licensed under the MIT License.
34
+ *
35
+ * Code generated by Microsoft (R) AutoRest Code Generator.
36
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
37
+ */
38
+ /** Known values of {@link Origin} that the service accepts. */
39
+ exports.KnownOrigin = void 0;
40
+ (function (KnownOrigin) {
41
+ /** User */
42
+ KnownOrigin["User"] = "user";
43
+ /** System */
44
+ KnownOrigin["System"] = "system";
45
+ /** UserSystem */
46
+ KnownOrigin["UserSystem"] = "user,system";
47
+ })(exports.KnownOrigin || (exports.KnownOrigin = {}));
48
+ /** Known values of {@link ActionType} that the service accepts. */
49
+ exports.KnownActionType = void 0;
50
+ (function (KnownActionType) {
51
+ /** Internal */
52
+ KnownActionType["Internal"] = "Internal";
53
+ })(exports.KnownActionType || (exports.KnownActionType = {}));
54
+ /** Known values of {@link ReportStatus} that the service accepts. */
55
+ exports.KnownReportStatus = void 0;
56
+ (function (KnownReportStatus) {
57
+ /** Active */
58
+ KnownReportStatus["Active"] = "Active";
59
+ /** Failed */
60
+ KnownReportStatus["Failed"] = "Failed";
61
+ /** Disabled */
62
+ KnownReportStatus["Disabled"] = "Disabled";
63
+ })(exports.KnownReportStatus || (exports.KnownReportStatus = {}));
64
+ /** Known values of {@link ProvisioningState} that the service accepts. */
65
+ exports.KnownProvisioningState = void 0;
66
+ (function (KnownProvisioningState) {
67
+ /** Succeeded */
68
+ KnownProvisioningState["Succeeded"] = "Succeeded";
69
+ /** Failed */
70
+ KnownProvisioningState["Failed"] = "Failed";
71
+ /** Canceled */
72
+ KnownProvisioningState["Canceled"] = "Canceled";
73
+ /** Creating */
74
+ KnownProvisioningState["Creating"] = "Creating";
75
+ /** Deleting */
76
+ KnownProvisioningState["Deleting"] = "Deleting";
77
+ /** Updating */
78
+ KnownProvisioningState["Updating"] = "Updating";
79
+ })(exports.KnownProvisioningState || (exports.KnownProvisioningState = {}));
80
+ /** Known values of {@link CreatedByType} that the service accepts. */
81
+ exports.KnownCreatedByType = void 0;
82
+ (function (KnownCreatedByType) {
83
+ /** User */
84
+ KnownCreatedByType["User"] = "User";
85
+ /** Application */
86
+ KnownCreatedByType["Application"] = "Application";
87
+ /** ManagedIdentity */
88
+ KnownCreatedByType["ManagedIdentity"] = "ManagedIdentity";
89
+ /** Key */
90
+ KnownCreatedByType["Key"] = "Key";
91
+ })(exports.KnownCreatedByType || (exports.KnownCreatedByType = {}));
92
+ /** Known values of {@link CategoryType} that the service accepts. */
93
+ exports.KnownCategoryType = void 0;
94
+ (function (KnownCategoryType) {
95
+ /** FullyAutomated */
96
+ KnownCategoryType["FullyAutomated"] = "FullyAutomated";
97
+ /** PartiallyAutomated */
98
+ KnownCategoryType["PartiallyAutomated"] = "PartiallyAutomated";
99
+ /** Manual */
100
+ KnownCategoryType["Manual"] = "Manual";
101
+ })(exports.KnownCategoryType || (exports.KnownCategoryType = {}));
102
+ /** Known values of {@link CategoryStatus} that the service accepts. */
103
+ exports.KnownCategoryStatus = void 0;
104
+ (function (KnownCategoryStatus) {
105
+ /** Healthy */
106
+ KnownCategoryStatus["Healthy"] = "Healthy";
107
+ /** Unhealthy */
108
+ KnownCategoryStatus["Unhealthy"] = "Unhealthy";
109
+ })(exports.KnownCategoryStatus || (exports.KnownCategoryStatus = {}));
110
+ /** Known values of {@link ControlFamilyType} that the service accepts. */
111
+ exports.KnownControlFamilyType = void 0;
112
+ (function (KnownControlFamilyType) {
113
+ /** FullyAutomated */
114
+ KnownControlFamilyType["FullyAutomated"] = "FullyAutomated";
115
+ /** PartiallyAutomated */
116
+ KnownControlFamilyType["PartiallyAutomated"] = "PartiallyAutomated";
117
+ /** Manual */
118
+ KnownControlFamilyType["Manual"] = "Manual";
119
+ })(exports.KnownControlFamilyType || (exports.KnownControlFamilyType = {}));
120
+ /** Known values of {@link ControlFamilyStatus} that the service accepts. */
121
+ exports.KnownControlFamilyStatus = void 0;
122
+ (function (KnownControlFamilyStatus) {
123
+ /** Healthy */
124
+ KnownControlFamilyStatus["Healthy"] = "Healthy";
125
+ /** Unhealthy */
126
+ KnownControlFamilyStatus["Unhealthy"] = "Unhealthy";
127
+ })(exports.KnownControlFamilyStatus || (exports.KnownControlFamilyStatus = {}));
128
+ /** Known values of {@link ControlType} that the service accepts. */
129
+ exports.KnownControlType = void 0;
130
+ (function (KnownControlType) {
131
+ /** FullyAutomated */
132
+ KnownControlType["FullyAutomated"] = "FullyAutomated";
133
+ /** PartiallyAutomated */
134
+ KnownControlType["PartiallyAutomated"] = "PartiallyAutomated";
135
+ /** Manual */
136
+ KnownControlType["Manual"] = "Manual";
137
+ })(exports.KnownControlType || (exports.KnownControlType = {}));
138
+ /** Known values of {@link ControlStatus} that the service accepts. */
139
+ exports.KnownControlStatus = void 0;
140
+ (function (KnownControlStatus) {
141
+ /** Passed */
142
+ KnownControlStatus["Passed"] = "Passed";
143
+ /** Failed */
144
+ KnownControlStatus["Failed"] = "Failed";
145
+ /** NotApplicable */
146
+ KnownControlStatus["NotApplicable"] = "NotApplicable";
147
+ })(exports.KnownControlStatus || (exports.KnownControlStatus = {}));
148
+ /** Known values of {@link AssessmentSeverity} that the service accepts. */
149
+ exports.KnownAssessmentSeverity = void 0;
150
+ (function (KnownAssessmentSeverity) {
151
+ /** High */
152
+ KnownAssessmentSeverity["High"] = "High";
153
+ /** Medium */
154
+ KnownAssessmentSeverity["Medium"] = "Medium";
155
+ /** Low */
156
+ KnownAssessmentSeverity["Low"] = "Low";
157
+ })(exports.KnownAssessmentSeverity || (exports.KnownAssessmentSeverity = {}));
158
+ /** Known values of {@link IsPass} that the service accepts. */
159
+ exports.KnownIsPass = void 0;
160
+ (function (KnownIsPass) {
161
+ /** True */
162
+ KnownIsPass["True"] = "True";
163
+ /** False */
164
+ KnownIsPass["False"] = "False";
165
+ })(exports.KnownIsPass || (exports.KnownIsPass = {}));
166
+ /** Known values of {@link ResourceStatus} that the service accepts. */
167
+ exports.KnownResourceStatus = void 0;
168
+ (function (KnownResourceStatus) {
169
+ /** Healthy */
170
+ KnownResourceStatus["Healthy"] = "Healthy";
171
+ /** Unhealthy */
172
+ KnownResourceStatus["Unhealthy"] = "Unhealthy";
173
+ /** NotApplicable */
174
+ KnownResourceStatus["NotApplicable"] = "NotApplicable";
175
+ })(exports.KnownResourceStatus || (exports.KnownResourceStatus = {}));
176
+ /** Known values of {@link DownloadType} that the service accepts. */
177
+ exports.KnownDownloadType = void 0;
178
+ (function (KnownDownloadType) {
179
+ /** ComplianceReport */
180
+ KnownDownloadType["ComplianceReport"] = "ComplianceReport";
181
+ /** CompliancePdfReport */
182
+ KnownDownloadType["CompliancePdfReport"] = "CompliancePdfReport";
183
+ /** ComplianceDetailedPdfReport */
184
+ KnownDownloadType["ComplianceDetailedPdfReport"] = "ComplianceDetailedPdfReport";
185
+ /** ResourceList */
186
+ KnownDownloadType["ResourceList"] = "ResourceList";
187
+ })(exports.KnownDownloadType || (exports.KnownDownloadType = {}));
188
+ /** Known values of {@link ComplianceState} that the service accepts. */
189
+ exports.KnownComplianceState = void 0;
190
+ (function (KnownComplianceState) {
191
+ /** Healthy */
192
+ KnownComplianceState["Healthy"] = "Healthy";
193
+ /** Unhealthy */
194
+ KnownComplianceState["Unhealthy"] = "Unhealthy";
195
+ })(exports.KnownComplianceState || (exports.KnownComplianceState = {}));
196
+
197
+ /*
198
+ * Copyright (c) Microsoft Corporation.
199
+ * Licensed under the MIT License.
200
+ *
201
+ * Code generated by Microsoft (R) AutoRest Code Generator.
202
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
203
+ */
204
+ const OperationListResult = {
205
+ type: {
206
+ name: "Composite",
207
+ className: "OperationListResult",
208
+ modelProperties: {
209
+ value: {
210
+ serializedName: "value",
211
+ readOnly: true,
212
+ type: {
213
+ name: "Sequence",
214
+ element: {
215
+ type: {
216
+ name: "Composite",
217
+ className: "Operation"
218
+ }
219
+ }
220
+ }
221
+ },
222
+ nextLink: {
223
+ serializedName: "nextLink",
224
+ readOnly: true,
225
+ type: {
226
+ name: "String"
227
+ }
228
+ }
229
+ }
230
+ }
231
+ };
232
+ const Operation = {
233
+ type: {
234
+ name: "Composite",
235
+ className: "Operation",
236
+ modelProperties: {
237
+ name: {
238
+ serializedName: "name",
239
+ readOnly: true,
240
+ type: {
241
+ name: "String"
242
+ }
243
+ },
244
+ isDataAction: {
245
+ serializedName: "isDataAction",
246
+ readOnly: true,
247
+ type: {
248
+ name: "Boolean"
249
+ }
250
+ },
251
+ display: {
252
+ serializedName: "display",
253
+ type: {
254
+ name: "Composite",
255
+ className: "OperationDisplay"
256
+ }
257
+ },
258
+ origin: {
259
+ serializedName: "origin",
260
+ readOnly: true,
261
+ type: {
262
+ name: "String"
263
+ }
264
+ },
265
+ actionType: {
266
+ serializedName: "actionType",
267
+ readOnly: true,
268
+ type: {
269
+ name: "String"
270
+ }
271
+ }
272
+ }
273
+ }
274
+ };
275
+ const OperationDisplay = {
276
+ type: {
277
+ name: "Composite",
278
+ className: "OperationDisplay",
279
+ modelProperties: {
280
+ provider: {
281
+ serializedName: "provider",
282
+ readOnly: true,
283
+ type: {
284
+ name: "String"
285
+ }
286
+ },
287
+ resource: {
288
+ serializedName: "resource",
289
+ readOnly: true,
290
+ type: {
291
+ name: "String"
292
+ }
293
+ },
294
+ operation: {
295
+ serializedName: "operation",
296
+ readOnly: true,
297
+ type: {
298
+ name: "String"
299
+ }
300
+ },
301
+ description: {
302
+ serializedName: "description",
303
+ readOnly: true,
304
+ type: {
305
+ name: "String"
306
+ }
307
+ }
308
+ }
309
+ }
310
+ };
311
+ const ErrorResponse = {
312
+ type: {
313
+ name: "Composite",
314
+ className: "ErrorResponse",
315
+ modelProperties: {
316
+ error: {
317
+ serializedName: "error",
318
+ type: {
319
+ name: "Composite",
320
+ className: "ErrorDetail"
321
+ }
322
+ }
323
+ }
324
+ }
325
+ };
326
+ const ErrorDetail = {
327
+ type: {
328
+ name: "Composite",
329
+ className: "ErrorDetail",
330
+ modelProperties: {
331
+ code: {
332
+ serializedName: "code",
333
+ readOnly: true,
334
+ type: {
335
+ name: "String"
336
+ }
337
+ },
338
+ message: {
339
+ serializedName: "message",
340
+ readOnly: true,
341
+ type: {
342
+ name: "String"
343
+ }
344
+ },
345
+ target: {
346
+ serializedName: "target",
347
+ readOnly: true,
348
+ type: {
349
+ name: "String"
350
+ }
351
+ },
352
+ details: {
353
+ serializedName: "details",
354
+ readOnly: true,
355
+ type: {
356
+ name: "Sequence",
357
+ element: {
358
+ type: {
359
+ name: "Composite",
360
+ className: "ErrorDetail"
361
+ }
362
+ }
363
+ }
364
+ },
365
+ additionalInfo: {
366
+ serializedName: "additionalInfo",
367
+ readOnly: true,
368
+ type: {
369
+ name: "Sequence",
370
+ element: {
371
+ type: {
372
+ name: "Composite",
373
+ className: "ErrorAdditionalInfo"
374
+ }
375
+ }
376
+ }
377
+ }
378
+ }
379
+ }
380
+ };
381
+ const ErrorAdditionalInfo = {
382
+ type: {
383
+ name: "Composite",
384
+ className: "ErrorAdditionalInfo",
385
+ modelProperties: {
386
+ type: {
387
+ serializedName: "type",
388
+ readOnly: true,
389
+ type: {
390
+ name: "String"
391
+ }
392
+ },
393
+ info: {
394
+ serializedName: "info",
395
+ readOnly: true,
396
+ type: {
397
+ name: "Dictionary",
398
+ value: { type: { name: "any" } }
399
+ }
400
+ }
401
+ }
402
+ }
403
+ };
404
+ const ReportResourceList = {
405
+ type: {
406
+ name: "Composite",
407
+ className: "ReportResourceList",
408
+ modelProperties: {
409
+ value: {
410
+ serializedName: "value",
411
+ readOnly: true,
412
+ type: {
413
+ name: "Sequence",
414
+ element: {
415
+ type: {
416
+ name: "Composite",
417
+ className: "ReportResource"
418
+ }
419
+ }
420
+ }
421
+ },
422
+ nextLink: {
423
+ serializedName: "nextLink",
424
+ type: {
425
+ name: "String"
426
+ }
427
+ }
428
+ }
429
+ }
430
+ };
431
+ const ReportProperties = {
432
+ type: {
433
+ name: "Composite",
434
+ className: "ReportProperties",
435
+ modelProperties: {
436
+ id: {
437
+ serializedName: "id",
438
+ readOnly: true,
439
+ type: {
440
+ name: "String"
441
+ }
442
+ },
443
+ status: {
444
+ serializedName: "status",
445
+ readOnly: true,
446
+ type: {
447
+ name: "String"
448
+ }
449
+ },
450
+ tenantId: {
451
+ serializedName: "tenantId",
452
+ readOnly: true,
453
+ type: {
454
+ name: "String"
455
+ }
456
+ },
457
+ reportName: {
458
+ serializedName: "reportName",
459
+ readOnly: true,
460
+ type: {
461
+ name: "String"
462
+ }
463
+ },
464
+ offerGuid: {
465
+ serializedName: "offerGuid",
466
+ type: {
467
+ name: "String"
468
+ }
469
+ },
470
+ timeZone: {
471
+ serializedName: "timeZone",
472
+ required: true,
473
+ type: {
474
+ name: "String"
475
+ }
476
+ },
477
+ triggerTime: {
478
+ serializedName: "triggerTime",
479
+ required: true,
480
+ type: {
481
+ name: "DateTime"
482
+ }
483
+ },
484
+ nextTriggerTime: {
485
+ serializedName: "nextTriggerTime",
486
+ readOnly: true,
487
+ type: {
488
+ name: "DateTime"
489
+ }
490
+ },
491
+ lastTriggerTime: {
492
+ serializedName: "lastTriggerTime",
493
+ readOnly: true,
494
+ type: {
495
+ name: "DateTime"
496
+ }
497
+ },
498
+ subscriptions: {
499
+ serializedName: "subscriptions",
500
+ readOnly: true,
501
+ type: {
502
+ name: "Sequence",
503
+ element: {
504
+ type: {
505
+ name: "String"
506
+ }
507
+ }
508
+ }
509
+ },
510
+ resources: {
511
+ serializedName: "resources",
512
+ required: true,
513
+ type: {
514
+ name: "Sequence",
515
+ element: {
516
+ type: {
517
+ name: "Composite",
518
+ className: "ResourceMetadata"
519
+ }
520
+ }
521
+ }
522
+ },
523
+ complianceStatus: {
524
+ serializedName: "complianceStatus",
525
+ type: {
526
+ name: "Composite",
527
+ className: "ReportComplianceStatus"
528
+ }
529
+ },
530
+ provisioningState: {
531
+ serializedName: "provisioningState",
532
+ readOnly: true,
533
+ type: {
534
+ name: "String"
535
+ }
536
+ }
537
+ }
538
+ }
539
+ };
540
+ const ResourceMetadata = {
541
+ type: {
542
+ name: "Composite",
543
+ className: "ResourceMetadata",
544
+ modelProperties: {
545
+ resourceId: {
546
+ serializedName: "resourceId",
547
+ required: true,
548
+ type: {
549
+ name: "String"
550
+ }
551
+ },
552
+ resourceType: {
553
+ serializedName: "resourceType",
554
+ type: {
555
+ name: "String"
556
+ }
557
+ },
558
+ resourceKind: {
559
+ serializedName: "resourceKind",
560
+ type: {
561
+ name: "String"
562
+ }
563
+ },
564
+ resourceName: {
565
+ serializedName: "resourceName",
566
+ type: {
567
+ name: "String"
568
+ }
569
+ },
570
+ tags: {
571
+ serializedName: "tags",
572
+ type: {
573
+ name: "Dictionary",
574
+ value: { type: { name: "String" } }
575
+ }
576
+ }
577
+ }
578
+ }
579
+ };
580
+ const ReportComplianceStatus = {
581
+ type: {
582
+ name: "Composite",
583
+ className: "ReportComplianceStatus",
584
+ modelProperties: {
585
+ m365: {
586
+ serializedName: "m365",
587
+ type: {
588
+ name: "Composite",
589
+ className: "OverviewStatus"
590
+ }
591
+ }
592
+ }
593
+ }
594
+ };
595
+ const OverviewStatus = {
596
+ type: {
597
+ name: "Composite",
598
+ className: "OverviewStatus",
599
+ modelProperties: {
600
+ passedCount: {
601
+ serializedName: "passedCount",
602
+ type: {
603
+ name: "Number"
604
+ }
605
+ },
606
+ failedCount: {
607
+ serializedName: "failedCount",
608
+ type: {
609
+ name: "Number"
610
+ }
611
+ },
612
+ manualCount: {
613
+ serializedName: "manualCount",
614
+ type: {
615
+ name: "Number"
616
+ }
617
+ }
618
+ }
619
+ }
620
+ };
621
+ const Resource = {
622
+ type: {
623
+ name: "Composite",
624
+ className: "Resource",
625
+ modelProperties: {
626
+ id: {
627
+ serializedName: "id",
628
+ readOnly: true,
629
+ type: {
630
+ name: "String"
631
+ }
632
+ },
633
+ name: {
634
+ serializedName: "name",
635
+ readOnly: true,
636
+ type: {
637
+ name: "String"
638
+ }
639
+ },
640
+ type: {
641
+ serializedName: "type",
642
+ readOnly: true,
643
+ type: {
644
+ name: "String"
645
+ }
646
+ },
647
+ systemData: {
648
+ serializedName: "systemData",
649
+ type: {
650
+ name: "Composite",
651
+ className: "SystemData"
652
+ }
653
+ }
654
+ }
655
+ }
656
+ };
657
+ const SystemData = {
658
+ type: {
659
+ name: "Composite",
660
+ className: "SystemData",
661
+ modelProperties: {
662
+ createdBy: {
663
+ serializedName: "createdBy",
664
+ type: {
665
+ name: "String"
666
+ }
667
+ },
668
+ createdByType: {
669
+ serializedName: "createdByType",
670
+ type: {
671
+ name: "String"
672
+ }
673
+ },
674
+ createdAt: {
675
+ serializedName: "createdAt",
676
+ type: {
677
+ name: "DateTime"
678
+ }
679
+ },
680
+ lastModifiedBy: {
681
+ serializedName: "lastModifiedBy",
682
+ type: {
683
+ name: "String"
684
+ }
685
+ },
686
+ lastModifiedByType: {
687
+ serializedName: "lastModifiedByType",
688
+ type: {
689
+ name: "String"
690
+ }
691
+ },
692
+ lastModifiedAt: {
693
+ serializedName: "lastModifiedAt",
694
+ type: {
695
+ name: "DateTime"
696
+ }
697
+ }
698
+ }
699
+ }
700
+ };
701
+ const ReportResourcePatch = {
702
+ type: {
703
+ name: "Composite",
704
+ className: "ReportResourcePatch",
705
+ modelProperties: {
706
+ properties: {
707
+ serializedName: "properties",
708
+ type: {
709
+ name: "Composite",
710
+ className: "ReportProperties"
711
+ }
712
+ }
713
+ }
714
+ }
715
+ };
716
+ const SnapshotResourceList = {
717
+ type: {
718
+ name: "Composite",
719
+ className: "SnapshotResourceList",
720
+ modelProperties: {
721
+ value: {
722
+ serializedName: "value",
723
+ readOnly: true,
724
+ type: {
725
+ name: "Sequence",
726
+ element: {
727
+ type: {
728
+ name: "Composite",
729
+ className: "SnapshotResource"
730
+ }
731
+ }
732
+ }
733
+ },
734
+ nextLink: {
735
+ serializedName: "nextLink",
736
+ type: {
737
+ name: "String"
738
+ }
739
+ }
740
+ }
741
+ }
742
+ };
743
+ const SnapshotProperties = {
744
+ type: {
745
+ name: "Composite",
746
+ className: "SnapshotProperties",
747
+ modelProperties: {
748
+ id: {
749
+ serializedName: "id",
750
+ readOnly: true,
751
+ type: {
752
+ name: "String"
753
+ }
754
+ },
755
+ snapshotName: {
756
+ serializedName: "snapshotName",
757
+ readOnly: true,
758
+ type: {
759
+ name: "String"
760
+ }
761
+ },
762
+ createdAt: {
763
+ serializedName: "createdAt",
764
+ readOnly: true,
765
+ type: {
766
+ name: "DateTime"
767
+ }
768
+ },
769
+ provisioningState: {
770
+ serializedName: "provisioningState",
771
+ readOnly: true,
772
+ type: {
773
+ name: "String"
774
+ }
775
+ },
776
+ reportProperties: {
777
+ serializedName: "reportProperties",
778
+ type: {
779
+ name: "Composite",
780
+ className: "ReportProperties"
781
+ }
782
+ },
783
+ reportSystemData: {
784
+ serializedName: "reportSystemData",
785
+ type: {
786
+ name: "Composite",
787
+ className: "SystemData"
788
+ }
789
+ },
790
+ complianceResults: {
791
+ serializedName: "complianceResults",
792
+ readOnly: true,
793
+ type: {
794
+ name: "Sequence",
795
+ element: {
796
+ type: {
797
+ name: "Composite",
798
+ className: "ComplianceResult"
799
+ }
800
+ }
801
+ }
802
+ }
803
+ }
804
+ }
805
+ };
806
+ const ComplianceResult = {
807
+ type: {
808
+ name: "Composite",
809
+ className: "ComplianceResult",
810
+ modelProperties: {
811
+ complianceName: {
812
+ serializedName: "complianceName",
813
+ readOnly: true,
814
+ type: {
815
+ name: "String"
816
+ }
817
+ },
818
+ categories: {
819
+ serializedName: "categories",
820
+ readOnly: true,
821
+ type: {
822
+ name: "Sequence",
823
+ element: {
824
+ type: {
825
+ name: "Composite",
826
+ className: "Category"
827
+ }
828
+ }
829
+ }
830
+ }
831
+ }
832
+ }
833
+ };
834
+ const Category = {
835
+ type: {
836
+ name: "Composite",
837
+ className: "Category",
838
+ modelProperties: {
839
+ categoryName: {
840
+ serializedName: "categoryName",
841
+ readOnly: true,
842
+ type: {
843
+ name: "String"
844
+ }
845
+ },
846
+ categoryType: {
847
+ serializedName: "categoryType",
848
+ readOnly: true,
849
+ type: {
850
+ name: "String"
851
+ }
852
+ },
853
+ categoryStatus: {
854
+ serializedName: "categoryStatus",
855
+ readOnly: true,
856
+ type: {
857
+ name: "String"
858
+ }
859
+ },
860
+ controlFamilies: {
861
+ serializedName: "controlFamilies",
862
+ readOnly: true,
863
+ type: {
864
+ name: "Sequence",
865
+ element: {
866
+ type: {
867
+ name: "Composite",
868
+ className: "ControlFamily"
869
+ }
870
+ }
871
+ }
872
+ }
873
+ }
874
+ }
875
+ };
876
+ const ControlFamily = {
877
+ type: {
878
+ name: "Composite",
879
+ className: "ControlFamily",
880
+ modelProperties: {
881
+ familyName: {
882
+ serializedName: "familyName",
883
+ readOnly: true,
884
+ type: {
885
+ name: "String"
886
+ }
887
+ },
888
+ familyType: {
889
+ serializedName: "familyType",
890
+ readOnly: true,
891
+ type: {
892
+ name: "String"
893
+ }
894
+ },
895
+ familyStatus: {
896
+ serializedName: "familyStatus",
897
+ readOnly: true,
898
+ type: {
899
+ name: "String"
900
+ }
901
+ },
902
+ controls: {
903
+ serializedName: "controls",
904
+ readOnly: true,
905
+ type: {
906
+ name: "Sequence",
907
+ element: {
908
+ type: {
909
+ name: "Composite",
910
+ className: "Control"
911
+ }
912
+ }
913
+ }
914
+ }
915
+ }
916
+ }
917
+ };
918
+ const Control = {
919
+ type: {
920
+ name: "Composite",
921
+ className: "Control",
922
+ modelProperties: {
923
+ controlId: {
924
+ serializedName: "controlId",
925
+ readOnly: true,
926
+ type: {
927
+ name: "String"
928
+ }
929
+ },
930
+ controlShortName: {
931
+ serializedName: "controlShortName",
932
+ readOnly: true,
933
+ type: {
934
+ name: "String"
935
+ }
936
+ },
937
+ controlFullName: {
938
+ serializedName: "controlFullName",
939
+ readOnly: true,
940
+ type: {
941
+ name: "String"
942
+ }
943
+ },
944
+ controlType: {
945
+ serializedName: "controlType",
946
+ readOnly: true,
947
+ type: {
948
+ name: "String"
949
+ }
950
+ },
951
+ controlDescription: {
952
+ serializedName: "controlDescription",
953
+ readOnly: true,
954
+ type: {
955
+ name: "String"
956
+ }
957
+ },
958
+ controlDescriptionHyperLink: {
959
+ serializedName: "controlDescriptionHyperLink",
960
+ readOnly: true,
961
+ type: {
962
+ name: "String"
963
+ }
964
+ },
965
+ controlStatus: {
966
+ serializedName: "controlStatus",
967
+ readOnly: true,
968
+ type: {
969
+ name: "String"
970
+ }
971
+ },
972
+ assessments: {
973
+ serializedName: "assessments",
974
+ readOnly: true,
975
+ type: {
976
+ name: "Sequence",
977
+ element: {
978
+ type: {
979
+ name: "Composite",
980
+ className: "Assessment"
981
+ }
982
+ }
983
+ }
984
+ }
985
+ }
986
+ }
987
+ };
988
+ const Assessment = {
989
+ type: {
990
+ name: "Composite",
991
+ className: "Assessment",
992
+ modelProperties: {
993
+ name: {
994
+ serializedName: "name",
995
+ readOnly: true,
996
+ type: {
997
+ name: "String"
998
+ }
999
+ },
1000
+ severity: {
1001
+ serializedName: "severity",
1002
+ readOnly: true,
1003
+ type: {
1004
+ name: "String"
1005
+ }
1006
+ },
1007
+ description: {
1008
+ serializedName: "description",
1009
+ readOnly: true,
1010
+ type: {
1011
+ name: "String"
1012
+ }
1013
+ },
1014
+ remediation: {
1015
+ serializedName: "remediation",
1016
+ readOnly: true,
1017
+ type: {
1018
+ name: "String"
1019
+ }
1020
+ },
1021
+ isPass: {
1022
+ serializedName: "isPass",
1023
+ readOnly: true,
1024
+ type: {
1025
+ name: "String"
1026
+ }
1027
+ },
1028
+ policyId: {
1029
+ serializedName: "policyId",
1030
+ readOnly: true,
1031
+ type: {
1032
+ name: "String"
1033
+ }
1034
+ },
1035
+ resourceList: {
1036
+ serializedName: "resourceList",
1037
+ readOnly: true,
1038
+ type: {
1039
+ name: "Sequence",
1040
+ element: {
1041
+ type: {
1042
+ name: "Composite",
1043
+ className: "AssessmentResource"
1044
+ }
1045
+ }
1046
+ }
1047
+ }
1048
+ }
1049
+ }
1050
+ };
1051
+ const AssessmentResource = {
1052
+ type: {
1053
+ name: "Composite",
1054
+ className: "AssessmentResource",
1055
+ modelProperties: {
1056
+ resourceId: {
1057
+ serializedName: "resourceId",
1058
+ readOnly: true,
1059
+ type: {
1060
+ name: "String"
1061
+ }
1062
+ },
1063
+ resourceStatus: {
1064
+ serializedName: "resourceStatus",
1065
+ readOnly: true,
1066
+ type: {
1067
+ name: "String"
1068
+ }
1069
+ },
1070
+ reason: {
1071
+ serializedName: "reason",
1072
+ readOnly: true,
1073
+ type: {
1074
+ name: "String"
1075
+ }
1076
+ },
1077
+ statusChangeDate: {
1078
+ serializedName: "statusChangeDate",
1079
+ readOnly: true,
1080
+ type: {
1081
+ name: "String"
1082
+ }
1083
+ }
1084
+ }
1085
+ }
1086
+ };
1087
+ const SnapshotDownloadRequest = {
1088
+ type: {
1089
+ name: "Composite",
1090
+ className: "SnapshotDownloadRequest",
1091
+ modelProperties: {
1092
+ reportCreatorTenantId: {
1093
+ serializedName: "reportCreatorTenantId",
1094
+ type: {
1095
+ name: "String"
1096
+ }
1097
+ },
1098
+ downloadType: {
1099
+ serializedName: "downloadType",
1100
+ required: true,
1101
+ type: {
1102
+ name: "String"
1103
+ }
1104
+ },
1105
+ offerGuid: {
1106
+ constraints: {
1107
+ MinLength: 1
1108
+ },
1109
+ serializedName: "offerGuid",
1110
+ type: {
1111
+ name: "String"
1112
+ }
1113
+ }
1114
+ }
1115
+ }
1116
+ };
1117
+ const DownloadResponse = {
1118
+ type: {
1119
+ name: "Composite",
1120
+ className: "DownloadResponse",
1121
+ modelProperties: {
1122
+ resourceList: {
1123
+ serializedName: "resourceList",
1124
+ readOnly: true,
1125
+ type: {
1126
+ name: "Sequence",
1127
+ element: {
1128
+ type: {
1129
+ name: "Composite",
1130
+ className: "ResourceItem"
1131
+ }
1132
+ }
1133
+ }
1134
+ },
1135
+ complianceReport: {
1136
+ serializedName: "complianceReport",
1137
+ readOnly: true,
1138
+ type: {
1139
+ name: "Sequence",
1140
+ element: {
1141
+ type: {
1142
+ name: "Composite",
1143
+ className: "ComplianceReportItem"
1144
+ }
1145
+ }
1146
+ }
1147
+ },
1148
+ compliancePdfReport: {
1149
+ serializedName: "compliancePdfReport",
1150
+ type: {
1151
+ name: "Composite",
1152
+ className: "DownloadResponseCompliancePdfReport"
1153
+ }
1154
+ },
1155
+ complianceDetailedPdfReport: {
1156
+ serializedName: "complianceDetailedPdfReport",
1157
+ type: {
1158
+ name: "Composite",
1159
+ className: "DownloadResponseComplianceDetailedPdfReport"
1160
+ }
1161
+ }
1162
+ }
1163
+ }
1164
+ };
1165
+ const ResourceItem = {
1166
+ type: {
1167
+ name: "Composite",
1168
+ className: "ResourceItem",
1169
+ modelProperties: {
1170
+ subscriptionId: {
1171
+ serializedName: "subscriptionId",
1172
+ readOnly: true,
1173
+ type: {
1174
+ name: "String"
1175
+ }
1176
+ },
1177
+ resourceGroup: {
1178
+ serializedName: "resourceGroup",
1179
+ readOnly: true,
1180
+ type: {
1181
+ name: "String"
1182
+ }
1183
+ },
1184
+ resourceType: {
1185
+ serializedName: "resourceType",
1186
+ readOnly: true,
1187
+ type: {
1188
+ name: "String"
1189
+ }
1190
+ },
1191
+ resourceId: {
1192
+ serializedName: "resourceId",
1193
+ readOnly: true,
1194
+ type: {
1195
+ name: "String"
1196
+ }
1197
+ }
1198
+ }
1199
+ }
1200
+ };
1201
+ const ComplianceReportItem = {
1202
+ type: {
1203
+ name: "Composite",
1204
+ className: "ComplianceReportItem",
1205
+ modelProperties: {
1206
+ categoryName: {
1207
+ serializedName: "categoryName",
1208
+ readOnly: true,
1209
+ type: {
1210
+ name: "String"
1211
+ }
1212
+ },
1213
+ controlId: {
1214
+ serializedName: "controlId",
1215
+ readOnly: true,
1216
+ type: {
1217
+ name: "String"
1218
+ }
1219
+ },
1220
+ controlName: {
1221
+ serializedName: "controlName",
1222
+ readOnly: true,
1223
+ type: {
1224
+ name: "String"
1225
+ }
1226
+ },
1227
+ controlType: {
1228
+ serializedName: "controlType",
1229
+ readOnly: true,
1230
+ type: {
1231
+ name: "String"
1232
+ }
1233
+ },
1234
+ complianceState: {
1235
+ serializedName: "complianceState",
1236
+ readOnly: true,
1237
+ type: {
1238
+ name: "String"
1239
+ }
1240
+ },
1241
+ policyId: {
1242
+ serializedName: "policyId",
1243
+ readOnly: true,
1244
+ type: {
1245
+ name: "String"
1246
+ }
1247
+ },
1248
+ policyDisplayName: {
1249
+ serializedName: "policyDisplayName",
1250
+ readOnly: true,
1251
+ type: {
1252
+ name: "String"
1253
+ }
1254
+ },
1255
+ policyDescription: {
1256
+ serializedName: "policyDescription",
1257
+ readOnly: true,
1258
+ type: {
1259
+ name: "String"
1260
+ }
1261
+ },
1262
+ subscriptionId: {
1263
+ serializedName: "subscriptionId",
1264
+ readOnly: true,
1265
+ type: {
1266
+ name: "String"
1267
+ }
1268
+ },
1269
+ resourceGroup: {
1270
+ serializedName: "resourceGroup",
1271
+ readOnly: true,
1272
+ type: {
1273
+ name: "String"
1274
+ }
1275
+ },
1276
+ resourceType: {
1277
+ serializedName: "resourceType",
1278
+ readOnly: true,
1279
+ type: {
1280
+ name: "String"
1281
+ }
1282
+ },
1283
+ resourceId: {
1284
+ serializedName: "resourceId",
1285
+ readOnly: true,
1286
+ type: {
1287
+ name: "String"
1288
+ }
1289
+ },
1290
+ statusChangeDate: {
1291
+ serializedName: "statusChangeDate",
1292
+ readOnly: true,
1293
+ type: {
1294
+ name: "String"
1295
+ }
1296
+ }
1297
+ }
1298
+ }
1299
+ };
1300
+ const DownloadResponseCompliancePdfReport = {
1301
+ type: {
1302
+ name: "Composite",
1303
+ className: "DownloadResponseCompliancePdfReport",
1304
+ modelProperties: {
1305
+ sasUri: {
1306
+ serializedName: "sasUri",
1307
+ readOnly: true,
1308
+ type: {
1309
+ name: "String"
1310
+ }
1311
+ }
1312
+ }
1313
+ }
1314
+ };
1315
+ const DownloadResponseComplianceDetailedPdfReport = {
1316
+ type: {
1317
+ name: "Composite",
1318
+ className: "DownloadResponseComplianceDetailedPdfReport",
1319
+ modelProperties: {
1320
+ sasUri: {
1321
+ serializedName: "sasUri",
1322
+ readOnly: true,
1323
+ type: {
1324
+ name: "String"
1325
+ }
1326
+ }
1327
+ }
1328
+ }
1329
+ };
1330
+ const ProxyResource = {
1331
+ type: {
1332
+ name: "Composite",
1333
+ className: "ProxyResource",
1334
+ modelProperties: Object.assign({}, Resource.type.modelProperties)
1335
+ }
1336
+ };
1337
+ const ReportResource = {
1338
+ type: {
1339
+ name: "Composite",
1340
+ className: "ReportResource",
1341
+ modelProperties: Object.assign(Object.assign({}, ProxyResource.type.modelProperties), { properties: {
1342
+ serializedName: "properties",
1343
+ type: {
1344
+ name: "Composite",
1345
+ className: "ReportProperties"
1346
+ }
1347
+ } })
1348
+ }
1349
+ };
1350
+ const SnapshotResource = {
1351
+ type: {
1352
+ name: "Composite",
1353
+ className: "SnapshotResource",
1354
+ modelProperties: Object.assign(Object.assign({}, ProxyResource.type.modelProperties), { properties: {
1355
+ serializedName: "properties",
1356
+ type: {
1357
+ name: "Composite",
1358
+ className: "SnapshotProperties"
1359
+ }
1360
+ } })
1361
+ }
1362
+ };
1363
+
1364
+ var Mappers = /*#__PURE__*/Object.freeze({
1365
+ __proto__: null,
1366
+ OperationListResult: OperationListResult,
1367
+ Operation: Operation,
1368
+ OperationDisplay: OperationDisplay,
1369
+ ErrorResponse: ErrorResponse,
1370
+ ErrorDetail: ErrorDetail,
1371
+ ErrorAdditionalInfo: ErrorAdditionalInfo,
1372
+ ReportResourceList: ReportResourceList,
1373
+ ReportProperties: ReportProperties,
1374
+ ResourceMetadata: ResourceMetadata,
1375
+ ReportComplianceStatus: ReportComplianceStatus,
1376
+ OverviewStatus: OverviewStatus,
1377
+ Resource: Resource,
1378
+ SystemData: SystemData,
1379
+ ReportResourcePatch: ReportResourcePatch,
1380
+ SnapshotResourceList: SnapshotResourceList,
1381
+ SnapshotProperties: SnapshotProperties,
1382
+ ComplianceResult: ComplianceResult,
1383
+ Category: Category,
1384
+ ControlFamily: ControlFamily,
1385
+ Control: Control,
1386
+ Assessment: Assessment,
1387
+ AssessmentResource: AssessmentResource,
1388
+ SnapshotDownloadRequest: SnapshotDownloadRequest,
1389
+ DownloadResponse: DownloadResponse,
1390
+ ResourceItem: ResourceItem,
1391
+ ComplianceReportItem: ComplianceReportItem,
1392
+ DownloadResponseCompliancePdfReport: DownloadResponseCompliancePdfReport,
1393
+ DownloadResponseComplianceDetailedPdfReport: DownloadResponseComplianceDetailedPdfReport,
1394
+ ProxyResource: ProxyResource,
1395
+ ReportResource: ReportResource,
1396
+ SnapshotResource: SnapshotResource
1397
+ });
1398
+
1399
+ /*
1400
+ * Copyright (c) Microsoft Corporation.
1401
+ * Licensed under the MIT License.
1402
+ *
1403
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1404
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1405
+ */
1406
+ const accept = {
1407
+ parameterPath: "accept",
1408
+ mapper: {
1409
+ defaultValue: "application/json",
1410
+ isConstant: true,
1411
+ serializedName: "Accept",
1412
+ type: {
1413
+ name: "String"
1414
+ }
1415
+ }
1416
+ };
1417
+ const $host = {
1418
+ parameterPath: "$host",
1419
+ mapper: {
1420
+ serializedName: "$host",
1421
+ required: true,
1422
+ type: {
1423
+ name: "String"
1424
+ }
1425
+ },
1426
+ skipEncoding: true
1427
+ };
1428
+ const apiVersion = {
1429
+ parameterPath: "apiVersion",
1430
+ mapper: {
1431
+ defaultValue: "2022-11-16-preview",
1432
+ isConstant: true,
1433
+ serializedName: "api-version",
1434
+ type: {
1435
+ name: "String"
1436
+ }
1437
+ }
1438
+ };
1439
+ const nextLink = {
1440
+ parameterPath: "nextLink",
1441
+ mapper: {
1442
+ serializedName: "nextLink",
1443
+ required: true,
1444
+ type: {
1445
+ name: "String"
1446
+ }
1447
+ },
1448
+ skipEncoding: true
1449
+ };
1450
+ const skipToken = {
1451
+ parameterPath: ["options", "skipToken"],
1452
+ mapper: {
1453
+ serializedName: "$skipToken",
1454
+ type: {
1455
+ name: "String"
1456
+ }
1457
+ }
1458
+ };
1459
+ const top = {
1460
+ parameterPath: ["options", "top"],
1461
+ mapper: {
1462
+ constraints: {
1463
+ InclusiveMaximum: 100,
1464
+ InclusiveMinimum: 1
1465
+ },
1466
+ serializedName: "$top",
1467
+ type: {
1468
+ name: "Number"
1469
+ }
1470
+ }
1471
+ };
1472
+ const select = {
1473
+ parameterPath: ["options", "select"],
1474
+ mapper: {
1475
+ constraints: {
1476
+ MinLength: 1
1477
+ },
1478
+ serializedName: "$select",
1479
+ type: {
1480
+ name: "String"
1481
+ }
1482
+ }
1483
+ };
1484
+ const offerGuid = {
1485
+ parameterPath: ["options", "offerGuid"],
1486
+ mapper: {
1487
+ constraints: {
1488
+ MinLength: 1
1489
+ },
1490
+ serializedName: "offerGuid",
1491
+ type: {
1492
+ name: "String"
1493
+ }
1494
+ }
1495
+ };
1496
+ const reportCreatorTenantId = {
1497
+ parameterPath: ["options", "reportCreatorTenantId"],
1498
+ mapper: {
1499
+ constraints: {
1500
+ MinLength: 1
1501
+ },
1502
+ serializedName: "reportCreatorTenantId",
1503
+ type: {
1504
+ name: "String"
1505
+ }
1506
+ }
1507
+ };
1508
+ const reportName = {
1509
+ parameterPath: "reportName",
1510
+ mapper: {
1511
+ constraints: {
1512
+ Pattern: new RegExp("^[-a-zA-Z0-9_]+$")
1513
+ },
1514
+ serializedName: "reportName",
1515
+ required: true,
1516
+ type: {
1517
+ name: "String"
1518
+ }
1519
+ }
1520
+ };
1521
+ const contentType = {
1522
+ parameterPath: ["options", "contentType"],
1523
+ mapper: {
1524
+ defaultValue: "application/json",
1525
+ isConstant: true,
1526
+ serializedName: "Content-Type",
1527
+ type: {
1528
+ name: "String"
1529
+ }
1530
+ }
1531
+ };
1532
+ const parameters = {
1533
+ parameterPath: "parameters",
1534
+ mapper: ReportResource
1535
+ };
1536
+ const parameters1 = {
1537
+ parameterPath: "parameters",
1538
+ mapper: ReportResourcePatch
1539
+ };
1540
+ const snapshotName = {
1541
+ parameterPath: "snapshotName",
1542
+ mapper: {
1543
+ serializedName: "snapshotName",
1544
+ required: true,
1545
+ type: {
1546
+ name: "String"
1547
+ }
1548
+ }
1549
+ };
1550
+ const parameters2 = {
1551
+ parameterPath: "parameters",
1552
+ mapper: SnapshotDownloadRequest
1553
+ };
1554
+
1555
+ /*
1556
+ * Copyright (c) Microsoft Corporation.
1557
+ * Licensed under the MIT License.
1558
+ *
1559
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1560
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1561
+ */
1562
+ /// <reference lib="esnext.asynciterable" />
1563
+ /** Class containing Operations operations. */
1564
+ class OperationsImpl {
1565
+ /**
1566
+ * Initialize a new instance of the class Operations class.
1567
+ * @param client Reference to the service client
1568
+ */
1569
+ constructor(client) {
1570
+ this.client = client;
1571
+ }
1572
+ /**
1573
+ * Lists all of the available REST API operations of the Microsoft.AppComplianceAutomation provider.
1574
+ * @param options The options parameters.
1575
+ */
1576
+ list(options) {
1577
+ const iter = this.listPagingAll(options);
1578
+ return {
1579
+ next() {
1580
+ return iter.next();
1581
+ },
1582
+ [Symbol.asyncIterator]() {
1583
+ return this;
1584
+ },
1585
+ byPage: () => {
1586
+ return this.listPagingPage(options);
1587
+ }
1588
+ };
1589
+ }
1590
+ listPagingPage(options) {
1591
+ return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
1592
+ let result = yield tslib.__await(this._list(options));
1593
+ yield yield tslib.__await(result.value || []);
1594
+ let continuationToken = result.nextLink;
1595
+ while (continuationToken) {
1596
+ result = yield tslib.__await(this._listNext(continuationToken, options));
1597
+ continuationToken = result.nextLink;
1598
+ yield yield tslib.__await(result.value || []);
1599
+ }
1600
+ });
1601
+ }
1602
+ listPagingAll(options) {
1603
+ return tslib.__asyncGenerator(this, arguments, function* listPagingAll_1() {
1604
+ var e_1, _a;
1605
+ try {
1606
+ for (var _b = tslib.__asyncValues(this.listPagingPage(options)), _c; _c = yield tslib.__await(_b.next()), !_c.done;) {
1607
+ const page = _c.value;
1608
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
1609
+ }
1610
+ }
1611
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
1612
+ finally {
1613
+ try {
1614
+ if (_c && !_c.done && (_a = _b.return)) yield tslib.__await(_a.call(_b));
1615
+ }
1616
+ finally { if (e_1) throw e_1.error; }
1617
+ }
1618
+ });
1619
+ }
1620
+ /**
1621
+ * Lists all of the available REST API operations of the Microsoft.AppComplianceAutomation provider.
1622
+ * @param options The options parameters.
1623
+ */
1624
+ _list(options) {
1625
+ return this.client.sendOperationRequest({ options }, listOperationSpec$2);
1626
+ }
1627
+ /**
1628
+ * ListNext
1629
+ * @param nextLink The nextLink from the previous successful call to the List method.
1630
+ * @param options The options parameters.
1631
+ */
1632
+ _listNext(nextLink, options) {
1633
+ return this.client.sendOperationRequest({ nextLink, options }, listNextOperationSpec$2);
1634
+ }
1635
+ }
1636
+ // Operation Specifications
1637
+ const serializer$4 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
1638
+ const listOperationSpec$2 = {
1639
+ path: "/providers/Microsoft.AppComplianceAutomation/operations",
1640
+ httpMethod: "GET",
1641
+ responses: {
1642
+ 200: {
1643
+ bodyMapper: OperationListResult
1644
+ },
1645
+ default: {
1646
+ bodyMapper: ErrorResponse
1647
+ }
1648
+ },
1649
+ queryParameters: [apiVersion],
1650
+ urlParameters: [$host],
1651
+ headerParameters: [accept],
1652
+ serializer: serializer$4
1653
+ };
1654
+ const listNextOperationSpec$2 = {
1655
+ path: "{nextLink}",
1656
+ httpMethod: "GET",
1657
+ responses: {
1658
+ 200: {
1659
+ bodyMapper: OperationListResult
1660
+ },
1661
+ default: {
1662
+ bodyMapper: ErrorResponse
1663
+ }
1664
+ },
1665
+ queryParameters: [apiVersion],
1666
+ urlParameters: [$host, nextLink],
1667
+ headerParameters: [accept],
1668
+ serializer: serializer$4
1669
+ };
1670
+
1671
+ /*
1672
+ * Copyright (c) Microsoft Corporation.
1673
+ * Licensed under the MIT License.
1674
+ *
1675
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1676
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1677
+ */
1678
+ /// <reference lib="esnext.asynciterable" />
1679
+ /** Class containing Reports operations. */
1680
+ class ReportsImpl {
1681
+ /**
1682
+ * Initialize a new instance of the class Reports class.
1683
+ * @param client Reference to the service client
1684
+ */
1685
+ constructor(client) {
1686
+ this.client = client;
1687
+ }
1688
+ /**
1689
+ * Get the AppComplianceAutomation report list for the tenant.
1690
+ * @param options The options parameters.
1691
+ */
1692
+ list(options) {
1693
+ const iter = this.listPagingAll(options);
1694
+ return {
1695
+ next() {
1696
+ return iter.next();
1697
+ },
1698
+ [Symbol.asyncIterator]() {
1699
+ return this;
1700
+ },
1701
+ byPage: () => {
1702
+ return this.listPagingPage(options);
1703
+ }
1704
+ };
1705
+ }
1706
+ listPagingPage(options) {
1707
+ return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
1708
+ let result = yield tslib.__await(this._list(options));
1709
+ yield yield tslib.__await(result.value || []);
1710
+ let continuationToken = result.nextLink;
1711
+ while (continuationToken) {
1712
+ result = yield tslib.__await(this._listNext(continuationToken, options));
1713
+ continuationToken = result.nextLink;
1714
+ yield yield tslib.__await(result.value || []);
1715
+ }
1716
+ });
1717
+ }
1718
+ listPagingAll(options) {
1719
+ return tslib.__asyncGenerator(this, arguments, function* listPagingAll_1() {
1720
+ var e_1, _a;
1721
+ try {
1722
+ for (var _b = tslib.__asyncValues(this.listPagingPage(options)), _c; _c = yield tslib.__await(_b.next()), !_c.done;) {
1723
+ const page = _c.value;
1724
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
1725
+ }
1726
+ }
1727
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
1728
+ finally {
1729
+ try {
1730
+ if (_c && !_c.done && (_a = _b.return)) yield tslib.__await(_a.call(_b));
1731
+ }
1732
+ finally { if (e_1) throw e_1.error; }
1733
+ }
1734
+ });
1735
+ }
1736
+ /**
1737
+ * Get the AppComplianceAutomation report list for the tenant.
1738
+ * @param options The options parameters.
1739
+ */
1740
+ _list(options) {
1741
+ return this.client.sendOperationRequest({ options }, listOperationSpec$1);
1742
+ }
1743
+ /**
1744
+ * ListNext
1745
+ * @param nextLink The nextLink from the previous successful call to the List method.
1746
+ * @param options The options parameters.
1747
+ */
1748
+ _listNext(nextLink, options) {
1749
+ return this.client.sendOperationRequest({ nextLink, options }, listNextOperationSpec$1);
1750
+ }
1751
+ }
1752
+ // Operation Specifications
1753
+ const serializer$3 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
1754
+ const listOperationSpec$1 = {
1755
+ path: "/providers/Microsoft.AppComplianceAutomation/reports",
1756
+ httpMethod: "GET",
1757
+ responses: {
1758
+ 200: {
1759
+ bodyMapper: ReportResourceList
1760
+ },
1761
+ default: {
1762
+ bodyMapper: ErrorResponse
1763
+ }
1764
+ },
1765
+ queryParameters: [
1766
+ apiVersion,
1767
+ skipToken,
1768
+ top,
1769
+ select,
1770
+ offerGuid,
1771
+ reportCreatorTenantId
1772
+ ],
1773
+ urlParameters: [$host],
1774
+ headerParameters: [accept],
1775
+ serializer: serializer$3
1776
+ };
1777
+ const listNextOperationSpec$1 = {
1778
+ path: "{nextLink}",
1779
+ httpMethod: "GET",
1780
+ responses: {
1781
+ 200: {
1782
+ bodyMapper: ReportResourceList
1783
+ },
1784
+ default: {
1785
+ bodyMapper: ErrorResponse
1786
+ }
1787
+ },
1788
+ queryParameters: [
1789
+ apiVersion,
1790
+ skipToken,
1791
+ top,
1792
+ select,
1793
+ offerGuid,
1794
+ reportCreatorTenantId
1795
+ ],
1796
+ urlParameters: [$host, nextLink],
1797
+ headerParameters: [accept],
1798
+ serializer: serializer$3
1799
+ };
1800
+
1801
+ /*
1802
+ * Copyright (c) Microsoft Corporation.
1803
+ * Licensed under the MIT License.
1804
+ *
1805
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1806
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1807
+ */
1808
+ class LroImpl {
1809
+ constructor(sendOperationFn, args, spec, requestPath = spec.path, requestMethod = spec.httpMethod) {
1810
+ this.sendOperationFn = sendOperationFn;
1811
+ this.args = args;
1812
+ this.spec = spec;
1813
+ this.requestPath = requestPath;
1814
+ this.requestMethod = requestMethod;
1815
+ }
1816
+ sendInitialRequest() {
1817
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1818
+ return this.sendOperationFn(this.args, this.spec);
1819
+ });
1820
+ }
1821
+ sendPollRequest(path) {
1822
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1823
+ const _a = this.spec, restSpec = tslib.__rest(_a, ["requestBody"]);
1824
+ return this.sendOperationFn(this.args, Object.assign(Object.assign({}, restSpec), { path, httpMethod: "GET" }));
1825
+ });
1826
+ }
1827
+ }
1828
+
1829
+ /*
1830
+ * Copyright (c) Microsoft Corporation.
1831
+ * Licensed under the MIT License.
1832
+ *
1833
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1834
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1835
+ */
1836
+ /** Class containing Report operations. */
1837
+ class ReportImpl {
1838
+ /**
1839
+ * Initialize a new instance of the class Report class.
1840
+ * @param client Reference to the service client
1841
+ */
1842
+ constructor(client) {
1843
+ this.client = client;
1844
+ }
1845
+ /**
1846
+ * Get the AppComplianceAutomation report and its properties.
1847
+ * @param reportName Report Name.
1848
+ * @param options The options parameters.
1849
+ */
1850
+ get(reportName, options) {
1851
+ return this.client.sendOperationRequest({ reportName, options }, getOperationSpec$1);
1852
+ }
1853
+ /**
1854
+ * Create a new AppComplianceAutomation report or update an exiting AppComplianceAutomation report.
1855
+ * @param reportName Report Name.
1856
+ * @param parameters Parameters for the create or update operation
1857
+ * @param options The options parameters.
1858
+ */
1859
+ beginCreateOrUpdate(reportName, parameters, options) {
1860
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1861
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1862
+ return this.client.sendOperationRequest(args, spec);
1863
+ });
1864
+ const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1865
+ var _a;
1866
+ let currentRawResponse = undefined;
1867
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1868
+ const callback = (rawResponse, flatResponse) => {
1869
+ currentRawResponse = rawResponse;
1870
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1871
+ };
1872
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1873
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1874
+ return {
1875
+ flatResponse,
1876
+ rawResponse: {
1877
+ statusCode: currentRawResponse.status,
1878
+ body: currentRawResponse.parsedBody,
1879
+ headers: currentRawResponse.headers.toJSON()
1880
+ }
1881
+ };
1882
+ });
1883
+ const lro = new LroImpl(sendOperation, { reportName, parameters, options }, createOrUpdateOperationSpec);
1884
+ const poller = new coreLro.LroEngine(lro, {
1885
+ resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1886
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1887
+ lroResourceLocationConfig: "azure-async-operation"
1888
+ });
1889
+ yield poller.poll();
1890
+ return poller;
1891
+ });
1892
+ }
1893
+ /**
1894
+ * Create a new AppComplianceAutomation report or update an exiting AppComplianceAutomation report.
1895
+ * @param reportName Report Name.
1896
+ * @param parameters Parameters for the create or update operation
1897
+ * @param options The options parameters.
1898
+ */
1899
+ beginCreateOrUpdateAndWait(reportName, parameters, options) {
1900
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1901
+ const poller = yield this.beginCreateOrUpdate(reportName, parameters, options);
1902
+ return poller.pollUntilDone();
1903
+ });
1904
+ }
1905
+ /**
1906
+ * Update an exiting AppComplianceAutomation report.
1907
+ * @param reportName Report Name.
1908
+ * @param parameters Parameters for the create or update operation
1909
+ * @param options The options parameters.
1910
+ */
1911
+ beginUpdate(reportName, parameters, options) {
1912
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1913
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1914
+ return this.client.sendOperationRequest(args, spec);
1915
+ });
1916
+ const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1917
+ var _a;
1918
+ let currentRawResponse = undefined;
1919
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1920
+ const callback = (rawResponse, flatResponse) => {
1921
+ currentRawResponse = rawResponse;
1922
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1923
+ };
1924
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1925
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1926
+ return {
1927
+ flatResponse,
1928
+ rawResponse: {
1929
+ statusCode: currentRawResponse.status,
1930
+ body: currentRawResponse.parsedBody,
1931
+ headers: currentRawResponse.headers.toJSON()
1932
+ }
1933
+ };
1934
+ });
1935
+ const lro = new LroImpl(sendOperation, { reportName, parameters, options }, updateOperationSpec);
1936
+ const poller = new coreLro.LroEngine(lro, {
1937
+ resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1938
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1939
+ lroResourceLocationConfig: "azure-async-operation"
1940
+ });
1941
+ yield poller.poll();
1942
+ return poller;
1943
+ });
1944
+ }
1945
+ /**
1946
+ * Update an exiting AppComplianceAutomation report.
1947
+ * @param reportName Report Name.
1948
+ * @param parameters Parameters for the create or update operation
1949
+ * @param options The options parameters.
1950
+ */
1951
+ beginUpdateAndWait(reportName, parameters, options) {
1952
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1953
+ const poller = yield this.beginUpdate(reportName, parameters, options);
1954
+ return poller.pollUntilDone();
1955
+ });
1956
+ }
1957
+ /**
1958
+ * Delete an AppComplianceAutomation report.
1959
+ * @param reportName Report Name.
1960
+ * @param options The options parameters.
1961
+ */
1962
+ beginDelete(reportName, options) {
1963
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1964
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1965
+ return this.client.sendOperationRequest(args, spec);
1966
+ });
1967
+ const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1968
+ var _a;
1969
+ let currentRawResponse = undefined;
1970
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1971
+ const callback = (rawResponse, flatResponse) => {
1972
+ currentRawResponse = rawResponse;
1973
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1974
+ };
1975
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1976
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1977
+ return {
1978
+ flatResponse,
1979
+ rawResponse: {
1980
+ statusCode: currentRawResponse.status,
1981
+ body: currentRawResponse.parsedBody,
1982
+ headers: currentRawResponse.headers.toJSON()
1983
+ }
1984
+ };
1985
+ });
1986
+ const lro = new LroImpl(sendOperation, { reportName, options }, deleteOperationSpec);
1987
+ const poller = new coreLro.LroEngine(lro, {
1988
+ resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1989
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1990
+ lroResourceLocationConfig: "azure-async-operation"
1991
+ });
1992
+ yield poller.poll();
1993
+ return poller;
1994
+ });
1995
+ }
1996
+ /**
1997
+ * Delete an AppComplianceAutomation report.
1998
+ * @param reportName Report Name.
1999
+ * @param options The options parameters.
2000
+ */
2001
+ beginDeleteAndWait(reportName, options) {
2002
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2003
+ const poller = yield this.beginDelete(reportName, options);
2004
+ return poller.pollUntilDone();
2005
+ });
2006
+ }
2007
+ }
2008
+ // Operation Specifications
2009
+ const serializer$2 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2010
+ const getOperationSpec$1 = {
2011
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}",
2012
+ httpMethod: "GET",
2013
+ responses: {
2014
+ 200: {
2015
+ bodyMapper: ReportResource
2016
+ },
2017
+ default: {
2018
+ bodyMapper: ErrorResponse
2019
+ }
2020
+ },
2021
+ queryParameters: [apiVersion],
2022
+ urlParameters: [$host, reportName],
2023
+ headerParameters: [accept],
2024
+ serializer: serializer$2
2025
+ };
2026
+ const createOrUpdateOperationSpec = {
2027
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}",
2028
+ httpMethod: "PUT",
2029
+ responses: {
2030
+ 200: {
2031
+ bodyMapper: ReportResource
2032
+ },
2033
+ 201: {
2034
+ bodyMapper: ReportResource
2035
+ },
2036
+ 202: {
2037
+ bodyMapper: ReportResource
2038
+ },
2039
+ 204: {
2040
+ bodyMapper: ReportResource
2041
+ },
2042
+ default: {
2043
+ bodyMapper: ErrorResponse
2044
+ }
2045
+ },
2046
+ requestBody: parameters,
2047
+ queryParameters: [apiVersion],
2048
+ urlParameters: [$host, reportName],
2049
+ headerParameters: [accept, contentType],
2050
+ mediaType: "json",
2051
+ serializer: serializer$2
2052
+ };
2053
+ const updateOperationSpec = {
2054
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}",
2055
+ httpMethod: "PATCH",
2056
+ responses: {
2057
+ 200: {
2058
+ bodyMapper: ReportResource
2059
+ },
2060
+ 201: {
2061
+ bodyMapper: ReportResource
2062
+ },
2063
+ 202: {
2064
+ bodyMapper: ReportResource
2065
+ },
2066
+ 204: {
2067
+ bodyMapper: ReportResource
2068
+ },
2069
+ default: {
2070
+ bodyMapper: ErrorResponse
2071
+ }
2072
+ },
2073
+ requestBody: parameters1,
2074
+ queryParameters: [apiVersion],
2075
+ urlParameters: [$host, reportName],
2076
+ headerParameters: [accept, contentType],
2077
+ mediaType: "json",
2078
+ serializer: serializer$2
2079
+ };
2080
+ const deleteOperationSpec = {
2081
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}",
2082
+ httpMethod: "DELETE",
2083
+ responses: {
2084
+ 200: {},
2085
+ 201: {},
2086
+ 202: {},
2087
+ 204: {},
2088
+ default: {
2089
+ bodyMapper: ErrorResponse
2090
+ }
2091
+ },
2092
+ queryParameters: [apiVersion],
2093
+ urlParameters: [$host, reportName],
2094
+ headerParameters: [accept],
2095
+ serializer: serializer$2
2096
+ };
2097
+
2098
+ /*
2099
+ * Copyright (c) Microsoft Corporation.
2100
+ * Licensed under the MIT License.
2101
+ *
2102
+ * Code generated by Microsoft (R) AutoRest Code Generator.
2103
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2104
+ */
2105
+ /// <reference lib="esnext.asynciterable" />
2106
+ /** Class containing Snapshots operations. */
2107
+ class SnapshotsImpl {
2108
+ /**
2109
+ * Initialize a new instance of the class Snapshots class.
2110
+ * @param client Reference to the service client
2111
+ */
2112
+ constructor(client) {
2113
+ this.client = client;
2114
+ }
2115
+ /**
2116
+ * Get the AppComplianceAutomation snapshot list.
2117
+ * @param reportName Report Name.
2118
+ * @param options The options parameters.
2119
+ */
2120
+ list(reportName, options) {
2121
+ const iter = this.listPagingAll(reportName, options);
2122
+ return {
2123
+ next() {
2124
+ return iter.next();
2125
+ },
2126
+ [Symbol.asyncIterator]() {
2127
+ return this;
2128
+ },
2129
+ byPage: () => {
2130
+ return this.listPagingPage(reportName, options);
2131
+ }
2132
+ };
2133
+ }
2134
+ listPagingPage(reportName, options) {
2135
+ return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
2136
+ let result = yield tslib.__await(this._list(reportName, options));
2137
+ yield yield tslib.__await(result.value || []);
2138
+ let continuationToken = result.nextLink;
2139
+ while (continuationToken) {
2140
+ result = yield tslib.__await(this._listNext(reportName, continuationToken, options));
2141
+ continuationToken = result.nextLink;
2142
+ yield yield tslib.__await(result.value || []);
2143
+ }
2144
+ });
2145
+ }
2146
+ listPagingAll(reportName, options) {
2147
+ return tslib.__asyncGenerator(this, arguments, function* listPagingAll_1() {
2148
+ var e_1, _a;
2149
+ try {
2150
+ for (var _b = tslib.__asyncValues(this.listPagingPage(reportName, options)), _c; _c = yield tslib.__await(_b.next()), !_c.done;) {
2151
+ const page = _c.value;
2152
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
2153
+ }
2154
+ }
2155
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
2156
+ finally {
2157
+ try {
2158
+ if (_c && !_c.done && (_a = _b.return)) yield tslib.__await(_a.call(_b));
2159
+ }
2160
+ finally { if (e_1) throw e_1.error; }
2161
+ }
2162
+ });
2163
+ }
2164
+ /**
2165
+ * Get the AppComplianceAutomation snapshot list.
2166
+ * @param reportName Report Name.
2167
+ * @param options The options parameters.
2168
+ */
2169
+ _list(reportName, options) {
2170
+ return this.client.sendOperationRequest({ reportName, options }, listOperationSpec);
2171
+ }
2172
+ /**
2173
+ * ListNext
2174
+ * @param reportName Report Name.
2175
+ * @param nextLink The nextLink from the previous successful call to the List method.
2176
+ * @param options The options parameters.
2177
+ */
2178
+ _listNext(reportName, nextLink, options) {
2179
+ return this.client.sendOperationRequest({ reportName, nextLink, options }, listNextOperationSpec);
2180
+ }
2181
+ }
2182
+ // Operation Specifications
2183
+ const serializer$1 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2184
+ const listOperationSpec = {
2185
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}/snapshots",
2186
+ httpMethod: "GET",
2187
+ responses: {
2188
+ 200: {
2189
+ bodyMapper: SnapshotResourceList
2190
+ },
2191
+ default: {
2192
+ bodyMapper: ErrorResponse
2193
+ }
2194
+ },
2195
+ queryParameters: [
2196
+ apiVersion,
2197
+ skipToken,
2198
+ top,
2199
+ select,
2200
+ offerGuid,
2201
+ reportCreatorTenantId
2202
+ ],
2203
+ urlParameters: [$host, reportName],
2204
+ headerParameters: [accept],
2205
+ serializer: serializer$1
2206
+ };
2207
+ const listNextOperationSpec = {
2208
+ path: "{nextLink}",
2209
+ httpMethod: "GET",
2210
+ responses: {
2211
+ 200: {
2212
+ bodyMapper: SnapshotResourceList
2213
+ },
2214
+ default: {
2215
+ bodyMapper: ErrorResponse
2216
+ }
2217
+ },
2218
+ queryParameters: [
2219
+ apiVersion,
2220
+ skipToken,
2221
+ top,
2222
+ select,
2223
+ offerGuid,
2224
+ reportCreatorTenantId
2225
+ ],
2226
+ urlParameters: [$host, nextLink, reportName],
2227
+ headerParameters: [accept],
2228
+ serializer: serializer$1
2229
+ };
2230
+
2231
+ /*
2232
+ * Copyright (c) Microsoft Corporation.
2233
+ * Licensed under the MIT License.
2234
+ *
2235
+ * Code generated by Microsoft (R) AutoRest Code Generator.
2236
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2237
+ */
2238
+ /** Class containing Snapshot operations. */
2239
+ class SnapshotImpl {
2240
+ /**
2241
+ * Initialize a new instance of the class Snapshot class.
2242
+ * @param client Reference to the service client
2243
+ */
2244
+ constructor(client) {
2245
+ this.client = client;
2246
+ }
2247
+ /**
2248
+ * Get the AppComplianceAutomation snapshot and its properties.
2249
+ * @param reportName Report Name.
2250
+ * @param snapshotName Snapshot Name.
2251
+ * @param options The options parameters.
2252
+ */
2253
+ get(reportName, snapshotName, options) {
2254
+ return this.client.sendOperationRequest({ reportName, snapshotName, options }, getOperationSpec);
2255
+ }
2256
+ /**
2257
+ * Download compliance needs from snapshot, like: Compliance Report, Resource List.
2258
+ * @param reportName Report Name.
2259
+ * @param snapshotName Snapshot Name.
2260
+ * @param parameters Parameters for the query operation
2261
+ * @param options The options parameters.
2262
+ */
2263
+ beginDownload(reportName, snapshotName, parameters, options) {
2264
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2265
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2266
+ return this.client.sendOperationRequest(args, spec);
2267
+ });
2268
+ const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2269
+ var _a;
2270
+ let currentRawResponse = undefined;
2271
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
2272
+ const callback = (rawResponse, flatResponse) => {
2273
+ currentRawResponse = rawResponse;
2274
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
2275
+ };
2276
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
2277
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
2278
+ return {
2279
+ flatResponse,
2280
+ rawResponse: {
2281
+ statusCode: currentRawResponse.status,
2282
+ body: currentRawResponse.parsedBody,
2283
+ headers: currentRawResponse.headers.toJSON()
2284
+ }
2285
+ };
2286
+ });
2287
+ const lro = new LroImpl(sendOperation, { reportName, snapshotName, parameters, options }, downloadOperationSpec);
2288
+ const poller = new coreLro.LroEngine(lro, {
2289
+ resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2290
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
2291
+ lroResourceLocationConfig: "azure-async-operation"
2292
+ });
2293
+ yield poller.poll();
2294
+ return poller;
2295
+ });
2296
+ }
2297
+ /**
2298
+ * Download compliance needs from snapshot, like: Compliance Report, Resource List.
2299
+ * @param reportName Report Name.
2300
+ * @param snapshotName Snapshot Name.
2301
+ * @param parameters Parameters for the query operation
2302
+ * @param options The options parameters.
2303
+ */
2304
+ beginDownloadAndWait(reportName, snapshotName, parameters, options) {
2305
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2306
+ const poller = yield this.beginDownload(reportName, snapshotName, parameters, options);
2307
+ return poller.pollUntilDone();
2308
+ });
2309
+ }
2310
+ }
2311
+ // Operation Specifications
2312
+ const serializer = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2313
+ const getOperationSpec = {
2314
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}/snapshots/{snapshotName}",
2315
+ httpMethod: "GET",
2316
+ responses: {
2317
+ 200: {
2318
+ bodyMapper: SnapshotResource
2319
+ },
2320
+ default: {
2321
+ bodyMapper: ErrorResponse
2322
+ }
2323
+ },
2324
+ queryParameters: [apiVersion],
2325
+ urlParameters: [
2326
+ $host,
2327
+ reportName,
2328
+ snapshotName
2329
+ ],
2330
+ headerParameters: [accept],
2331
+ serializer
2332
+ };
2333
+ const downloadOperationSpec = {
2334
+ path: "/providers/Microsoft.AppComplianceAutomation/reports/{reportName}/snapshots/{snapshotName}/download",
2335
+ httpMethod: "POST",
2336
+ responses: {
2337
+ 200: {
2338
+ bodyMapper: DownloadResponse
2339
+ },
2340
+ 201: {
2341
+ bodyMapper: DownloadResponse
2342
+ },
2343
+ 202: {
2344
+ bodyMapper: DownloadResponse
2345
+ },
2346
+ 204: {
2347
+ bodyMapper: DownloadResponse
2348
+ },
2349
+ default: {
2350
+ bodyMapper: ErrorResponse
2351
+ }
2352
+ },
2353
+ requestBody: parameters2,
2354
+ queryParameters: [apiVersion],
2355
+ urlParameters: [
2356
+ $host,
2357
+ reportName,
2358
+ snapshotName
2359
+ ],
2360
+ headerParameters: [accept, contentType],
2361
+ mediaType: "json",
2362
+ serializer
2363
+ };
2364
+
2365
+ /*
2366
+ * Copyright (c) Microsoft Corporation.
2367
+ * Licensed under the MIT License.
2368
+ *
2369
+ * Code generated by Microsoft (R) AutoRest Code Generator.
2370
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2371
+ */
2372
+ class AppComplianceAutomationToolForMicrosoft365 extends coreClient__namespace.ServiceClient {
2373
+ /**
2374
+ * Initializes a new instance of the AppComplianceAutomationToolForMicrosoft365 class.
2375
+ * @param credentials Subscription credentials which uniquely identify client subscription.
2376
+ * @param options The parameter options
2377
+ */
2378
+ constructor(credentials, options) {
2379
+ var _a, _b;
2380
+ if (credentials === undefined) {
2381
+ throw new Error("'credentials' cannot be null");
2382
+ }
2383
+ // Initializing default values for options
2384
+ if (!options) {
2385
+ options = {};
2386
+ }
2387
+ const defaults = {
2388
+ requestContentType: "application/json; charset=utf-8",
2389
+ credential: credentials
2390
+ };
2391
+ const packageDetails = `azsdk-js-arm-appcomplianceautomation/1.0.0-beta.1`;
2392
+ const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
2393
+ ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
2394
+ : `${packageDetails}`;
2395
+ if (!options.credentialScopes) {
2396
+ options.credentialScopes = ["https://management.azure.com/.default"];
2397
+ }
2398
+ const optionsWithDefaults = Object.assign(Object.assign(Object.assign({}, defaults), options), { userAgentOptions: {
2399
+ userAgentPrefix
2400
+ }, baseUri: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" });
2401
+ super(optionsWithDefaults);
2402
+ let bearerTokenAuthenticationPolicyFound = false;
2403
+ if ((options === null || options === void 0 ? void 0 : options.pipeline) && options.pipeline.getOrderedPolicies().length > 0) {
2404
+ const pipelinePolicies = options.pipeline.getOrderedPolicies();
2405
+ bearerTokenAuthenticationPolicyFound = pipelinePolicies.some((pipelinePolicy) => pipelinePolicy.name ===
2406
+ coreRestPipeline__namespace.bearerTokenAuthenticationPolicyName);
2407
+ }
2408
+ if (!options ||
2409
+ !options.pipeline ||
2410
+ options.pipeline.getOrderedPolicies().length == 0 ||
2411
+ !bearerTokenAuthenticationPolicyFound) {
2412
+ this.pipeline.removePolicy({
2413
+ name: coreRestPipeline__namespace.bearerTokenAuthenticationPolicyName
2414
+ });
2415
+ this.pipeline.addPolicy(coreRestPipeline__namespace.bearerTokenAuthenticationPolicy({
2416
+ credential: credentials,
2417
+ scopes: `${optionsWithDefaults.credentialScopes}`,
2418
+ challengeCallbacks: {
2419
+ authorizeRequestOnChallenge: coreClient__namespace.authorizeRequestOnClaimChallenge
2420
+ }
2421
+ }));
2422
+ }
2423
+ // Assigning values to Constant parameters
2424
+ this.$host = options.$host || "https://management.azure.com";
2425
+ this.apiVersion = options.apiVersion || "2022-11-16-preview";
2426
+ this.operations = new OperationsImpl(this);
2427
+ this.reports = new ReportsImpl(this);
2428
+ this.report = new ReportImpl(this);
2429
+ this.snapshots = new SnapshotsImpl(this);
2430
+ this.snapshot = new SnapshotImpl(this);
2431
+ this.addCustomApiVersionPolicy(options.apiVersion);
2432
+ }
2433
+ /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */
2434
+ addCustomApiVersionPolicy(apiVersion) {
2435
+ if (!apiVersion) {
2436
+ return;
2437
+ }
2438
+ const apiVersionPolicy = {
2439
+ name: "CustomApiVersionPolicy",
2440
+ sendRequest(request, next) {
2441
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2442
+ const param = request.url.split("?");
2443
+ if (param.length > 1) {
2444
+ const newParams = param[1].split("&").map((item) => {
2445
+ if (item.indexOf("api-version") > -1) {
2446
+ return "api-version=" + apiVersion;
2447
+ }
2448
+ else {
2449
+ return item;
2450
+ }
2451
+ });
2452
+ request.url = param[0] + "?" + newParams.join("&");
2453
+ }
2454
+ return next(request);
2455
+ });
2456
+ }
2457
+ };
2458
+ this.pipeline.addPolicy(apiVersionPolicy);
2459
+ }
2460
+ }
2461
+
2462
+ exports.AppComplianceAutomationToolForMicrosoft365 = AppComplianceAutomationToolForMicrosoft365;
2463
+ //# sourceMappingURL=index.js.map