@kronos-integration/service 13.2.37 → 13.2.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -89,8 +89,10 @@ The transitions are:
89
89
  * [Parameters](#parameters-12)
90
90
  * [configure](#configure-1)
91
91
  * [Parameters](#parameters-13)
92
- * [log](#log)
92
+ * [getCredential](#getcredential)
93
93
  * [Parameters](#parameters-14)
94
+ * [log](#log)
95
+ * [Parameters](#parameters-15)
94
96
  * [attributes](#attributes)
95
97
  * [endpoints](#endpoints-2)
96
98
  * [StandaloneServiceProvider](#standaloneserviceprovider)
@@ -375,7 +377,7 @@ or simply assign the attribute value.
375
377
 
376
378
  * `config` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)** 
377
379
 
378
- Returns **[Set](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Set)** of modified attributes
380
+ Returns **[Set](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Set)<[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)>** of modified attributes
379
381
 
380
382
  ### configure
381
383
 
@@ -388,7 +390,15 @@ will be called.
388
390
 
389
391
  * `config` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)**&#x20;
390
392
 
391
- Returns **[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)** fillfills when config is applied
393
+ Returns **[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)<[undefined](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/undefined)>** fillfills when config is applied
394
+
395
+ ### getCredential
396
+
397
+ #### Parameters
398
+
399
+ * `key` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)**&#x20;
400
+
401
+ Returns **[Promise](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise)<([string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String) | [Uint8Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array))>**&#x20;
392
402
 
393
403
  ### log
394
404
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kronos-integration/service",
3
- "version": "13.2.37",
3
+ "version": "13.2.39",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "provenance": true
@@ -36,10 +36,10 @@
36
36
  "lint:typescript": "tsc --allowJs --checkJs --noEmit --resolveJsonModule --target es2024 --lib es2024 -m esnext --module nodenext --moduleResolution nodenext ./src**/*.mjs"
37
37
  },
38
38
  "dependencies": {
39
- "@kronos-integration/endpoint": "^10.1.18",
40
- "@kronos-integration/interceptor": "^12.2.2",
39
+ "@kronos-integration/endpoint": "^10.1.19",
40
+ "@kronos-integration/interceptor": "^12.2.3",
41
41
  "loglevel-mixin": "^7.2.5",
42
- "pacc": "^4.39.2",
42
+ "pacc": "^4.39.3",
43
43
  "statetransition-mixin": "^8.1.3"
44
44
  },
45
45
  "devDependencies": {
@@ -47,7 +47,7 @@
47
47
  "c8": "^10.1.3",
48
48
  "documentation": "^14.0.3",
49
49
  "semantic-release": "^24.2.9",
50
- "typescript": "^5.9.2"
50
+ "typescript": "^5.9.3"
51
51
  },
52
52
  "engines": {
53
53
  "node": ">=22.20.0"
package/src/service.mjs CHANGED
@@ -399,7 +399,7 @@ export class Service extends EndpointsMixin(
399
399
  * and then for each attribute decide if we use the default, call a setter function
400
400
  * or simply assign the attribute value.
401
401
  * @param {Object} config
402
- * @return {Set} of modified attributes
402
+ * @return {Set<string>} of modified attributes
403
403
  */
404
404
  _configure(config) {
405
405
  const modified = new Set();
@@ -425,7 +425,7 @@ export class Service extends EndpointsMixin(
425
425
  * If attribute with needsRestart are touched the restartIfRunning method
426
426
  * will be called.
427
427
  * @param {Object} config
428
- * @return {Promise} fillfills when config is applied
428
+ * @return {Promise<undefined>} fillfills when config is applied
429
429
  */
430
430
  async configure(config) {
431
431
  for (const a of this._configure(config)) {
@@ -435,6 +435,11 @@ export class Service extends EndpointsMixin(
435
435
  }
436
436
  }
437
437
 
438
+ /**
439
+ *
440
+ * @param {string} key
441
+ * @returns {Promise<string|Uint8Array>}
442
+ */
438
443
  async getCredential(key) {
439
444
  return this.owner.getCredential(this.name + "." + key, "utf8");
440
445
  }
@@ -129,19 +129,24 @@ export class Service extends Service_base {
129
129
  * and then for each attribute decide if we use the default, call a setter function
130
130
  * or simply assign the attribute value.
131
131
  * @param {Object} config
132
- * @return {Set} of modified attributes
132
+ * @return {Set<string>} of modified attributes
133
133
  */
134
- _configure(config: any): Set<any>;
134
+ _configure(config: any): Set<string>;
135
135
  /**
136
136
  * Use new configuration.
137
137
  * Internally calls _configure(config) as the constructor does.
138
138
  * If attribute with needsRestart are touched the restartIfRunning method
139
139
  * will be called.
140
140
  * @param {Object} config
141
- * @return {Promise} fillfills when config is applied
141
+ * @return {Promise<undefined>} fillfills when config is applied
142
142
  */
143
- configure(config: any): Promise<any>;
144
- getCredential(key: any): Promise<any>;
143
+ configure(config: any): Promise<undefined>;
144
+ /**
145
+ *
146
+ * @param {string} key
147
+ * @returns {Promise<string|Uint8Array>}
148
+ */
149
+ getCredential(key: string): Promise<string | Uint8Array>;
145
150
  /**
146
151
  * Adds service name to the log event.
147
152
  * @param {string} level the log level