@azure/digital-twins-core 1.1.0-alpha.20220627.2 → 1.1.0-alpha.20220719.4
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.
- package/dist/index.js +7 -10
- package/dist/index.js.map +1 -1
- package/dist-esm/src/digitalTwinsClient.js +3 -7
- package/dist-esm/src/digitalTwinsClient.js.map +1 -1
- package/dist-esm/src/generated/azureDigitalTwinsAPIContext.js +1 -1
- package/dist-esm/src/generated/azureDigitalTwinsAPIContext.js.map +1 -1
- package/dist-esm/src/generated/models/parameters.js +1 -1
- package/dist-esm/src/generated/models/parameters.js.map +1 -1
- package/package.json +1 -1
- package/types/digital-twins-core.d.ts +1 -5
package/dist/index.js
CHANGED
|
@@ -560,7 +560,7 @@ const tracestate = {
|
|
|
560
560
|
const apiVersion = {
|
|
561
561
|
parameterPath: "apiVersion",
|
|
562
562
|
mapper: {
|
|
563
|
-
defaultValue: "
|
|
563
|
+
defaultValue: "2022-05-31",
|
|
564
564
|
isConstant: true,
|
|
565
565
|
serializedName: "api-version",
|
|
566
566
|
type: {
|
|
@@ -1894,7 +1894,7 @@ class AzureDigitalTwinsAPIContext extends coreHttp__namespace.ServiceClient {
|
|
|
1894
1894
|
// Assigning values to Constant parameters
|
|
1895
1895
|
this.$host =
|
|
1896
1896
|
options.$host || "https://digitaltwins-name.digitaltwins.azure.net";
|
|
1897
|
-
this.apiVersion = options.apiVersion || "
|
|
1897
|
+
this.apiVersion = options.apiVersion || "2022-05-31";
|
|
1898
1898
|
}
|
|
1899
1899
|
}
|
|
1900
1900
|
|
|
@@ -1921,7 +1921,7 @@ class AzureDigitalTwinsAPI extends AzureDigitalTwinsAPIContext {
|
|
|
1921
1921
|
|
|
1922
1922
|
// Copyright (c) Microsoft Corporation.
|
|
1923
1923
|
// Licensed under the MIT license.
|
|
1924
|
-
const SDK_VERSION = "1.1.0";
|
|
1924
|
+
const SDK_VERSION$1 = "1.1.0";
|
|
1925
1925
|
|
|
1926
1926
|
// Copyright (c) Microsoft Corporation.
|
|
1927
1927
|
/**
|
|
@@ -1931,7 +1931,7 @@ const SDK_VERSION = "1.1.0";
|
|
|
1931
1931
|
const tracingClient = coreTracing.createTracingClient({
|
|
1932
1932
|
namespace: "Microsoft.DigitalTwins",
|
|
1933
1933
|
packageName: "@azure/digital-twins-core",
|
|
1934
|
-
packageVersion: SDK_VERSION,
|
|
1934
|
+
packageVersion: SDK_VERSION$1,
|
|
1935
1935
|
});
|
|
1936
1936
|
|
|
1937
1937
|
// Copyright (c) Microsoft Corporation.
|
|
@@ -1941,6 +1941,7 @@ const tracingClient = coreTracing.createTracingClient({
|
|
|
1941
1941
|
const logger = logger$1.createClientLogger("azure-digitaltwins-core");
|
|
1942
1942
|
|
|
1943
1943
|
// Copyright (c) Microsoft Corporation.
|
|
1944
|
+
const SDK_VERSION = "1.1.0";
|
|
1944
1945
|
const DEFAULT_DIGITALTWINS_SCOPE = "https://digitaltwins.azure.net/.default";
|
|
1945
1946
|
/**
|
|
1946
1947
|
* Client for Azure IoT DigitalTwins API.
|
|
@@ -1963,10 +1964,6 @@ class DigitalTwinsClient {
|
|
|
1963
1964
|
* @param options - Used to configure the service client.
|
|
1964
1965
|
*/
|
|
1965
1966
|
constructor(endpointUrl, credential, options = {}) {
|
|
1966
|
-
/**
|
|
1967
|
-
* @deprecated Please use {@link DigitalTwinsClient.decommissionModel} instead.
|
|
1968
|
-
*/
|
|
1969
|
-
this.decomissionModel = this.decommissionModel;
|
|
1970
1967
|
const authPolicy = coreHttp.bearerTokenAuthenticationPolicy(credential, DEFAULT_DIGITALTWINS_SCOPE);
|
|
1971
1968
|
const libInfo = `azsdk-js-digital-twins-core/${SDK_VERSION}`;
|
|
1972
1969
|
const { apiVersion } = options, pipelineOptions = tslib.__rest(options, ["apiVersion"]);
|
|
@@ -2418,9 +2415,9 @@ class DigitalTwinsClient {
|
|
|
2418
2415
|
* @returns The http response.
|
|
2419
2416
|
*
|
|
2420
2417
|
*/
|
|
2421
|
-
|
|
2418
|
+
decomissionModel(modelId, options = {}) {
|
|
2422
2419
|
const jsonPatch = [{ op: "replace", path: "/decommissioned", value: true }];
|
|
2423
|
-
return tracingClient.withSpan("DigitalTwinsClient.
|
|
2420
|
+
return tracingClient.withSpan("DigitalTwinsClient.decomissionModel", options, async (updatedOptions) => {
|
|
2424
2421
|
return this.client.digitalTwinModels.update(modelId, jsonPatch, updatedOptions);
|
|
2425
2422
|
});
|
|
2426
2423
|
}
|