@azure/arm-selfhelp 2.0.0-beta.1 → 2.0.0-beta.3

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 (174) hide show
  1. package/CHANGELOG.md +214 -1
  2. package/LICENSE +1 -1
  3. package/README.md +3 -2
  4. package/dist/index.js +1679 -907
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.js +1 -1
  7. package/dist/index.min.js.map +1 -1
  8. package/dist-esm/samples-dev/checkNameAvailabilityPostSample.js +7 -7
  9. package/dist-esm/samples-dev/checkNameAvailabilityPostSample.js.map +1 -1
  10. package/dist-esm/samples-dev/diagnosticsCreateSample.js +3 -3
  11. package/dist-esm/samples-dev/diagnosticsGetSample.js +1 -1
  12. package/dist-esm/samples-dev/discoverySolutionListSample.js +6 -41
  13. package/dist-esm/samples-dev/discoverySolutionListSample.js.map +1 -1
  14. package/dist-esm/samples-dev/discoverySolutionNlpSubscriptionScopePostSample.d.ts +2 -0
  15. package/dist-esm/samples-dev/discoverySolutionNlpSubscriptionScopePostSample.d.ts.map +1 -0
  16. package/dist-esm/samples-dev/discoverySolutionNlpSubscriptionScopePostSample.js +45 -0
  17. package/dist-esm/samples-dev/discoverySolutionNlpSubscriptionScopePostSample.js.map +1 -0
  18. package/dist-esm/samples-dev/discoverySolutionNlpTenantScopePostSample.d.ts +2 -0
  19. package/dist-esm/samples-dev/discoverySolutionNlpTenantScopePostSample.d.ts.map +1 -0
  20. package/dist-esm/samples-dev/discoverySolutionNlpTenantScopePostSample.js +43 -0
  21. package/dist-esm/samples-dev/discoverySolutionNlpTenantScopePostSample.js.map +1 -0
  22. package/dist-esm/samples-dev/operationsListSample.js +5 -3
  23. package/dist-esm/samples-dev/operationsListSample.js.map +1 -1
  24. package/dist-esm/samples-dev/simplifiedSolutionsCreateSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/simplifiedSolutionsCreateSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/simplifiedSolutionsCreateSample.js +46 -0
  27. package/dist-esm/samples-dev/simplifiedSolutionsCreateSample.js.map +1 -0
  28. package/dist-esm/samples-dev/simplifiedSolutionsGetSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/simplifiedSolutionsGetSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/simplifiedSolutionsGetSample.js +37 -0
  31. package/dist-esm/samples-dev/simplifiedSolutionsGetSample.js.map +1 -0
  32. package/dist-esm/samples-dev/solutionCreateSample.js +8 -10
  33. package/dist-esm/samples-dev/solutionCreateSample.js.map +1 -1
  34. package/dist-esm/samples-dev/solutionGetSample.js +1 -1
  35. package/dist-esm/samples-dev/solutionSelfHelpGetSample.d.ts +2 -0
  36. package/dist-esm/samples-dev/solutionSelfHelpGetSample.d.ts.map +1 -0
  37. package/dist-esm/samples-dev/solutionSelfHelpGetSample.js +36 -0
  38. package/dist-esm/samples-dev/solutionSelfHelpGetSample.js.map +1 -0
  39. package/dist-esm/samples-dev/solutionUpdateSample.js +1 -1
  40. package/dist-esm/samples-dev/solutionWarmUpSample.d.ts +2 -0
  41. package/dist-esm/samples-dev/solutionWarmUpSample.d.ts.map +1 -0
  42. package/dist-esm/samples-dev/solutionWarmUpSample.js +37 -0
  43. package/dist-esm/samples-dev/solutionWarmUpSample.js.map +1 -0
  44. package/dist-esm/samples-dev/troubleshootersContinueSample.js +6 -6
  45. package/dist-esm/samples-dev/troubleshootersContinueSample.js.map +1 -1
  46. package/dist-esm/samples-dev/troubleshootersCreateSample.js +7 -7
  47. package/dist-esm/samples-dev/troubleshootersCreateSample.js.map +1 -1
  48. package/dist-esm/samples-dev/troubleshootersEndSample.js +1 -1
  49. package/dist-esm/samples-dev/troubleshootersGetSample.js +1 -1
  50. package/dist-esm/samples-dev/troubleshootersRestartSample.js +1 -1
  51. package/dist-esm/src/helpRP.d.ts +8 -1
  52. package/dist-esm/src/helpRP.d.ts.map +1 -1
  53. package/dist-esm/src/helpRP.js +25 -15
  54. package/dist-esm/src/helpRP.js.map +1 -1
  55. package/dist-esm/src/lroImpl.js +1 -1
  56. package/dist-esm/src/models/index.d.ts +350 -89
  57. package/dist-esm/src/models/index.d.ts.map +1 -1
  58. package/dist-esm/src/models/index.js +49 -19
  59. package/dist-esm/src/models/index.js.map +1 -1
  60. package/dist-esm/src/models/mappers.d.ts +10 -2
  61. package/dist-esm/src/models/mappers.d.ts.map +1 -1
  62. package/dist-esm/src/models/mappers.js +947 -590
  63. package/dist-esm/src/models/mappers.js.map +1 -1
  64. package/dist-esm/src/models/parameters.d.ts +6 -0
  65. package/dist-esm/src/models/parameters.d.ts.map +1 -1
  66. package/dist-esm/src/models/parameters.js +95 -44
  67. package/dist-esm/src/models/parameters.js.map +1 -1
  68. package/dist-esm/src/operations/checkNameAvailability.d.ts +3 -2
  69. package/dist-esm/src/operations/checkNameAvailability.d.ts.map +1 -1
  70. package/dist-esm/src/operations/checkNameAvailability.js +7 -6
  71. package/dist-esm/src/operations/checkNameAvailability.js.map +1 -1
  72. package/dist-esm/src/operations/diagnostics.d.ts +15 -16
  73. package/dist-esm/src/operations/diagnostics.d.ts.map +1 -1
  74. package/dist-esm/src/operations/diagnostics.js +33 -34
  75. package/dist-esm/src/operations/diagnostics.js.map +1 -1
  76. package/dist-esm/src/operations/discoverySolution.d.ts +5 -13
  77. package/dist-esm/src/operations/discoverySolution.d.ts.map +1 -1
  78. package/dist-esm/src/operations/discoverySolution.js +29 -37
  79. package/dist-esm/src/operations/discoverySolution.js.map +1 -1
  80. package/dist-esm/src/operations/discoverySolutionNLPSubscriptionScope.d.ts +19 -0
  81. package/dist-esm/src/operations/discoverySolutionNLPSubscriptionScope.d.ts.map +1 -0
  82. package/dist-esm/src/operations/discoverySolutionNLPSubscriptionScope.js +49 -0
  83. package/dist-esm/src/operations/discoverySolutionNLPSubscriptionScope.js.map +1 -0
  84. package/dist-esm/src/operations/discoverySolutionNLPTenantScope.d.ts +19 -0
  85. package/dist-esm/src/operations/discoverySolutionNLPTenantScope.d.ts.map +1 -0
  86. package/dist-esm/src/operations/discoverySolutionNLPTenantScope.js +49 -0
  87. package/dist-esm/src/operations/discoverySolutionNLPTenantScope.js.map +1 -0
  88. package/dist-esm/src/operations/index.d.ts +4 -0
  89. package/dist-esm/src/operations/index.d.ts.map +1 -1
  90. package/dist-esm/src/operations/index.js +4 -0
  91. package/dist-esm/src/operations/index.js.map +1 -1
  92. package/dist-esm/src/operations/operations.js +9 -9
  93. package/dist-esm/src/operations/operations.js.map +1 -1
  94. package/dist-esm/src/operations/simplifiedSolutions.d.ts +52 -0
  95. package/dist-esm/src/operations/simplifiedSolutions.d.ts.map +1 -0
  96. package/dist-esm/src/operations/simplifiedSolutions.js +159 -0
  97. package/dist-esm/src/operations/simplifiedSolutions.js.map +1 -0
  98. package/dist-esm/src/operations/solution.d.ts +41 -37
  99. package/dist-esm/src/operations/solution.d.ts.map +1 -1
  100. package/dist-esm/src/operations/solution.js +92 -66
  101. package/dist-esm/src/operations/solution.js.map +1 -1
  102. package/dist-esm/src/operations/solutionSelfHelp.d.ts +23 -0
  103. package/dist-esm/src/operations/solutionSelfHelp.d.ts.map +1 -0
  104. package/dist-esm/src/operations/solutionSelfHelp.js +51 -0
  105. package/dist-esm/src/operations/solutionSelfHelp.js.map +1 -0
  106. package/dist-esm/src/operations/troubleshooters.d.ts +22 -19
  107. package/dist-esm/src/operations/troubleshooters.d.ts.map +1 -1
  108. package/dist-esm/src/operations/troubleshooters.js +48 -45
  109. package/dist-esm/src/operations/troubleshooters.js.map +1 -1
  110. package/dist-esm/src/operationsInterfaces/checkNameAvailability.d.ts +3 -2
  111. package/dist-esm/src/operationsInterfaces/checkNameAvailability.d.ts.map +1 -1
  112. package/dist-esm/src/operationsInterfaces/diagnostics.d.ts +15 -16
  113. package/dist-esm/src/operationsInterfaces/diagnostics.d.ts.map +1 -1
  114. package/dist-esm/src/operationsInterfaces/discoverySolution.d.ts +3 -6
  115. package/dist-esm/src/operationsInterfaces/discoverySolution.d.ts.map +1 -1
  116. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPSubscriptionScope.d.ts +11 -0
  117. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPSubscriptionScope.d.ts.map +1 -0
  118. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPSubscriptionScope.js +9 -0
  119. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPSubscriptionScope.js.map +1 -0
  120. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPTenantScope.d.ts +11 -0
  121. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPTenantScope.d.ts.map +1 -0
  122. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPTenantScope.js +9 -0
  123. package/dist-esm/src/operationsInterfaces/discoverySolutionNLPTenantScope.js.map +1 -0
  124. package/dist-esm/src/operationsInterfaces/index.d.ts +4 -0
  125. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -1
  126. package/dist-esm/src/operationsInterfaces/index.js +4 -0
  127. package/dist-esm/src/operationsInterfaces/index.js.map +1 -1
  128. package/dist-esm/src/operationsInterfaces/simplifiedSolutions.d.ts +44 -0
  129. package/dist-esm/src/operationsInterfaces/simplifiedSolutions.d.ts.map +1 -0
  130. package/dist-esm/src/operationsInterfaces/simplifiedSolutions.js +9 -0
  131. package/dist-esm/src/operationsInterfaces/simplifiedSolutions.js.map +1 -0
  132. package/dist-esm/src/operationsInterfaces/solution.d.ts +41 -37
  133. package/dist-esm/src/operationsInterfaces/solution.d.ts.map +1 -1
  134. package/dist-esm/src/operationsInterfaces/solutionSelfHelp.d.ts +15 -0
  135. package/dist-esm/src/operationsInterfaces/solutionSelfHelp.d.ts.map +1 -0
  136. package/dist-esm/src/operationsInterfaces/solutionSelfHelp.js +9 -0
  137. package/dist-esm/src/operationsInterfaces/solutionSelfHelp.js.map +1 -0
  138. package/dist-esm/src/operationsInterfaces/troubleshooters.d.ts +22 -19
  139. package/dist-esm/src/operationsInterfaces/troubleshooters.d.ts.map +1 -1
  140. package/dist-esm/src/pagingHelper.js.map +1 -1
  141. package/dist-esm/test/selfhelp_operations_test.spec.js +2 -2
  142. package/dist-esm/test/selfhelp_operations_test.spec.js.map +1 -1
  143. package/package.json +11 -11
  144. package/review/arm-selfhelp.api.md +198 -19
  145. package/src/helpRP.ts +58 -17
  146. package/src/lroImpl.ts +3 -3
  147. package/src/models/index.ts +385 -106
  148. package/src/models/mappers.ts +995 -597
  149. package/src/models/parameters.ts +105 -45
  150. package/src/operations/checkNameAvailability.ts +10 -9
  151. package/src/operations/diagnostics.ts +48 -52
  152. package/src/operations/discoverySolution.ts +31 -47
  153. package/src/operations/discoverySolutionNLPSubscriptionScope.ts +64 -0
  154. package/src/operations/discoverySolutionNLPTenantScope.ts +64 -0
  155. package/src/operations/index.ts +4 -0
  156. package/src/operations/operations.ts +16 -16
  157. package/src/operations/simplifiedSolutions.ts +216 -0
  158. package/src/operations/solution.ts +122 -89
  159. package/src/operations/solutionSelfHelp.ts +68 -0
  160. package/src/operations/troubleshooters.ts +64 -66
  161. package/src/operationsInterfaces/checkNameAvailability.ts +5 -4
  162. package/src/operationsInterfaces/diagnostics.ts +19 -20
  163. package/src/operationsInterfaces/discoverySolution.ts +4 -8
  164. package/src/operationsInterfaces/discoverySolutionNLPSubscriptionScope.ts +24 -0
  165. package/src/operationsInterfaces/discoverySolutionNLPTenantScope.ts +24 -0
  166. package/src/operationsInterfaces/index.ts +4 -0
  167. package/src/operationsInterfaces/operations.ts +1 -1
  168. package/src/operationsInterfaces/simplifiedSolutions.ts +74 -0
  169. package/src/operationsInterfaces/solution.ts +51 -42
  170. package/src/operationsInterfaces/solutionSelfHelp.ts +29 -0
  171. package/src/operationsInterfaces/troubleshooters.ts +28 -25
  172. package/src/pagingHelper.ts +1 -1
  173. package/types/arm-selfhelp.d.ts +505 -136
  174. package/types/tsdoc-metadata.json +1 -1
