@azure/arm-extendedlocation 1.0.0-beta.1 → 1.0.0-beta.2

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 (129) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/LICENSE +1 -1
  3. package/README.md +23 -8
  4. package/dist/index.js +806 -83
  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/customLocationsCreateOrUpdateSample.d.ts +2 -0
  9. package/dist-esm/samples-dev/customLocationsCreateOrUpdateSample.d.ts.map +1 -0
  10. package/dist-esm/samples-dev/customLocationsCreateOrUpdateSample.js +42 -0
  11. package/dist-esm/samples-dev/customLocationsCreateOrUpdateSample.js.map +1 -0
  12. package/dist-esm/samples-dev/customLocationsDeleteSample.d.ts +2 -0
  13. package/dist-esm/samples-dev/customLocationsDeleteSample.d.ts.map +1 -0
  14. package/dist-esm/samples-dev/customLocationsDeleteSample.js +31 -0
  15. package/dist-esm/samples-dev/customLocationsDeleteSample.js.map +1 -0
  16. package/dist-esm/samples-dev/customLocationsFindTargetResourceGroupSample.d.ts +2 -0
  17. package/dist-esm/samples-dev/customLocationsFindTargetResourceGroupSample.d.ts.map +1 -0
  18. package/dist-esm/samples-dev/customLocationsFindTargetResourceGroupSample.js +34 -0
  19. package/dist-esm/samples-dev/customLocationsFindTargetResourceGroupSample.js.map +1 -0
  20. package/dist-esm/samples-dev/customLocationsGetSample.d.ts +2 -0
  21. package/dist-esm/samples-dev/customLocationsGetSample.d.ts.map +1 -0
  22. package/dist-esm/samples-dev/customLocationsGetSample.js +31 -0
  23. package/dist-esm/samples-dev/customLocationsGetSample.js.map +1 -0
  24. package/dist-esm/samples-dev/customLocationsListByResourceGroupSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/customLocationsListByResourceGroupSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/customLocationsListByResourceGroupSample.js +44 -0
  27. package/dist-esm/samples-dev/customLocationsListByResourceGroupSample.js.map +1 -0
  28. package/dist-esm/samples-dev/customLocationsListBySubscriptionSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/customLocationsListBySubscriptionSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/customLocationsListBySubscriptionSample.js +43 -0
  31. package/dist-esm/samples-dev/customLocationsListBySubscriptionSample.js.map +1 -0
  32. package/dist-esm/samples-dev/customLocationsListEnabledResourceTypesSample.d.ts +2 -0
  33. package/dist-esm/samples-dev/customLocationsListEnabledResourceTypesSample.d.ts.map +1 -0
  34. package/dist-esm/samples-dev/customLocationsListEnabledResourceTypesSample.js +45 -0
  35. package/dist-esm/samples-dev/customLocationsListEnabledResourceTypesSample.js.map +1 -0
  36. package/dist-esm/samples-dev/customLocationsListOperationsSample.d.ts +2 -0
  37. package/dist-esm/samples-dev/customLocationsListOperationsSample.d.ts.map +1 -0
  38. package/dist-esm/samples-dev/customLocationsListOperationsSample.js +43 -0
  39. package/dist-esm/samples-dev/customLocationsListOperationsSample.js.map +1 -0
  40. package/dist-esm/samples-dev/customLocationsUpdateSample.d.ts +2 -0
  41. package/dist-esm/samples-dev/customLocationsUpdateSample.d.ts.map +1 -0
  42. package/dist-esm/samples-dev/customLocationsUpdateSample.js +34 -0
  43. package/dist-esm/samples-dev/customLocationsUpdateSample.js.map +1 -0
  44. package/dist-esm/samples-dev/resourceSyncRulesCreateOrUpdateSample.d.ts +2 -0
  45. package/dist-esm/samples-dev/resourceSyncRulesCreateOrUpdateSample.d.ts.map +1 -0
  46. package/dist-esm/samples-dev/resourceSyncRulesCreateOrUpdateSample.js +41 -0
  47. package/dist-esm/samples-dev/resourceSyncRulesCreateOrUpdateSample.js.map +1 -0
  48. package/dist-esm/samples-dev/resourceSyncRulesDeleteSample.d.ts +2 -0
  49. package/dist-esm/samples-dev/resourceSyncRulesDeleteSample.d.ts.map +1 -0
  50. package/dist-esm/samples-dev/resourceSyncRulesDeleteSample.js +32 -0
  51. package/dist-esm/samples-dev/resourceSyncRulesDeleteSample.js.map +1 -0
  52. package/dist-esm/samples-dev/resourceSyncRulesGetSample.d.ts +2 -0
  53. package/dist-esm/samples-dev/resourceSyncRulesGetSample.d.ts.map +1 -0
  54. package/dist-esm/samples-dev/resourceSyncRulesGetSample.js +32 -0
  55. package/dist-esm/samples-dev/resourceSyncRulesGetSample.js.map +1 -0
  56. package/dist-esm/samples-dev/resourceSyncRulesListByCustomLocationIdSample.d.ts +2 -0
  57. package/dist-esm/samples-dev/resourceSyncRulesListByCustomLocationIdSample.d.ts.map +1 -0
  58. package/dist-esm/samples-dev/resourceSyncRulesListByCustomLocationIdSample.js +45 -0
  59. package/dist-esm/samples-dev/resourceSyncRulesListByCustomLocationIdSample.js.map +1 -0
  60. package/dist-esm/samples-dev/resourceSyncRulesUpdateSample.d.ts +2 -0
  61. package/dist-esm/samples-dev/resourceSyncRulesUpdateSample.d.ts.map +1 -0
  62. package/dist-esm/samples-dev/resourceSyncRulesUpdateSample.js +34 -0
  63. package/dist-esm/samples-dev/resourceSyncRulesUpdateSample.js.map +1 -0
  64. package/dist-esm/src/customLocationsManagementClient.d.ts +9 -3
  65. package/dist-esm/src/customLocationsManagementClient.d.ts.map +1 -1
  66. package/dist-esm/src/customLocationsManagementClient.js +81 -4
  67. package/dist-esm/src/customLocationsManagementClient.js.map +1 -1
  68. package/dist-esm/src/index.d.ts +0 -1
  69. package/dist-esm/src/index.d.ts.map +1 -1
  70. package/dist-esm/src/index.js +0 -1
  71. package/dist-esm/src/index.js.map +1 -1
  72. package/dist-esm/src/models/index.d.ts +172 -25
  73. package/dist-esm/src/models/index.d.ts.map +1 -1
  74. package/dist-esm/src/models/index.js +7 -0
  75. package/dist-esm/src/models/index.js.map +1 -1
  76. package/dist-esm/src/models/mappers.d.ts +8 -1
  77. package/dist-esm/src/models/mappers.d.ts.map +1 -1
  78. package/dist-esm/src/models/mappers.js +228 -29
  79. package/dist-esm/src/models/mappers.js.map +1 -1
  80. package/dist-esm/src/models/parameters.d.ts +7 -0
  81. package/dist-esm/src/models/parameters.d.ts.map +1 -1
  82. package/dist-esm/src/models/parameters.js +41 -2
  83. package/dist-esm/src/models/parameters.js.map +1 -1
  84. package/dist-esm/src/operations/customLocations.d.ts +12 -3
  85. package/dist-esm/src/operations/customLocations.d.ts.map +1 -1
  86. package/dist-esm/src/operations/customLocations.js +41 -2
  87. package/dist-esm/src/operations/customLocations.js.map +1 -1
  88. package/dist-esm/src/operations/index.d.ts +1 -0
  89. package/dist-esm/src/operations/index.d.ts.map +1 -1
  90. package/dist-esm/src/operations/index.js +1 -0
  91. package/dist-esm/src/operations/index.js.map +1 -1
  92. package/dist-esm/src/operations/resourceSyncRules.d.ts +97 -0
  93. package/dist-esm/src/operations/resourceSyncRules.d.ts.map +1 -0
  94. package/dist-esm/src/operations/resourceSyncRules.js +400 -0
  95. package/dist-esm/src/operations/resourceSyncRules.js.map +1 -0
  96. package/dist-esm/src/operationsInterfaces/customLocations.d.ts +10 -1
  97. package/dist-esm/src/operationsInterfaces/customLocations.d.ts.map +1 -1
  98. package/dist-esm/src/operationsInterfaces/index.d.ts +1 -0
  99. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -1
  100. package/dist-esm/src/operationsInterfaces/index.js +1 -0
  101. package/dist-esm/src/operationsInterfaces/index.js.map +1 -1
  102. package/dist-esm/src/operationsInterfaces/resourceSyncRules.d.ts +71 -0
  103. package/dist-esm/src/operationsInterfaces/resourceSyncRules.d.ts.map +1 -0
  104. package/dist-esm/src/operationsInterfaces/resourceSyncRules.js +9 -0
  105. package/dist-esm/src/operationsInterfaces/resourceSyncRules.js.map +1 -0
  106. package/dist-esm/test/sampleTest.js +11 -13
  107. package/dist-esm/test/sampleTest.js.map +1 -1
  108. package/package.json +54 -25
  109. package/review/arm-extendedlocation.api.md +139 -27
  110. package/rollup.config.js +6 -72
  111. package/src/customLocationsManagementClient.ts +109 -5
  112. package/src/index.ts +0 -1
  113. package/src/models/index.ts +186 -26
  114. package/src/models/mappers.ts +243 -30
  115. package/src/models/parameters.ts +53 -2
  116. package/src/operations/customLocations.ts +57 -5
  117. package/src/operations/index.ts +1 -0
  118. package/src/operations/resourceSyncRules.ts +562 -0
  119. package/src/operationsInterfaces/customLocations.ts +18 -1
  120. package/src/operationsInterfaces/index.ts +1 -0
  121. package/src/operationsInterfaces/resourceSyncRules.ts +136 -0
  122. package/tsconfig.json +19 -5
  123. package/types/arm-extendedlocation.d.ts +257 -20
  124. package/types/tsdoc-metadata.json +1 -1
  125. package/dist-esm/src/customLocationsManagementClientContext.d.ts +0 -16
  126. package/dist-esm/src/customLocationsManagementClientContext.d.ts.map +0 -1
  127. package/dist-esm/src/customLocationsManagementClientContext.js +0 -49
  128. package/dist-esm/src/customLocationsManagementClientContext.js.map +0 -1
  129. package/src/customLocationsManagementClientContext.ts +0 -70
