@twin.org/blob-storage-connector-ipfs 0.0.1-next.16 → 0.0.1-next.18
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 +0 -1
- package/dist/esm/index.mjs +0 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/ipfsBlobStorageConnector.d.ts +2 -5
- package/dist/types/models/IIpfsBlobStorageConnectorConstructorOptions.d.ts +10 -0
- package/docs/changelog.md +1 -1
- package/docs/reference/classes/IpfsBlobStorageConnector.md +12 -8
- package/docs/reference/index.md +1 -0
- package/docs/reference/interfaces/IIpfsBlobStorageConnectorConstructorOptions.md +11 -0
- package/package.json +2 -2
package/dist/cjs/index.cjs
CHANGED
|
@@ -24,7 +24,6 @@ class IpfsBlobStorageConnector {
|
|
|
24
24
|
/**
|
|
25
25
|
* Create a new instance of IpfsBlobStorageConnector.
|
|
26
26
|
* @param options The options for the connector.
|
|
27
|
-
* @param options.config The configuration for the connector.
|
|
28
27
|
*/
|
|
29
28
|
constructor(options) {
|
|
30
29
|
core.Guards.object(this.CLASS_NAME, "options", options);
|
package/dist/esm/index.mjs
CHANGED
|
@@ -22,7 +22,6 @@ class IpfsBlobStorageConnector {
|
|
|
22
22
|
/**
|
|
23
23
|
* Create a new instance of IpfsBlobStorageConnector.
|
|
24
24
|
* @param options The options for the connector.
|
|
25
|
-
* @param options.config The configuration for the connector.
|
|
26
25
|
*/
|
|
27
26
|
constructor(options) {
|
|
28
27
|
Guards.object(this.CLASS_NAME, "options", options);
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { IBlobStorageConnector } from "@twin.org/blob-storage-models";
|
|
2
|
-
import type {
|
|
2
|
+
import type { IIpfsBlobStorageConnectorConstructorOptions } from "./models/IIpfsBlobStorageConnectorConstructorOptions";
|
|
3
3
|
/**
|
|
4
4
|
* Class for performing blob storage operations on IPFS.
|
|
5
5
|
* See https://docs.ipfs.tech/reference/kubo/rpc/ for more information.
|
|
@@ -16,11 +16,8 @@ export declare class IpfsBlobStorageConnector implements IBlobStorageConnector {
|
|
|
16
16
|
/**
|
|
17
17
|
* Create a new instance of IpfsBlobStorageConnector.
|
|
18
18
|
* @param options The options for the connector.
|
|
19
|
-
* @param options.config The configuration for the connector.
|
|
20
19
|
*/
|
|
21
|
-
constructor(options:
|
|
22
|
-
config: IIpfsBlobStorageConnectorConfig;
|
|
23
|
-
});
|
|
20
|
+
constructor(options: IIpfsBlobStorageConnectorConstructorOptions);
|
|
24
21
|
/**
|
|
25
22
|
* Set the blob.
|
|
26
23
|
* @param blob The data for the blob.
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { IIpfsBlobStorageConnectorConfig } from "./IIpfsBlobStorageConnectorConfig";
|
|
2
|
+
/**
|
|
3
|
+
* Options for the IPFS Blob Storage Connector constructor.
|
|
4
|
+
*/
|
|
5
|
+
export interface IIpfsBlobStorageConnectorConstructorOptions {
|
|
6
|
+
/**
|
|
7
|
+
* The configuration for the connector.
|
|
8
|
+
*/
|
|
9
|
+
config: IIpfsBlobStorageConnectorConfig;
|
|
10
|
+
}
|
package/docs/changelog.md
CHANGED
|
@@ -17,13 +17,11 @@ Create a new instance of IpfsBlobStorageConnector.
|
|
|
17
17
|
|
|
18
18
|
#### Parameters
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
##### options
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
• **options.config**: [`IIpfsBlobStorageConnectorConfig`](../interfaces/IIpfsBlobStorageConnectorConfig.md)
|
|
22
|
+
[`IIpfsBlobStorageConnectorConstructorOptions`](../interfaces/IIpfsBlobStorageConnectorConstructorOptions.md)
|
|
25
23
|
|
|
26
|
-
The
|
|
24
|
+
The options for the connector.
|
|
27
25
|
|
|
28
26
|
#### Returns
|
|
29
27
|
|
|
@@ -59,7 +57,9 @@ Set the blob.
|
|
|
59
57
|
|
|
60
58
|
#### Parameters
|
|
61
59
|
|
|
62
|
-
|
|
60
|
+
##### blob
|
|
61
|
+
|
|
62
|
+
`Uint8Array`
|
|
63
63
|
|
|
64
64
|
The data for the blob.
|
|
65
65
|
|
|
@@ -83,7 +83,9 @@ Get the blob.
|
|
|
83
83
|
|
|
84
84
|
#### Parameters
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
##### id
|
|
87
|
+
|
|
88
|
+
`string`
|
|
87
89
|
|
|
88
90
|
The id of the blob to get in urn format.
|
|
89
91
|
|
|
@@ -107,7 +109,9 @@ Remove the blob.
|
|
|
107
109
|
|
|
108
110
|
#### Parameters
|
|
109
111
|
|
|
110
|
-
|
|
112
|
+
##### id
|
|
113
|
+
|
|
114
|
+
`string`
|
|
111
115
|
|
|
112
116
|
The id of the blob to remove in urn format.
|
|
113
117
|
|
package/docs/reference/index.md
CHANGED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# Interface: IIpfsBlobStorageConnectorConstructorOptions
|
|
2
|
+
|
|
3
|
+
Options for the IPFS Blob Storage Connector constructor.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### config
|
|
8
|
+
|
|
9
|
+
> **config**: [`IIpfsBlobStorageConnectorConfig`](IIpfsBlobStorageConnectorConfig.md)
|
|
10
|
+
|
|
11
|
+
The configuration for the connector.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/blob-storage-connector-ipfs",
|
|
3
|
-
"version": "0.0.1-next.
|
|
3
|
+
"version": "0.0.1-next.18",
|
|
4
4
|
"description": "Blob Storage connector implementation using IPFS",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"node": ">=20.0.0"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@twin.org/blob-storage-models": "0.0.1-next.
|
|
17
|
+
"@twin.org/blob-storage-models": "0.0.1-next.18",
|
|
18
18
|
"@twin.org/core": "next",
|
|
19
19
|
"@twin.org/crypto": "next",
|
|
20
20
|
"@twin.org/nameof": "next",
|