@azure/arm-deviceupdate 1.0.1-alpha.20230201.1 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (103) hide show
  1. package/CHANGELOG.md +6 -9
  2. package/LICENSE +1 -1
  3. package/dist/index.js +133 -51
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.js +1 -1
  6. package/dist/index.min.js.map +1 -1
  7. package/dist-esm/samples-dev/accountsCreateSample.js +11 -3
  8. package/dist-esm/samples-dev/accountsCreateSample.js.map +1 -1
  9. package/dist-esm/samples-dev/accountsDeleteSample.js +11 -3
  10. package/dist-esm/samples-dev/accountsDeleteSample.js.map +1 -1
  11. package/dist-esm/samples-dev/accountsGetSample.js +11 -3
  12. package/dist-esm/samples-dev/accountsGetSample.js.map +1 -1
  13. package/dist-esm/samples-dev/accountsHeadSample.js +11 -3
  14. package/dist-esm/samples-dev/accountsHeadSample.js.map +1 -1
  15. package/dist-esm/samples-dev/accountsListByResourceGroupSample.js +11 -3
  16. package/dist-esm/samples-dev/accountsListByResourceGroupSample.js.map +1 -1
  17. package/dist-esm/samples-dev/accountsListBySubscriptionSample.js +10 -2
  18. package/dist-esm/samples-dev/accountsListBySubscriptionSample.js.map +1 -1
  19. package/dist-esm/samples-dev/accountsUpdateSample.js +11 -3
  20. package/dist-esm/samples-dev/accountsUpdateSample.js.map +1 -1
  21. package/dist-esm/samples-dev/checkNameAvailabilitySample.js +13 -4
  22. package/dist-esm/samples-dev/checkNameAvailabilitySample.js.map +1 -1
  23. package/dist-esm/samples-dev/instancesCreateSample.js +11 -3
  24. package/dist-esm/samples-dev/instancesCreateSample.js.map +1 -1
  25. package/dist-esm/samples-dev/instancesDeleteSample.js +11 -3
  26. package/dist-esm/samples-dev/instancesDeleteSample.js.map +1 -1
  27. package/dist-esm/samples-dev/instancesGetSample.js +11 -3
  28. package/dist-esm/samples-dev/instancesGetSample.js.map +1 -1
  29. package/dist-esm/samples-dev/instancesHeadSample.js +11 -3
  30. package/dist-esm/samples-dev/instancesHeadSample.js.map +1 -1
  31. package/dist-esm/samples-dev/instancesListByAccountSample.js +11 -3
  32. package/dist-esm/samples-dev/instancesListByAccountSample.js.map +1 -1
  33. package/dist-esm/samples-dev/instancesUpdateSample.js +11 -3
  34. package/dist-esm/samples-dev/instancesUpdateSample.js.map +1 -1
  35. package/dist-esm/samples-dev/operationsListSample.js +10 -2
  36. package/dist-esm/samples-dev/operationsListSample.js.map +1 -1
  37. package/dist-esm/samples-dev/privateEndpointConnectionProxiesCreateOrUpdateSample.js +11 -3
  38. package/dist-esm/samples-dev/privateEndpointConnectionProxiesCreateOrUpdateSample.js.map +1 -1
  39. package/dist-esm/samples-dev/privateEndpointConnectionProxiesDeleteSample.js +11 -3
  40. package/dist-esm/samples-dev/privateEndpointConnectionProxiesDeleteSample.js.map +1 -1
  41. package/dist-esm/samples-dev/privateEndpointConnectionProxiesGetSample.js +11 -3
  42. package/dist-esm/samples-dev/privateEndpointConnectionProxiesGetSample.js.map +1 -1
  43. package/dist-esm/samples-dev/privateEndpointConnectionProxiesListByAccountSample.js +11 -3
  44. package/dist-esm/samples-dev/privateEndpointConnectionProxiesListByAccountSample.js.map +1 -1
  45. package/dist-esm/samples-dev/privateEndpointConnectionProxiesUpdatePrivateEndpointPropertiesSample.js +11 -3
  46. package/dist-esm/samples-dev/privateEndpointConnectionProxiesUpdatePrivateEndpointPropertiesSample.js.map +1 -1
  47. package/dist-esm/samples-dev/privateEndpointConnectionProxiesValidateSample.js +11 -3
  48. package/dist-esm/samples-dev/privateEndpointConnectionProxiesValidateSample.js.map +1 -1
  49. package/dist-esm/samples-dev/privateEndpointConnectionsCreateOrUpdateSample.js +11 -3
  50. package/dist-esm/samples-dev/privateEndpointConnectionsCreateOrUpdateSample.js.map +1 -1
  51. package/dist-esm/samples-dev/privateEndpointConnectionsDeleteSample.js +11 -3
  52. package/dist-esm/samples-dev/privateEndpointConnectionsDeleteSample.js.map +1 -1
  53. package/dist-esm/samples-dev/privateEndpointConnectionsGetSample.js +11 -3
  54. package/dist-esm/samples-dev/privateEndpointConnectionsGetSample.js.map +1 -1
  55. package/dist-esm/samples-dev/privateEndpointConnectionsListByAccountSample.js +11 -3
  56. package/dist-esm/samples-dev/privateEndpointConnectionsListByAccountSample.js.map +1 -1
  57. package/dist-esm/samples-dev/privateLinkResourcesGetSample.js +11 -3
  58. package/dist-esm/samples-dev/privateLinkResourcesGetSample.js.map +1 -1
  59. package/dist-esm/samples-dev/privateLinkResourcesListByAccountSample.js +11 -3
  60. package/dist-esm/samples-dev/privateLinkResourcesListByAccountSample.js.map +1 -1
  61. package/dist-esm/src/deviceUpdate.d.ts.map +1 -1
  62. package/dist-esm/src/deviceUpdate.js +4 -7
  63. package/dist-esm/src/deviceUpdate.js.map +1 -1
  64. package/dist-esm/src/index.d.ts +1 -0
  65. package/dist-esm/src/index.d.ts.map +1 -1
  66. package/dist-esm/src/index.js +1 -0
  67. package/dist-esm/src/index.js.map +1 -1
  68. package/dist-esm/src/models/index.d.ts.map +1 -1
  69. package/dist-esm/src/operations/accounts.d.ts.map +1 -1
  70. package/dist-esm/src/operations/accounts.js +37 -16
  71. package/dist-esm/src/operations/accounts.js.map +1 -1
  72. package/dist-esm/src/operations/instances.d.ts.map +1 -1
  73. package/dist-esm/src/operations/instances.js +19 -8
  74. package/dist-esm/src/operations/instances.js.map +1 -1
  75. package/dist-esm/src/operations/operations.d.ts.map +1 -1
  76. package/dist-esm/src/operations/operations.js +19 -8
  77. package/dist-esm/src/operations/operations.js.map +1 -1
  78. package/dist-esm/src/operations/privateEndpointConnectionProxies.d.ts.map +1 -1
  79. package/dist-esm/src/operations/privateEndpointConnectionProxies.js +8 -4
  80. package/dist-esm/src/operations/privateEndpointConnectionProxies.js.map +1 -1
  81. package/dist-esm/src/operations/privateEndpointConnections.d.ts.map +1 -1
  82. package/dist-esm/src/operations/privateEndpointConnections.js +8 -4
  83. package/dist-esm/src/operations/privateEndpointConnections.js.map +1 -1
  84. package/dist-esm/src/operations/privateLinkResources.d.ts.map +1 -1
  85. package/dist-esm/src/operations/privateLinkResources.js +8 -4
  86. package/dist-esm/src/operations/privateLinkResources.js.map +1 -1
  87. package/dist-esm/src/pagingHelper.d.ts +13 -0
  88. package/dist-esm/src/pagingHelper.d.ts.map +1 -0
  89. package/dist-esm/src/pagingHelper.js +32 -0
  90. package/dist-esm/src/pagingHelper.js.map +1 -0
  91. package/package.json +7 -5
  92. package/review/arm-deviceupdate.api.md +3 -0
  93. package/src/deviceUpdate.ts +5 -6
  94. package/src/index.ts +1 -0
  95. package/src/models/index.ts +25 -25
  96. package/src/operations/accounts.ts +45 -18
  97. package/src/operations/instances.ts +26 -13
  98. package/src/operations/operations.ts +21 -9
  99. package/src/operations/privateEndpointConnectionProxies.ts +11 -9
  100. package/src/operations/privateEndpointConnections.ts +11 -9
  101. package/src/operations/privateLinkResources.ts +11 -9
  102. package/src/pagingHelper.ts +39 -0
  103. package/types/arm-deviceupdate.d.ts +9 -0