@@ -22,7 +22,10 @@ import {
22
22
  CustomLocationsCreateOrUpdateResponse,
23
23
  CustomLocationsDeleteOptionalParams,
24
24
  CustomLocationsUpdateOptionalParams,
25
- CustomLocationsUpdateResponse
25
+ CustomLocationsUpdateResponse,
26
+ CustomLocationFindTargetResourceGroupProperties,
27
+ CustomLocationsFindTargetResourceGroupOptionalParams,
28
+ CustomLocationsFindTargetResourceGroupResponse
26
29
  } from "../models";
27
30
 
28
31
  /// <reference lib="esnext.asynciterable" />
@@ -140,4 +143,18 @@ export interface CustomLocations {
140
143
  resourceName: string,
141
144
  options?: CustomLocationsUpdateOptionalParams
142
145
  ): Promise<CustomLocationsUpdateResponse>;
146
+ /**
147
+ * Returns the target resource group associated with the resource sync rules of the Custom Location
148
+ * that match the rules passed in with the Find Target Resource Group Request.
149
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
150
+ * @param resourceName Custom Locations name.
151
+ * @param parameters Parameters of the find target resource group request.
152
+ * @param options The options parameters.
153
+ */
154
+ findTargetResourceGroup(
155
+ resourceGroupName: string,
156
+ resourceName: string,
157
+ parameters: CustomLocationFindTargetResourceGroupProperties,
158
+ options?: CustomLocationsFindTargetResourceGroupOptionalParams
159
+ ): Promise<CustomLocationsFindTargetResourceGroupResponse>;
143
160
  }