@@ -9,15 +9,18 @@
9
9
  import {
10
10
  OperationParameter,
11
11
  OperationURLParameter,
12
- OperationQueryParameter
12
+ OperationQueryParameter,
13
13
  } from "@azure/core-client";
14
14
  import {
15
15
  CheckNameAvailabilityRequest as CheckNameAvailabilityRequestMapper,
16
16
  DiagnosticResource as DiagnosticResourceMapper,
17
17
  SolutionResource as SolutionResourceMapper,
18
18
  SolutionPatchRequestBody as SolutionPatchRequestBodyMapper,
19
+ SolutionWarmUpRequestBody as SolutionWarmUpRequestBodyMapper,
20
+ SimplifiedSolutionsResource as SimplifiedSolutionsResourceMapper,
19
21
  TroubleshooterResource as TroubleshooterResourceMapper,
20
- ContinueRequestBody as ContinueRequestBodyMapper
22
+ ContinueRequestBody as ContinueRequestBodyMapper,
23
+ DiscoveryNlpRequest as DiscoveryNlpRequestMapper,
21
24
  } from "../models/mappers";
22
25
 
23
26
  export const accept: OperationParameter = {
@@ -27,9 +30,9 @@ export const accept: OperationParameter = {
27
30
  isConstant: true,
28
31
  serializedName: "Accept",
29
32
  type: {
30
- name: "String"
31
- }
32
- }
33
+ name: "String",
34
+ },
35
+ },
33
36
  };
