@twin.org/api-service 0.0.3-next.29 → 0.0.3-next.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/healthRoutes.js +108 -0
- package/dist/es/healthRoutes.js.map +1 -0
- package/dist/es/healthService.js +136 -0
- package/dist/es/healthService.js.map +1 -0
- package/dist/es/hostingService.js +1 -209
- package/dist/es/hostingService.js.map +1 -1
- package/dist/es/index.js +7 -0
- package/dist/es/index.js.map +1 -1
- package/dist/es/informationRoutes.js +31 -65
- package/dist/es/informationRoutes.js.map +1 -1
- package/dist/es/informationService.js +9 -85
- package/dist/es/informationService.js.map +1 -1
- package/dist/es/models/IHealthServiceConfig.js +4 -0
- package/dist/es/models/IHealthServiceConfig.js.map +1 -0
- package/dist/es/models/IHealthServiceConstructorOptions.js +2 -0
- package/dist/es/models/IHealthServiceConstructorOptions.js.map +1 -0
- package/dist/es/models/IHostingServiceConfig.js.map +1 -1
- package/dist/es/models/IHostingServiceConstructorOptions.js.map +1 -1
- package/dist/es/models/IUrlTransformerServiceConfig.js +4 -0
- package/dist/es/models/IUrlTransformerServiceConfig.js.map +1 -0
- package/dist/es/models/IUrlTransformerServiceConstructorOptions.js +2 -0
- package/dist/es/models/IUrlTransformerServiceConstructorOptions.js.map +1 -0
- package/dist/es/restEntryPoints.js +7 -0
- package/dist/es/restEntryPoints.js.map +1 -1
- package/dist/es/urlTransformerService.js +214 -0
- package/dist/es/urlTransformerService.js.map +1 -0
- package/dist/types/healthRoutes.d.ts +20 -0
- package/dist/types/healthService.d.ts +42 -0
- package/dist/types/hostingService.d.ts +1 -62
- package/dist/types/index.d.ts +7 -0
- package/dist/types/informationRoutes.d.ts +3 -3
- package/dist/types/informationService.d.ts +9 -21
- package/dist/types/models/IHealthServiceConfig.d.ts +10 -0
- package/dist/types/models/IHealthServiceConstructorOptions.d.ts +10 -0
- package/dist/types/models/IHostingServiceConfig.d.ts +0 -10
- package/dist/types/models/IHostingServiceConstructorOptions.d.ts +1 -6
- package/dist/types/models/IUrlTransformerServiceConfig.d.ts +19 -0
- package/dist/types/models/IUrlTransformerServiceConstructorOptions.d.ts +15 -0
- package/dist/types/urlTransformerService.d.ts +81 -0
- package/docs/changelog.md +14 -0
- package/docs/reference/classes/HealthService.md +123 -0
- package/docs/reference/classes/HostingService.md +0 -266
- package/docs/reference/classes/InformationService.md +8 -84
- package/docs/reference/classes/UrlTransformerService.md +321 -0
- package/docs/reference/functions/generateRestRoutesHealth.md +25 -0
- package/docs/reference/functions/serverReadyz.md +31 -0
- package/docs/reference/index.md +10 -1
- package/docs/reference/interfaces/IHealthServiceConfig.md +17 -0
- package/docs/reference/interfaces/IHealthServiceConstructorOptions.md +11 -0
- package/docs/reference/interfaces/IHostingServiceConfig.md +0 -28
- package/docs/reference/interfaces/IHostingServiceConstructorOptions.md +1 -15
- package/docs/reference/interfaces/IUrlTransformerServiceConfig.md +32 -0
- package/docs/reference/interfaces/IUrlTransformerServiceConstructorOptions.md +25 -0
- package/docs/reference/variables/tagsHealth.md +5 -0
- package/locales/en.json +6 -3
- package/package.json +4 -2
|
@@ -0,0 +1,321 @@
|
|
|
1
|
+
# Class: UrlTransformerService
|
|
2
|
+
|
|
3
|
+
The URL transformer service for encrypting and decrypting URL parameters.
|
|
4
|
+
|
|
5
|
+
## Implements
|
|
6
|
+
|
|
7
|
+
- `IUrlTransformerComponent`
|
|
8
|
+
|
|
9
|
+
## Constructors
|
|
10
|
+
|
|
11
|
+
### Constructor
|
|
12
|
+
|
|
13
|
+
> **new UrlTransformerService**(`options?`): `UrlTransformerService`
|
|
14
|
+
|
|
15
|
+
Create a new instance of UrlTransformerService.
|
|
16
|
+
|
|
17
|
+
#### Parameters
|
|
18
|
+
|
|
19
|
+
##### options?
|
|
20
|
+
|
|
21
|
+
[`IUrlTransformerServiceConstructorOptions`](../interfaces/IUrlTransformerServiceConstructorOptions.md)
|
|
22
|
+
|
|
23
|
+
The options to create the service.
|
|
24
|
+
|
|
25
|
+
#### Returns
|
|
26
|
+
|
|
27
|
+
`UrlTransformerService`
|
|
28
|
+
|
|
29
|
+
## Properties
|
|
30
|
+
|
|
31
|
+
### CLASS\_NAME {#class_name}
|
|
32
|
+
|
|
33
|
+
> `readonly` `static` **CLASS\_NAME**: `string`
|
|
34
|
+
|
|
35
|
+
Runtime name for the class.
|
|
36
|
+
|
|
37
|
+
## Methods
|
|
38
|
+
|
|
39
|
+
### className() {#classname}
|
|
40
|
+
|
|
41
|
+
> **className**(): `string`
|
|
42
|
+
|
|
43
|
+
Returns the class name of the component.
|
|
44
|
+
|
|
45
|
+
#### Returns
|
|
46
|
+
|
|
47
|
+
`string`
|
|
48
|
+
|
|
49
|
+
The class name of the component.
|
|
50
|
+
|
|
51
|
+
#### Implementation of
|
|
52
|
+
|
|
53
|
+
`IUrlTransformerComponent.className`
|
|
54
|
+
|
|
55
|
+
***
|
|
56
|
+
|
|
57
|
+
### start() {#start}
|
|
58
|
+
|
|
59
|
+
> **start**(): `Promise`\<`void`\>
|
|
60
|
+
|
|
61
|
+
The component needs to be started when the node is initialized.
|
|
62
|
+
|
|
63
|
+
#### Returns
|
|
64
|
+
|
|
65
|
+
`Promise`\<`void`\>
|
|
66
|
+
|
|
67
|
+
Nothing.
|
|
68
|
+
|
|
69
|
+
#### Implementation of
|
|
70
|
+
|
|
71
|
+
`IUrlTransformerComponent.start`
|
|
72
|
+
|
|
73
|
+
***
|
|
74
|
+
|
|
75
|
+
### addEncryptedQueryParamToUrl() {#addencryptedqueryparamtourl}
|
|
76
|
+
|
|
77
|
+
> **addEncryptedQueryParamToUrl**(`url`, `id`, `value`): `Promise`\<`string`\>
|
|
78
|
+
|
|
79
|
+
Encrypt a named token value and append it as a query parameter to the given URL.
|
|
80
|
+
|
|
81
|
+
#### Parameters
|
|
82
|
+
|
|
83
|
+
##### url
|
|
84
|
+
|
|
85
|
+
`string`
|
|
86
|
+
|
|
87
|
+
The URL to append the encrypted token to.
|
|
88
|
+
|
|
89
|
+
##### id
|
|
90
|
+
|
|
91
|
+
`string`
|
|
92
|
+
|
|
93
|
+
The logical token identifier (e.g. "tenant").
|
|
94
|
+
|
|
95
|
+
##### value
|
|
96
|
+
|
|
97
|
+
`string`
|
|
98
|
+
|
|
99
|
+
The value to encrypt and add.
|
|
100
|
+
|
|
101
|
+
#### Returns
|
|
102
|
+
|
|
103
|
+
`Promise`\<`string`\>
|
|
104
|
+
|
|
105
|
+
The URL with the encrypted token added as a query parameter.
|
|
106
|
+
|
|
107
|
+
#### Implementation of
|
|
108
|
+
|
|
109
|
+
`IUrlTransformerComponent.addEncryptedQueryParamToUrl`
|
|
110
|
+
|
|
111
|
+
***
|
|
112
|
+
|
|
113
|
+
### getEncryptedQueryParam() {#getencryptedqueryparam}
|
|
114
|
+
|
|
115
|
+
> **getEncryptedQueryParam**(`queryParams`, `id`): `Promise`\<`string` \| `undefined`\>
|
|
116
|
+
|
|
117
|
+
Get a named token value from the query parameters.
|
|
118
|
+
|
|
119
|
+
#### Parameters
|
|
120
|
+
|
|
121
|
+
##### queryParams
|
|
122
|
+
|
|
123
|
+
`IHttpRequestQuery` \| `undefined`
|
|
124
|
+
|
|
125
|
+
The HTTP request query containing the parameters.
|
|
126
|
+
|
|
127
|
+
##### id
|
|
128
|
+
|
|
129
|
+
`string`
|
|
130
|
+
|
|
131
|
+
The logical token identifier (e.g. "tenant").
|
|
132
|
+
|
|
133
|
+
#### Returns
|
|
134
|
+
|
|
135
|
+
`Promise`\<`string` \| `undefined`\>
|
|
136
|
+
|
|
137
|
+
The decrypted token value if it exists.
|
|
138
|
+
|
|
139
|
+
#### Implementation of
|
|
140
|
+
|
|
141
|
+
`IUrlTransformerComponent.getEncryptedQueryParam`
|
|
142
|
+
|
|
143
|
+
***
|
|
144
|
+
|
|
145
|
+
### addEncryptedParamsToUrl() {#addencryptedparamstourl}
|
|
146
|
+
|
|
147
|
+
> **addEncryptedParamsToUrl**(`url`, `params`): `Promise`\<`string`\>
|
|
148
|
+
|
|
149
|
+
Add encrypted key/value pairs to a URL's query string.
|
|
150
|
+
|
|
151
|
+
#### Parameters
|
|
152
|
+
|
|
153
|
+
##### url
|
|
154
|
+
|
|
155
|
+
`string`
|
|
156
|
+
|
|
157
|
+
The base URL to add parameters to.
|
|
158
|
+
|
|
159
|
+
##### params
|
|
160
|
+
|
|
161
|
+
`IHttpRequestQuery`
|
|
162
|
+
|
|
163
|
+
The key/value pairs to encrypt and append.
|
|
164
|
+
|
|
165
|
+
#### Returns
|
|
166
|
+
|
|
167
|
+
`Promise`\<`string`\>
|
|
168
|
+
|
|
169
|
+
The URL with the encrypted parameters added.
|
|
170
|
+
|
|
171
|
+
#### Implementation of
|
|
172
|
+
|
|
173
|
+
`IUrlTransformerComponent.addEncryptedParamsToUrl`
|
|
174
|
+
|
|
175
|
+
***
|
|
176
|
+
|
|
177
|
+
### getDecryptedParamsFromQueryParams() {#getdecryptedparamsfromqueryparams}
|
|
178
|
+
|
|
179
|
+
> **getDecryptedParamsFromQueryParams**(`queryParams`, `keys`): `Promise`\<`IHttpRequestQuery`\>
|
|
180
|
+
|
|
181
|
+
Decrypt specified keys from a query parameter object and return their plain-text values.
|
|
182
|
+
|
|
183
|
+
#### Parameters
|
|
184
|
+
|
|
185
|
+
##### queryParams
|
|
186
|
+
|
|
187
|
+
`IHttpRequestQuery` \| `undefined`
|
|
188
|
+
|
|
189
|
+
The HTTP request query containing the encrypted parameters.
|
|
190
|
+
|
|
191
|
+
##### keys
|
|
192
|
+
|
|
193
|
+
`string`[]
|
|
194
|
+
|
|
195
|
+
The keys to decrypt.
|
|
196
|
+
|
|
197
|
+
#### Returns
|
|
198
|
+
|
|
199
|
+
`Promise`\<`IHttpRequestQuery`\>
|
|
200
|
+
|
|
201
|
+
A map of the decrypted key/value pairs that were present.
|
|
202
|
+
|
|
203
|
+
#### Implementation of
|
|
204
|
+
|
|
205
|
+
`IUrlTransformerComponent.getDecryptedParamsFromQueryParams`
|
|
206
|
+
|
|
207
|
+
***
|
|
208
|
+
|
|
209
|
+
### encryptQueryParams() {#encryptqueryparams}
|
|
210
|
+
|
|
211
|
+
> **encryptQueryParams**(`httpRequestQuery`, `keys`): `Promise`\<`void`\>
|
|
212
|
+
|
|
213
|
+
Encrypt query parameters.
|
|
214
|
+
|
|
215
|
+
#### Parameters
|
|
216
|
+
|
|
217
|
+
##### httpRequestQuery
|
|
218
|
+
|
|
219
|
+
`IHttpRequestQuery` \| `undefined`
|
|
220
|
+
|
|
221
|
+
The HTTP request query containing the parameters to encrypt.
|
|
222
|
+
|
|
223
|
+
##### keys
|
|
224
|
+
|
|
225
|
+
`string`[]
|
|
226
|
+
|
|
227
|
+
The keys of the parameters to encrypt.
|
|
228
|
+
|
|
229
|
+
#### Returns
|
|
230
|
+
|
|
231
|
+
`Promise`\<`void`\>
|
|
232
|
+
|
|
233
|
+
A promise that resolves when the query parameters have been encrypted.
|
|
234
|
+
|
|
235
|
+
#### Implementation of
|
|
236
|
+
|
|
237
|
+
`IUrlTransformerComponent.encryptQueryParams`
|
|
238
|
+
|
|
239
|
+
***
|
|
240
|
+
|
|
241
|
+
### decryptQueryParams() {#decryptqueryparams}
|
|
242
|
+
|
|
243
|
+
> **decryptQueryParams**(`httpRequestQuery`, `keys`): `Promise`\<`void`\>
|
|
244
|
+
|
|
245
|
+
Decrypt query parameters.
|
|
246
|
+
|
|
247
|
+
#### Parameters
|
|
248
|
+
|
|
249
|
+
##### httpRequestQuery
|
|
250
|
+
|
|
251
|
+
`IHttpRequestQuery` \| `undefined`
|
|
252
|
+
|
|
253
|
+
The HTTP request query containing the encrypted values.
|
|
254
|
+
|
|
255
|
+
##### keys
|
|
256
|
+
|
|
257
|
+
`string`[]
|
|
258
|
+
|
|
259
|
+
The keys of the parameters to decrypt.
|
|
260
|
+
|
|
261
|
+
#### Returns
|
|
262
|
+
|
|
263
|
+
`Promise`\<`void`\>
|
|
264
|
+
|
|
265
|
+
A promise that resolves when the query parameters have been decrypted.
|
|
266
|
+
|
|
267
|
+
#### Implementation of
|
|
268
|
+
|
|
269
|
+
`IUrlTransformerComponent.decryptQueryParams`
|
|
270
|
+
|
|
271
|
+
***
|
|
272
|
+
|
|
273
|
+
### encryptParam() {#encryptparam}
|
|
274
|
+
|
|
275
|
+
> **encryptParam**(`paramValue`): `Promise`\<`string`\>
|
|
276
|
+
|
|
277
|
+
Encrypt a parameter value.
|
|
278
|
+
|
|
279
|
+
#### Parameters
|
|
280
|
+
|
|
281
|
+
##### paramValue
|
|
282
|
+
|
|
283
|
+
`string`
|
|
284
|
+
|
|
285
|
+
The value of the parameter to encrypt.
|
|
286
|
+
|
|
287
|
+
#### Returns
|
|
288
|
+
|
|
289
|
+
`Promise`\<`string`\>
|
|
290
|
+
|
|
291
|
+
A promise that resolves to the encrypted value of the parameter.
|
|
292
|
+
|
|
293
|
+
#### Implementation of
|
|
294
|
+
|
|
295
|
+
`IUrlTransformerComponent.encryptParam`
|
|
296
|
+
|
|
297
|
+
***
|
|
298
|
+
|
|
299
|
+
### decryptParam() {#decryptparam}
|
|
300
|
+
|
|
301
|
+
> **decryptParam**(`encryptedValue`): `Promise`\<`string`\>
|
|
302
|
+
|
|
303
|
+
Decrypt a parameter value.
|
|
304
|
+
|
|
305
|
+
#### Parameters
|
|
306
|
+
|
|
307
|
+
##### encryptedValue
|
|
308
|
+
|
|
309
|
+
`string`
|
|
310
|
+
|
|
311
|
+
The encrypted value of the parameter.
|
|
312
|
+
|
|
313
|
+
#### Returns
|
|
314
|
+
|
|
315
|
+
`Promise`\<`string`\>
|
|
316
|
+
|
|
317
|
+
A promise that resolves to the decrypted value of the parameter.
|
|
318
|
+
|
|
319
|
+
#### Implementation of
|
|
320
|
+
|
|
321
|
+
`IUrlTransformerComponent.decryptParam`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Function: generateRestRoutesHealth()
|
|
2
|
+
|
|
3
|
+
> **generateRestRoutesHealth**(`baseRouteName`, `componentName`): `IRestRoute`\<`any`, `any`\>[]
|
|
4
|
+
|
|
5
|
+
The REST routes for server health.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### baseRouteName
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
Prefix to prepend to the paths.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes stored in the ComponentFactory.
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`IRestRoute`\<`any`, `any`\>[]
|
|
24
|
+
|
|
25
|
+
The generated routes.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: serverReadyz()
|
|
2
|
+
|
|
3
|
+
> **serverReadyz**(`httpRequestContext`, `componentName`, `request`): `Promise`\<`IServerReadyzResponse`\>
|
|
4
|
+
|
|
5
|
+
Get the readyz for the server.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
`INoContentRequest`
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<`IServerReadyzResponse`\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
package/docs/reference/index.md
CHANGED
|
@@ -2,27 +2,36 @@
|
|
|
2
2
|
|
|
3
3
|
## Classes
|
|
4
4
|
|
|
5
|
+
- [HealthService](classes/HealthService.md)
|
|
5
6
|
- [HostingService](classes/HostingService.md)
|
|
6
7
|
- [InformationService](classes/InformationService.md)
|
|
8
|
+
- [UrlTransformerService](classes/UrlTransformerService.md)
|
|
7
9
|
|
|
8
10
|
## Interfaces
|
|
9
11
|
|
|
12
|
+
- [IHealthServiceConfig](interfaces/IHealthServiceConfig.md)
|
|
13
|
+
- [IHealthServiceConstructorOptions](interfaces/IHealthServiceConstructorOptions.md)
|
|
10
14
|
- [IHostingServiceConfig](interfaces/IHostingServiceConfig.md)
|
|
11
15
|
- [IHostingServiceConstructorOptions](interfaces/IHostingServiceConstructorOptions.md)
|
|
12
16
|
- [IInformationServiceConfig](interfaces/IInformationServiceConfig.md)
|
|
13
17
|
- [IInformationServiceConstructorOptions](interfaces/IInformationServiceConstructorOptions.md)
|
|
18
|
+
- [IUrlTransformerServiceConfig](interfaces/IUrlTransformerServiceConfig.md)
|
|
19
|
+
- [IUrlTransformerServiceConstructorOptions](interfaces/IUrlTransformerServiceConstructorOptions.md)
|
|
14
20
|
|
|
15
21
|
## Variables
|
|
16
22
|
|
|
23
|
+
- [tagsHealth](variables/tagsHealth.md)
|
|
17
24
|
- [tagsInformation](variables/tagsInformation.md)
|
|
18
25
|
- [restEntryPoints](variables/restEntryPoints.md)
|
|
19
26
|
|
|
20
27
|
## Functions
|
|
21
28
|
|
|
29
|
+
- [generateRestRoutesHealth](functions/generateRestRoutesHealth.md)
|
|
30
|
+
- [serverHealth](functions/serverHealth.md)
|
|
22
31
|
- [generateRestRoutesInformation](functions/generateRestRoutesInformation.md)
|
|
23
32
|
- [serverRoot](functions/serverRoot.md)
|
|
24
33
|
- [serverInfo](functions/serverInfo.md)
|
|
25
34
|
- [serverLivez](functions/serverLivez.md)
|
|
26
|
-
- [
|
|
35
|
+
- [serverReadyz](functions/serverReadyz.md)
|
|
27
36
|
- [serverFavIcon](functions/serverFavIcon.md)
|
|
28
37
|
- [serverSpec](functions/serverSpec.md)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Interface: IHealthServiceConfig
|
|
2
|
+
|
|
3
|
+
Configuration for the health service.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### healthCheckInterval? {#healthcheckinterval}
|
|
8
|
+
|
|
9
|
+
> `optional` **healthCheckInterval?**: `number`
|
|
10
|
+
|
|
11
|
+
The interval for checking the health of the components and setting it in the health service.
|
|
12
|
+
|
|
13
|
+
#### Default
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
30000
|
|
17
|
+
```
|
|
@@ -17,31 +17,3 @@ The local origin, must be provided as a fallback e.g. http://localhost:1234.
|
|
|
17
17
|
> `optional` **publicOrigin?**: `string`
|
|
18
18
|
|
|
19
19
|
The APIs public base URL e.g. "https://api.example.com:1234".
|
|
20
|
-
|
|
21
|
-
***
|
|
22
|
-
|
|
23
|
-
### paramEncryptionKeyName? {#paramencryptionkeyname}
|
|
24
|
-
|
|
25
|
-
> `optional` **paramEncryptionKeyName?**: `string`
|
|
26
|
-
|
|
27
|
-
The name of the key to retrieve from the vault for encryption/decryption of parameters.
|
|
28
|
-
|
|
29
|
-
#### Default
|
|
30
|
-
|
|
31
|
-
```ts
|
|
32
|
-
param-encryption
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
***
|
|
36
|
-
|
|
37
|
-
### tenantTokenName? {#tenanttokenname}
|
|
38
|
-
|
|
39
|
-
> `optional` **tenantTokenName?**: `string`
|
|
40
|
-
|
|
41
|
-
The query param name to look for the encrypted tenant token.
|
|
42
|
-
|
|
43
|
-
#### Default
|
|
44
|
-
|
|
45
|
-
```ts
|
|
46
|
-
tenant-token
|
|
47
|
-
```
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Interface: IHostingServiceConstructorOptions
|
|
2
2
|
|
|
3
|
-
Options for the
|
|
3
|
+
Options for the HostingService constructor.
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
@@ -18,20 +18,6 @@ tenant-admin
|
|
|
18
18
|
|
|
19
19
|
***
|
|
20
20
|
|
|
21
|
-
### vaultConnectorType? {#vaultconnectortype}
|
|
22
|
-
|
|
23
|
-
> `optional` **vaultConnectorType?**: `string`
|
|
24
|
-
|
|
25
|
-
The vault connector type.
|
|
26
|
-
|
|
27
|
-
#### Default
|
|
28
|
-
|
|
29
|
-
```ts
|
|
30
|
-
vault
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
***
|
|
34
|
-
|
|
35
21
|
### config {#config}
|
|
36
22
|
|
|
37
23
|
> **config**: [`IHostingServiceConfig`](IHostingServiceConfig.md)
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Interface: IUrlTransformerServiceConfig
|
|
2
|
+
|
|
3
|
+
Configuration for the URL transformer service.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### paramEncryptionKeyName? {#paramencryptionkeyname}
|
|
8
|
+
|
|
9
|
+
> `optional` **paramEncryptionKeyName?**: `string`
|
|
10
|
+
|
|
11
|
+
The name of the key to retrieve from the vault for encryption/decryption of parameters.
|
|
12
|
+
|
|
13
|
+
#### Default
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
param-encryption
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
***
|
|
20
|
+
|
|
21
|
+
### queryParamNames? {#queryparamnames}
|
|
22
|
+
|
|
23
|
+
> `optional` **queryParamNames?**: `object`
|
|
24
|
+
|
|
25
|
+
A dictionary mapping logical token identifiers to their URL query parameter names.
|
|
26
|
+
For example: { "tenant": "tenant-token" } maps the logical id "tenant" to the
|
|
27
|
+
query param "tenant-token". When an id is not present the id itself is used as
|
|
28
|
+
the param name.
|
|
29
|
+
|
|
30
|
+
#### Index Signature
|
|
31
|
+
|
|
32
|
+
\[`id`: `string`\]: `string`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Interface: IUrlTransformerServiceConstructorOptions
|
|
2
|
+
|
|
3
|
+
Options for the UrlTransformerService constructor.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### vaultConnectorType? {#vaultconnectortype}
|
|
8
|
+
|
|
9
|
+
> `optional` **vaultConnectorType?**: `string`
|
|
10
|
+
|
|
11
|
+
The vault connector type.
|
|
12
|
+
|
|
13
|
+
#### Default
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
vault
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
***
|
|
20
|
+
|
|
21
|
+
### config? {#config}
|
|
22
|
+
|
|
23
|
+
> `optional` **config?**: [`IUrlTransformerServiceConfig`](IUrlTransformerServiceConfig.md)
|
|
24
|
+
|
|
25
|
+
The configuration for the service.
|
package/locales/en.json
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"error": {
|
|
3
|
-
"
|
|
4
|
-
"encryptionUnavailable": "Encryption is unavailable because no
|
|
5
|
-
"decryptionUnavailable": "Decryption is unavailable because no
|
|
3
|
+
"urlTransformerService": {
|
|
4
|
+
"encryptionUnavailable": "Encryption is unavailable because no nodeId is configured",
|
|
5
|
+
"decryptionUnavailable": "Decryption is unavailable because no nodeId is configured",
|
|
6
6
|
"encryptionFailed": "An error occurred during encryption",
|
|
7
7
|
"decryptionFailed": "An error occurred during decryption"
|
|
8
|
+
},
|
|
9
|
+
"healthService": {
|
|
10
|
+
"componentHealthCheckFailed": "Health check failed for component \"{className}\""
|
|
8
11
|
}
|
|
9
12
|
}
|
|
10
13
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/api-service",
|
|
3
|
-
"version": "0.0.3-next.
|
|
3
|
+
"version": "0.0.3-next.30",
|
|
4
4
|
"description": "Information and hosting service implementations with generated REST route handlers.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -14,9 +14,11 @@
|
|
|
14
14
|
"node": ">=20.0.0"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@twin.org/api-models": "0.0.3-next.
|
|
17
|
+
"@twin.org/api-models": "0.0.3-next.30",
|
|
18
18
|
"@twin.org/context": "next",
|
|
19
19
|
"@twin.org/core": "next",
|
|
20
|
+
"@twin.org/engine-models": "next",
|
|
21
|
+
"@twin.org/logging-models": "next",
|
|
20
22
|
"@twin.org/nameof": "next",
|
|
21
23
|
"@twin.org/vault-models": "next",
|
|
22
24
|
"@twin.org/web": "next"
|