@azure/arm-operations 4.0.0-beta.2 → 4.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 (90) hide show
  1. package/CHANGELOG.md +2 -2
  2. package/LICENSE +1 -1
  3. package/README.md +12 -1
  4. package/dist/index.js +124 -63
  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/managementAssociationsCreateOrUpdateSample.d.ts +2 -0
  9. package/dist-esm/samples-dev/managementAssociationsCreateOrUpdateSample.d.ts.map +1 -0
  10. package/dist-esm/samples-dev/managementAssociationsCreateOrUpdateSample.js +40 -0
  11. package/dist-esm/samples-dev/managementAssociationsCreateOrUpdateSample.js.map +1 -0
  12. package/dist-esm/samples-dev/managementAssociationsDeleteSample.d.ts +2 -0
  13. package/dist-esm/samples-dev/managementAssociationsDeleteSample.d.ts.map +1 -0
  14. package/dist-esm/samples-dev/managementAssociationsDeleteSample.js +34 -0
  15. package/dist-esm/samples-dev/managementAssociationsDeleteSample.js.map +1 -0
  16. package/dist-esm/samples-dev/managementAssociationsGetSample.d.ts +2 -0
  17. package/dist-esm/samples-dev/managementAssociationsGetSample.d.ts.map +1 -0
  18. package/dist-esm/samples-dev/managementAssociationsGetSample.js +34 -0
  19. package/dist-esm/samples-dev/managementAssociationsGetSample.js.map +1 -0
  20. package/dist-esm/samples-dev/managementAssociationsListBySubscriptionSample.d.ts +2 -0
  21. package/dist-esm/samples-dev/managementAssociationsListBySubscriptionSample.d.ts.map +1 -0
  22. package/dist-esm/samples-dev/managementAssociationsListBySubscriptionSample.js +29 -0
  23. package/dist-esm/samples-dev/managementAssociationsListBySubscriptionSample.js.map +1 -0
  24. package/dist-esm/samples-dev/managementConfigurationsCreateOrUpdateSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/managementConfigurationsCreateOrUpdateSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/managementConfigurationsCreateOrUpdateSample.js +32 -0
  27. package/dist-esm/samples-dev/managementConfigurationsCreateOrUpdateSample.js.map +1 -0
  28. package/dist-esm/samples-dev/managementConfigurationsDeleteSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/managementConfigurationsDeleteSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/managementConfigurationsDeleteSample.js +31 -0
  31. package/dist-esm/samples-dev/managementConfigurationsDeleteSample.js.map +1 -0
  32. package/dist-esm/samples-dev/managementConfigurationsGetSample.d.ts +2 -0
  33. package/dist-esm/samples-dev/managementConfigurationsGetSample.d.ts.map +1 -0
  34. package/dist-esm/samples-dev/managementConfigurationsGetSample.js +31 -0
  35. package/dist-esm/samples-dev/managementConfigurationsGetSample.js.map +1 -0
  36. package/dist-esm/samples-dev/managementConfigurationsListBySubscriptionSample.d.ts +2 -0
  37. package/dist-esm/samples-dev/managementConfigurationsListBySubscriptionSample.d.ts.map +1 -0
  38. package/dist-esm/samples-dev/managementConfigurationsListBySubscriptionSample.js +29 -0
  39. package/dist-esm/samples-dev/managementConfigurationsListBySubscriptionSample.js.map +1 -0
  40. package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
  41. package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
  42. package/dist-esm/samples-dev/operationsListSample.js +43 -0
  43. package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
  44. package/dist-esm/samples-dev/solutionsCreateOrUpdateSample.d.ts +2 -0
  45. package/dist-esm/samples-dev/solutionsCreateOrUpdateSample.d.ts.map +1 -0
  46. package/dist-esm/samples-dev/solutionsCreateOrUpdateSample.js +51 -0
  47. package/dist-esm/samples-dev/solutionsCreateOrUpdateSample.js.map +1 -0
  48. package/dist-esm/samples-dev/solutionsDeleteSample.d.ts +2 -0
  49. package/dist-esm/samples-dev/solutionsDeleteSample.d.ts.map +1 -0
  50. package/dist-esm/samples-dev/solutionsDeleteSample.js +31 -0
  51. package/dist-esm/samples-dev/solutionsDeleteSample.js.map +1 -0
  52. package/dist-esm/samples-dev/solutionsGetSample.d.ts +2 -0
  53. package/dist-esm/samples-dev/solutionsGetSample.d.ts.map +1 -0
  54. package/dist-esm/samples-dev/solutionsGetSample.js +31 -0
  55. package/dist-esm/samples-dev/solutionsGetSample.js.map +1 -0
  56. package/dist-esm/samples-dev/solutionsListByResourceGroupSample.d.ts +2 -0
  57. package/dist-esm/samples-dev/solutionsListByResourceGroupSample.d.ts.map +1 -0
  58. package/dist-esm/samples-dev/solutionsListByResourceGroupSample.js +30 -0
  59. package/dist-esm/samples-dev/solutionsListByResourceGroupSample.js.map +1 -0
  60. package/dist-esm/samples-dev/solutionsListBySubscriptionSample.d.ts +2 -0
  61. package/dist-esm/samples-dev/solutionsListBySubscriptionSample.d.ts.map +1 -0
  62. package/dist-esm/samples-dev/solutionsListBySubscriptionSample.js +29 -0
  63. package/dist-esm/samples-dev/solutionsListBySubscriptionSample.js.map +1 -0
  64. package/dist-esm/samples-dev/solutionsUpdateSample.d.ts +2 -0
  65. package/dist-esm/samples-dev/solutionsUpdateSample.d.ts.map +1 -0
  66. package/dist-esm/samples-dev/solutionsUpdateSample.js +34 -0
  67. package/dist-esm/samples-dev/solutionsUpdateSample.js.map +1 -0
  68. package/dist-esm/src/operations/managementAssociations.d.ts +12 -3
  69. package/dist-esm/src/operations/managementAssociations.d.ts.map +1 -1
  70. package/dist-esm/src/operations/managementAssociations.js +37 -6
  71. package/dist-esm/src/operations/managementAssociations.js.map +1 -1
  72. package/dist-esm/src/operations/solutions.d.ts.map +1 -1
  73. package/dist-esm/src/operations/solutions.js +9 -3
  74. package/dist-esm/src/operations/solutions.js.map +1 -1
  75. package/dist-esm/src/operationsInterfaces/managementAssociations.d.ts +12 -3
  76. package/dist-esm/src/operationsInterfaces/managementAssociations.d.ts.map +1 -1
  77. package/dist-esm/src/operationsManagementClient.d.ts +1 -7
  78. package/dist-esm/src/operationsManagementClient.d.ts.map +1 -1
  79. package/dist-esm/src/operationsManagementClient.js +21 -18
  80. package/dist-esm/src/operationsManagementClient.js.map +1 -1
  81. package/package.json +40 -14
  82. package/review/arm-operations.api.md +4 -10
  83. package/rollup.config.js +6 -72
  84. package/src/operations/managementAssociations.ts +43 -3
  85. package/src/operations/solutions.ts +9 -3
  86. package/src/operationsInterfaces/managementAssociations.ts +18 -0
  87. package/src/operationsManagementClient.ts +27 -23
  88. package/tsconfig.json +19 -5
  89. package/types/arm-operations.d.ts +13 -10
  90. package/types/tsdoc-metadata.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # Release History
