@azure/template 1.0.12-beta.3829994 → 1.0.12-beta.4086740

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 (50) hide show
  1. package/dist/browser/configurationClient.js +1 -1
  2. package/dist/browser/configurationClient.js.map +1 -1
  3. package/dist/browser/constants.js +2 -2
  4. package/dist/browser/constants.js.map +1 -1
  5. package/dist/browser/generated/generatedClientContext.js +1 -1
  6. package/dist/browser/generated/generatedClientContext.js.map +1 -1
  7. package/dist/browser/index.js +1 -1
  8. package/dist/browser/index.js.map +1 -1
  9. package/dist/browser/logger.js +1 -1
  10. package/dist/browser/logger.js.map +1 -1
  11. package/dist/browser/util.js +1 -1
  12. package/dist/browser/util.js.map +1 -1
  13. package/dist/commonjs/configurationClient.js +1 -1
  14. package/dist/commonjs/configurationClient.js.map +1 -1
  15. package/dist/commonjs/constants.js +2 -2
  16. package/dist/commonjs/constants.js.map +1 -1
  17. package/dist/commonjs/generated/generatedClientContext.js +1 -1
  18. package/dist/commonjs/generated/generatedClientContext.js.map +1 -1
  19. package/dist/commonjs/index.js +1 -1
  20. package/dist/commonjs/index.js.map +1 -1
  21. package/dist/commonjs/logger.js +1 -1
  22. package/dist/commonjs/logger.js.map +1 -1
  23. package/dist/commonjs/tsdoc-metadata.json +1 -1
  24. package/dist/commonjs/util.js +2 -3
  25. package/dist/commonjs/util.js.map +1 -1
  26. package/dist/esm/configurationClient.js +1 -1
  27. package/dist/esm/configurationClient.js.map +1 -1
  28. package/dist/esm/constants.js +2 -2
  29. package/dist/esm/constants.js.map +1 -1
  30. package/dist/esm/generated/generatedClientContext.js +1 -1
  31. package/dist/esm/generated/generatedClientContext.js.map +1 -1
  32. package/dist/esm/index.js +1 -1
  33. package/dist/esm/index.js.map +1 -1
  34. package/dist/esm/logger.js +1 -1
  35. package/dist/esm/logger.js.map +1 -1
  36. package/dist/esm/util.js +1 -1
  37. package/dist/esm/util.js.map +1 -1
  38. package/dist/react-native/configurationClient.js +1 -1
  39. package/dist/react-native/configurationClient.js.map +1 -1
  40. package/dist/react-native/constants.js +2 -2
  41. package/dist/react-native/constants.js.map +1 -1
  42. package/dist/react-native/generated/generatedClientContext.js +1 -1
  43. package/dist/react-native/generated/generatedClientContext.js.map +1 -1
  44. package/dist/react-native/index.js +1 -1
  45. package/dist/react-native/index.js.map +1 -1
  46. package/dist/react-native/logger.js +1 -1
  47. package/dist/react-native/logger.js.map +1 -1
  48. package/dist/react-native/util.js +1 -1
  49. package/dist/react-native/util.js.map +1 -1
  50. package/package.json +8 -7
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { GeneratedClient } from "./generated/index.js";
4
4
  import { bearerTokenAuthenticationPolicy } from "@azure/core-rest-pipeline";
5
5
  import { createTracingClient } from "@azure/core-tracing";