34
37
 
35
38
  export const $host: OperationURLParameter = {
@@ -38,22 +41,22 @@ export const $host: OperationURLParameter = {
38
41
  serializedName: "$host",
39
42
  required: true,
40
43
  type: {
41
- name: "String"
42
- }
44
+ name: "String",
45
+ },
43
46
  },
44
- skipEncoding: true
47
+ skipEncoding: true,
45
48
  };
46
49
 
47
50
  export const apiVersion: OperationQueryParameter = {
48
51
  parameterPath: "apiVersion",
49
52
  mapper: {
50
- defaultValue: "2023-09-01-preview",
53
+ defaultValue: "2024-03-01-preview",
51
54
  isConstant: true,
52
55
  serializedName: "api-version",
53
56
  type: {
54
- name: "String"
55
- }
56
- }
57
+ name: "String",
58
+ },
59
+ },
57
60
  };
58
61
 
59
62
  export const nextLink: OperationURLParameter = {
@@ -62,10 +65,10 @@ export const nextLink: OperationURLParameter = {
62
65
  serializedName: "nextLink",
63
66
  required: true,
64
67
  type: {
65
- name: "String"
66
- }
68
+ name: "String",
69
+ },
67
70
  },
68
- skipEncoding: true
71
+ skipEncoding: true,
69
72
  };