@@ -7,3 +7,4 @@
7
7
  */
8
8
 
9
9
  export * from "./customLocations";
10
+ export * from "./resourceSyncRules";
@@ -0,0 +1,136 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { PollerLike, PollOperationState } from "@azure/core-lro";
11
+ import {
12
+ ResourceSyncRule,
13
+ ResourceSyncRulesListByCustomLocationIDOptionalParams,
14
+ ResourceSyncRulesGetOptionalParams,
15
+ ResourceSyncRulesGetResponse,
16
+ ResourceSyncRulesCreateOrUpdateOptionalParams,
17
+ ResourceSyncRulesCreateOrUpdateResponse,
18
+ ResourceSyncRulesDeleteOptionalParams,
19
+ ResourceSyncRulesUpdateOptionalParams,
20
+ ResourceSyncRulesUpdateResponse
21
+ } from "../models";
22
+
23
+ /// <reference lib="esnext.asynciterable" />
24
+ /** Interface representing a ResourceSyncRules. */
25
+ export interface ResourceSyncRules {
26
+ /**
27
+ * Gets a list of Resource Sync Rules in the specified subscription. The operation returns properties
28
+ * of each Resource Sync Rule
29
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
30
+ * @param resourceName Custom Locations name.
31
+ * @param options The options parameters.
32
+ */
33
+ listByCustomLocationID(
34
+ resourceGroupName: string,
35
+ resourceName: string,
36
+ options?: ResourceSyncRulesListByCustomLocationIDOptionalParams
37
+ ): PagedAsyncIterableIterator<ResourceSyncRule>;
38
+ /**
39
+ * Gets the details of the resourceSyncRule with a specified resource group, subscription id Custom
40
+ * Location resource name and Resource Sync Rule name.
41
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
42
+ * @param resourceName Custom Locations name.
43
+ * @param childResourceName Resource Sync Rule name.
44
+ * @param options The options parameters.
45
+ */
46
+ get(
47
+ resourceGroupName: string,
48
+ resourceName: string,
49
+ childResourceName: string,
50
+ options?: ResourceSyncRulesGetOptionalParams
51
+ ): Promise<ResourceSyncRulesGetResponse>;
52
+ /**
53
+ * Creates or updates a Resource Sync Rule in the parent Custom Location, Subscription Id and Resource
54
+ * Group
55
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
56
+ * @param resourceName Custom Locations name.
57
+ * @param childResourceName Resource Sync Rule name.
58
+ * @param parameters Parameters supplied to create or update a Resource Sync Rule.
59
+ * @param options The options parameters.
60
+ */
61
+ beginCreateOrUpdate(
62
+ resourceGroupName: string,
63
+ resourceName: string,
64
+ childResourceName: string,
65
+ parameters: ResourceSyncRule,
66
+ options?: ResourceSyncRulesCreateOrUpdateOptionalParams
67
+ ): Promise<
68
+ PollerLike<
69
+ PollOperationState<ResourceSyncRulesCreateOrUpdateResponse>,
70
+ ResourceSyncRulesCreateOrUpdateResponse
71
+ >
72
+ >;
73
+ /**
74
+ * Creates or updates a Resource Sync Rule in the parent Custom Location, Subscription Id and Resource
75
+ * Group
76
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
77
+ * @param resourceName Custom Locations name.
78
+ * @param childResourceName Resource Sync Rule name.
79
+ * @param parameters Parameters supplied to create or update a Resource Sync Rule.
80
+ * @param options The options parameters.
81
+ */
82
+ beginCreateOrUpdateAndWait(
83
+ resourceGroupName: string,
84
+ resourceName: string,
85
+ childResourceName: string,
86
+ parameters: ResourceSyncRule,
87
+ options?: ResourceSyncRulesCreateOrUpdateOptionalParams
88
+ ): Promise<ResourceSyncRulesCreateOrUpdateResponse>;
89
+ /**
90
+ * Deletes the Resource Sync Rule with the specified Resource Sync Rule Name, Custom Location Resource
91
+ * Name, Resource Group, and Subscription Id.
92
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
93
+ * @param resourceName Custom Locations name.
94
+ * @param childResourceName Resource Sync Rule name.
95
+ * @param options The options parameters.
96
+ */
97
+ delete(
98
+ resourceGroupName: string,
99
+ resourceName: string,
100
+ childResourceName: string,
101
+ options?: ResourceSyncRulesDeleteOptionalParams
102
+ ): Promise<void>;
103
+ /**
104
+ * Updates a Resource Sync Rule with the specified Resource Sync Rule name in the specified Resource
105
+ * Group, Subscription and Custom Location name.
106
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
107
+ * @param resourceName Custom Locations name.
108
+ * @param childResourceName Resource Sync Rule name.
109
+ * @param options The options parameters.
110
+ */
111
+ beginUpdate(
112
+ resourceGroupName: string,
113
+ resourceName: string,
114
+ childResourceName: string,
115
+ options?: ResourceSyncRulesUpdateOptionalParams
116
+ ): Promise<
117
+ PollerLike<
118
+ PollOperationState<ResourceSyncRulesUpdateResponse>,
119
+ ResourceSyncRulesUpdateResponse
120
+ >
121
+ >;
122
+ /**
123
+ * Updates a Resource Sync Rule with the specified Resource Sync Rule name in the specified Resource
124
+ * Group, Subscription and Custom Location name.
125
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
126
+ * @param resourceName Custom Locations name.
127
+ * @param childResourceName Resource Sync Rule name.
128
+ * @param options The options parameters.
129
+ */
130
+ beginUpdateAndWait(
131
+ resourceGroupName: string,
132
+ resourceName: string,
133
+ childResourceName: string,
134
+ options?: ResourceSyncRulesUpdateOptionalParams
135
+ ): Promise<ResourceSyncRulesUpdateResponse>;
136
+ }
package/tsconfig.json CHANGED
@@ -9,11 +9,25 @@
9
9
  "esModuleInterop": true,