@@ -1 +1 @@
1
- {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAwB,MAAM,sBAAsB,CAAC;AAM7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAC;AAE5E,OAAO,EAAiB,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AA2BtC;;GAEG;AACH,MAAM,OAAO,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,+BAA+B,CAAC;YACjD,UAAU;YACV,MAAM,EAAE,GAAG,WAAW,WAAW;SAClC,CAAC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,IAAI,CAAC;gBAC/B,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,WAAW,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
1
+ {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAwB,MAAM,sBAAsB,CAAC;AAM7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAC;AAE5E,OAAO,EAAiB,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AA2BtC;;GAEG;AACH,MAAM,OAAO,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,+BAA+B,CAAC;YACjD,UAAU;YACV,MAAM,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BACxB,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;gBAC/B,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,WAAW,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
3
- export const SDK_VERSION = "1.0.12-beta.3829994";
2
+ // Licensed under the MIT License.
3
+ export const SDK_VERSION = "1.0.12-beta.4086740";
4
4
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.3829994\";\n"]}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.4086740\";\n"]}
@@ -24,7 +24,7 @@ export class GeneratedClientContext extends coreClient.ServiceClient {
24
24
  const defaults = {
25
25
  requestContentType: "application/json; charset=utf-8"
26
26
  };
27
- const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;
27
+ const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;
28
28
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
29
29
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
30
30
  : `${packageDetails}`;
@@ -1 +1 @@
1
- {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
1
+ {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  export * from "./configurationClient.js";
4
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport * from \"./configurationClient.js\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport * from \"./configurationClient.js\";\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { createClientLogger } from "@azure/logger";
4
4
  /**
5
5
  * The \@azure/logger configuration for this package.
@@ -1 +1 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
1
+ {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  /**
4
4
  * Handles etag quoting in AppConfig response objects.
5
5
  *
@@ -1 +1 @@
1
- {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
1
+ {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
3
+ // Licensed under the MIT License.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.ConfigurationClient = void 0;
6
6
  const index_js_1 = require("./generated/index.js");
@@ -1 +1 @@
1
- {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,mDAA6E;AAM7E,kEAA4E;AAE5E,sDAAyE;AACzE,iDAA6C;AAC7C,2CAAqC;AACrC,uCAAsC;AA2BtC;;GAEG;AACH,MAAa,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,IAAA,oDAA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BACN,GAAG,GAAG,YAAY,CAAC,GAAI,CAAC;gBACxB,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;gBAC/B,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,WAAW,GAAG,IAAA,mBAAS,EAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF;AA3HD,kDA2HC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
1
+ {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,mDAA6E;AAM7E,kEAA4E;AAE5E,sDAAyE;AACzE,iDAA6C;AAC7C,2CAAqC;AACrC,uCAAsC;AA2BtC;;GAEG;AACH,MAAa,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,IAAA,oDAA+B,EAAC;YACjD,UAAU;YACV,MAAM,EAAE,GAAG,WAAW,WAAW;SAClC,CAAC,CAAC;QAEH,MAAM,6BAA6B,iDAC9B,OAAO,KACV,sBAAsB,EAAE;gBACtB,oBAAoB,EAAE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GAAG,IAAA,mBAAS,EAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF;AA3HD,kDA2HC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
3
+ // Licensed under the MIT License.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.SDK_VERSION = void 0;
6
- exports.SDK_VERSION = "1.0.12-beta.3829994";
6
+ exports.SDK_VERSION = "1.0.12-beta.4086740";
7
7
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAErB,QAAA,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.3829994\";\n"]}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAErB,QAAA,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.4086740\";\n"]}
@@ -28,7 +28,7 @@ class GeneratedClientContext extends coreClient.ServiceClient {
28
28
  const defaults = {
29
29
  requestContentType: "application/json; charset=utf-8"
30
30
  };
31
- const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;
31
+ const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;
32
32
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
33
33
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
34
34
  : `${packageDetails}`;
@@ -1 +1 @@
1
- {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAEH,uEAAiD;AAGjD,gBAAgB;AAChB,MAAa,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF;AA5CD,wDA4CC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
1
+ {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAEH,uEAAiD;AAGjD,gBAAgB;AAChB,MAAa,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF;AA5CD,wDA4CC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
3
+ // Licensed under the MIT License.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
5
  const tslib_1 = require("tslib");
6
6
  tslib_1.__exportStar(require("./configurationClient.js"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,mEAAyC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport * from \"./configurationClient.js\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,mEAAyC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport * from \"./configurationClient.js\";\n"]}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
3
+ // Licensed under the MIT License.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
5
  exports.logger = void 0;
6
6
  const logger_1 = require("@azure/logger");
@@ -1 +1 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,0CAAmD;AAEnD;;;;GAIG;AACU,QAAA,MAAM,GAAG,IAAA,2BAAkB,EAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
1
+ {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC,0CAAmD;AAEnD;;;;GAIG;AACU,QAAA,MAAM,GAAG,IAAA,2BAAkB,EAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
@@ -5,7 +5,7 @@
5
5
  "toolPackages": [
6
6
  {
7
7
  "packageName": "@microsoft/api-extractor",
8
- "packageVersion": "7.45.1"
8
+ "packageVersion": "7.47.7"
9
9
  }
10
10
  ]
11
11
  }
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT license.
3
+ // Licensed under the MIT License.
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.quoteETag = void 0;
5
+ exports.quoteETag = quoteETag;
6
6
  /**
7
7
  * Handles etag quoting in AppConfig response objects.
8
8
  *
@@ -26,5 +26,4 @@ function quoteETag(etag) {
26
26
  }
27
27
  return `"${etag}"`;
28
28
  }
29
- exports.quoteETag = quoteETag;
30
29
  //# sourceMappingURL=util.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;;AAElC;;;;;;;;;GASG;AACH,SAAgB,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC;AAfD,8BAeC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
1
+ {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;AAYlC,8BAeC;AAzBD;;;;;;;;;GASG;AACH,SAAgB,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { GeneratedClient } from "./generated/index.js";
4
4
  import { bearerTokenAuthenticationPolicy } from "@azure/core-rest-pipeline";
5
5
  import { createTracingClient } from "@azure/core-tracing";
@@ -1 +1 @@
1
- {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.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YAC/B,WAAW,EAAE,iBAAiB;YAC9B,cAAc,EAAE,WAAW;SAC5B,CAAC,CAAC;IACL,CAAC;IAyBM,KAAK,CAAC,uBAAuB,CAClC,YAA2C,EAC3C,UAA0C,EAAE;QAE5C,IAAI,GAAW,CAAC;QAChB,IAAI,WAA+B,CAAC;QAEpC,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ;QAChC,8DAA8D;QAC9D,6CAA6C,EAC7C,OAAO,EACP,CAAC,cAAc,EAAE,EAAE;YACjB,IAAI,OAAO,YAAY,KAAK,QAAQ,EAAE,CAAC;gBACrC,GAAG,GAAG,YAAY,CAAC;gBACnB,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,MAAM,IAAI,UAAU,CAClB,uFAAuF,CACxF,CAAC;gBACJ,CAAC;YACH,CAAC;iBAAM,CAAC;gBACN,GAAG,GAAG,YAAY,CAAC,GAAI,CAAC;gBACxB,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;gBAC/B,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,WAAW,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
1
+ {"version":3,"file":"configuration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AAS,EAAE,iBAAiB;YAC5B,+BAA+B;YAC/B,WAAW,EAAE,iBAAiB;YAC9B,cAAc,EAAE,WAAW;SAC5B,CAAC,CAAC;IACL,CAAC;IAyBM,KAAK,CAAC,uBAAuB,CAClC,YAA2C,EAC3C,UAA0C,EAAE;QAE5C,IAAI,GAAW,CAAC;QAChB,IAAI,WAA+B,CAAC;QAEpC,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ;QAChC,8DAA8D;QAC9D,6CAA6C,EAC7C,OAAO,EACP,CAAC,cAAc,EAAE,EAAE;YACjB,IAAI,OAAO,YAAY,KAAK,QAAQ,EAAE,CAAC;gBACrC,GAAG,GAAG,YAAY,CAAC;gBACnB,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,MAAM,IAAI,UAAU,CAClB,uFAAuF,CACxF,CAAC;gBACJ,CAAC;YACH,CAAC;iBAAM,CAAC;gBACN,GAAG,GAAG,YAAY,CAAC,GAAI,CAAC;gBACxB,MAAM,IAAI,GAAG,YAAY,CAAC,IAAI,CAAC;gBAC/B,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;oBAC1B,WAAW,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;gBAChC,CAAC;YACH,CAAC;YAED,0EAA0E;YAC1E,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,GAAG,kCAAO,cAAc,KAAE,WAAW,IAAG,CAAC;QAC1E,CAAC,CACF,CAAC;IACJ,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
3
- export const SDK_VERSION = "1.0.12-beta.3829994";
2
+ // Licensed under the MIT License.
3
+ export const SDK_VERSION = "1.0.12-beta.4086740";
4
4
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.3829994\";\n"]}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.4086740\";\n"]}
@@ -24,7 +24,7 @@ export class GeneratedClientContext extends coreClient.ServiceClient {
24
24
  const defaults = {
25
25
  requestContentType: "application/json; charset=utf-8"
26
26
  };
27
- const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;
27
+ const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;
28
28
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
29
29
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
30
30
  : `${packageDetails}`;
@@ -1 +1 @@
1
- {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
1
+ {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
package/dist/esm/index.js CHANGED
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  export * from "./configurationClient.js";
4
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport * from \"./configurationClient.js\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport * from \"./configurationClient.js\";\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { createClientLogger } from "@azure/logger";
4
4
  /**
5
5
  * The \@azure/logger configuration for this package.
@@ -1 +1 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
1
+ {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
package/dist/esm/util.js CHANGED
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  /**
4
4
  * Handles etag quoting in AppConfig response objects.
5
5
  *
@@ -1 +1 @@
1
- {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
1
+ {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { GeneratedClient } from "./generated/index.js";
4
4
  import { bearerTokenAuthenticationPolicy } from "@azure/core-rest-pipeline";
5
5
  import { createTracingClient } from "@azure/core-tracing";
@@ -1 +1 @@
1
- {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAwB,MAAM,sBAAsB,CAAC;AAM7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAC;AAE5E,OAAO,EAAiB,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AA2BtC;;GAEG;AACH,MAAM,OAAO,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,+BAA+B,CAAC;YACjD,UAAU;YACV,MAAM,EAAE,GAAG,WAAW,WAAW;SAClC,CAAC,CAAC;QAEH,MAAM,6BAA6B,iDAC9B,OAAO,KACV,sBAAsB,EAAE;gBACtB,oBAAoB,EAAE;oBACpB,IAAI,EAAE;wBACJ,gDAAgD;wBAChD,6CAA6C;wBAC7C,8CAA8C;wBAC9C,iDAAiD;wBACjD,+CAA+C;qBAChD;iBACF;aACF,KACE;YACD,cAAc,EAAE;gBACd,MAAM,EAAE,MAAM,CAAC,IAAI;gBACnB,uEAAuE;gBACvE,uEAAuE;gBAC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right (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
1
+ {"version":3,"file":"configurationClient.js","sourceRoot":"","sources":["../../src/configurationClient.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,eAAe,EAAwB,MAAM,sBAAsB,CAAC;AAM7E,OAAO,EAAE,+BAA+B,EAAE,MAAM,2BAA2B,CAAC;AAE5E,OAAO,EAAiB,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AA2BtC;;GAEG;AACH,MAAM,OAAO,mBAAmB;IAI9B;;;;;;;;;;;;;;;;OAgBG;IACH,YACE,WAAmB,EACnB,UAA2B,EAC3B,UAAsC,EAAE;QAExC,wEAAwE;QACxE,qCAAqC;QACrC,MAAM,UAAU,GAAG,+BAA+B,CAAC;YACjD,UAAU;YACV,MAAM,EAAE,GAAG,WAAW,WAAW;SAClC,CAAC,CAAC;QAEH,MAAM,6BAA6B,iDAC9B,OAAO,KACV,sBAAsB,EAAE;gBACtB,oBAAoB,EAAE;oBACpB,IAAI,EAAE;wBACJ,gDAAgD;wBAChD,6CAA6C;wBAC7C,8CAA8C;wBAC9C,iDAAiD;wBACjD,+CAA+C;qBAChD;iBACF;aACF,KACE;YACD,cAAc,EAAE;gBACd,MAAM,EAAE,MAAM,CAAC,IAAI;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AC;IACJ,CAAC;CACF","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { GeneratedClient, ConfigurationSetting } from \"./generated/index.js\";\nimport {\n CommonClientOptions,\n OperationOptions,\n InternalClientPipelineOptions,\n} from \"@azure/core-client\";\nimport { bearerTokenAuthenticationPolicy } from \"@azure/core-rest-pipeline\";\nimport { TokenCredential } from \"@azure/core-auth\";\nimport { TracingClient, createTracingClient } from \"@azure/core-tracing\";\nimport { SDK_VERSION } from \"./constants.js\";\nimport { logger } from \"./logger.js\";\nimport { quoteETag } from \"./util.js\";\n\n// re-export generated types that are used as public interfaces.\nexport { ConfigurationSetting };\n\n/**\n * Options for the `getConfigurationSetting` method of `ConfigurationClient`.\n */\nexport interface GetConfigurationSettingOptions extends OperationOptions {\n /**\n * If set to `true`, the method will use entity tags to instruct the service\n * to send an updated value only if the value has changed.\n *\n * NOTE: This option is only supported if passing a full\n * `ConfigurationSetting` object with an `etag` as the first parameter to\n * `getConfigurationSetting`.\n */\n onlyIfChanged?: boolean;\n}\n\n/**\n * Client options used to configure App Configuration API requests.\n */\nexport interface ConfigurationClientOptions extends CommonClientOptions {\n // Any custom options configured at the client level go here.\n}\n\n/**\n * The client class used to interact with the App Configuration service.\n */\nexport class ConfigurationClient {\n private client: GeneratedClient;\n private tracingClient: TracingClient;\n\n /**\n * Creates an instance of a ConfigurationClient.\n *\n * Example usage:\n * ```ts\n * import { ConfigurationClient} from \"@azure/ai-text-analytics\";\n * import { DefaultAzureCredential} from \"@azure/identity\";\n *\n * const client = new ConfigurationClient(\n * \"<app configuration endpoint>\",\n * new DefaultAzureCredential()\n * );\n * ```\n * @param endpointUrl - the URL to the App Configuration endpoint\n * @param credential - used to authenticate requests to the service\n * @param options - optional configuration used to send requests to the service\n */\n constructor(\n endpointUrl: string,\n credential: TokenCredential,\n options: ConfigurationClientOptions = {},\n ) {\n // The AAD scope for an API is usually the baseUri + \"/.default\", but it\n // may be different for your service.\n const authPolicy = bearerTokenAuthenticationPolicy({\n credential,\n scopes: `${endpointUrl}/.default`,\n });\n\n const internalClientPipelineOptions: InternalClientPipelineOptions = {\n ...options,\n deserializationOptions: {\n expectedContentTypes: {\n json: [\n \"application/vnd.microsoft.appconfig.kvset+json\",\n \"application/vnd.microsoft.appconfig.kv+json\",\n \"application/vnd.microsoft.appconfig.kvs+json\",\n \"application/vnd.microsoft.appconfig.keyset+json\",\n \"application/vnd.microsoft.appconfig.revs+json\",\n ],\n },\n },\n ...{\n loggingOptions: {\n logger: logger.info,\n // This array contains header names we want to log that are not already\n // included as safe. Unknown/unsafe headers are logged as \"<REDACTED>\".\n additionalAllowedHeaderNames: [\"x-ms-correlation-request-id\"],\n },\n },\n };\n\n this.client = new GeneratedClient(endpointUrl, internalClientPipelineOptions);\n this.client.pipeline.addPolicy(authPolicy);\n this.tracingClient = createTracingClient({\n // The name of the resource provider requests are made against, as described in\n // https://github.com/Azure/azure-sdk/blob/main/docs/tracing/distributed-tracing-conventions.yml#L11-L15\n namespace: \"Microsoft.Learn\",\n // The package name and version\n packageName: \"@azure/template\",\n packageVersion: SDK_VERSION,\n });\n }\n\n /**\n * Retrieve the contents of an App Configuration setting by name (key).\n *\n * @param key - the unique name of the setting to get\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n key: string,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n /**\n * Retrieve an updated value of an App Configuration setting, allowing for\n * the use of entity tags to request the new value only if it has changed.\n *\n * @param setting - the setting to retrieve from the service\n * @param options - optional configuration for the operation\n */\n public async getConfigurationSetting(\n setting: ConfigurationSetting,\n options?: GetConfigurationSettingOptions,\n ): Promise<ConfigurationSetting>;\n\n public async getConfigurationSetting(\n keyOrSetting: string | ConfigurationSetting,\n options: GetConfigurationSettingOptions = {},\n ): Promise<ConfigurationSetting> {\n let key: string;\n let ifNoneMatch: string | undefined;\n\n return this.tracingClient.withSpan(\n // Span names should take the form \"<className>.<methodName>\".\n \"ConfigurationClient.getConfigurationSetting\",\n options,\n (updatedOptions) => {\n if (typeof keyOrSetting === \"string\") {\n key = keyOrSetting;\n if (options.onlyIfChanged) {\n throw new RangeError(\n \"You must pass a ConfigurationSetting instead of a key to perform a conditional fetch.\",\n );\n }\n } else {\n key = keyOrSetting.key!;\n const etag = keyOrSetting.etag;\n if (options.onlyIfChanged) {\n ifNoneMatch = quoteETag(etag);\n }\n }\n\n // You must pass updatedOptions to any calls you make within the callback.\n return this.client.getKeyValue(key, { ...updatedOptions, ifNoneMatch });\n },\n );\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
3
- export const SDK_VERSION = "1.0.12-beta.3829994";
2
+ // Licensed under the MIT License.
3
+ export const SDK_VERSION = "1.0.12-beta.4086740";
4
4
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.3829994\";\n"]}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,CAAC,MAAM,WAAW,GAAW,qBAAqB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport const SDK_VERSION: string = \"1.0.12-beta.4086740\";\n"]}
@@ -24,7 +24,7 @@ export class GeneratedClientContext extends coreClient.ServiceClient {
24
24
  const defaults = {
25
25
  requestContentType: "application/json; charset=utf-8"
26
26
  };
27
- const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;
27
+ const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;
28
28
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
29
29
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
30
30
  : `${packageDetails}`;
@@ -1 +1 @@
1
- {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.3829994`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
1
+ {"version":3,"file":"generatedClientContext.js","sourceRoot":"","sources":["../../../src/generated/generatedClientContext.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AAGjD,gBAAgB;AAChB,MAAM,OAAO,sBAAuB,SAAQ,UAAU,CAAC,aAAa;IAKlE;;;;OAIG;IACH,YAAY,QAAgB,EAAE,OAAuC;QACnE,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC3B,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QAC/C,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAAkC;YAC9C,kBAAkB,EAAE,iCAAiC;SACtD,CAAC;QAEF,MAAM,cAAc,GAAG,uCAAuC,CAAC;QAC/D,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,YAAY,GAC1C,CAAC;QACF,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC3B,wBAAwB;QACxB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QAEzB,0CAA0C;QAC1C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,YAAY,CAAC;IACvD,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport { GeneratedClientOptionalParams } from \"./models/index.js\";\n\n/** @internal */\nexport class GeneratedClientContext extends coreClient.ServiceClient {\n endpoint: string;\n syncToken?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the GeneratedClientContext class.\n * @param endpoint The endpoint of the App Configuration instance to send requests to.\n * @param options The parameter options\n */\n constructor(endpoint: string, options?: GeneratedClientOptionalParams) {\n if (endpoint === undefined) {\n throw new Error(\"'endpoint' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: GeneratedClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\"\n };\n\n const packageDetails = `azsdk-js-template/1.0.12-beta.4086740`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n baseUri: options.endpoint || \"{endpoint}\"\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.endpoint = endpoint;\n\n // Assigning values to Constant parameters\n this.apiVersion = options.apiVersion || \"2023-10-01\";\n }\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  export * from "./configurationClient.js";
4
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nexport * from \"./configurationClient.js\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,cAAc,0BAA0B,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport * from \"./configurationClient.js\";\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  import { createClientLogger } from "@azure/logger";
4
4
  /**
5
5
  * The \@azure/logger configuration for this package.
@@ -1 +1 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
1
+ {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { createClientLogger } from \"@azure/logger\";\n\n/**\n * The \\@azure/logger configuration for this package.\n *\n * @internal\n */\nexport const logger = createClientLogger(\"template\");\n"]}
@@ -1,5 +1,5 @@
1
1
  // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT license.
2
+ // Licensed under the MIT License.
3
3
  /**
4
4
  * Handles etag quoting in AppConfig response objects.
5
5
  *
@@ -1 +1 @@
1
- {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
1
+ {"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/util.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC;;;;;;;;;GASG;AACH,MAAM,UAAU,SAAS,CAAC,IAAwB;IAChD,kDAAkD;IAClD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,GAAG,EAAE,CAAC;QACvC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,IAAI,IAAI,GAAG,CAAC;AACrB,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/**\n * Handles etag quoting in AppConfig response objects.\n *\n * This is important because the etag inside the body of the configuration\n * object isn't quoted, even though the header is.\n *\n * @param etag - the tag to quote, if it isn't quoted already\n *\n * @internal\n */\nexport function quoteETag(etag: string | undefined): string | undefined {\n // https://tools.ietf.org/html/rfc7232#section-3.1\n if (etag === undefined || etag === \"*\") {\n return etag;\n }\n\n if (etag.startsWith('\"') && etag.endsWith('\"')) {\n return etag;\n }\n\n if (etag.startsWith(\"'\") && etag.endsWith(\"'\")) {\n return etag;\n }\n\n return `\"${etag}\"`;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@azure/template",
3
- "version": "1.0.12-beta.3829994",
3
+ "version": "1.0.12-beta.4086740",
4
4
  "description": "Example project for learning how to build a client library",
5
5
  "sdk-type": "client",
6
6
  "main": "./dist/commonjs/index.js",
@@ -47,8 +47,8 @@
47
47
  "integration-test:browser": "tshy && dev-tool run build-test && dev-tool run test:vitest --browser",
48
48
  "integration-test:node": "dev-tool run test:vitest",
49
49
  "integration-test": "npm run integration-test:node && npm run integration-test:browser",
50
- "lint:fix": "eslint README.md package.json api-extractor.json src test --ext .ts,.javascript,.js --fix --fix-type [problem,suggestion]",
51
- "lint": "eslint README.md package.json api-extractor.json src test --ext .ts,.javascript,.js",
50
+ "lint:fix": "eslint README.md package.json api-extractor.json src test --fix --fix-type [problem,suggestion]",
51
+ "lint": "eslint README.md package.json api-extractor.json src test",
52
52
  "pack": "npm pack 2>&1",
53
53
  "test:browser": "npm run clean && npm run integration-test:browser",
54
54
  "test:node": "npm run clean && npm run build:test && npm run integration-test:node",
@@ -102,13 +102,13 @@
102
102
  "@vitest/coverage-istanbul": "^1.5.3",
103
103
  "cross-env": "^7.0.2",
104
104
  "dotenv": "^16.0.0",
105
- "eslint": "^8.56.0",
105
+ "eslint": "^9.9.0",
106
106
  "loupe": "^3.1.0",
107
107
  "playwright": "^1.41.2",
108
108
  "rimraf": "^5.0.5",
109
109
  "source-map-support": "^0.5.9",
110
- "tshy": "^1.14.0",
111
- "typescript": "~5.4.5",
110
+ "tshy": "^2.0.0",
111
+ "typescript": "~5.5.3",
112
112
  "vitest": "^1.5.3"
113
113
  },
114
114
  "tshy": {
@@ -147,5 +147,6 @@
147
147
  }
148
148
  }
149
149
  },
150
- "type": "module"
150
+ "type": "module",
151
+ "module": "./dist/esm/index.js"
151
152
  }