@azure/arm-botservice
Advanced tools
Comparing version 4.0.0-alpha.20220413.1 to 4.0.0-alpha.20220414.2
# Release History | ||
## 4.0.0-beta.3 (Unreleased) | ||
## 4.0.0-beta.4 (Unreleased) | ||
@@ -13,5 +13,5 @@ ### Features Added | ||
## 4.0.0-beta.2 (2021-12-27) | ||
## 4.0.0-beta.3 (2022-04-11) | ||
The package of @azure/arm-botservice is using our next generation design principles since version 4.0.0-beta.2, which contains breaking changes. | ||
The package of @azure/arm-botservice is using our next generation design principles since version 4.0.0-beta.3, which contains breaking changes. | ||
@@ -18,0 +18,0 @@ To understand the detail of the change, please refer to [Changelog](https://aka.ms/js-track2-changelog). |
@@ -18,2 +18,3 @@ /* | ||
constructor(credentials, subscriptionId, options) { | ||
var _a, _b; | ||
if (credentials === undefined) { | ||
@@ -33,3 +34,3 @@ throw new Error("'credentials' cannot be null"); | ||
}; | ||
const packageDetails = `azsdk-js-arm-botservice/4.0.0-beta.2`; | ||
const packageDetails = `azsdk-js-arm-botservice/4.0.0-beta.4`; | ||
const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix | ||
@@ -43,3 +44,3 @@ ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` | ||
userAgentPrefix | ||
}, baseUri: options.endpoint || "https://management.azure.com" }); | ||
}, baseUri: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" }); | ||
super(optionsWithDefaults); | ||
@@ -46,0 +47,0 @@ // Parameter assignments |
@@ -53,6 +53,8 @@ /* | ||
const lro = new LroImpl(sendOperation, { operationResultId, options }, getOperationSpec); | ||
return new LroEngine(lro, { | ||
const poller = new LroEngine(lro, { | ||
resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom, | ||
intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs | ||
}); | ||
yield poller.poll(); | ||
return poller; | ||
}); | ||
@@ -59,0 +61,0 @@ } |
@@ -6,3 +6,3 @@ { | ||
"description": "A generated SDK for AzureBotService.", | ||
"version": "4.0.0-alpha.20220413.1", | ||
"version": "4.0.0-alpha.20220414.2", | ||
"engines": { | ||
@@ -34,8 +34,8 @@ "node": ">=12.0.0" | ||
"@rollup/plugin-commonjs": "^21.0.1", | ||
"@rollup/plugin-json": "^4.0.0", | ||
"@rollup/plugin-multi-entry": "^3.0.0", | ||
"@rollup/plugin-node-resolve": "^8.0.0", | ||
"@rollup/plugin-json": "^4.1.0", | ||
"@rollup/plugin-multi-entry": "^4.1.0", | ||
"@rollup/plugin-node-resolve": "^13.1.3", | ||
"mkdirp": "^1.0.4", | ||
"rollup": "^2.0.0", | ||
"rollup-plugin-sourcemaps": "^0.4.2", | ||
"rollup": "^2.66.1", | ||
"rollup-plugin-sourcemaps": "^0.6.3", | ||
"typescript": "~4.2.0", | ||
@@ -103,3 +103,19 @@ "uglify-js": "^3.4.9", | ||
"sideEffects": false, | ||
"autoPublish": true | ||
"//metadata": { | ||
"constantPaths": [ | ||
{ | ||
"path": "src/azureBotService.ts", | ||
"prefix": "packageDetails" | ||
} | ||
] | ||
}, | ||
"autoPublish": true, | ||
"//sampleConfiguration": { | ||
"productName": "", | ||
"productSlugs": [ | ||
"azure" | ||
], | ||
"disableDocsMs": true, | ||
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-botservice?view=azure-node-preview" | ||
} | ||
} |
@@ -19,2 +19,4 @@ # Azure Bot client library for JavaScript | ||
See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details. | ||
### Prerequisites | ||
@@ -53,4 +55,13 @@ | ||
const { DefaultAzureCredential } = require("@azure/identity"); | ||
// For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details. | ||
const subscriptionId = "00000000-0000-0000-0000-000000000000"; | ||
const client = new AzureBotService(new DefaultAzureCredential(), subscriptionId); | ||
// For client-side applications running in the browser, use this code instead: | ||
// const credential = new InteractiveBrowserCredential({ | ||
// tenantId: "<YOUR_TENANT_ID>", | ||
// clientId: "<YOUR_CLIENT_ID>" | ||
// }); | ||
// const client = new AzureBotService(credential, subscriptionId); | ||
``` | ||
@@ -57,0 +68,0 @@ |
@@ -17,58 +17,10 @@ /* | ||
/** | ||
* Gets the proper configuration needed for rollup's commonJS plugin for @opentelemetry/api. | ||
* | ||
* NOTE: this manual configuration is only needed because OpenTelemetry uses an | ||
* __exportStar downleveled helper function to declare its exports which confuses | ||
* rollup's automatic discovery mechanism. | ||
* | ||
* @returns an object reference that can be `...`'d into your cjs() configuration. | ||
*/ | ||
export function openTelemetryCommonJs() { | ||
const namedExports = {}; | ||
for (const key of [ | ||
"@opentelemetry/api", | ||
"@azure/core-tracing/node_modules/@opentelemetry/api" | ||
]) { | ||
namedExports[key] = [ | ||
"SpanKind", | ||
"TraceFlags", | ||
"getSpan", | ||
"setSpan", | ||
"SpanStatusCode", | ||
"getSpanContext", | ||
"setSpanContext" | ||
]; | ||
} | ||
const releasedOpenTelemetryVersions = ["0.10.2", "1.0.0-rc.0"]; | ||
for (const version of releasedOpenTelemetryVersions) { | ||
namedExports[ | ||
// working around a limitation in the rollup common.js plugin - it's not able to resolve these modules so the named exports listed above will not get applied. We have to drill down to the actual path. | ||
`../../../common/temp/node_modules/.pnpm/@opentelemetry/api@${version}/node_modules/@opentelemetry/api/build/src/index.js` | ||
] = [ | ||
"SpanKind", | ||
"TraceFlags", | ||
"getSpan", | ||
"setSpan", | ||
"StatusCode", | ||
"CanonicalCode", | ||
"getSpanContext", | ||
"setSpanContext" | ||
]; | ||
} | ||
return namedExports; | ||
} | ||
// #region Warning Handler | ||
/** | ||
* A function that can determine whether a rollupwarning should be ignored. If | ||
* A function that can determine whether a rollup warning should be ignored. If | ||
* the function returns `true`, then the warning will not be displayed. | ||
*/ | ||
function ignoreNiseSinonEvalWarnings(warning) { | ||
function ignoreNiseSinonEval(warning) { | ||
return ( | ||
@@ -82,3 +34,3 @@ warning.code === "EVAL" && | ||
function ignoreChaiCircularDependencyWarnings(warning) { | ||
function ignoreChaiCircularDependency(warning) { | ||
return ( | ||
@@ -90,6 +42,3 @@ warning.code === "CIRCULAR_DEPENDENCY" && | ||
const warningInhibitors = [ | ||
ignoreChaiCircularDependencyWarnings, | ||
ignoreNiseSinonEvalWarnings | ||
]; | ||
const warningInhibitors = [ignoreChaiCircularDependency, ignoreNiseSinonEval]; | ||
@@ -128,18 +77,3 @@ /** | ||
}), | ||
cjs({ | ||
namedExports: { | ||
// Chai's strange internal architecture makes it impossible to statically | ||
// analyze its exports. | ||
chai: [ | ||
"version", | ||
"use", | ||
"util", | ||
"config", | ||
"expect", | ||
"should", | ||
"assert" | ||
], | ||
...openTelemetryCommonJs() | ||
} | ||
}), | ||
cjs(), | ||
json(), | ||
@@ -180,3 +114,3 @@ sourcemaps() | ||
preserveSymlinks: false, | ||
plugins: [sourcemaps(), nodeResolve(), cjs()] | ||
plugins: [sourcemaps(), nodeResolve()] | ||
}; | ||
@@ -183,0 +117,0 @@ |
@@ -67,3 +67,3 @@ /* | ||
const packageDetails = `azsdk-js-arm-botservice/4.0.0-beta.2`; | ||
const packageDetails = `azsdk-js-arm-botservice/4.0.0-beta.4`; | ||
const userAgentPrefix = | ||
@@ -83,3 +83,4 @@ options.userAgentOptions && options.userAgentOptions.userAgentPrefix | ||
}, | ||
baseUri: options.endpoint || "https://management.azure.com" | ||
baseUri: | ||
options.endpoint ?? options.baseUri ?? "https://management.azure.com" | ||
}; | ||
@@ -86,0 +87,0 @@ super(optionsWithDefaults); |
@@ -91,6 +91,8 @@ /* | ||
); | ||
return new LroEngine(lro, { | ||
const poller = new LroEngine(lro, { | ||
resumeFrom: options?.resumeFrom, | ||
intervalInMs: options?.updateIntervalInMs | ||
}); | ||
await poller.poll(); | ||
return poller; | ||
} | ||
@@ -97,0 +99,0 @@ |
@@ -12,9 +12,23 @@ { | ||
"forceConsistentCasingInFileNames": true, | ||
"lib": ["es6", "dom"], | ||
"lib": [ | ||
"es6", | ||
"dom" | ||
], | ||
"declaration": true, | ||
"outDir": "./dist-esm", | ||
"importHelpers": true | ||
"importHelpers": true, | ||
"paths": { | ||
"@azure/arm-botservice": [ | ||
"./src/index" | ||
] | ||
} | ||
}, | ||
"include": ["./src/**/*.ts", "./test/**/*.ts"], | ||
"exclude": ["node_modules"] | ||
} | ||
"include": [ | ||
"./src/**/*.ts", | ||
"./test/**/*.ts", | ||
"samples-dev/**/*.ts" | ||
], | ||
"exclude": [ | ||
"node_modules" | ||
] | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1338503
263
20876
110