package/CHANGELOG.md CHANGED
@@ -1,15 +1,12 @@
1
1
  # Release History
2
+
3
+ ## 1.1.0 (2023-01-09)
4
+
5
+ **Features**
2
6
 
3
- ## 1.0.1 (Unreleased)
4
-
5
- ### Features Added
6
-
7
- ### Breaking Changes
8
-
9
- ### Bugs Fixed
10
-
11
- ### Other Changes
7
+ - Added function getContinuationToken
12
8
 
9
+
13
10
  ## 1.0.0 (2022-08-18)
14
11
 
15
12
  The package of @azure/arm-deviceupdate is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/js-track2-quickstart).
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2022 Microsoft
3
+ Copyright (c) 2023 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/dist/index.js CHANGED
@@ -28,6 +28,38 @@ function _interopNamespace(e) {
28
28
  var coreClient__namespace = /*#__PURE__*/_interopNamespace(coreClient);
29
29
  var coreRestPipeline__namespace = /*#__PURE__*/_interopNamespace(coreRestPipeline);
30
30
 
31
+ /*
32
+ * Copyright (c) Microsoft Corporation.
33
+ * Licensed under the MIT License.
34
+ *
35
+ * Code generated by Microsoft (R) AutoRest Code Generator.
36
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
37
+ */
38
+ const pageMap = new WeakMap();
39
+ /**
40
+ * Given the last `.value` produced by the `byPage` iterator,
41
+ * returns a continuation token that can be used to begin paging from
42
+ * that point later.
43
+ * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator.
44
+ * @returns The continuation token that can be passed into byPage() during future calls.
45
+ */
46
+ function getContinuationToken(page) {
47
+ var _a;
48
+ if (typeof page !== "object" || page === null) {
49
+ return undefined;
50
+ }
51
+ return (_a = pageMap.get(page)) === null || _a === void 0 ? void 0 : _a.continuationToken;
52
+ }
53
+ function setContinuationToken(page, continuationToken) {
54
+ var _a;
55
+ if (typeof page !== "object" || page === null || !continuationToken) {
56
+ return;
57
+ }
58
+ const pageInfo = (_a = pageMap.get(page)) !== null && _a !== void 0 ? _a : {};
59
+ pageInfo.continuationToken = continuationToken;
60
+ pageMap.set(page, pageInfo);
61
+ }
62
+
31
63
  /*
32
64
  * Copyright (c) Microsoft Corporation.
33
65
  * Licensed under the MIT License.
@@ -1719,20 +1751,31 @@ class AccountsImpl {
1719
1751
  [Symbol.asyncIterator]() {
1720
1752
  return this;
1721
1753
  },
1722
- byPage: () => {
1723
- return this.listBySubscriptionPagingPage(options);
1754
+ byPage: (settings) => {
1755
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
1756
+ throw new Error("maxPageSize is not supported by this operation.");
1757
+ }
1758
+ return this.listBySubscriptionPagingPage(options, settings);
1724
1759
  }
1725
1760
  };
1726
1761
  }
1727
- listBySubscriptionPagingPage(options) {
1762
+ listBySubscriptionPagingPage(options, settings) {
1728
1763
  return tslib.__asyncGenerator(this, arguments, function* listBySubscriptionPagingPage_1() {
1729
- let result = yield tslib.__await(this._listBySubscription(options));
1730
- yield yield tslib.__await(result.value || []);
1731
- let continuationToken = result.nextLink;
1764
+ let result;
1765
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
1766
+ if (!continuationToken) {
1767
+ result = yield tslib.__await(this._listBySubscription(options));
1768
+ let page = result.value || [];
1769
+ continuationToken = result.nextLink;
1770
+ setContinuationToken(page, continuationToken);
1771
+ yield yield tslib.__await(page);
1772
+ }
1732
1773
  while (continuationToken) {
1733
1774
  result = yield tslib.__await(this._listBySubscriptionNext(continuationToken, options));
1734
1775
  continuationToken = result.nextLink;
1735
- yield yield tslib.__await(result.value || []);
1776
+ let page = result.value || [];
1777
+ setContinuationToken(page, continuationToken);
1778
+ yield yield tslib.__await(page);
1736
1779
  }
1737
1780
  });
1738
1781
  }
@@ -1768,20 +1811,31 @@ class AccountsImpl {
1768
1811
  [Symbol.asyncIterator]() {
1769
1812
  return this;
1770
1813
  },
1771
- byPage: () => {
1772
- return this.listByResourceGroupPagingPage(resourceGroupName, options);
1814
+ byPage: (settings) => {
1815
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
1816
+ throw new Error("maxPageSize is not supported by this operation.");
1817
+ }
1818
+ return this.listByResourceGroupPagingPage(resourceGroupName, options, settings);
1773
1819
  }
1774
1820
  };
1775
1821
  }
1776
- listByResourceGroupPagingPage(resourceGroupName, options) {
1822
+ listByResourceGroupPagingPage(resourceGroupName, options, settings) {
1777
1823
  return tslib.__asyncGenerator(this, arguments, function* listByResourceGroupPagingPage_1() {
1778
- let result = yield tslib.__await(this._listByResourceGroup(resourceGroupName, options));
1779
- yield yield tslib.__await(result.value || []);
1780
- let continuationToken = result.nextLink;
1824
+ let result;
1825
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
1826
+ if (!continuationToken) {
1827
+ result = yield tslib.__await(this._listByResourceGroup(resourceGroupName, options));
1828
+ let page = result.value || [];
1829
+ continuationToken = result.nextLink;
1830
+ setContinuationToken(page, continuationToken);
1831
+ yield yield tslib.__await(page);
1832
+ }
1781
1833
  while (continuationToken) {
1782
1834
  result = yield tslib.__await(this._listByResourceGroupNext(resourceGroupName, continuationToken, options));
1783
1835
  continuationToken = result.nextLink;
1784
- yield yield tslib.__await(result.value || []);
1836
+ let page = result.value || [];
1837
+ setContinuationToken(page, continuationToken);
1838
+ yield yield tslib.__await(page);
1785
1839
  }
1786
1840
  });
1787
1841
  }
@@ -2189,7 +2243,6 @@ const listBySubscriptionNextOperationSpec = {
2189
2243
  bodyMapper: ErrorResponse
2190
2244
  }
2191
2245
  },
2192
- queryParameters: [apiVersion],
2193
2246
  urlParameters: [
2194
2247
  $host,
2195
2248
  subscriptionId,
@@ -2209,7 +2262,6 @@ const listByResourceGroupNextOperationSpec = {
2209
2262
  bodyMapper: ErrorResponse
2210
2263
  }
2211
2264
  },
2212
- queryParameters: [apiVersion],
2213
2265
  urlParameters: [
2214
2266
  $host,
2215
2267
  subscriptionId,
@@ -2252,20 +2304,31 @@ class InstancesImpl {
2252
2304
  [Symbol.asyncIterator]() {
2253
2305
  return this;
2254
2306
  },
2255
- byPage: () => {
2256
- return this.listByAccountPagingPage(resourceGroupName, accountName, options);
2307
+ byPage: (settings) => {
2308
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
2309
+ throw new Error("maxPageSize is not supported by this operation.");
2310
+ }
2311
+ return this.listByAccountPagingPage(resourceGroupName, accountName, options, settings);
2257
2312
  }
2258
2313
  };
2259
2314
  }
2260
- listByAccountPagingPage(resourceGroupName, accountName, options) {
2315
+ listByAccountPagingPage(resourceGroupName, accountName, options, settings) {
2261
2316
  return tslib.__asyncGenerator(this, arguments, function* listByAccountPagingPage_1() {
2262
- let result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
2263
- yield yield tslib.__await(result.value || []);
2264
- let continuationToken = result.nextLink;
2317
+ let result;
2318
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
2319
+ if (!continuationToken) {
2320
+ result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
2321
+ let page = result.value || [];
2322
+ continuationToken = result.nextLink;
2323
+ setContinuationToken(page, continuationToken);
2324
+ yield yield tslib.__await(page);
2325
+ }
2265
2326
  while (continuationToken) {
2266
2327
  result = yield tslib.__await(this._listByAccountNext(resourceGroupName, accountName, continuationToken, options));
2267
2328
  continuationToken = result.nextLink;
2268
- yield yield tslib.__await(result.value || []);
2329
+ let page = result.value || [];
2330
+ setContinuationToken(page, continuationToken);
2331
+ yield yield tslib.__await(page);
2269
2332
  }
2270
2333
  });
2271
2334
  }
@@ -2610,7 +2673,6 @@ const listByAccountNextOperationSpec = {
2610
2673
  bodyMapper: ErrorResponse
2611
2674
  }
2612
2675
  },
2613
- queryParameters: [apiVersion],
2614
2676
  urlParameters: [
2615
2677
  $host,
2616
2678
  subscriptionId,
@@ -2654,14 +2716,18 @@ class PrivateEndpointConnectionsImpl {
2654
2716
  [Symbol.asyncIterator]() {
2655
2717
  return this;
2656
2718
  },
2657
- byPage: () => {
2658
- return this.listByAccountPagingPage(resourceGroupName, accountName, options);
2719
+ byPage: (settings) => {
2720
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
2721
+ throw new Error("maxPageSize is not supported by this operation.");
2722
+ }
2723
+ return this.listByAccountPagingPage(resourceGroupName, accountName, options, settings);
2659
2724
  }
2660
2725
  };
2661
2726
  }
2662
- listByAccountPagingPage(resourceGroupName, accountName, options) {
2727
+ listByAccountPagingPage(resourceGroupName, accountName, options, _settings) {
2663
2728
  return tslib.__asyncGenerator(this, arguments, function* listByAccountPagingPage_1() {
2664
- let result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
2729
+ let result;
2730
+ result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
2665
2731
  yield yield tslib.__await(result.value || []);
2666
2732
  });
2667
2733
  }
@@ -2968,14 +3034,18 @@ class PrivateLinkResourcesImpl {
2968
3034
  [Symbol.asyncIterator]() {
2969
3035
  return this;
2970
3036
  },
2971
- byPage: () => {
2972
- return this.listByAccountPagingPage(resourceGroupName, accountName, options);
3037
+ byPage: (settings) => {
3038
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
3039
+ throw new Error("maxPageSize is not supported by this operation.");
3040
+ }
3041
+ return this.listByAccountPagingPage(resourceGroupName, accountName, options, settings);
2973
3042
  }
2974
3043
  };
2975
3044
  }
2976
- listByAccountPagingPage(resourceGroupName, accountName, options) {
3045
+ listByAccountPagingPage(resourceGroupName, accountName, options, _settings) {
2977
3046
  return tslib.__asyncGenerator(this, arguments, function* listByAccountPagingPage_1() {
2978
- let result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
3047
+ let result;
3048
+ result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
2979
3049
  yield yield tslib.__await(result.value || []);
2980
3050
  });
2981
3051
  }
@@ -3095,14 +3165,18 @@ class PrivateEndpointConnectionProxiesImpl {
3095
3165
  [Symbol.asyncIterator]() {
3096
3166
  return this;
3097
3167
  },
3098
- byPage: () => {
3099
- return this.listByAccountPagingPage(resourceGroupName, accountName, options);
3168
+ byPage: (settings) => {
3169
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
3170
+ throw new Error("maxPageSize is not supported by this operation.");
3171
+ }
3172
+ return this.listByAccountPagingPage(resourceGroupName, accountName, options, settings);
3100
3173
  }
3101
3174
  };
3102
3175
  }
3103
- listByAccountPagingPage(resourceGroupName, accountName, options) {
3176
+ listByAccountPagingPage(resourceGroupName, accountName, options, _settings) {
3104
3177
  return tslib.__asyncGenerator(this, arguments, function* listByAccountPagingPage_1() {
3105
- let result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
3178
+ let result;
3179
+ result = yield tslib.__await(this._listByAccount(resourceGroupName, accountName, options));
3106
3180
  yield yield tslib.__await(result.value || []);
3107
3181
  });
3108
3182
  }
@@ -3489,20 +3563,31 @@ class OperationsImpl {
3489
3563
  [Symbol.asyncIterator]() {
3490
3564
  return this;
3491
3565
  },
3492
- byPage: () => {
3493
- return this.listPagingPage(options);
3566
+ byPage: (settings) => {
3567
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
3568
+ throw new Error("maxPageSize is not supported by this operation.");
3569
+ }
3570
+ return this.listPagingPage(options, settings);
3494
3571
  }
3495
3572
  };
3496
3573
  }
3497
- listPagingPage(options) {
3574
+ listPagingPage(options, settings) {
3498
3575
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
3499
- let result = yield tslib.__await(this._list(options));
3500
- yield yield tslib.__await(result.value || []);
3501
- let continuationToken = result.nextLink;
3576
+ let result;
3577
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
3578
+ if (!continuationToken) {
3579
+ result = yield tslib.__await(this._list(options));
3580
+ let page = result.value || [];
3581
+ continuationToken = result.nextLink;
3582
+ setContinuationToken(page, continuationToken);
3583
+ yield yield tslib.__await(page);
3584
+ }
3502
3585
  while (continuationToken) {
3503
3586
  result = yield tslib.__await(this._listNext(continuationToken, options));
3504
3587
  continuationToken = result.nextLink;
3505
- yield yield tslib.__await(result.value || []);
3588
+ let page = result.value || [];
3589
+ setContinuationToken(page, continuationToken);
3590
+ yield yield tslib.__await(page);
3506
3591
  }
3507
3592
  });
3508
3593
  }
@@ -3569,7 +3654,6 @@ const listNextOperationSpec = {
3569
3654
  bodyMapper: ErrorResponse
3570
3655
  }
3571
3656
  },
3572
- queryParameters: [apiVersion],
3573
3657
  urlParameters: [$host, nextLink],
3574
3658
  headerParameters: [accept],
3575
3659
  serializer: serializer$1
@@ -3590,7 +3674,7 @@ class DeviceUpdate extends coreClient__namespace.ServiceClient {
3590
3674
  * @param options The parameter options
3591
3675
  */
3592
3676
  constructor(credentials, subscriptionId, options) {
3593
- var _a, _b;
3677
+ var _a, _b, _c;
3594
3678
  if (credentials === undefined) {
3595
3679
  throw new Error("'credentials' cannot be null");
3596
3680
  }
@@ -3605,16 +3689,13 @@ class DeviceUpdate extends coreClient__namespace.ServiceClient {
3605
3689
  requestContentType: "application/json; charset=utf-8",
3606
3690
  credential: credentials
3607
3691
  };
3608
- const packageDetails = `azsdk-js-arm-deviceupdate/1.0.1`;
3692
+ const packageDetails = `azsdk-js-arm-deviceupdate/1.1.0`;
3609
3693
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
3610
3694
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
3611
3695
  : `${packageDetails}`;
3612
- if (!options.credentialScopes) {
3613
- options.credentialScopes = ["https://management.azure.com/.default"];
3614
- }
3615
3696
  const optionsWithDefaults = Object.assign(Object.assign(Object.assign({}, defaults), options), { userAgentOptions: {
3616
3697
  userAgentPrefix
3617
- }, baseUri: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" });
3698
+ }, endpoint: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" });
3618
3699
  super(optionsWithDefaults);
3619
3700
  let bearerTokenAuthenticationPolicyFound = false;
3620
3701
  if ((options === null || options === void 0 ? void 0 : options.pipeline) && options.pipeline.getOrderedPolicies().length > 0) {
@@ -3631,7 +3712,7 @@ class DeviceUpdate extends coreClient__namespace.ServiceClient {
3631
3712
  });
3632
3713
  this.pipeline.addPolicy(coreRestPipeline__namespace.bearerTokenAuthenticationPolicy({
3633
3714
  credential: credentials,
3634
- scopes: `${optionsWithDefaults.credentialScopes}`,
3715
+ scopes: (_c = optionsWithDefaults.credentialScopes) !== null && _c !== void 0 ? _c : `${optionsWithDefaults.endpoint}/.default`,
3635
3716
  challengeCallbacks: {
3636
3717
  authorizeRequestOnChallenge: coreClient__namespace.authorizeRequestOnClaimChallenge
3637
3718
  }
@@ -3708,4 +3789,5 @@ const checkNameAvailabilityOperationSpec = {
3708
3789
  };
3709
3790
 
3710
3791
  exports.DeviceUpdate = DeviceUpdate;
3792
+ exports.getContinuationToken = getContinuationToken;
3711
3793
  //# sourceMappingURL=index.js.map