@twin.org/blob-storage-service 0.0.1-next.33 → 0.0.1-next.35
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 +61 -20
- package/dist/esm/index.mjs +62 -21
- package/dist/types/blobStorageService.d.ts +18 -4
- package/dist/types/entities/blobStorageEntry.d.ts +4 -0
- package/dist/types/models/IBlobStorageServiceConfig.d.ts +1 -2
- package/dist/types/models/IBlobStorageServiceConstructorOptions.d.ts +1 -1
- package/docs/changelog.md +32 -0
- package/docs/open-api/spec.json +64 -1101
- package/docs/reference/classes/BlobStorageEntry.md +8 -0
- package/docs/reference/classes/BlobStorageService.md +36 -4
- package/docs/reference/interfaces/IBlobStorageServiceConfig.md +1 -7
- package/docs/reference/interfaces/IBlobStorageServiceConstructorOptions.md +1 -1
- package/locales/en.json +2 -1
- package/package.json +2 -2
|
@@ -50,7 +50,7 @@ Runtime name for the class.
|
|
|
50
50
|
|
|
51
51
|
### create()
|
|
52
52
|
|
|
53
|
-
> **create**(`blob`, `encodingFormat?`, `fileExtension?`, `metadata?`, `
|
|
53
|
+
> **create**(`blob`, `encodingFormat?`, `fileExtension?`, `metadata?`, `options?`, `userIdentity?`, `nodeIdentity?`): `Promise`\<`string`\>
|
|
54
54
|
|
|
55
55
|
Create the blob with some metadata.
|
|
56
56
|
|
|
@@ -80,7 +80,23 @@ Extension for the blob, will be detected if left undefined.
|
|
|
80
80
|
|
|
81
81
|
Data for the custom metadata as JSON-LD.
|
|
82
82
|
|
|
83
|
-
#####
|
|
83
|
+
##### options?
|
|
84
|
+
|
|
85
|
+
Optional options for the creation of the blob.
|
|
86
|
+
|
|
87
|
+
###### disableEncryption?
|
|
88
|
+
|
|
89
|
+
`boolean`
|
|
90
|
+
|
|
91
|
+
Disables encryption if enabled by default.
|
|
92
|
+
|
|
93
|
+
###### overrideVaultKeyId?
|
|
94
|
+
|
|
95
|
+
`string`
|
|
96
|
+
|
|
97
|
+
Use a different vault key id for encryption, if not provided the default vault key id will be used.
|
|
98
|
+
|
|
99
|
+
###### namespace?
|
|
84
100
|
|
|
85
101
|
`string`
|
|
86
102
|
|
|
@@ -112,7 +128,7 @@ The id of the stored blob in urn format.
|
|
|
112
128
|
|
|
113
129
|
### get()
|
|
114
130
|
|
|
115
|
-
> **get**(`id`, `
|
|
131
|
+
> **get**(`id`, `options?`, `userIdentity?`, `nodeIdentity?`): `Promise`\<`IBlobStorageEntry`\>
|
|
116
132
|
|
|
117
133
|
Get the blob entry.
|
|
118
134
|
|
|
@@ -124,12 +140,28 @@ Get the blob entry.
|
|
|
124
140
|
|
|
125
141
|
The id of the blob to get in urn format.
|
|
126
142
|
|
|
127
|
-
#####
|
|
143
|
+
##### options?
|
|
144
|
+
|
|
145
|
+
Optional options for the retrieval of the blob.
|
|
146
|
+
|
|
147
|
+
###### includeContent?
|
|
128
148
|
|
|
129
149
|
`boolean`
|
|
130
150
|
|
|
131
151
|
Include the content, or just get the metadata.
|
|
132
152
|
|
|
153
|
+
###### disableDecryption?
|
|
154
|
+
|
|
155
|
+
`boolean`
|
|
156
|
+
|
|
157
|
+
Disables decryption if enabled by default.
|
|
158
|
+
|
|
159
|
+
###### overrideVaultKeyId?
|
|
160
|
+
|
|
161
|
+
`string`
|
|
162
|
+
|
|
163
|
+
Use a different vault key id for decryption, if not provided the default vault key id will be used.
|
|
164
|
+
|
|
133
165
|
##### userIdentity?
|
|
134
166
|
|
|
135
167
|
`string`
|
|
@@ -8,13 +8,7 @@ Configuration for the blob storage service.
|
|
|
8
8
|
|
|
9
9
|
> `optional` **vaultKeyId**: `string`
|
|
10
10
|
|
|
11
|
-
The name of the vault key to use for encryption if
|
|
12
|
-
|
|
13
|
-
#### Default
|
|
14
|
-
|
|
15
|
-
```ts
|
|
16
|
-
blob-storage.
|
|
17
|
-
```
|
|
11
|
+
The name of the vault key to use for encryption, if not configured no encryption will happen.
|
|
18
12
|
|
|
19
13
|
***
|
|
20
14
|
|
package/locales/en.json
CHANGED
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
"getFailed": "There was a problem getting the blob",
|
|
7
7
|
"updateFailed": "There was a problem updating the blob",
|
|
8
8
|
"removeFailed": "There was a problem removing the blob",
|
|
9
|
-
"namespaceMismatch": "The namespace in the urn \"{id}\" does not match the namespace of the blob storage service \"{namespace}\""
|
|
9
|
+
"namespaceMismatch": "The namespace in the urn \"{id}\" does not match the namespace of the blob storage service \"{namespace}\"",
|
|
10
|
+
"vaultConnectorNotConfigured": "The vault connector is not configured, but encryption/decryption was requested."
|
|
10
11
|
}
|
|
11
12
|
}
|
|
12
13
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/blob-storage-service",
|
|
3
|
-
"version": "0.0.1-next.
|
|
3
|
+
"version": "0.0.1-next.35",
|
|
4
4
|
"description": "Blob storage contract implementation and REST endpoint definitions",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"@twin.org/api-models": "next",
|
|
18
|
-
"@twin.org/blob-storage-models": "0.0.1-next.
|
|
18
|
+
"@twin.org/blob-storage-models": "0.0.1-next.35",
|
|
19
19
|
"@twin.org/core": "next",
|
|
20
20
|
"@twin.org/crypto": "next",
|
|
21
21
|
"@twin.org/data-json-ld": "next",
|