70
73
 
71
74
  export const contentType: OperationParameter = {
@@ -75,14 +78,14 @@ export const contentType: OperationParameter = {
75
78
  isConstant: true,
76
79
  serializedName: "Content-Type",
77
80
  type: {
78
- name: "String"
79
- }
80
- }
81
+ name: "String",
82
+ },
83
+ },
81
84
  };
82
85
 
83
86
  export const checkNameAvailabilityRequest: OperationParameter = {
84
87
  parameterPath: ["options", "checkNameAvailabilityRequest"],
85
- mapper: CheckNameAvailabilityRequestMapper
88
+ mapper: CheckNameAvailabilityRequestMapper,
86
89
  };
87
90
 
88
91
  export const scope: OperationURLParameter = {
@@ -91,15 +94,15 @@ export const scope: OperationURLParameter = {
91
94
  serializedName: "scope",
92
95
  required: true,
93
96
  type: {
94
- name: "String"
95
- }
97
+ name: "String",
98
+ },
96
99
  },
97
- skipEncoding: true
100
+ skipEncoding: true,
98
101
  };
99
102
 
100
103
  export const diagnosticResourceRequest: OperationParameter = {
101
104
  parameterPath: ["options", "diagnosticResourceRequest"],
102
- mapper: DiagnosticResourceMapper
105
+ mapper: DiagnosticResourceMapper,
103
106
  };
104
107
 
105
108
  export const diagnosticsResourceName: OperationURLParameter = {
@@ -108,14 +111,14 @@ export const diagnosticsResourceName: OperationURLParameter = {
108
111
  constraints: {
109
112
  Pattern: new RegExp("^[A-Za-z0-9-+@()_]+$"),
110
113
  MaxLength: 100,
111
- MinLength: 1
114
+ MinLength: 1,
112
115
  },
113
116
  serializedName: "diagnosticsResourceName",
114
117
  required: true,
115
118
  type: {
116
- name: "String"
117
- }
118
- }
119
+ name: "String",
120
+ },
121
+ },
119
122
  };
120
123
 