2
2
 
3
- ## 4.0.0-beta.2 (2021-12-21)
3
+ ## 4.0.0-beta.3 (2022-05-11)
4
4
 
5
- The package of @azure/arm-operations is using our next generation design principles since version 4.0.0-beta.2, which contains breaking changes.
5
+ The package of @azure/arm-operations is using our next generation design principles since version 4.0.0-beta.3, which contains breaking changes.
6
6
 
7
7
  To understand the detail of the change, please refer to [Changelog](https://aka.ms/js-track2-changelog).
8
8
 
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2021 Microsoft
3
+ Copyright (c) 2022 Microsoft
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -6,7 +6,7 @@ Operations Management Client
6
6
 
7
7
  [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/operationsmanagement/arm-operations) |
8
8
  [Package (NPM)](https://www.npmjs.com/package/@azure/arm-operations) |
9
- [API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-operations) |
9
+ [API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-operations?view=azure-node-preview) |
10
10
  [Samples](https://github.com/Azure-Samples/azure-samples-js-management)
11
11
 
12
12
  ## Getting started
@@ -16,6 +16,8 @@ Operations Management Client
16
16
  - [LTS versions of Node.js](https://nodejs.org/about/releases/)
17
17
  - Latest versions of Safari, Chrome, Edge and Firefox.
18
18
 
19
+ See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details.
20
+
19
21
  ### Prerequisites
20
22
 
21
23
  - An [Azure subscription][azure_sub].
@@ -49,8 +51,17 @@ For more information about how to create an Azure AD Application check out [this
49
51
  ```javascript
50
52
  const { OperationsManagementClient } = require("@azure/arm-operations");
51
53
  const { DefaultAzureCredential } = require("@azure/identity");
54
+ // For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details.
55
+
52
56
  const subscriptionId = "00000000-0000-0000-0000-000000000000";
53
57
  const client = new OperationsManagementClient(new DefaultAzureCredential(), subscriptionId);
58
+
59
+ // For client-side applications running in the browser, use this code instead:
60
+ // const credential = new InteractiveBrowserCredential({
61
+ // tenantId: "<YOUR_TENANT_ID>",
62
+ // clientId: "<YOUR_CLIENT_ID>"
63
+ // });
64
+ // const client = new OperationsManagementClient(credential, subscriptionId);
54
65
  ```
55
66
 
56
67
 
package/dist/index.js CHANGED
@@ -3,9 +3,31 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var coreClient = require('@azure/core-client');
6
+ var coreRestPipeline = require('@azure/core-rest-pipeline');
6
7
  var tslib = require('tslib');
7
8
  var coreLro = require('@azure/core-lro');
8
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
+
9
31
  /*
10
32
  * Copyright (c) Microsoft Corporation.
11
33
  * Licensed under the MIT License.
@@ -740,11 +762,13 @@ class SolutionsImpl {
740
762
  }
741
763
  };
742
764
  });
743
- const lro = new LroImpl(sendOperation, { resourceGroupName, solutionName, parameters, options }, createOrUpdateOperationSpec);
744
- return new coreLro.LroEngine(lro, {
765
+ const lro = new LroImpl(sendOperation, { resourceGroupName, solutionName, parameters, options }, createOrUpdateOperationSpec$2);
766
+ const poller = new coreLro.LroEngine(lro, {
745
767
  resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
746
768
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
747
769
  });
770
+ yield poller.poll();
771
+ return poller;
748
772
  });
749
773
  }
750
774
  /**
@@ -792,10 +816,12 @@ class SolutionsImpl {
792
816
  };
793
817
  });
794
818
  const lro = new LroImpl(sendOperation, { resourceGroupName, solutionName, parameters, options }, updateOperationSpec);
795
- return new coreLro.LroEngine(lro, {
819
+ const poller = new coreLro.LroEngine(lro, {
796
820
  resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
797
821
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
798
822
  });
823
+ yield poller.poll();
824
+ return poller;
799
825
  });
800
826
  }
801
827
  /**
@@ -841,11 +867,13 @@ class SolutionsImpl {
841
867
  }
842
868
  };
843
869
  });
844
- const lro = new LroImpl(sendOperation, { resourceGroupName, solutionName, options }, deleteOperationSpec);
845
- return new coreLro.LroEngine(lro, {
870
+ const lro = new LroImpl(sendOperation, { resourceGroupName, solutionName, options }, deleteOperationSpec$2);
871
+ const poller = new coreLro.LroEngine(lro, {
846
872
  resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
847
873
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
848
874
  });
875
+ yield poller.poll();
876
+ return poller;
849
877
  });
850
878
  }
851
879
  /**
@@ -867,7 +895,7 @@ class SolutionsImpl {
867
895
  * @param options The options parameters.
868
896
  */
869
897
  get(resourceGroupName, solutionName, options) {
870
- return this.client.sendOperationRequest({ resourceGroupName, solutionName, options }, getOperationSpec);
898
+ return this.client.sendOperationRequest({ resourceGroupName, solutionName, options }, getOperationSpec$2);
871
899
  }
872
900
  /**
873
901
  * Retrieves the solution list. It will retrieve both first party and third party solutions
@@ -882,12 +910,12 @@ class SolutionsImpl {
882
910
  * @param options The options parameters.
883
911
  */
884
912
  listBySubscription(options) {
885
- return this.client.sendOperationRequest({ options }, listBySubscriptionOperationSpec);
913
+ return this.client.sendOperationRequest({ options }, listBySubscriptionOperationSpec$2);
886
914
  }
887
915
  }
888
916
  // Operation Specifications
889
- const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
890
- const createOrUpdateOperationSpec = {
917
+ const serializer$3 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
918
+ const createOrUpdateOperationSpec$2 = {
891
919
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/solutions/{solutionName}",
892
920
  httpMethod: "PUT",
893
921
  responses: {
@@ -917,7 +945,7 @@ const createOrUpdateOperationSpec = {
917
945
  ],
918
946
  headerParameters: [contentType, accept],
919
947
  mediaType: "json",
920
- serializer
948
+ serializer: serializer$3
921
949
  };
922
950
  const updateOperationSpec = {
923
951
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/solutions/{solutionName}",
@@ -949,9 +977,9 @@ const updateOperationSpec = {
949
977
  ],
950
978
  headerParameters: [contentType, accept],
951
979
  mediaType: "json",
952
- serializer
980
+ serializer: serializer$3
953
981
  };
954
- const deleteOperationSpec = {
982
+ const deleteOperationSpec$2 = {
955
983
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/solutions/{solutionName}",
956
984
  httpMethod: "DELETE",
957
985
  responses: {
@@ -971,9 +999,9 @@ const deleteOperationSpec = {
971
999
  solutionName
972
1000
  ],
973
1001
  headerParameters: [accept],
974
- serializer
1002
+ serializer: serializer$3
975
1003
  };
976
- const getOperationSpec = {
1004
+ const getOperationSpec$2 = {
977
1005
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/solutions/{solutionName}",
978
1006
  httpMethod: "GET",
979
1007
  responses: {
@@ -992,7 +1020,7 @@ const getOperationSpec = {
992
1020
  solutionName
993
1021
  ],
994
1022
  headerParameters: [accept],
995
- serializer
1023
+ serializer: serializer$3
996
1024
  };
997
1025
  const listByResourceGroupOperationSpec = {
998
1026
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/solutions",
@@ -1012,9 +1040,9 @@ const listByResourceGroupOperationSpec = {
1012
1040
  resourceGroupName
1013
1041
  ],
1014
1042
  headerParameters: [accept],
1015
- serializer
1043
+ serializer: serializer$3
1016
1044
  };
1017
- const listBySubscriptionOperationSpec = {
1045
+ const listBySubscriptionOperationSpec$2 = {
1018
1046
  path: "/subscriptions/{subscriptionId}/providers/Microsoft.OperationsManagement/solutions",
1019
1047
  httpMethod: "GET",
1020
1048
  responses: {
@@ -1028,7 +1056,7 @@ const listBySubscriptionOperationSpec = {
1028
1056
  queryParameters: [apiVersion],
1029
1057
  urlParameters: [$host, subscriptionId],
1030
1058
  headerParameters: [accept],
1031
- serializer
1059
+ serializer: serializer$3
1032
1060
  };
1033
1061
 
1034
1062
  /*
@@ -1057,34 +1085,65 @@ class ManagementAssociationsImpl {
1057
1085
  /**
1058
1086
  * Creates or updates the ManagementAssociation.
1059
1087
  * @param resourceGroupName The name of the resource group to get. The name is case insensitive.
1088
+ * @param providerName Provider name for the parent resource.
1089
+ * @param resourceType Resource type for the parent resource
1090
+ * @param resourceName Parent resource name.
1060
1091
  * @param managementAssociationName User ManagementAssociation Name.
1061
1092
  * @param parameters The parameters required to create ManagementAssociation extension.
1062
1093
  * @param options The options parameters.
1063
1094
  */
1064
- createOrUpdate(resourceGroupName, managementAssociationName, parameters, options) {
1065
- return this.client.sendOperationRequest({ resourceGroupName, managementAssociationName, parameters, options }, createOrUpdateOperationSpec$1);
1095
+ createOrUpdate(resourceGroupName, providerName, resourceType, resourceName, managementAssociationName, parameters, options) {
1096
+ return this.client.sendOperationRequest({
1097
+ resourceGroupName,
1098
+ providerName,
1099
+ resourceType,
1100
+ resourceName,
1101
+ managementAssociationName,
1102
+ parameters,
1103
+ options
1104
+ }, createOrUpdateOperationSpec$1);
1066
1105
  }
1067
1106
  /**
1068
1107
  * Deletes the ManagementAssociation in the subscription.
1069
1108
  * @param resourceGroupName The name of the resource group to get. The name is case insensitive.
1109
+ * @param providerName Provider name for the parent resource.
1110
+ * @param resourceType Resource type for the parent resource
1111
+ * @param resourceName Parent resource name.
1070
1112
  * @param managementAssociationName User ManagementAssociation Name.
1071
1113
  * @param options The options parameters.
1072
1114
  */
1073
- delete(resourceGroupName, managementAssociationName, options) {
1074
- return this.client.sendOperationRequest({ resourceGroupName, managementAssociationName, options }, deleteOperationSpec$1);
1115
+ delete(resourceGroupName, providerName, resourceType, resourceName, managementAssociationName, options) {
1116
+ return this.client.sendOperationRequest({
1117
+ resourceGroupName,
1118
+ providerName,
1119
+ resourceType,
1120
+ resourceName,
1121
+ managementAssociationName,
1122
+ options
1123
+ }, deleteOperationSpec$1);
1075
1124
  }
1076
1125
  /**
1077
1126
  * Retrieves the user ManagementAssociation.
1078
1127
  * @param resourceGroupName The name of the resource group to get. The name is case insensitive.
1128
+ * @param providerName Provider name for the parent resource.
1129
+ * @param resourceType Resource type for the parent resource
1130
+ * @param resourceName Parent resource name.
1079
1131
  * @param managementAssociationName User ManagementAssociation Name.
1080
1132
  * @param options The options parameters.
1081
1133
  */
1082
- get(resourceGroupName, managementAssociationName, options) {
1083
- return this.client.sendOperationRequest({ resourceGroupName, managementAssociationName, options }, getOperationSpec$1);
1134
+ get(resourceGroupName, providerName, resourceType, resourceName, managementAssociationName, options) {
1135
+ return this.client.sendOperationRequest({
1136
+ resourceGroupName,
1137
+ providerName,
1138
+ resourceType,
1139
+ resourceName,
1140
+ managementAssociationName,
1141
+ options
1142
+ }, getOperationSpec$1);
1084
1143
  }
1085
1144
  }
1086
1145
  // Operation Specifications
1087
- const serializer$1 = coreClient.createSerializer(Mappers, /* isXml */ false);
1146
+ const serializer$2 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
1088
1147
  const listBySubscriptionOperationSpec$1 = {
1089
1148
  path: "/subscriptions/{subscriptionId}/providers/Microsoft.OperationsManagement/ManagementAssociations",
1090
1149
  httpMethod: "GET",
@@ -1099,7 +1158,7 @@ const listBySubscriptionOperationSpec$1 = {
1099
1158
  queryParameters: [apiVersion],
1100
1159
  urlParameters: [$host, subscriptionId],
1101
1160
  headerParameters: [accept],
1102
- serializer: serializer$1
1161
+ serializer: serializer$2
1103
1162
  };
1104
1163
  const createOrUpdateOperationSpec$1 = {
1105
1164
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{providerName}/{resourceType}/{resourceName}/providers/Microsoft.OperationsManagement/ManagementAssociations/{managementAssociationName}",
@@ -1125,7 +1184,7 @@ const createOrUpdateOperationSpec$1 = {
1125
1184
  ],
1126
1185
  headerParameters: [contentType, accept],
1127
1186
  mediaType: "json",
1128
- serializer: serializer$1
1187
+ serializer: serializer$2
1129
1188
  };
1130
1189
  const deleteOperationSpec$1 = {
1131
1190
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{providerName}/{resourceType}/{resourceName}/providers/Microsoft.OperationsManagement/ManagementAssociations/{managementAssociationName}",
@@ -1147,7 +1206,7 @@ const deleteOperationSpec$1 = {
1147
1206
  managementAssociationName
1148
1207
  ],
1149
1208
  headerParameters: [accept],
1150
- serializer: serializer$1
1209
+ serializer: serializer$2
1151
1210
  };
1152
1211
  const getOperationSpec$1 = {
1153
1212
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{providerName}/{resourceType}/{resourceName}/providers/Microsoft.OperationsManagement/ManagementAssociations/{managementAssociationName}",
@@ -1171,7 +1230,7 @@ const getOperationSpec$1 = {
1171
1230
  managementAssociationName
1172
1231
  ],
1173
1232
  headerParameters: [accept],
1174
- serializer: serializer$1
1233
+ serializer: serializer$2
1175
1234
  };
1176
1235
 
1177
1236
  /*
@@ -1195,7 +1254,7 @@ class ManagementConfigurationsImpl {
1195
1254
  * @param options The options parameters.
1196
1255
  */
1197
1256
  listBySubscription(options) {
1198
- return this.client.sendOperationRequest({ options }, listBySubscriptionOperationSpec$2);
1257
+ return this.client.sendOperationRequest({ options }, listBySubscriptionOperationSpec);
1199
1258
  }
1200
1259
  /**
1201
1260
  * Creates or updates the ManagementConfiguration.
@@ -1205,7 +1264,7 @@ class ManagementConfigurationsImpl {
1205
1264
  * @param options The options parameters.
1206
1265
  */
1207
1266
  createOrUpdate(resourceGroupName, managementConfigurationName, parameters, options) {
1208
- return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, parameters, options }, createOrUpdateOperationSpec$2);
1267
+ return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, parameters, options }, createOrUpdateOperationSpec);
1209
1268
  }
1210
1269
  /**
1211
1270
  * Deletes the ManagementConfiguration in the subscription.
@@ -1214,7 +1273,7 @@ class ManagementConfigurationsImpl {
1214
1273
  * @param options The options parameters.
1215
1274
  */
1216
1275
  delete(resourceGroupName, managementConfigurationName, options) {
1217
- return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, options }, deleteOperationSpec$2);
1276
+ return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, options }, deleteOperationSpec);
1218
1277
  }
1219
1278
  /**
1220
1279
  * Retrieves the user ManagementConfiguration.
@@ -1223,12 +1282,12 @@ class ManagementConfigurationsImpl {
1223
1282
  * @param options The options parameters.
1224
1283
  */
1225
1284
  get(resourceGroupName, managementConfigurationName, options) {
1226
- return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, options }, getOperationSpec$2);
1285
+ return this.client.sendOperationRequest({ resourceGroupName, managementConfigurationName, options }, getOperationSpec);
1227
1286
  }
1228
1287
  }
1229
1288
  // Operation Specifications
1230
- const serializer$2 = coreClient.createSerializer(Mappers, /* isXml */ false);
1231
- const listBySubscriptionOperationSpec$2 = {
1289
+ const serializer$1 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
1290
+ const listBySubscriptionOperationSpec = {
1232
1291
  path: "/subscriptions/{subscriptionId}/providers/Microsoft.OperationsManagement/ManagementConfigurations",
1233
1292
  httpMethod: "GET",
1234
1293
  responses: {
@@ -1242,9 +1301,9 @@ const listBySubscriptionOperationSpec$2 = {
1242
1301
  queryParameters: [apiVersion],
1243
1302
  urlParameters: [$host, subscriptionId],
1244
1303
  headerParameters: [accept],
1245
- serializer: serializer$2
1304
+ serializer: serializer$1
1246
1305
  };
1247
- const createOrUpdateOperationSpec$2 = {
1306
+ const createOrUpdateOperationSpec = {
1248
1307
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/ManagementConfigurations/{managementConfigurationName}",
1249
1308
  httpMethod: "PUT",
1250
1309
  responses: {
@@ -1265,9 +1324,9 @@ const createOrUpdateOperationSpec$2 = {
1265
1324
  ],
1266
1325
  headerParameters: [contentType, accept],
1267
1326
  mediaType: "json",
1268
- serializer: serializer$2
1327
+ serializer: serializer$1
1269
1328
  };
1270
- const deleteOperationSpec$2 = {
1329
+ const deleteOperationSpec = {
1271
1330
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/ManagementConfigurations/{managementConfigurationName}",
1272
1331
  httpMethod: "DELETE",
1273
1332
  responses: {
@@ -1284,9 +1343,9 @@ const deleteOperationSpec$2 = {
1284
1343
  managementConfigurationName
1285
1344
  ],
1286
1345
  headerParameters: [accept],
1287
- serializer: serializer$2
1346
+ serializer: serializer$1
1288
1347
  };
1289
- const getOperationSpec$2 = {
1348
+ const getOperationSpec = {
1290
1349
  path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationsManagement/ManagementConfigurations/{managementConfigurationName}",
1291
1350
  httpMethod: "GET",
1292
1351
  responses: {
@@ -1305,7 +1364,7 @@ const getOperationSpec$2 = {
1305
1364
  managementConfigurationName
1306
1365
  ],
1307
1366
  headerParameters: [accept],
1308
- serializer: serializer$2
1367
+ serializer: serializer$1
1309
1368
  };
1310
1369
 
1311
1370
  /*
@@ -1376,7 +1435,7 @@ class OperationsImpl {
1376
1435
  }
1377
1436
  }
1378
1437
  // Operation Specifications
1379
- const serializer$3 = coreClient.createSerializer(Mappers, /* isXml */ false);
1438
+ const serializer = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
1380
1439
  const listOperationSpec = {
1381
1440
  path: "/providers/Microsoft.OperationsManagement/operations",
1382
1441
  httpMethod: "GET",
@@ -1388,7 +1447,7 @@ const listOperationSpec = {
1388
1447
  queryParameters: [apiVersion],
1389
1448
  urlParameters: [$host],
1390
1449
  headerParameters: [accept],
1391
- serializer: serializer$3
1450
+ serializer
1392
1451
  };
1393
1452
 
1394
1453
  /*
@@ -1398,33 +1457,22 @@ const listOperationSpec = {
1398
1457
  * Code generated by Microsoft (R) AutoRest Code Generator.
1399
1458
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1400
1459
  */
1401
- class OperationsManagementClient extends coreClient.ServiceClient {
1460
+ class OperationsManagementClient extends coreClient__namespace.ServiceClient {
1402
1461
  /**
1403
1462
  * Initializes a new instance of the OperationsManagementClient class.
1404
1463
  * @param credentials Subscription credentials which uniquely identify client subscription.
1405
1464
  * @param subscriptionId Gets subscription credentials which uniquely identify Microsoft Azure
1406
1465
  * subscription. The subscription ID forms part of the URI for every service call.
1407
- * @param providerName Provider name for the parent resource.
1408
- * @param resourceType Resource type for the parent resource
1409
- * @param resourceName Parent resource name.
1410
1466
  * @param options The parameter options
1411
1467
  */
1412
- constructor(credentials, subscriptionId, providerName, resourceType, resourceName, options) {
1468
+ constructor(credentials, subscriptionId, options) {
1469
+ var _a, _b;
1413
1470
  if (credentials === undefined) {
1414
1471
  throw new Error("'credentials' cannot be null");
1415
1472
  }
1416
1473
  if (subscriptionId === undefined) {
1417
1474
  throw new Error("'subscriptionId' cannot be null");
1418
1475
  }
1419
- if (providerName === undefined) {
1420
- throw new Error("'providerName' cannot be null");
1421
- }
1422
- if (resourceType === undefined) {
1423
- throw new Error("'resourceType' cannot be null");
1424
- }
1425
- if (resourceName === undefined) {
1426
- throw new Error("'resourceName' cannot be null");
1427
- }
1428
1476
  // Initializing default values for options
1429
1477
  if (!options) {
1430
1478
  options = {};
@@ -1433,7 +1481,7 @@ class OperationsManagementClient extends coreClient.ServiceClient {
1433
1481
  requestContentType: "application/json; charset=utf-8",
1434
1482
  credential: credentials
1435
1483
  };
1436
- const packageDetails = `azsdk-js-arm-operations/4.0.0-beta.2`;
1484
+ const packageDetails = `azsdk-js-arm-operations/4.0.0-beta.3`;
1437
1485
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
1438
1486
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
1439
1487
  : `${packageDetails}`;
@@ -1442,13 +1490,26 @@ class OperationsManagementClient extends coreClient.ServiceClient {
1442
1490
  }
1443
1491
  const optionsWithDefaults = Object.assign(Object.assign(Object.assign({}, defaults), options), { userAgentOptions: {
1444
1492
  userAgentPrefix
1445
- }, baseUri: options.endpoint || "https://management.azure.com" });
1493
+ }, baseUri: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" });
1446
1494
  super(optionsWithDefaults);
1495
+ if ((options === null || options === void 0 ? void 0 : options.pipeline) && options.pipeline.getOrderedPolicies().length > 0) {
1496
+ const pipelinePolicies = options.pipeline.getOrderedPolicies();
1497
+ const bearerTokenAuthenticationPolicyFound = pipelinePolicies.some((pipelinePolicy) => pipelinePolicy.name ===
1498
+ coreRestPipeline__namespace.bearerTokenAuthenticationPolicyName);
1499
+ if (!bearerTokenAuthenticationPolicyFound) {
1500
+ this.pipeline.removePolicy({
1501
+ name: coreRestPipeline__namespace.bearerTokenAuthenticationPolicyName
1502
+ });
1503
+ this.pipeline.addPolicy(coreRestPipeline__namespace.bearerTokenAuthenticationPolicy({
1504
+ scopes: `${optionsWithDefaults.baseUri}/.default`,
1505
+ challengeCallbacks: {
1506
+ authorizeRequestOnChallenge: coreClient__namespace.authorizeRequestOnClaimChallenge
1507
+ }
1508
+ }));
1509
+ }
1510
+ }
1447
1511
  // Parameter assignments
1448
1512
  this.subscriptionId = subscriptionId;
1449
- this.providerName = providerName;
1450
- this.resourceType = resourceType;
1451
- this.resourceName = resourceName;
1452
1513
  // Assigning values to Constant parameters
1453
1514
  this.$host = options.$host || "https://management.azure.com";
1454
1515
  this.apiVersion = options.apiVersion || "2015-11-01-preview";