@twin.org/node-core 0.0.2-next.2 → 0.0.2-next.21
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/cjs/index.cjs +864 -391
- package/dist/esm/index.mjs +852 -394
- package/dist/types/bootstrap.d.ts +9 -9
- package/dist/types/builders/engineEnvBuilder.d.ts +1 -1
- package/dist/types/builders/engineServerEnvBuilder.d.ts +3 -2
- package/dist/types/builders/extensionsBuilder.d.ts +32 -0
- package/dist/types/defaults.d.ts +6 -0
- package/dist/types/index.d.ts +4 -0
- package/dist/types/models/IEngineEnvironmentVariables.d.ts +188 -24
- package/dist/types/models/IEngineServerEnvironmentVariables.d.ts +12 -3
- package/dist/types/models/INodeEngineConfig.d.ts +6 -0
- package/dist/types/models/INodeEnvironmentVariables.d.ts +1 -2
- package/dist/types/models/INodeOptions.d.ts +6 -1
- package/dist/types/models/nodeExtensionMethods.d.ts +27 -0
- package/dist/types/models/nodeFeatures.d.ts +4 -0
- package/dist/types/node.d.ts +7 -2
- package/dist/types/server.d.ts +4 -2
- package/dist/types/utils.d.ts +24 -0
- package/docs/changelog.md +138 -0
- package/docs/reference/functions/{bootstrapAttestationMethod.md → bootstrapSynchronisedStorage.md} +3 -3
- package/docs/reference/functions/buildConfiguration.md +2 -2
- package/docs/reference/functions/buildEngineConfiguration.md +2 -2
- package/docs/reference/functions/buildEngineServerConfiguration.md +9 -3
- package/docs/reference/functions/directoryExists.md +19 -0
- package/docs/reference/functions/extensionsConfiguration.md +25 -0
- package/docs/reference/functions/extensionsInitialiseEngine.md +25 -0
- package/docs/reference/functions/extensionsInitialiseEngineServer.md +31 -0
- package/docs/reference/functions/getFiles.md +19 -0
- package/docs/reference/functions/getSubFolders.md +19 -0
- package/docs/reference/functions/loadTextFile.md +19 -0
- package/docs/reference/functions/overrideModuleImport.md +17 -0
- package/docs/reference/functions/shutdownExtensions.md +25 -0
- package/docs/reference/functions/start.md +4 -4
- package/docs/reference/index.md +21 -1
- package/docs/reference/interfaces/IEngineEnvironmentVariables.md +374 -36
- package/docs/reference/interfaces/IEngineServerEnvironmentVariables.md +1673 -5
- package/docs/reference/interfaces/INodeEngineConfig.md +7 -0
- package/docs/reference/interfaces/INodeEnvironmentVariables.md +643 -137
- package/docs/reference/interfaces/INodeOptions.md +14 -2
- package/docs/reference/type-aliases/NodeExtensionInitialiseEngineMethod.md +18 -0
- package/docs/reference/type-aliases/NodeExtensionInitialiseEngineServerMethod.md +24 -0
- package/docs/reference/type-aliases/NodeExtensionInitialiseMethod.md +23 -0
- package/docs/reference/type-aliases/NodeExtensionShutdownMethod.md +10 -0
- package/docs/reference/variables/ATTESTATION_VERIFICATION_METHOD_ID.md +3 -0
- package/docs/reference/variables/AUTH_SIGNING_KEY_ID.md +3 -0
- package/docs/reference/variables/BLOB_STORAGE_ENCRYPTION_KEY_ID.md +3 -0
- package/docs/reference/variables/IMMUTABLE_PROOF_VERIFICATION_METHOD_ID.md +3 -0
- package/docs/reference/variables/NodeFeatures.md +7 -1
- package/docs/reference/variables/SYNCHRONISED_STORAGE_BLOB_STORAGE_ENCRYPTION_KEY_ID.md +3 -0
- package/docs/reference/variables/VC_AUTHENTICATION_VERIFICATION_METHOD_ID.md +3 -0
- package/locales/en.json +15 -7
- package/package.json +18 -2
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,143 @@
|
|
|
1
1
|
# @twin.org/node-core - Changelog
|
|
2
2
|
|
|
3
|
+
## [0.0.2-next.21](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.20...node-core-v0.0.2-next.21) (2025-10-07)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* update engine dependency ([3494c31](https://github.com/twinfoundation/node/commit/3494c3144fd5ce6d3a9f2936c7890ab36795aeaa))
|
|
9
|
+
|
|
10
|
+
## [0.0.2-next.20](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.19...node-core-v0.0.2-next.20) (2025-10-06)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* improve node logging ([63d6ea6](https://github.com/twinfoundation/node/commit/63d6ea661c2c76985d98addb8d905ad6f0c7f164))
|
|
16
|
+
* improve node logging ([c25b9c6](https://github.com/twinfoundation/node/commit/c25b9c6779bdb76f341df072c39b4c2fae4565a3))
|
|
17
|
+
|
|
18
|
+
## [0.0.2-next.19](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.18...node-core-v0.0.2-next.19) (2025-10-03)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Features
|
|
22
|
+
|
|
23
|
+
* use features instead of disableNodeIdentity ([2e6109b](https://github.com/twinfoundation/node/commit/2e6109bd1de825e0f5396fc120d99ad7b3929852))
|
|
24
|
+
|
|
25
|
+
## [0.0.2-next.18](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.17...node-core-v0.0.2-next.18) (2025-10-03)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Features
|
|
29
|
+
|
|
30
|
+
* improve error handling for extensions and logging ([bd84fde](https://github.com/twinfoundation/node/commit/bd84fde67e5a9db6ac66730397992401ca52e88c))
|
|
31
|
+
|
|
32
|
+
## [0.0.2-next.17](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.16...node-core-v0.0.2-next.17) (2025-10-02)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
### Features
|
|
36
|
+
|
|
37
|
+
* add extensions support ([476d5a8](https://github.com/twinfoundation/node/commit/476d5a864026a2f78e5b02bc9eb81359777a4a45))
|
|
38
|
+
* updating linting ([feacd17](https://github.com/twinfoundation/node/commit/feacd178bb025bcd29a0ae6e4b8e79f23a989169))
|
|
39
|
+
|
|
40
|
+
## [0.0.2-next.16](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.15...node-core-v0.0.2-next.16) (2025-09-29)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
### Features
|
|
44
|
+
|
|
45
|
+
* update framework components ([4bee2b9](https://github.com/twinfoundation/node/commit/4bee2b9d3651df09b8550a9ed226be1b46031854))
|
|
46
|
+
|
|
47
|
+
## [0.0.2-next.15](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.14...node-core-v0.0.2-next.15) (2025-09-26)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
### Features
|
|
51
|
+
|
|
52
|
+
* additional options for enabling components ([e13d772](https://github.com/twinfoundation/node/commit/e13d7721a0dd7143d456fff246622cbe63dbd0f1))
|
|
53
|
+
|
|
54
|
+
## [0.0.2-next.14](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.13...node-core-v0.0.2-next.14) (2025-09-25)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
### Features
|
|
58
|
+
|
|
59
|
+
* additional route logging env vars ([7152c88](https://github.com/twinfoundation/node/commit/7152c887c3ba76778e2d9e68ba57198b8d81d802))
|
|
60
|
+
|
|
61
|
+
## [0.0.2-next.13](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.12...node-core-v0.0.2-next.13) (2025-09-24)
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
### Features
|
|
65
|
+
|
|
66
|
+
* update to latest engine ([00d4974](https://github.com/twinfoundation/node/commit/00d4974f9cfb02bf48505cfb4af4a7aba1df4b3d))
|
|
67
|
+
|
|
68
|
+
## [0.0.2-next.12](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.11...node-core-v0.0.2-next.12) (2025-09-19)
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
### Features
|
|
72
|
+
|
|
73
|
+
* update rights management components ([176a0d6](https://github.com/twinfoundation/node/commit/176a0d611f88360fc845ae233b26ee0b43d7cb23))
|
|
74
|
+
|
|
75
|
+
## [0.0.2-next.11](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.10...node-core-v0.0.2-next.11) (2025-09-08)
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
### Features
|
|
79
|
+
|
|
80
|
+
* update rights management dependencies ([97ad02e](https://github.com/twinfoundation/node/commit/97ad02e4b74cfe5e722f74da2fc2229bbf004c0a))
|
|
81
|
+
|
|
82
|
+
## [0.0.2-next.10](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.9...node-core-v0.0.2-next.10) (2025-09-05)
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
### Features
|
|
86
|
+
|
|
87
|
+
* add rights management components ([0fc6293](https://github.com/twinfoundation/node/commit/0fc629332db24494bd73003625c7bf3f939a2597))
|
|
88
|
+
|
|
89
|
+
## [0.0.2-next.9](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.8...node-core-v0.0.2-next.9) (2025-08-31)
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
### Features
|
|
93
|
+
|
|
94
|
+
* eslint migration to flat config ([080db74](https://github.com/twinfoundation/node/commit/080db746390230f78725d214bc957da2efee9eb1))
|
|
95
|
+
|
|
96
|
+
## [0.0.2-next.8](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.7...node-core-v0.0.2-next.8) (2025-08-27)
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
### Features
|
|
100
|
+
|
|
101
|
+
* add module override for better local import resolution ([ba00d17](https://github.com/twinfoundation/node/commit/ba00d17beea0a9a1851c89ad7c6a33256051c818))
|
|
102
|
+
|
|
103
|
+
## [0.0.2-next.7](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.6...node-core-v0.0.2-next.7) (2025-08-26)
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
### Features
|
|
107
|
+
|
|
108
|
+
* add data space connector ([5a57087](https://github.com/twinfoundation/node/commit/5a57087d938265d3a4a812ff7c83d130ea4e103c))
|
|
109
|
+
* add data space connector ([f7a3644](https://github.com/twinfoundation/node/commit/f7a364477ec664e333e5ad018795acec6ee61edc))
|
|
110
|
+
* add data space connector ([157e8b0](https://github.com/twinfoundation/node/commit/157e8b0a76e3a8a63c1991924f7f963eb83e27ae))
|
|
111
|
+
|
|
112
|
+
## [0.0.2-next.6](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.5...node-core-v0.0.2-next.6) (2025-08-22)
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
### Features
|
|
116
|
+
|
|
117
|
+
* add rights management ([78fba62](https://github.com/twinfoundation/node/commit/78fba62f82afdbe615d55dd90eca8ee70ea62fc0))
|
|
118
|
+
* remove unused properties ([d8344b5](https://github.com/twinfoundation/node/commit/d8344b5aee5dc1c8104d75fad5093097f6530168))
|
|
119
|
+
|
|
120
|
+
## [0.0.2-next.5](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.4...node-core-v0.0.2-next.5) (2025-08-21)
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
### Features
|
|
124
|
+
|
|
125
|
+
* update framework core ([8bd769a](https://github.com/twinfoundation/node/commit/8bd769a4451f5f1f6be3f115a5e94eeb05bce7f1))
|
|
126
|
+
|
|
127
|
+
## [0.0.2-next.4](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.3...node-core-v0.0.2-next.4) (2025-08-14)
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
### Features
|
|
131
|
+
|
|
132
|
+
* add synchronised storage config ([e315869](https://github.com/twinfoundation/node/commit/e315869adbffcd7fe5d3ce151dd35f662f6134a9))
|
|
133
|
+
|
|
134
|
+
## [0.0.2-next.3](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.2...node-core-v0.0.2-next.3) (2025-07-21)
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
### Features
|
|
138
|
+
|
|
139
|
+
* update to latest engine config ([347386c](https://github.com/twinfoundation/node/commit/347386c0609e717dc20c456ad2264c83df793c59))
|
|
140
|
+
|
|
3
141
|
## [0.0.2-next.2](https://github.com/twinfoundation/node/compare/node-core-v0.0.2-next.1...node-core-v0.0.2-next.2) (2025-07-17)
|
|
4
142
|
|
|
5
143
|
|
package/docs/reference/functions/{bootstrapAttestationMethod.md → bootstrapSynchronisedStorage.md}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
# Function:
|
|
1
|
+
# Function: bootstrapSynchronisedStorage()
|
|
2
2
|
|
|
3
|
-
> **
|
|
3
|
+
> **bootstrapSynchronisedStorage**(`engineCore`, `context`, `envVars`, `features`): `Promise`\<`void`\>
|
|
4
4
|
|
|
5
|
-
Bootstrap the
|
|
5
|
+
Bootstrap the synchronised storage blob encryption and verification methods.
|
|
6
6
|
|
|
7
7
|
## Parameters
|
|
8
8
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Function: buildConfiguration()
|
|
2
2
|
|
|
3
|
-
> **buildConfiguration**(`processEnv`, `options`, `serverInfo`): `Promise`\<\{ `nodeEnvVars`: [`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md) & `object`; `
|
|
3
|
+
> **buildConfiguration**(`processEnv`, `options`, `serverInfo`): `Promise`\<\{ `nodeEnvVars`: [`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md) & `object`; `nodeEngineConfig`: [`INodeEngineConfig`](../interfaces/INodeEngineConfig.md); \}\>
|
|
4
4
|
|
|
5
5
|
Build the configuration for the TWIN Node server.
|
|
6
6
|
|
|
@@ -24,7 +24,7 @@ The server information.
|
|
|
24
24
|
|
|
25
25
|
## Returns
|
|
26
26
|
|
|
27
|
-
`Promise`\<\{ `nodeEnvVars`: [`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md) & `object`; `
|
|
27
|
+
`Promise`\<\{ `nodeEnvVars`: [`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md) & `object`; `nodeEngineConfig`: [`INodeEngineConfig`](../interfaces/INodeEngineConfig.md); \}\>
|
|
28
28
|
|
|
29
29
|
A promise that resolves to the engine server configuration, environment prefix, environment variables,
|
|
30
30
|
and options.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Function: buildEngineConfiguration()
|
|
2
2
|
|
|
3
|
-
> **buildEngineConfiguration**(`envVars`): `IEngineConfig
|
|
3
|
+
> **buildEngineConfiguration**(`envVars`): `Promise`\<`IEngineConfig`\>
|
|
4
4
|
|
|
5
5
|
Build the engine core configuration from environment variables.
|
|
6
6
|
|
|
@@ -14,6 +14,6 @@ The environment variables.
|
|
|
14
14
|
|
|
15
15
|
## Returns
|
|
16
16
|
|
|
17
|
-
`IEngineConfig
|
|
17
|
+
`Promise`\<`IEngineConfig`\>
|
|
18
18
|
|
|
19
19
|
The config for the core.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Function: buildEngineServerConfiguration()
|
|
2
2
|
|
|
3
|
-
> **buildEngineServerConfiguration**(`envVars`, `coreEngineConfig`, `serverInfo`, `openApiSpecPath?`): `IEngineServerConfig
|
|
3
|
+
> **buildEngineServerConfiguration**(`envVars`, `coreEngineConfig`, `serverInfo`, `openApiSpecPath?`, `favIconPath?`): `Promise`\<`IEngineServerConfig`\>
|
|
4
4
|
|
|
5
5
|
Handles the configuration of the server.
|
|
6
6
|
|
|
@@ -30,8 +30,14 @@ The server information.
|
|
|
30
30
|
|
|
31
31
|
The path to the open api spec.
|
|
32
32
|
|
|
33
|
+
### favIconPath?
|
|
34
|
+
|
|
35
|
+
`string`
|
|
36
|
+
|
|
37
|
+
The path to the favicon.
|
|
38
|
+
|
|
33
39
|
## Returns
|
|
34
40
|
|
|
35
|
-
`IEngineServerConfig
|
|
41
|
+
`Promise`\<`IEngineServerConfig`\>
|
|
36
42
|
|
|
37
|
-
The
|
|
43
|
+
The config for the core and the server.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Function: directoryExists()
|
|
2
|
+
|
|
3
|
+
> **directoryExists**(`directory`): `Promise`\<`boolean`\>
|
|
4
|
+
|
|
5
|
+
Does the specified directory exist.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### directory
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
The directory to check for existence.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`boolean`\>
|
|
18
|
+
|
|
19
|
+
True if the directory exists.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Function: extensionsConfiguration()
|
|
2
|
+
|
|
3
|
+
> **extensionsConfiguration**(`envVars`, `nodeEngineConfig`): `Promise`\<[`INodeEngineConfig`](../interfaces/INodeEngineConfig.md)\>
|
|
4
|
+
|
|
5
|
+
Handles the configuration of the extensions.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### envVars
|
|
10
|
+
|
|
11
|
+
[`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md)
|
|
12
|
+
|
|
13
|
+
The environment variables for the node.
|
|
14
|
+
|
|
15
|
+
### nodeEngineConfig
|
|
16
|
+
|
|
17
|
+
[`INodeEngineConfig`](../interfaces/INodeEngineConfig.md)
|
|
18
|
+
|
|
19
|
+
The node engine config.
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`Promise`\<[`INodeEngineConfig`](../interfaces/INodeEngineConfig.md)\>
|
|
24
|
+
|
|
25
|
+
The config for the core and the server.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Function: extensionsInitialiseEngine()
|
|
2
|
+
|
|
3
|
+
> **extensionsInitialiseEngine**(`envVars`, `engineCore`): `Promise`\<`void`\>
|
|
4
|
+
|
|
5
|
+
Handles the initialisation of the extensions when the engine has been constructed.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### envVars
|
|
10
|
+
|
|
11
|
+
[`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md)
|
|
12
|
+
|
|
13
|
+
The environment variables for the node.
|
|
14
|
+
|
|
15
|
+
### engineCore
|
|
16
|
+
|
|
17
|
+
`IEngineCore`
|
|
18
|
+
|
|
19
|
+
The engine core instance.
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`Promise`\<`void`\>
|
|
24
|
+
|
|
25
|
+
Nothing.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: extensionsInitialiseEngineServer()
|
|
2
|
+
|
|
3
|
+
> **extensionsInitialiseEngineServer**(`envVars`, `engineCore`, `engineServer`): `Promise`\<`void`\>
|
|
4
|
+
|
|
5
|
+
Handles the initialisation of the extensions when the engine server has been constructed.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### envVars
|
|
10
|
+
|
|
11
|
+
[`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md)
|
|
12
|
+
|
|
13
|
+
The environment variables for the node.
|
|
14
|
+
|
|
15
|
+
### engineCore
|
|
16
|
+
|
|
17
|
+
`IEngineCore`
|
|
18
|
+
|
|
19
|
+
The engine core instance.
|
|
20
|
+
|
|
21
|
+
### engineServer
|
|
22
|
+
|
|
23
|
+
`IEngineServer`
|
|
24
|
+
|
|
25
|
+
The engine server instance.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<`void`\>
|
|
30
|
+
|
|
31
|
+
Nothing.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Function: getFiles()
|
|
2
|
+
|
|
3
|
+
> **getFiles**(`directory`): `Promise`\<`string`[]\>
|
|
4
|
+
|
|
5
|
+
Get the files in the directory.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### directory
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
The directory to get the files from.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`string`[]\>
|
|
18
|
+
|
|
19
|
+
The list of files in the directory.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Function: getSubFolders()
|
|
2
|
+
|
|
3
|
+
> **getSubFolders**(`directory`): `Promise`\<`string`[]\>
|
|
4
|
+
|
|
5
|
+
Get the sub folders for the folder.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### directory
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
The directory to get the sub folders.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`string`[]\>
|
|
18
|
+
|
|
19
|
+
The list of sub folders.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Function: loadTextFile()
|
|
2
|
+
|
|
3
|
+
> **loadTextFile**(`filename`): `Promise`\<`string`\>
|
|
4
|
+
|
|
5
|
+
Load the text file.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### filename
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
The filename of the text file to load.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`Promise`\<`string`\>
|
|
18
|
+
|
|
19
|
+
The contents of the text file if it could not be loaded.
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Function: overrideModuleImport()
|
|
2
|
+
|
|
3
|
+
> **overrideModuleImport**(`executionDirectory`): `void`
|
|
4
|
+
|
|
5
|
+
Override module imports to use local files where possible.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### executionDirectory
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
The execution directory for resolving local module paths.
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`void`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Function: shutdownExtensions()
|
|
2
|
+
|
|
3
|
+
> **shutdownExtensions**(`envVars`, `engineCore`): `Promise`\<`void`\>
|
|
4
|
+
|
|
5
|
+
Handles the shutdown of the extensions.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### envVars
|
|
10
|
+
|
|
11
|
+
[`INodeEnvironmentVariables`](../interfaces/INodeEnvironmentVariables.md)
|
|
12
|
+
|
|
13
|
+
The environment variables for the node.
|
|
14
|
+
|
|
15
|
+
### engineCore
|
|
16
|
+
|
|
17
|
+
`IEngineCore`
|
|
18
|
+
|
|
19
|
+
The engine core instance.
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`Promise`\<`void`\>
|
|
24
|
+
|
|
25
|
+
Nothing.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Function: start()
|
|
2
2
|
|
|
3
|
-
> **start**(`nodeOptions`, `
|
|
3
|
+
> **start**(`nodeOptions`, `nodeEngineConfig`, `envVars`): `Promise`\<`undefined` \| \{ `engine`: `Engine`\<`IEngineServerConfig`, `IEngineState`\>; `server`: `EngineServer`; `shutdown`: () => `Promise`\<`void`\>; \}\>
|
|
4
4
|
|
|
5
5
|
Start the engine server.
|
|
6
6
|
|
|
@@ -12,9 +12,9 @@ Optional run options for the engine server.
|
|
|
12
12
|
|
|
13
13
|
`undefined` | [`INodeOptions`](../interfaces/INodeOptions.md)
|
|
14
14
|
|
|
15
|
-
###
|
|
15
|
+
### nodeEngineConfig
|
|
16
16
|
|
|
17
|
-
`
|
|
17
|
+
[`INodeEngineConfig`](../interfaces/INodeEngineConfig.md)
|
|
18
18
|
|
|
19
19
|
The configuration for the engine server.
|
|
20
20
|
|
|
@@ -26,6 +26,6 @@ The environment variables.
|
|
|
26
26
|
|
|
27
27
|
## Returns
|
|
28
28
|
|
|
29
|
-
`Promise`\<`undefined` \| \{ `engine`: `Engine`\<`IEngineServerConfig`, `IEngineState`\>; `server`: `EngineServer`; \}\>
|
|
29
|
+
`Promise`\<`undefined` \| \{ `engine`: `Engine`\<`IEngineServerConfig`, `IEngineState`\>; `server`: `EngineServer`; `shutdown`: () => `Promise`\<`void`\>; \}\>
|
|
30
30
|
|
|
31
31
|
The engine server.
|
package/docs/reference/index.md
CHANGED
|
@@ -4,15 +4,26 @@
|
|
|
4
4
|
|
|
5
5
|
- [IEngineEnvironmentVariables](interfaces/IEngineEnvironmentVariables.md)
|
|
6
6
|
- [IEngineServerEnvironmentVariables](interfaces/IEngineServerEnvironmentVariables.md)
|
|
7
|
+
- [INodeEngineConfig](interfaces/INodeEngineConfig.md)
|
|
7
8
|
- [INodeEnvironmentVariables](interfaces/INodeEnvironmentVariables.md)
|
|
8
9
|
- [INodeOptions](interfaces/INodeOptions.md)
|
|
9
10
|
|
|
10
11
|
## Type Aliases
|
|
11
12
|
|
|
13
|
+
- [NodeExtensionInitialiseMethod](type-aliases/NodeExtensionInitialiseMethod.md)
|
|
14
|
+
- [NodeExtensionInitialiseEngineMethod](type-aliases/NodeExtensionInitialiseEngineMethod.md)
|
|
15
|
+
- [NodeExtensionInitialiseEngineServerMethod](type-aliases/NodeExtensionInitialiseEngineServerMethod.md)
|
|
16
|
+
- [NodeExtensionShutdownMethod](type-aliases/NodeExtensionShutdownMethod.md)
|
|
12
17
|
- [NodeFeatures](type-aliases/NodeFeatures.md)
|
|
13
18
|
|
|
14
19
|
## Variables
|
|
15
20
|
|
|
21
|
+
- [ATTESTATION\_VERIFICATION\_METHOD\_ID](variables/ATTESTATION_VERIFICATION_METHOD_ID.md)
|
|
22
|
+
- [IMMUTABLE\_PROOF\_VERIFICATION\_METHOD\_ID](variables/IMMUTABLE_PROOF_VERIFICATION_METHOD_ID.md)
|
|
23
|
+
- [BLOB\_STORAGE\_ENCRYPTION\_KEY\_ID](variables/BLOB_STORAGE_ENCRYPTION_KEY_ID.md)
|
|
24
|
+
- [SYNCHRONISED\_STORAGE\_BLOB\_STORAGE\_ENCRYPTION\_KEY\_ID](variables/SYNCHRONISED_STORAGE_BLOB_STORAGE_ENCRYPTION_KEY_ID.md)
|
|
25
|
+
- [VC\_AUTHENTICATION\_VERIFICATION\_METHOD\_ID](variables/VC_AUTHENTICATION_VERIFICATION_METHOD_ID.md)
|
|
26
|
+
- [AUTH\_SIGNING\_KEY\_ID](variables/AUTH_SIGNING_KEY_ID.md)
|
|
16
27
|
- [NodeFeatures](variables/NodeFeatures.md)
|
|
17
28
|
|
|
18
29
|
## Functions
|
|
@@ -20,17 +31,26 @@
|
|
|
20
31
|
- [bootstrap](functions/bootstrap.md)
|
|
21
32
|
- [bootstrapNodeIdentity](functions/bootstrapNodeIdentity.md)
|
|
22
33
|
- [bootstrapNodeUser](functions/bootstrapNodeUser.md)
|
|
23
|
-
- [bootstrapAttestationMethod](functions/bootstrapAttestationMethod.md)
|
|
24
34
|
- [bootstrapImmutableProofMethod](functions/bootstrapImmutableProofMethod.md)
|
|
25
35
|
- [bootstrapBlobEncryption](functions/bootstrapBlobEncryption.md)
|
|
26
36
|
- [bootstrapAuth](functions/bootstrapAuth.md)
|
|
37
|
+
- [bootstrapSynchronisedStorage](functions/bootstrapSynchronisedStorage.md)
|
|
27
38
|
- [buildEngineConfiguration](functions/buildEngineConfiguration.md)
|
|
28
39
|
- [buildEngineServerConfiguration](functions/buildEngineServerConfiguration.md)
|
|
40
|
+
- [extensionsConfiguration](functions/extensionsConfiguration.md)
|
|
41
|
+
- [extensionsInitialiseEngine](functions/extensionsInitialiseEngine.md)
|
|
42
|
+
- [extensionsInitialiseEngineServer](functions/extensionsInitialiseEngineServer.md)
|
|
43
|
+
- [shutdownExtensions](functions/shutdownExtensions.md)
|
|
29
44
|
- [run](functions/run.md)
|
|
30
45
|
- [buildConfiguration](functions/buildConfiguration.md)
|
|
46
|
+
- [overrideModuleImport](functions/overrideModuleImport.md)
|
|
31
47
|
- [start](functions/start.md)
|
|
32
48
|
- [initialiseLocales](functions/initialiseLocales.md)
|
|
33
49
|
- [getExecutionDirectory](functions/getExecutionDirectory.md)
|
|
34
50
|
- [fileExists](functions/fileExists.md)
|
|
51
|
+
- [directoryExists](functions/directoryExists.md)
|
|
52
|
+
- [getSubFolders](functions/getSubFolders.md)
|
|
53
|
+
- [getFiles](functions/getFiles.md)
|
|
54
|
+
- [loadTextFile](functions/loadTextFile.md)
|
|
35
55
|
- [loadJsonFile](functions/loadJsonFile.md)
|
|
36
56
|
- [getFeatures](functions/getFeatures.md)
|