121
124
  export const filter: OperationQueryParameter = {
@@ -123,10 +126,10 @@ export const filter: OperationQueryParameter = {
123
126
  mapper: {
124
127
  serializedName: "$filter",
125
128
  type: {
126
- name: "String"
127
- }
129
+ name: "String",
130
+ },
128
131
  },
129
- skipEncoding: true
132
+ skipEncoding: true,
130
133
  };
131
134
 
132
135
  export const skiptoken: OperationQueryParameter = {
@@ -134,14 +137,14 @@ export const skiptoken: OperationQueryParameter = {
134
137
  mapper: {
135
138
  serializedName: "$skiptoken",
136
139
  type: {
137
- name: "String"
138
- }
139
- }
140
+ name: "String",
141
+ },
142
+ },
140
143
  };
141
144
 
142
145
  export const solutionRequestBody: OperationParameter = {
143
146
  parameterPath: ["options", "solutionRequestBody"],
144
- mapper: SolutionResourceMapper
147
+ mapper: SolutionResourceMapper,
145
148
  };
146
149
 
147
150
  export const solutionResourceName: OperationURLParameter = {
@@ -150,24 +153,50 @@ export const solutionResourceName: OperationURLParameter = {
150
153
  constraints: {
151
154
  Pattern: new RegExp("^[A-Za-z0-9-+@()_]+$"),
152
155
  MaxLength: 100,
153
- MinLength: 1
156
+ MinLength: 1,
154
157
  },
155
158
  serializedName: "solutionResourceName",
156
159
  required: true,
157
160
  type: {
158
- name: "String"
159
- }
160
- }
161
+ name: "String",
162
+ },
163
+ },
161
164
  };
162
165
 
163
166
  export const solutionPatchRequestBody: OperationParameter = {
164
167
  parameterPath: ["options", "solutionPatchRequestBody"],
165
- mapper: SolutionPatchRequestBodyMapper
168
+ mapper: SolutionPatchRequestBodyMapper,
169
+ };
170
+
171
+ export const solutionWarmUpRequestBody: OperationParameter = {
172
+ parameterPath: ["options", "solutionWarmUpRequestBody"],
173
+ mapper: SolutionWarmUpRequestBodyMapper,
174
+ };
175
+
176
+ export const simplifiedSolutionsRequestBody: OperationParameter = {
177
+ parameterPath: ["options", "simplifiedSolutionsRequestBody"],
178
+ mapper: SimplifiedSolutionsResourceMapper,
179
+ };
180
+
181
+ export const simplifiedSolutionsResourceName: OperationURLParameter = {
182
+ parameterPath: "simplifiedSolutionsResourceName",
183
+ mapper: {
184
+ constraints: {
185
+ Pattern: new RegExp("^[A-Za-z0-9-+@()_]+$"),
186
+ MaxLength: 100,
187
+ MinLength: 1,
188
+ },
189
+ serializedName: "simplifiedSolutionsResourceName",
190
+ required: true,
191
+ type: {
192
+ name: "String",
193
+ },
194
+ },
166
195
  };
167
196
 
168
197
  export const createTroubleshooterRequestBody: OperationParameter = {
169
198
  parameterPath: ["options", "createTroubleshooterRequestBody"],
170
- mapper: TroubleshooterResourceMapper
199
+ mapper: TroubleshooterResourceMapper,
171
200
  };
172
201
 
173
202
  export const troubleshooterName: OperationURLParameter = {
@@ -176,17 +205,48 @@ export const troubleshooterName: OperationURLParameter = {
176
205
  constraints: {
177
206
  Pattern: new RegExp("([A-Za-z0-9]+(-[A-Za-z0-9]+)+)"),
178
207
  MaxLength: 100,
179
- MinLength: 1
208
+ MinLength: 1,
180
209
  },
181
210
  serializedName: "troubleshooterName",
182
211
  required: true,
183
212
  type: {
184
- name: "String"
185
- }
186
- }
213
+ name: "String",
214
+ },
215
+ },
187
216
  };
188
217
 
189
218
  export const continueRequestBody: OperationParameter = {
190
219
  parameterPath: ["options", "continueRequestBody"],
191
- mapper: ContinueRequestBodyMapper
220
+ mapper: ContinueRequestBodyMapper,
221
+ };
222
+
223
+ export const solutionId: OperationURLParameter = {
224
+ parameterPath: "solutionId",
225
+ mapper: {
226
+ constraints: {
227
+ MaxLength: 100,
228
+ MinLength: 1,
229
+ },
230
+ serializedName: "solutionId",
231
+ required: true,
232
+ type: {
233
+ name: "String",
234
+ },
235
+ },
236
+ };
237
+
238
+ export const discoverSolutionRequest: OperationParameter = {
239
+ parameterPath: ["options", "discoverSolutionRequest"],
240
+ mapper: DiscoveryNlpRequestMapper,
241
+ };
242
+
243
+ export const subscriptionId: OperationURLParameter = {
244
+ parameterPath: "subscriptionId",
245
+ mapper: {
246
+ serializedName: "subscriptionId",
247
+ required: true,
248
+ type: {
249
+ name: "Uuid",
250
+ },
251
+ },
192
252
  };