10
10
  "allowSyntheticDefaultImports": true,
11
11
  "forceConsistentCasingInFileNames": true,
12
- "lib": ["es6", "dom"],
12
+ "lib": [
13
+ "es6",
14
+ "dom"
15
+ ],
13
16
  "declaration": true,
14
17
  "outDir": "./dist-esm",
15
- "importHelpers": true
18
+ "importHelpers": true,
19
+ "paths": {
20
+ "@azure/arm-extendedlocation": [
21
+ "./src/index"
22
+ ]
23
+ }
16
24
  },
17
- "include": ["./src/**/*.ts", "./test/**/*.ts"],
18
- "exclude": ["node_modules"]
19
- }
25
+ "include": [
26
+ "./src/**/*.ts",
27
+ "./test/**/*.ts",
28
+ "samples-dev/**/*.ts"
29
+ ],
30
+ "exclude": [
31
+ "node_modules"
32
+ ]
33
+ }
@@ -17,7 +17,7 @@ import { PollOperationState } from '@azure/core-lro';
17
17
  export declare type CreatedByType = string;
18
18
 
19
19
  /** Custom Locations definition. */
20
- export declare type CustomLocation = TrackedResource & {
20
+ export declare interface CustomLocation extends TrackedResource {
21
21
  /** Identity for the resource. */
22
22
  identity?: Identity;
23
23
  /**
@@ -39,7 +39,29 @@ export declare type CustomLocation = TrackedResource & {
39
39
  namespace?: string;
40
40
  /** Provisioning State for the Custom Location. */
41
41
  provisioningState?: string;
42
- };
42
+ }
43
+
44
+ /** The Find Target Resource Group operation request. */
45
+ export declare interface CustomLocationFindTargetResourceGroupProperties {
46
+ /** Labels of the custom resource, this is a map of {key,value} pairs. */
47
+ labels?: {
48
+ [propertyName: string]: string;
49
+ };
50
+ }
51
+
52
+ /** The Find Target Resource Group operation response. */
53
+ export declare interface CustomLocationFindTargetResourceGroupResult {
54
+ /**
55
+ * The matching resource sync rule is the particular resource sync rule that matched the match expressions and labels and had lowest priority. This is the rule responsible for mapping the target resource to the target resource group.
56
+ * NOTE: This property will not be serialized. It can only be populated by the server.
57
+ */
58
+ readonly matchedResourceSyncRule?: string;
59
+ /**
60
+ * The target resource group of matching resource sync rule. The labels from the request will be used to find out matching resource sync rule against the selector property of the resource sync rule. The one with highest priority will be returned if there are multiple matching rules.
61
+ * NOTE: This property will not be serialized. It can only be populated by the server.
62
+ */
63
+ readonly targetResourceGroup?: string;
64
+ }
43
65
 
