@oceanprotocol/lib 3.0.0-next.4 → 3.0.0-next.5
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/CHANGELOG.md +11 -1
- package/dist/lib.js +1 -1
- package/dist/lib.js.map +1 -1
- package/dist/lib.modern.js +1 -1
- package/dist/lib.modern.js.map +1 -1
- package/dist/lib.module.js +1 -1
- package/dist/lib.module.js.map +1 -1
- package/dist/lib.umd.js +1 -1
- package/dist/lib.umd.js.map +1 -1
- package/dist/src/@types/DDO/ConsumerParameter.d.ts +37 -0
- package/dist/src/@types/DDO/Metadata.d.ts +11 -0
- package/dist/src/@types/DDO/Service.d.ts +6 -0
- package/dist/src/@types/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
export interface ConsumerParameter {
|
|
2
|
+
/**
|
|
3
|
+
* Parameter name.
|
|
4
|
+
* @type {string}
|
|
5
|
+
*/
|
|
6
|
+
name: string;
|
|
7
|
+
/**
|
|
8
|
+
* Field type.
|
|
9
|
+
* @type {'text' | 'number' | 'boolean' | 'select'}
|
|
10
|
+
*/
|
|
11
|
+
type: 'text' | 'number' | 'boolean' | 'select';
|
|
12
|
+
/**
|
|
13
|
+
* Displayed field label.
|
|
14
|
+
* @type {string}
|
|
15
|
+
*/
|
|
16
|
+
label: string;
|
|
17
|
+
/**
|
|
18
|
+
* Defines if customer input for this field is mandatory.
|
|
19
|
+
* @type {boolean}
|
|
20
|
+
*/
|
|
21
|
+
required: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Field description.
|
|
24
|
+
* @type {string}
|
|
25
|
+
*/
|
|
26
|
+
description: string;
|
|
27
|
+
/**
|
|
28
|
+
* Field default value. For select types, string key of default option.
|
|
29
|
+
* @type {string}
|
|
30
|
+
*/
|
|
31
|
+
default: string;
|
|
32
|
+
/**
|
|
33
|
+
* For select types, a list of options.
|
|
34
|
+
* @type {string}
|
|
35
|
+
*/
|
|
36
|
+
options?: string;
|
|
37
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ConsumerParameter } from './ConsumerParameter';
|
|
1
2
|
export interface MetadataAlgorithm {
|
|
2
3
|
/**
|
|
3
4
|
* Programming language used to implement the software.
|
|
@@ -39,7 +40,17 @@ export interface MetadataAlgorithm {
|
|
|
39
40
|
* @type {string}
|
|
40
41
|
*/
|
|
41
42
|
checksum: string;
|
|
43
|
+
/**
|
|
44
|
+
* Array of objects describing the consumer parameters
|
|
45
|
+
* @type {ConsumerParameter[]}
|
|
46
|
+
*/
|
|
47
|
+
consumerParameters?: ConsumerParameter[];
|
|
42
48
|
};
|
|
49
|
+
/**
|
|
50
|
+
* Array of objects describing the consumer parameters
|
|
51
|
+
* @type {ConsumerParameter[]}
|
|
52
|
+
*/
|
|
53
|
+
consumerParameters?: ConsumerParameter[];
|
|
43
54
|
}
|
|
44
55
|
export interface Metadata {
|
|
45
56
|
/**
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ConsumerParameter } from './ConsumerParameter';
|
|
1
2
|
export interface PublisherTrustedAlgorithm {
|
|
2
3
|
/**
|
|
3
4
|
* The DID of the algorithm which is trusted by the publisher.
|
|
@@ -86,6 +87,11 @@ export interface Service {
|
|
|
86
87
|
* @type {ServiceComputeOptions}
|
|
87
88
|
*/
|
|
88
89
|
compute?: ServiceComputeOptions;
|
|
90
|
+
/**
|
|
91
|
+
* Array of objects describing the consumer parameters
|
|
92
|
+
* @type {ConsumerParameter[]}
|
|
93
|
+
*/
|
|
94
|
+
consumerParameters?: ConsumerParameter[];
|
|
89
95
|
/**
|
|
90
96
|
* Stores service specific additional information, this is customizable by publisher
|
|
91
97
|
* @type {any}
|
package/package.json
CHANGED