@@ -13,7 +13,7 @@ import * as Parameters from "../models/parameters";
13
13
  import { HelpRP } from "../helpRP";
14
14
  import {
15
15
  CheckNameAvailabilityPostOptionalParams,
16
- CheckNameAvailabilityPostResponse
16
+ CheckNameAvailabilityPostResponse,
17
17
  } from "../models";
18
18
 
19
19
  /** Class containing CheckNameAvailability operations. */
@@ -31,17 +31,18 @@ export class CheckNameAvailabilityImpl implements CheckNameAvailability {
31
31
  /**
32
32
  * This API is used to check the uniqueness of a resource name used for a diagnostic, troubleshooter or
33
33
  * solutions
34
- * @param scope This is an extension resource provider and only resource level extension is supported
35
- * at the moment.
34
+ * @param scope scope = resourceUri of affected resource.<br/> For example:
35
+ * /subscriptions/0d0fcd2e-c4fd-4349-8497-200edb3923c6/resourcegroups/myresourceGroup/providers/Microsoft.KeyVault/vaults/test-keyvault-non-read
36
+ *
36
37
  * @param options The options parameters.
37
38
  */
38
39
  post(
39
40
  scope: string,
40
- options?: CheckNameAvailabilityPostOptionalParams
41
+ options?: CheckNameAvailabilityPostOptionalParams,
41
42
  ): Promise<CheckNameAvailabilityPostResponse> {
42
43
  return this.client.sendOperationRequest(
43
44
  { scope, options },
44
- postOperationSpec
45
+ postOperationSpec,
45
46
  );
46
47
  }
47
48
  }
@@ -53,16 +54,16 @@ const postOperationSpec: coreClient.OperationSpec = {
53
54
  httpMethod: "POST",
54
55
  responses: {
55
56
  200: {
56
- bodyMapper: Mappers.CheckNameAvailabilityResponse
57
+ bodyMapper: Mappers.CheckNameAvailabilityResponse,
57
58
  },
58
59
  default: {
59
- bodyMapper: Mappers.ErrorResponse
60
- }
60
+ bodyMapper: Mappers.ErrorResponse,
61
+ },
61
62
  },
62
63
  requestBody: Parameters.checkNameAvailabilityRequest,
63
64
  queryParameters: [Parameters.apiVersion],
64
65
  urlParameters: [Parameters.$host, Parameters.scope],
65
66
  headerParameters: [Parameters.accept, Parameters.contentType],
66
67
  mediaType: "json",
67
- serializer
68
+ serializer,
68
69
  };
@@ -14,14 +14,14 @@ import { HelpRP } from "../helpRP";
14
14
  import {
15
15
  SimplePollerLike,
16
16
  OperationState,
17
- createHttpPoller
17
+ createHttpPoller,
18
18
  } from "@azure/core-lro";
19
19
  import { createLroSpec } from "../lroImpl";
20
20
  import {
21
21
  DiagnosticsCreateOptionalParams,
22
22
  DiagnosticsCreateResponse,
23
23
  DiagnosticsGetOptionalParams,
24
- DiagnosticsGetResponse
24
+ DiagnosticsGetResponse,
25
25
  } from "../models";
26
26
 
27
27
  /** Class containing Diagnostics operations. */
@@ -37,20 +37,19 @@ export class DiagnosticsImpl implements Diagnostics {
37
37
  }
38
38
 
39
39
  /**
40
- * Creates a diagnostic for the specific resource using solutionId and requiredInputs* from discovery
41
- * solutions. <br/>Diagnostics tells you precisely the root cause of the issue and the steps to address
42
- * it. You can get diagnostics once you discover the relevant solution for your Azure issue. <br/><br/>
43
- * <b>Note: </b> requiredInputs’ from Discovery solutions response must be passed via
44
- * ‘additionalParameters’ as an input to Diagnostics API.
45
- * @param scope This is an extension resource provider and only resource level extension is supported
46
- * at the moment.
40
+ * Creates a diagnostic for the specific resource using solutionId from discovery solutions.
41
+ * <br/>Diagnostics are powerful solutions that access product resources or other relevant data and
42
+ * provide the root cause of the issue and the steps to address the issue.<br/><br/>
43
+ * @param scope scope = resourceUri of affected resource.<br/> For example:
44
+ * /subscriptions/0d0fcd2e-c4fd-4349-8497-200edb3923c6/resourcegroups/myresourceGroup/providers/Microsoft.KeyVault/vaults/test-keyvault-non-read
45
+ *
47
46
  * @param diagnosticsResourceName Unique resource name for insight resources
48
47
  * @param options The options parameters.
49
48
  */