44
66
  /** The List Custom Locations operation response. */
45
67
  export declare interface CustomLocationListResult {
@@ -182,6 +204,15 @@ export declare interface CustomLocations {
182
204
  * @param options The options parameters.
183
205
  */
184
206
  update(resourceGroupName: string, resourceName: string, options?: CustomLocationsUpdateOptionalParams): Promise<CustomLocationsUpdateResponse>;
207
+ /**
208
+ * Returns the target resource group associated with the resource sync rules of the Custom Location
209
+ * that match the rules passed in with the Find Target Resource Group Request.
210
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
211
+ * @param resourceName Custom Locations name.
212
+ * @param parameters Parameters of the find target resource group request.
213
+ * @param options The options parameters.
214
+ */
215
+ findTargetResourceGroup(resourceGroupName: string, resourceName: string, parameters: CustomLocationFindTargetResourceGroupProperties, options?: CustomLocationsFindTargetResourceGroupOptionalParams): Promise<CustomLocationsFindTargetResourceGroupResponse>;
185
216
  }
186
217
 
187
218
  /** Optional parameters. */
@@ -203,6 +234,13 @@ export declare interface CustomLocationsDeleteOptionalParams extends coreClient.
203
234
  resumeFrom?: string;
204
235
  }
205
236
 
237
+ /** Optional parameters. */
238
+ export declare interface CustomLocationsFindTargetResourceGroupOptionalParams extends coreClient.OperationOptions {
239
+ }
240
+
241
+ /** Contains response data for the findTargetResourceGroup operation. */
242
+ export declare type CustomLocationsFindTargetResourceGroupResponse = CustomLocationFindTargetResourceGroupResult;
243
+
206
244
  /** Optional parameters. */
207
245
  export declare interface CustomLocationsGetOptionalParams extends coreClient.OperationOptions {
208
246
  }
@@ -266,28 +304,21 @@ export declare interface CustomLocationsListOperationsOptionalParams extends cor
266
304
  /** Contains response data for the listOperations operation. */
267
305
  export declare type CustomLocationsListOperationsResponse = CustomLocationOperationsList;
268
306
 
269
- export declare class CustomLocationsManagementClient extends CustomLocationsManagementClientContext {
270
- /**
271
- * Initializes a new instance of the CustomLocationsManagementClient class.
272
- * @param credentials Subscription credentials which uniquely identify client subscription.
273
- * @param subscriptionId The ID of the target subscription.
274
- * @param options The parameter options
275
- */
276
- constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: CustomLocationsManagementClientOptionalParams);
277
- customLocations: CustomLocations;
278
- }
279
-
280
- export declare class CustomLocationsManagementClientContext extends coreClient.ServiceClient {
307
+ export declare class CustomLocationsManagementClient extends coreClient.ServiceClient {
281
308
  $host: string;
282
309
  apiVersion: string;
283
310
  subscriptionId: string;
284
311
  /**
285
- * Initializes a new instance of the CustomLocationsManagementClientContext class.
312
+ * Initializes a new instance of the CustomLocationsManagementClient class.
286
313
  * @param credentials Subscription credentials which uniquely identify client subscription.
287
314
  * @param subscriptionId The ID of the target subscription.
288
315
  * @param options The parameter options
289
316
  */
290
317
  constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: CustomLocationsManagementClientOptionalParams);
318
+ /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */
319
+ private addCustomApiVersionPolicy;
320
+ customLocations: CustomLocations;
321
+ resourceSyncRules: ResourceSyncRules;
291
322
  }
292
323
 
293
324
  /** Optional parameters. */
@@ -328,7 +359,7 @@ export declare interface CustomLocationsUpdateOptionalParams extends coreClient.
328
359
  export declare type CustomLocationsUpdateResponse = CustomLocation;
329
360
 
330
361
  /** EnabledResourceType definition. */
331
- export declare type EnabledResourceType = ProxyResource & {
362
+ export declare interface EnabledResourceType extends ProxyResource {
332
363
  /**
333
364
  * Metadata pertaining to creation and last modification of the resource
334
365
  * NOTE: This property will not be serialized. It can only be populated by the server.
@@ -340,7 +371,7 @@ export declare type EnabledResourceType = ProxyResource & {
340
371
  extensionType?: string;
341
372
  /** Metadata of the Resource Type */
342
373
  typesMetadata?: EnabledResourceTypePropertiesTypesMetadataItem[];
343
- };
374
+ }
344
375
 