50
49
  async beginCreate(
51
50
  scope: string,
52
51
  diagnosticsResourceName: string,
53
- options?: DiagnosticsCreateOptionalParams
52
+ options?: DiagnosticsCreateOptionalParams,
54
53
  ): Promise<
55
54
  SimplePollerLike<
56
55
  OperationState<DiagnosticsCreateResponse>,
@@ -59,21 +58,20 @@ export class DiagnosticsImpl implements Diagnostics {
59
58
  > {
60
59
  const directSendOperation = async (
61
60
  args: coreClient.OperationArguments,
62
- spec: coreClient.OperationSpec
61
+ spec: coreClient.OperationSpec,
63
62
  ): Promise<DiagnosticsCreateResponse> => {
64
63
  return this.client.sendOperationRequest(args, spec);
65
64
  };
66
65
  const sendOperationFn = async (
67
66
  args: coreClient.OperationArguments,
68
- spec: coreClient.OperationSpec
67
+ spec: coreClient.OperationSpec,
69
68
  ) => {
70
- let currentRawResponse:
71
- | coreClient.FullOperationResponse
72
- | undefined = undefined;
69
+ let currentRawResponse: coreClient.FullOperationResponse | undefined =
70
+ undefined;
73
71
  const providedCallback = args.options?.onResponse;
74
72
  const callback: coreClient.RawResponseCallback = (
75
73
  rawResponse: coreClient.FullOperationResponse,
76
- flatResponse: unknown
74
+ flatResponse: unknown,
77
75
  ) => {
78
76
  currentRawResponse = rawResponse;
79
77
  providedCallback?.(rawResponse, flatResponse);
@@ -82,8 +80,8 @@ export class DiagnosticsImpl implements Diagnostics {
82
80
  ...args,
83
81
  options: {
84
82
  ...args.options,
85
- onResponse: callback
86
- }
83
+ onResponse: callback,
84
+ },
87
85
  };
88
86
  const flatResponse = await directSendOperation(updatedArgs, spec);
89
87
  return {
@@ -91,15 +89,15 @@ export class DiagnosticsImpl implements Diagnostics {
91
89
  rawResponse: {
92
90
  statusCode: currentRawResponse!.status,
93
91
  body: currentRawResponse!.parsedBody,
94
- headers: currentRawResponse!.headers.toJSON()
95
- }
92
+ headers: currentRawResponse!.headers.toJSON(),
93
+ },
96
94
  };
97
95
  };
98
96
 
99
97
  const lro = createLroSpec({
100
98
  sendOperationFn,
101
99
  args: { scope, diagnosticsResourceName, options },
102
- spec: createOperationSpec
100
+ spec: createOperationSpec,
103
101
  });
104
102
  const poller = await createHttpPoller<
105
103
  DiagnosticsCreateResponse,
@@ -107,51 +105,51 @@ export class DiagnosticsImpl implements Diagnostics {
107
105
  >(lro, {
108
106
  restoreFrom: options?.resumeFrom,
109
107
  intervalInMs: options?.updateIntervalInMs,
110
- resourceLocationConfig: "azure-async-operation"
108
+ resourceLocationConfig: "azure-async-operation",
111
109
  });
112
110
  await poller.poll();
113
111
  return poller;
114
112
  }
115
113
 
116
114
  /**
117
- * Creates a diagnostic for the specific resource using solutionId and requiredInputs* from discovery
118
- * solutions. <br/>Diagnostics tells you precisely the root cause of the issue and the steps to address
119
- * it. You can get diagnostics once you discover the relevant solution for your Azure issue. <br/><br/>
120
- * <b>Note: </b> requiredInputs’ from Discovery solutions response must be passed via
121
- * ‘additionalParameters’ as an input to Diagnostics API.
122
- * @param scope This is an extension resource provider and only resource level extension is supported
123
- * at the moment.
115
+ * Creates a diagnostic for the specific resource using solutionId from discovery solutions.
116
+ * <br/>Diagnostics are powerful solutions that access product resources or other relevant data and
117
+ * provide the root cause of the issue and the steps to address the issue.<br/><br/>
118
+ * @param scope scope = resourceUri of affected resource.<br/> For example:
119
+ * /subscriptions/0d0fcd2e-c4fd-4349-8497-200edb3923c6/resourcegroups/myresourceGroup/providers/Microsoft.KeyVault/vaults/test-keyvault-non-read
120
+ *
124
121
  * @param diagnosticsResourceName Unique resource name for insight resources
125
122
  * @param options The options parameters.
126
123
  */
127
124
  async beginCreateAndWait(
128
125
  scope: string,
129
126
  diagnosticsResourceName: string,
130
- options?: DiagnosticsCreateOptionalParams
127
+ options?: DiagnosticsCreateOptionalParams,
131
128
  ): Promise<DiagnosticsCreateResponse> {
132
129
  const poller = await this.beginCreate(
133
130
  scope,
134
131
  diagnosticsResourceName,
135
- options
132
+ options,
136
133
  );
137
134
  return poller.pollUntilDone();
138
135
  }
139
136
 
140
137
  /**
141
138
  * Get the diagnostics using the 'diagnosticsResourceName' you chose while creating the diagnostic.
142
- * @param scope This is an extension resource provider and only resource level extension is supported
143
- * at the moment.
139
+ * @param scope scope = resourceUri of affected resource.<br/> For example:
140
+ * /subscriptions/0d0fcd2e-c4fd-4349-8497-200edb3923c6/resourcegroups/myresourceGroup/providers/Microsoft.KeyVault/vaults/test-keyvault-non-read
141
+ *
144
142
  * @param diagnosticsResourceName Unique resource name for insight resources
145
143
  * @param options The options parameters.
146
144
  */
147
145
  get(
148
146
  scope: string,
149
147
  diagnosticsResourceName: string,
150
- options?: DiagnosticsGetOptionalParams
148
+ options?: DiagnosticsGetOptionalParams,
151
149
  ): Promise<DiagnosticsGetResponse> {
152
150
  return this.client.sendOperationRequest(
153
151
  { scope, diagnosticsResourceName, options },
154
- getOperationSpec
152
+ getOperationSpec,
155
153
  );
156
154
  }
157
155
  }
@@ -159,55 +157,53 @@ export class DiagnosticsImpl implements Diagnostics {
159
157
  const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
160
158
 
161
159
  const createOperationSpec: coreClient.OperationSpec = {
162
- path:
163
- "/{scope}/providers/Microsoft.Help/diagnostics/{diagnosticsResourceName}",
160
+ path: "/{scope}/providers/Microsoft.Help/diagnostics/{diagnosticsResourceName}",
164
161
  httpMethod: "PUT",
165
162
  responses: {
166
163
  200: {
167
- bodyMapper: Mappers.DiagnosticResource
164
+ bodyMapper: Mappers.DiagnosticResource,
168
165
  },
169
166
  201: {
170
- bodyMapper: Mappers.DiagnosticResource
167
+ bodyMapper: Mappers.DiagnosticResource,
171
168
  },
172
169
  202: {
173
- bodyMapper: Mappers.DiagnosticResource
170
+ bodyMapper: Mappers.DiagnosticResource,
174
171
  },
175
172
  204: {
176
- bodyMapper: Mappers.DiagnosticResource
173
+ bodyMapper: Mappers.DiagnosticResource,
177
174
  },
178
175
  default: {
179
- bodyMapper: Mappers.ErrorResponse
180
- }
176
+ bodyMapper: Mappers.ErrorResponse,
177
+ },
181
178
  },
182
179
  requestBody: Parameters.diagnosticResourceRequest,
183
180
  queryParameters: [Parameters.apiVersion],
184
181
  urlParameters: [
185
182
  Parameters.$host,
186
183
  Parameters.scope,
187
- Parameters.diagnosticsResourceName
184
+ Parameters.diagnosticsResourceName,
188
185
  ],
189
186
  headerParameters: [Parameters.accept, Parameters.contentType],
190
187
  mediaType: "json",
191
- serializer
188
+ serializer,
192
189
  };
193
190
  const getOperationSpec: coreClient.OperationSpec = {
194
- path:
195
- "/{scope}/providers/Microsoft.Help/diagnostics/{diagnosticsResourceName}",
191
+ path: "/{scope}/providers/Microsoft.Help/diagnostics/{diagnosticsResourceName}",
196
192
  httpMethod: "GET",
197
193
  responses: {
198
194
  200: {
199
- bodyMapper: Mappers.DiagnosticResource
195
+ bodyMapper: Mappers.DiagnosticResource,
200
196
  },
201
197
  default: {
202
- bodyMapper: Mappers.ErrorResponse
203
- }
198
+ bodyMapper: Mappers.ErrorResponse,
199
+ },
204
200
  },
205
201
  queryParameters: [Parameters.apiVersion],
206
202
  urlParameters: [
207
203
  Parameters.$host,
208
204
  Parameters.scope,
209
- Parameters.diagnosticsResourceName
205
+ Parameters.diagnosticsResourceName,
210
206
  ],
211
207
  headerParameters: [Parameters.accept],
212
- serializer
208
+ serializer,
213
209
  };