345
376
  /** Metadata of the Resource Type. */
346
377
  export declare interface EnabledResourceTypePropertiesTypesMetadataItem {
@@ -442,23 +473,40 @@ export declare interface Identity {
442
473
 
443
474
  /** Known values of {@link CreatedByType} that the service accepts. */
444
475
  export declare enum KnownCreatedByType {
476
+ /** User */
445
477
  User = "User",
478
+ /** Application */
446
479
  Application = "Application",
480
+ /** ManagedIdentity */
447
481
  ManagedIdentity = "ManagedIdentity",
482
+ /** Key */
448
483
  Key = "Key"
449
484
  }
450
485
 
451
486
  /** Known values of {@link HostType} that the service accepts. */
452
487
  export declare enum KnownHostType {
488
+ /** Kubernetes */
453
489
  Kubernetes = "Kubernetes"
454
490
  }
455
491
 
456
492
  /** Known values of {@link ResourceIdentityType} that the service accepts. */
457
493
  export declare enum KnownResourceIdentityType {
494
+ /** SystemAssigned */
458
495
  SystemAssigned = "SystemAssigned",
496
+ /** None */
459
497
  None = "None"
460
498
  }
461
499
 
500
+ /** Resource Sync Rules matchExpression property definition. */
501
+ export declare interface MatchExpressionsProperties {
502
+ /** Key is the label key that the selector applies to. */
503
+ key?: string;
504
+ /** The Operator field represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist. */
505
+ operator?: string;
506
+ /** The label value */
507
+ values?: string[];
508
+ }
509
+
462
510
  /** The Custom Locations patchable resource definition. */
463
511
  export declare interface PatchableCustomLocations {
464
512
  /** Identity for the resource. */
@@ -483,8 +531,28 @@ export declare interface PatchableCustomLocations {
483
531
  provisioningState?: string;
484
532
  }
485
533
 
534
+ /** The Resource Sync Rules patchable resource definition. */
535
+ export declare interface PatchableResourceSyncRule {
536
+ /** Resource tags */
537
+ tags?: {
538
+ [propertyName: string]: string;
539
+ };
540
+ /** Priority represents a priority of the Resource Sync Rule */
541
+ priority?: number;
542
+ /**
543
+ * Provisioning State for the Resource Sync Rule.
544
+ * NOTE: This property will not be serialized. It can only be populated by the server.
545
+ */
546
+ readonly provisioningState?: string;
547
+ /** A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match. */
548
+ selector?: ResourceSyncRulePropertiesSelector;
549
+ /** For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule. */
550
+ targetResourceGroup?: string;
551
+ }
552
+
486
553
  /** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */
487
- export declare type ProxyResource = Resource & {};
554
+ export declare interface ProxyResource extends Resource {
555
+ }
488
556
 
489
557
  /** Common fields that are returned in the response for all Azure Resource Manager resources */
490
558
  export declare interface Resource {
@@ -515,6 +583,175 @@ export declare interface Resource {
515
583
  */
516
584
  export declare type ResourceIdentityType = string;
517
585
 
586
+ /** Resource Sync Rules definition. */
587
+ export declare interface ResourceSyncRule extends TrackedResource {
588
+ /**
589
+ * Metadata pertaining to creation and last modification of the resource
590
+ * NOTE: This property will not be serialized. It can only be populated by the server.
591
+ */
592
+ readonly systemData?: SystemData;
593
+ /** Priority represents a priority of the Resource Sync Rule */
594
+ priority?: number;
595
+ /**
596
+ * Provisioning State for the Resource Sync Rule.
597
+ * NOTE: This property will not be serialized. It can only be populated by the server.
598
+ */
599
+ readonly provisioningState?: string;
600
+ /** A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match. */
601
+ selector?: ResourceSyncRulePropertiesSelector;
602
+ /** For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule. */
603
+ targetResourceGroup?: string;
604
+ }
605
+
606
+ /** The List Resource Sync Rules operation response. */
607
+ export declare interface ResourceSyncRuleListResult {
608
+ /**
609
+ * The URL to use for getting the next set of results.
610
+ * NOTE: This property will not be serialized. It can only be populated by the server.
611
+ */
612
+ readonly nextLink?: string;
613
+ /**
614
+ * The list of Resource Sync Rules.
615
+ * NOTE: This property will not be serialized. It can only be populated by the server.
616
+ */
617
+ readonly value?: ResourceSyncRule[];
618
+ }
619
+
620
+ /** A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match. */
621
+ export declare interface ResourceSyncRulePropertiesSelector {
622
+ /** MatchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. */
623
+ matchExpressions?: MatchExpressionsProperties[];
624
+ /** MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. */
625
+ matchLabels?: {
626
+ [propertyName: string]: string;
627
+ };
628
+ }
629
+
630
+ /** Interface representing a ResourceSyncRules. */
631
+ export declare interface ResourceSyncRules {
632
+ /**
633
+ * Gets a list of Resource Sync Rules in the specified subscription. The operation returns properties
634
+ * of each Resource Sync Rule
635
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
636
+ * @param resourceName Custom Locations name.
637
+ * @param options The options parameters.
638
+ */
639
+ listByCustomLocationID(resourceGroupName: string, resourceName: string, options?: ResourceSyncRulesListByCustomLocationIDOptionalParams): PagedAsyncIterableIterator<ResourceSyncRule>;
640
+ /**
641
+ * Gets the details of the resourceSyncRule with a specified resource group, subscription id Custom
642
+ * Location resource name and Resource Sync Rule name.
643
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
644
+ * @param resourceName Custom Locations name.
645
+ * @param childResourceName Resource Sync Rule name.
646
+ * @param options The options parameters.
647
+ */
648
+ get(resourceGroupName: string, resourceName: string, childResourceName: string, options?: ResourceSyncRulesGetOptionalParams): Promise<ResourceSyncRulesGetResponse>;
649
+ /**
650
+ * Creates or updates a Resource Sync Rule in the parent Custom Location, Subscription Id and Resource
651
+ * Group
652
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
653
+ * @param resourceName Custom Locations name.
654
+ * @param childResourceName Resource Sync Rule name.
655
+ * @param parameters Parameters supplied to create or update a Resource Sync Rule.
656
+ * @param options The options parameters.
657
+ */
658
+ beginCreateOrUpdate(resourceGroupName: string, resourceName: string, childResourceName: string, parameters: ResourceSyncRule, options?: ResourceSyncRulesCreateOrUpdateOptionalParams): Promise<PollerLike<PollOperationState<ResourceSyncRulesCreateOrUpdateResponse>, ResourceSyncRulesCreateOrUpdateResponse>>;
659
+ /**
660
+ * Creates or updates a Resource Sync Rule in the parent Custom Location, Subscription Id and Resource
661
+ * Group
662
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
663
+ * @param resourceName Custom Locations name.
664
+ * @param childResourceName Resource Sync Rule name.
665
+ * @param parameters Parameters supplied to create or update a Resource Sync Rule.
666
+ * @param options The options parameters.
667
+ */
668
+ beginCreateOrUpdateAndWait(resourceGroupName: string, resourceName: string, childResourceName: string, parameters: ResourceSyncRule, options?: ResourceSyncRulesCreateOrUpdateOptionalParams): Promise<ResourceSyncRulesCreateOrUpdateResponse>;
669
+ /**
670
+ * Deletes the Resource Sync Rule with the specified Resource Sync Rule Name, Custom Location Resource
671
+ * Name, Resource Group, and Subscription Id.
672
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
673
+ * @param resourceName Custom Locations name.
674
+ * @param childResourceName Resource Sync Rule name.
675
+ * @param options The options parameters.
676
+ */
677
+ delete(resourceGroupName: string, resourceName: string, childResourceName: string, options?: ResourceSyncRulesDeleteOptionalParams): Promise<void>;
678
+ /**
679
+ * Updates a Resource Sync Rule with the specified Resource Sync Rule name in the specified Resource
680
+ * Group, Subscription and Custom Location name.
681
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
682
+ * @param resourceName Custom Locations name.
683
+ * @param childResourceName Resource Sync Rule name.
684
+ * @param options The options parameters.
685
+ */
686
+ beginUpdate(resourceGroupName: string, resourceName: string, childResourceName: string, options?: ResourceSyncRulesUpdateOptionalParams): Promise<PollerLike<PollOperationState<ResourceSyncRulesUpdateResponse>, ResourceSyncRulesUpdateResponse>>;
687
+ /**
688
+ * Updates a Resource Sync Rule with the specified Resource Sync Rule name in the specified Resource
689
+ * Group, Subscription and Custom Location name.
690
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
691
+ * @param resourceName Custom Locations name.
692
+ * @param childResourceName Resource Sync Rule name.
693
+ * @param options The options parameters.
694
+ */
695
+ beginUpdateAndWait(resourceGroupName: string, resourceName: string, childResourceName: string, options?: ResourceSyncRulesUpdateOptionalParams): Promise<ResourceSyncRulesUpdateResponse>;
696
+ }
697
+
698
+ /** Optional parameters. */
699
+ export declare interface ResourceSyncRulesCreateOrUpdateOptionalParams extends coreClient.OperationOptions {
700
+ /** Delay to wait until next poll, in milliseconds. */
701
+ updateIntervalInMs?: number;
702
+ /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
703
+ resumeFrom?: string;
704
+ }
705
+
706
+ /** Contains response data for the createOrUpdate operation. */
707
+ export declare type ResourceSyncRulesCreateOrUpdateResponse = ResourceSyncRule;
708
+
709
+ /** Optional parameters. */
710
+ export declare interface ResourceSyncRulesDeleteOptionalParams extends coreClient.OperationOptions {
711
+ }
712
+
713
+ /** Optional parameters. */
714
+ export declare interface ResourceSyncRulesGetOptionalParams extends coreClient.OperationOptions {
715
+ }
716
+
717
+ /** Contains response data for the get operation. */
718
+ export declare type ResourceSyncRulesGetResponse = ResourceSyncRule;
719
+
720
+ /** Optional parameters. */
721
+ export declare interface ResourceSyncRulesListByCustomLocationIDNextOptionalParams extends coreClient.OperationOptions {
722
+ }
723
+
724
+ /** Contains response data for the listByCustomLocationIDNext operation. */
725
+ export declare type ResourceSyncRulesListByCustomLocationIDNextResponse = ResourceSyncRuleListResult;
726
+
727
+ /** Optional parameters. */
728
+ export declare interface ResourceSyncRulesListByCustomLocationIDOptionalParams extends coreClient.OperationOptions {
729
+ }
730
+
731
+ /** Contains response data for the listByCustomLocationID operation. */
732
+ export declare type ResourceSyncRulesListByCustomLocationIDResponse = ResourceSyncRuleListResult;
733
+
734
+ /** Optional parameters. */
735
+ export declare interface ResourceSyncRulesUpdateOptionalParams extends coreClient.OperationOptions {
736
+ /** Resource tags */
737
+ tags?: {
738
+ [propertyName: string]: string;
739
+ };
740
+ /** Priority represents a priority of the Resource Sync Rule */
741
+ priority?: number;
742
+ /** A label selector is composed of two parts, matchLabels and matchExpressions. The first part, matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is 'key', the operator is 'In', and the values array contains only 'value'. The second part, matchExpressions is a list of resource selector requirements. Valid operators include In, NotIn, Exists, and DoesNotExist. The values set must be non-empty in the case of In and NotIn. The values set must be empty in the case of Exists and DoesNotExist. All of the requirements, from both matchLabels and matchExpressions must all be satisfied in order to match. */
743
+ selector?: ResourceSyncRulePropertiesSelector;
744
+ /** For an unmapped custom resource, its labels will be used to find matching resource sync rules. If this resource sync rule is one of the matching rules with highest priority, then the unmapped custom resource will be projected to the target resource group associated with this resource sync rule. The user creating this resource sync rule should have write permissions on the target resource group and this write permission will be validated when creating the resource sync rule. */
745
+ targetResourceGroup?: string;
746
+ /** Delay to wait until next poll, in milliseconds. */
747
+ updateIntervalInMs?: number;
748
+ /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
749
+ resumeFrom?: string;
750
+ }
751
+
752
+ /** Contains response data for the update operation. */
753
+ export declare type ResourceSyncRulesUpdateResponse = ResourceSyncRule;
754
+
518
755
  /** Metadata pertaining to creation and last modification of the resource. */
519
756
  export declare interface SystemData {
520
757
  /** The identity that created the resource. */
@@ -532,13 +769,13 @@ export declare interface SystemData {
532
769
  }
533
770
 
534
771
  /** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */
535
- export declare type TrackedResource = Resource & {
772
+ export declare interface TrackedResource extends Resource {
536
773
  /** Resource tags. */
537
774
  tags?: {
538
775
  [propertyName: string]: string;
539
776
  };
540
777
  /** The geo-location where the resource lives */
541
778
  location: string;
542
- };
779
+ }
543
780
 
544
781
  export { }
@@ -5,7 +5,7 @@
5
5
  "toolPackages": [
6
6
  {
7
7
  "packageName": "@microsoft/api-extractor",
8
- "packageVersion": "7.7.11"
8
+ "packageVersion": "7.18.11"
9
9
  }
10
10
  ]
11
11
  }
@@ -1,16 +0,0 @@
1
- import * as coreClient from "@azure/core-client";
2
- import * as coreAuth from "@azure/core-auth";
3
- import { CustomLocationsManagementClientOptionalParams } from "./models";
4
- export declare class CustomLocationsManagementClientContext extends coreClient.ServiceClient {
5
- $host: string;
6
- apiVersion: string;
7
- subscriptionId: string;
8
- /**
9
- * Initializes a new instance of the CustomLocationsManagementClientContext class.
10
- * @param credentials Subscription credentials which uniquely identify client subscription.
11
- * @param subscriptionId The ID of the target subscription.
12
- * @param options The parameter options
13
- */
14
- constructor(credentials: coreAuth.TokenCredential, subscriptionId: string, options?: CustomLocationsManagementClientOptionalParams);
15
- }
16
- //# sourceMappingURL=customLocationsManagementClientContext.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"customLocationsManagementClientContext.d.ts","sourceRoot":"","sources":["../../src/customLocationsManagementClientContext.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AACjD,OAAO,KAAK,QAAQ,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,6CAA6C,EAAE,MAAM,UAAU,CAAC;AAEzE,qBAAa,sCAAuC,SAAQ,UAAU,CAAC,aAAa;IAClF,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IAEvB;;;;;OAKG;gBAED,WAAW,EAAE,QAAQ,CAAC,eAAe,EACrC,cAAc,EAAE,MAAM,EACtB,OAAO,CAAC,EAAE,6CAA6C;CA2C1D"}