@twin.org/federated-catalogue-service 0.0.1 → 0.0.2-next.2
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 +464 -469
- package/dist/esm/index.mjs +1368 -1373
- package/dist/types/federatedCatalogueService.d.ts +0 -4
- package/dist/types/index.d.ts +6 -6
- package/dist/types/models/IFederatedCatalogueServiceConstructorOptions.d.ts +2 -2
- package/dist/types/verification/complianceCredentialVerificationService.d.ts +2 -2
- package/docs/changelog.md +47 -0
- package/docs/open-api/spec.json +319 -29
- package/docs/reference/classes/FederatedCatalogueService.md +0 -8
- package/docs/reference/interfaces/IFederatedCatalogueServiceConstructorOptions.md +3 -3
- package/package.json +17 -17
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,32 +1,468 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
var entity = require('@twin.org/entity');
|
|
3
4
|
var core = require('@twin.org/core');
|
|
4
5
|
var federatedCatalogueModels = require('@twin.org/federated-catalogue-models');
|
|
5
6
|
var standardsGaiaX = require('@twin.org/standards-gaia-x');
|
|
6
7
|
var standardsSchemaOrg = require('@twin.org/standards-schema-org');
|
|
7
8
|
var web = require('@twin.org/web');
|
|
8
9
|
var dataJsonLd = require('@twin.org/data-json-ld');
|
|
9
|
-
var entity = require('@twin.org/entity');
|
|
10
10
|
var entityStorageModels = require('@twin.org/entity-storage-models');
|
|
11
11
|
var identityModels = require('@twin.org/identity-models');
|
|
12
|
-
var loggingModels = require('@twin.org/logging-models');
|
|
13
12
|
var crypto = require('@twin.org/crypto');
|
|
14
13
|
var standardsW3cDid = require('@twin.org/standards-w3c-did');
|
|
15
14
|
|
|
15
|
+
// Copyright 2024 IOTA Stiftung.
|
|
16
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
16
17
|
/**
|
|
17
|
-
*
|
|
18
|
+
* Data Resource Entry.
|
|
18
19
|
*/
|
|
19
|
-
|
|
20
|
+
exports.DataResourceEntry = class DataResourceEntry {
|
|
21
|
+
/**
|
|
22
|
+
* The Id.
|
|
23
|
+
*/
|
|
24
|
+
id;
|
|
25
|
+
/**
|
|
26
|
+
* The trusted issuer of the compliance credential
|
|
27
|
+
*/
|
|
28
|
+
issuer;
|
|
29
|
+
/**
|
|
30
|
+
* The name.
|
|
31
|
+
*/
|
|
32
|
+
name;
|
|
33
|
+
/**
|
|
34
|
+
* The description.
|
|
35
|
+
*/
|
|
36
|
+
description;
|
|
37
|
+
/**
|
|
38
|
+
* The Id of the producer of the data described by this Data Resource.
|
|
39
|
+
*/
|
|
40
|
+
producedBy;
|
|
41
|
+
/**
|
|
42
|
+
* The copyright owner
|
|
43
|
+
*/
|
|
44
|
+
copyrightOwnedBy;
|
|
45
|
+
/**
|
|
46
|
+
* The license
|
|
47
|
+
*/
|
|
48
|
+
license;
|
|
49
|
+
/**
|
|
50
|
+
* The data exchange component used to expose the Data Resource.
|
|
51
|
+
* Only a URL pointing to the resource is stored
|
|
52
|
+
*/
|
|
53
|
+
exposedThrough;
|
|
54
|
+
/**
|
|
55
|
+
* The Data Resource policy
|
|
56
|
+
*/
|
|
57
|
+
resourcePolicy;
|
|
58
|
+
/**
|
|
59
|
+
* Valid from
|
|
60
|
+
*/
|
|
61
|
+
validFrom;
|
|
62
|
+
/**
|
|
63
|
+
* Valid to
|
|
64
|
+
*/
|
|
65
|
+
validUntil;
|
|
66
|
+
/**
|
|
67
|
+
* Date created
|
|
68
|
+
*/
|
|
69
|
+
dateCreated;
|
|
70
|
+
/**
|
|
71
|
+
* Evidences
|
|
72
|
+
*/
|
|
73
|
+
evidence;
|
|
74
|
+
};
|
|
75
|
+
__decorate([
|
|
76
|
+
entity.property({ type: "string", isPrimary: true }),
|
|
77
|
+
__metadata("design:type", String)
|
|
78
|
+
], exports.DataResourceEntry.prototype, "id", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
entity.property({ type: "string" }),
|
|
81
|
+
__metadata("design:type", String)
|
|
82
|
+
], exports.DataResourceEntry.prototype, "issuer", void 0);
|
|
83
|
+
__decorate([
|
|
84
|
+
entity.property({ type: "string" }),
|
|
85
|
+
__metadata("design:type", String)
|
|
86
|
+
], exports.DataResourceEntry.prototype, "name", void 0);
|
|
87
|
+
__decorate([
|
|
88
|
+
entity.property({ type: "string", optional: true }),
|
|
89
|
+
__metadata("design:type", String)
|
|
90
|
+
], exports.DataResourceEntry.prototype, "description", void 0);
|
|
91
|
+
__decorate([
|
|
92
|
+
entity.property({ type: "string", isSecondary: true }),
|
|
93
|
+
__metadata("design:type", String)
|
|
94
|
+
], exports.DataResourceEntry.prototype, "producedBy", void 0);
|
|
95
|
+
__decorate([
|
|
96
|
+
entity.property({ type: "string" }),
|
|
97
|
+
__metadata("design:type", String)
|
|
98
|
+
], exports.DataResourceEntry.prototype, "copyrightOwnedBy", void 0);
|
|
99
|
+
__decorate([
|
|
100
|
+
entity.property({ type: "string" }),
|
|
101
|
+
__metadata("design:type", String)
|
|
102
|
+
], exports.DataResourceEntry.prototype, "license", void 0);
|
|
103
|
+
__decorate([
|
|
104
|
+
entity.property({ type: "string" }),
|
|
105
|
+
__metadata("design:type", String)
|
|
106
|
+
], exports.DataResourceEntry.prototype, "exposedThrough", void 0);
|
|
107
|
+
__decorate([
|
|
108
|
+
entity.property({ type: "array" }),
|
|
109
|
+
__metadata("design:type", Array)
|
|
110
|
+
], exports.DataResourceEntry.prototype, "resourcePolicy", void 0);
|
|
111
|
+
__decorate([
|
|
112
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
113
|
+
__metadata("design:type", String)
|
|
114
|
+
], exports.DataResourceEntry.prototype, "validFrom", void 0);
|
|
115
|
+
__decorate([
|
|
116
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
117
|
+
__metadata("design:type", String)
|
|
118
|
+
], exports.DataResourceEntry.prototype, "validUntil", void 0);
|
|
119
|
+
__decorate([
|
|
120
|
+
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
121
|
+
__metadata("design:type", String)
|
|
122
|
+
], exports.DataResourceEntry.prototype, "dateCreated", void 0);
|
|
123
|
+
__decorate([
|
|
124
|
+
entity.property({ type: "array" }),
|
|
125
|
+
__metadata("design:type", Array)
|
|
126
|
+
], exports.DataResourceEntry.prototype, "evidence", void 0);
|
|
127
|
+
exports.DataResourceEntry = __decorate([
|
|
128
|
+
entity.entity()
|
|
129
|
+
], exports.DataResourceEntry);
|
|
130
|
+
|
|
131
|
+
// Copyright 2024 IOTA Stiftung.
|
|
132
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
20
133
|
/**
|
|
21
|
-
*
|
|
134
|
+
* Data Space Connector Entry.
|
|
22
135
|
*/
|
|
23
|
-
|
|
136
|
+
exports.DataSpaceConnectorEntry = class DataSpaceConnectorEntry {
|
|
137
|
+
/**
|
|
138
|
+
* The Id.
|
|
139
|
+
*/
|
|
140
|
+
id;
|
|
141
|
+
/**
|
|
142
|
+
* The trusted issuer of the compliance credential.
|
|
143
|
+
*/
|
|
144
|
+
issuer;
|
|
145
|
+
/**
|
|
146
|
+
* The name.
|
|
147
|
+
*/
|
|
148
|
+
name;
|
|
149
|
+
/**
|
|
150
|
+
* The description.
|
|
151
|
+
*/
|
|
152
|
+
description;
|
|
153
|
+
/**
|
|
154
|
+
* The identity of the Data Space Connector
|
|
155
|
+
*/
|
|
156
|
+
identity;
|
|
157
|
+
/**
|
|
158
|
+
* Who maintains the Data Space Connector
|
|
159
|
+
*/
|
|
160
|
+
maintainer;
|
|
161
|
+
/**
|
|
162
|
+
* The default endpoint
|
|
163
|
+
*/
|
|
164
|
+
defaultEndpoint;
|
|
165
|
+
/**
|
|
166
|
+
* The activity push endpoint
|
|
167
|
+
*/
|
|
168
|
+
pushActivityEndpoint;
|
|
169
|
+
/**
|
|
170
|
+
* The activity subscribe endpoint
|
|
171
|
+
*/
|
|
172
|
+
subscriptionActivityEndpoint;
|
|
173
|
+
/**
|
|
174
|
+
* The pull data endpoint
|
|
175
|
+
*/
|
|
176
|
+
pullDataEndpoint;
|
|
177
|
+
/**
|
|
178
|
+
* The pull data endpoint
|
|
179
|
+
*/
|
|
180
|
+
offeredResource;
|
|
181
|
+
/**
|
|
182
|
+
* Valid from
|
|
183
|
+
*/
|
|
184
|
+
validFrom;
|
|
185
|
+
/**
|
|
186
|
+
* Valid to
|
|
187
|
+
*/
|
|
188
|
+
validUntil;
|
|
189
|
+
/**
|
|
190
|
+
* Date created
|
|
191
|
+
*/
|
|
192
|
+
dateCreated;
|
|
193
|
+
/**
|
|
194
|
+
* Evidences
|
|
195
|
+
*/
|
|
196
|
+
evidence;
|
|
197
|
+
};
|
|
198
|
+
__decorate([
|
|
199
|
+
entity.property({ type: "string", isPrimary: true }),
|
|
200
|
+
__metadata("design:type", String)
|
|
201
|
+
], exports.DataSpaceConnectorEntry.prototype, "id", void 0);
|
|
202
|
+
__decorate([
|
|
203
|
+
entity.property({ type: "string" }),
|
|
204
|
+
__metadata("design:type", String)
|
|
205
|
+
], exports.DataSpaceConnectorEntry.prototype, "issuer", void 0);
|
|
206
|
+
__decorate([
|
|
207
|
+
entity.property({ type: "string", optional: true }),
|
|
208
|
+
__metadata("design:type", String)
|
|
209
|
+
], exports.DataSpaceConnectorEntry.prototype, "name", void 0);
|
|
210
|
+
__decorate([
|
|
211
|
+
entity.property({ type: "string", optional: true }),
|
|
212
|
+
__metadata("design:type", String)
|
|
213
|
+
], exports.DataSpaceConnectorEntry.prototype, "description", void 0);
|
|
214
|
+
__decorate([
|
|
215
|
+
entity.property({ type: "string" }),
|
|
216
|
+
__metadata("design:type", String)
|
|
217
|
+
], exports.DataSpaceConnectorEntry.prototype, "identity", void 0);
|
|
218
|
+
__decorate([
|
|
219
|
+
entity.property({ type: "string", isSecondary: true }),
|
|
220
|
+
__metadata("design:type", String)
|
|
221
|
+
], exports.DataSpaceConnectorEntry.prototype, "maintainer", void 0);
|
|
222
|
+
__decorate([
|
|
223
|
+
entity.property({ type: "object" }),
|
|
224
|
+
__metadata("design:type", Object)
|
|
225
|
+
], exports.DataSpaceConnectorEntry.prototype, "defaultEndpoint", void 0);
|
|
226
|
+
__decorate([
|
|
227
|
+
entity.property({ type: "object" }),
|
|
228
|
+
__metadata("design:type", Object)
|
|
229
|
+
], exports.DataSpaceConnectorEntry.prototype, "pushActivityEndpoint", void 0);
|
|
230
|
+
__decorate([
|
|
231
|
+
entity.property({ type: "object", optional: true }),
|
|
232
|
+
__metadata("design:type", Object)
|
|
233
|
+
], exports.DataSpaceConnectorEntry.prototype, "subscriptionActivityEndpoint", void 0);
|
|
234
|
+
__decorate([
|
|
235
|
+
entity.property({ type: "object" }),
|
|
236
|
+
__metadata("design:type", Object)
|
|
237
|
+
], exports.DataSpaceConnectorEntry.prototype, "pullDataEndpoint", void 0);
|
|
238
|
+
__decorate([
|
|
239
|
+
entity.property({ type: "array" }),
|
|
240
|
+
__metadata("design:type", Array)
|
|
241
|
+
], exports.DataSpaceConnectorEntry.prototype, "offeredResource", void 0);
|
|
242
|
+
__decorate([
|
|
243
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
244
|
+
__metadata("design:type", String)
|
|
245
|
+
], exports.DataSpaceConnectorEntry.prototype, "validFrom", void 0);
|
|
246
|
+
__decorate([
|
|
247
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
248
|
+
__metadata("design:type", String)
|
|
249
|
+
], exports.DataSpaceConnectorEntry.prototype, "validUntil", void 0);
|
|
250
|
+
__decorate([
|
|
251
|
+
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
252
|
+
__metadata("design:type", String)
|
|
253
|
+
], exports.DataSpaceConnectorEntry.prototype, "dateCreated", void 0);
|
|
254
|
+
__decorate([
|
|
255
|
+
entity.property({ type: "array" }),
|
|
256
|
+
__metadata("design:type", Array)
|
|
257
|
+
], exports.DataSpaceConnectorEntry.prototype, "evidence", void 0);
|
|
258
|
+
exports.DataSpaceConnectorEntry = __decorate([
|
|
259
|
+
entity.entity()
|
|
260
|
+
], exports.DataSpaceConnectorEntry);
|
|
261
|
+
|
|
262
|
+
// Copyright 2024 IOTA Stiftung.
|
|
263
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
24
264
|
/**
|
|
25
|
-
*
|
|
265
|
+
* Participant entry.
|
|
26
266
|
*/
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
|
|
267
|
+
exports.ParticipantEntry = class ParticipantEntry {
|
|
268
|
+
/**
|
|
269
|
+
* The participant Id.
|
|
270
|
+
*/
|
|
271
|
+
id;
|
|
272
|
+
/**
|
|
273
|
+
* The trusted issuer of the compliance credential
|
|
274
|
+
*/
|
|
275
|
+
issuer;
|
|
276
|
+
/**
|
|
277
|
+
* The legal registration number.
|
|
278
|
+
*/
|
|
279
|
+
registrationNumber;
|
|
280
|
+
/**
|
|
281
|
+
* The legal name.
|
|
282
|
+
*/
|
|
283
|
+
legalName;
|
|
284
|
+
/**
|
|
285
|
+
* Address
|
|
286
|
+
*/
|
|
287
|
+
legalAddress;
|
|
288
|
+
/**
|
|
289
|
+
* Valid from
|
|
290
|
+
*/
|
|
291
|
+
validFrom;
|
|
292
|
+
/**
|
|
293
|
+
* Valid to
|
|
294
|
+
*/
|
|
295
|
+
validUntil;
|
|
296
|
+
/**
|
|
297
|
+
* Date created
|
|
298
|
+
*/
|
|
299
|
+
dateCreated;
|
|
300
|
+
/**
|
|
301
|
+
* Evidences
|
|
302
|
+
*/
|
|
303
|
+
evidence;
|
|
304
|
+
};
|
|
305
|
+
__decorate([
|
|
306
|
+
entity.property({ type: "string", isPrimary: true }),
|
|
307
|
+
__metadata("design:type", String)
|
|
308
|
+
], exports.ParticipantEntry.prototype, "id", void 0);
|
|
309
|
+
__decorate([
|
|
310
|
+
entity.property({ type: "string" }),
|
|
311
|
+
__metadata("design:type", String)
|
|
312
|
+
], exports.ParticipantEntry.prototype, "issuer", void 0);
|
|
313
|
+
__decorate([
|
|
314
|
+
entity.property({ type: "object", isSecondary: true }),
|
|
315
|
+
__metadata("design:type", Object)
|
|
316
|
+
], exports.ParticipantEntry.prototype, "registrationNumber", void 0);
|
|
317
|
+
__decorate([
|
|
318
|
+
entity.property({ type: "string", isSecondary: true }),
|
|
319
|
+
__metadata("design:type", String)
|
|
320
|
+
], exports.ParticipantEntry.prototype, "legalName", void 0);
|
|
321
|
+
__decorate([
|
|
322
|
+
entity.property({ type: "object" }),
|
|
323
|
+
__metadata("design:type", Object)
|
|
324
|
+
], exports.ParticipantEntry.prototype, "legalAddress", void 0);
|
|
325
|
+
__decorate([
|
|
326
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
327
|
+
__metadata("design:type", String)
|
|
328
|
+
], exports.ParticipantEntry.prototype, "validFrom", void 0);
|
|
329
|
+
__decorate([
|
|
330
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
331
|
+
__metadata("design:type", String)
|
|
332
|
+
], exports.ParticipantEntry.prototype, "validUntil", void 0);
|
|
333
|
+
__decorate([
|
|
334
|
+
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
335
|
+
__metadata("design:type", String)
|
|
336
|
+
], exports.ParticipantEntry.prototype, "dateCreated", void 0);
|
|
337
|
+
__decorate([
|
|
338
|
+
entity.property({ type: "array" }),
|
|
339
|
+
__metadata("design:type", Array)
|
|
340
|
+
], exports.ParticipantEntry.prototype, "evidence", void 0);
|
|
341
|
+
exports.ParticipantEntry = __decorate([
|
|
342
|
+
entity.entity()
|
|
343
|
+
], exports.ParticipantEntry);
|
|
344
|
+
|
|
345
|
+
// Copyright 2024 IOTA Stiftung.
|
|
346
|
+
// SPDX-License-Identifier: Apache-2.0.
|
|
347
|
+
/**
|
|
348
|
+
* Service Offering Entry.
|
|
349
|
+
*/
|
|
350
|
+
exports.ServiceOfferingEntry = class ServiceOfferingEntry {
|
|
351
|
+
/**
|
|
352
|
+
* The service Id.
|
|
353
|
+
*/
|
|
354
|
+
id;
|
|
355
|
+
/**
|
|
356
|
+
* The trusted issuer of the compliance credential associated with
|
|
357
|
+
*/
|
|
358
|
+
issuer;
|
|
359
|
+
/**
|
|
360
|
+
* The service name.
|
|
361
|
+
*/
|
|
362
|
+
name;
|
|
363
|
+
/**
|
|
364
|
+
* The service description.
|
|
365
|
+
*/
|
|
366
|
+
description;
|
|
367
|
+
/**
|
|
368
|
+
* The provider Id
|
|
369
|
+
*/
|
|
370
|
+
providedBy;
|
|
371
|
+
/**
|
|
372
|
+
* The REST endpoint
|
|
373
|
+
*/
|
|
374
|
+
endpoint;
|
|
375
|
+
/**
|
|
376
|
+
* The policy
|
|
377
|
+
*/
|
|
378
|
+
servicePolicy;
|
|
379
|
+
/**
|
|
380
|
+
* Resources aggregated
|
|
381
|
+
*/
|
|
382
|
+
aggregationOfResources;
|
|
383
|
+
/**
|
|
384
|
+
* Valid from
|
|
385
|
+
*/
|
|
386
|
+
validFrom;
|
|
387
|
+
/**
|
|
388
|
+
* Valid to
|
|
389
|
+
*/
|
|
390
|
+
validUntil;
|
|
391
|
+
/**
|
|
392
|
+
* Date created
|
|
393
|
+
*/
|
|
394
|
+
dateCreated;
|
|
395
|
+
/**
|
|
396
|
+
* Evidences
|
|
397
|
+
*/
|
|
398
|
+
evidence;
|
|
399
|
+
};
|
|
400
|
+
__decorate([
|
|
401
|
+
entity.property({ type: "string", isPrimary: true }),
|
|
402
|
+
__metadata("design:type", String)
|
|
403
|
+
], exports.ServiceOfferingEntry.prototype, "id", void 0);
|
|
404
|
+
__decorate([
|
|
405
|
+
entity.property({ type: "string" }),
|
|
406
|
+
__metadata("design:type", String)
|
|
407
|
+
], exports.ServiceOfferingEntry.prototype, "issuer", void 0);
|
|
408
|
+
__decorate([
|
|
409
|
+
entity.property({ type: "string" }),
|
|
410
|
+
__metadata("design:type", String)
|
|
411
|
+
], exports.ServiceOfferingEntry.prototype, "name", void 0);
|
|
412
|
+
__decorate([
|
|
413
|
+
entity.property({ type: "string", optional: true }),
|
|
414
|
+
__metadata("design:type", String)
|
|
415
|
+
], exports.ServiceOfferingEntry.prototype, "description", void 0);
|
|
416
|
+
__decorate([
|
|
417
|
+
entity.property({ type: "string", isSecondary: true }),
|
|
418
|
+
__metadata("design:type", String)
|
|
419
|
+
], exports.ServiceOfferingEntry.prototype, "providedBy", void 0);
|
|
420
|
+
__decorate([
|
|
421
|
+
entity.property({ type: "object" }),
|
|
422
|
+
__metadata("design:type", Object)
|
|
423
|
+
], exports.ServiceOfferingEntry.prototype, "endpoint", void 0);
|
|
424
|
+
__decorate([
|
|
425
|
+
entity.property({ type: "array" }),
|
|
426
|
+
__metadata("design:type", Array)
|
|
427
|
+
], exports.ServiceOfferingEntry.prototype, "servicePolicy", void 0);
|
|
428
|
+
__decorate([
|
|
429
|
+
entity.property({ type: "array", optional: true }),
|
|
430
|
+
__metadata("design:type", Array)
|
|
431
|
+
], exports.ServiceOfferingEntry.prototype, "aggregationOfResources", void 0);
|
|
432
|
+
__decorate([
|
|
433
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
434
|
+
__metadata("design:type", String)
|
|
435
|
+
], exports.ServiceOfferingEntry.prototype, "validFrom", void 0);
|
|
436
|
+
__decorate([
|
|
437
|
+
entity.property({ type: "string", format: "date-time" }),
|
|
438
|
+
__metadata("design:type", String)
|
|
439
|
+
], exports.ServiceOfferingEntry.prototype, "validUntil", void 0);
|
|
440
|
+
__decorate([
|
|
441
|
+
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
442
|
+
__metadata("design:type", String)
|
|
443
|
+
], exports.ServiceOfferingEntry.prototype, "dateCreated", void 0);
|
|
444
|
+
__decorate([
|
|
445
|
+
entity.property({ type: "array" }),
|
|
446
|
+
__metadata("design:type", Array)
|
|
447
|
+
], exports.ServiceOfferingEntry.prototype, "evidence", void 0);
|
|
448
|
+
exports.ServiceOfferingEntry = __decorate([
|
|
449
|
+
entity.entity()
|
|
450
|
+
], exports.ServiceOfferingEntry);
|
|
451
|
+
|
|
452
|
+
/**
|
|
453
|
+
* The source used when communicating about these routes.
|
|
454
|
+
*/
|
|
455
|
+
const ROUTES_SOURCE = "federatedCatalogueRoutes";
|
|
456
|
+
/**
|
|
457
|
+
* Participants route.
|
|
458
|
+
*/
|
|
459
|
+
const PARTICIPANTS_ROUTE = "participants";
|
|
460
|
+
/**
|
|
461
|
+
* Service offering route.
|
|
462
|
+
*/
|
|
463
|
+
const SERVICE_OFFERING_ROUTE = "service-offerings";
|
|
464
|
+
/**
|
|
465
|
+
* Data Resource route.
|
|
30
466
|
*/
|
|
31
467
|
const DATA_RESOURCE_ROUTE = "data-resources";
|
|
32
468
|
/**
|
|
@@ -156,7 +592,7 @@ function generateRestRoutesFederatedCatalogue(baseRouteName, factoryServiceName)
|
|
|
156
592
|
const participantEntryExample = {
|
|
157
593
|
"@context": federatedCatalogueModels.FederatedCatalogueContextInstances.DEFAULT_LD_CONTEXT_ENTRY,
|
|
158
594
|
id: "did:iota:xxx",
|
|
159
|
-
type: standardsGaiaX.GaiaXTypes.
|
|
595
|
+
type: standardsGaiaX.GaiaXTypes.LegalPerson,
|
|
160
596
|
registrationNumber: {
|
|
161
597
|
type: standardsGaiaX.GaiaXTypes.LocalRegistrationNumber,
|
|
162
598
|
local: "P1234567"
|
|
@@ -248,7 +684,7 @@ function generateRestRoutesFederatedCatalogue(baseRouteName, factoryServiceName)
|
|
|
248
684
|
"@context": [
|
|
249
685
|
"https://www.w3.org/ns/odrl/2/",
|
|
250
686
|
{
|
|
251
|
-
twin: "https://schema.twindev.org/odrl/",
|
|
687
|
+
twin: "https://schema.twindev.org/w3c-odrl/",
|
|
252
688
|
jsonPathSelector: "twin:jsonPathSelector"
|
|
253
689
|
}
|
|
254
690
|
],
|
|
@@ -628,7 +1064,7 @@ async function participantGet(httpRequestContext, factoryServiceName, request) {
|
|
|
628
1064
|
const id = request?.pathParams.id;
|
|
629
1065
|
core.Guards.stringValue(ROUTES_SOURCE, "id", id);
|
|
630
1066
|
return {
|
|
631
|
-
body: (await service.getEntry(standardsGaiaX.GaiaXTypes.
|
|
1067
|
+
body: (await service.getEntry(standardsGaiaX.GaiaXTypes.LegalPerson, id))
|
|
632
1068
|
};
|
|
633
1069
|
}
|
|
634
1070
|
/**
|
|
@@ -1031,10 +1467,6 @@ class ComplianceCredentialVerificationService {
|
|
|
1031
1467
|
* Service for performing logging operations to a connector.
|
|
1032
1468
|
*/
|
|
1033
1469
|
class FederatedCatalogueService {
|
|
1034
|
-
/**
|
|
1035
|
-
* The namespace for the service.
|
|
1036
|
-
*/
|
|
1037
|
-
static NAMESPACE = "fedcat";
|
|
1038
1470
|
/**
|
|
1039
1471
|
* Fields to skip when persisting entries to the Catalogue
|
|
1040
1472
|
* @internal
|
|
@@ -1053,7 +1485,7 @@ class FederatedCatalogueService {
|
|
|
1053
1485
|
* Logging service.
|
|
1054
1486
|
* @internal
|
|
1055
1487
|
*/
|
|
1056
|
-
|
|
1488
|
+
_logging;
|
|
1057
1489
|
/**
|
|
1058
1490
|
* Storage service for participants.
|
|
1059
1491
|
* @internal
|
|
@@ -1084,7 +1516,7 @@ class FederatedCatalogueService {
|
|
|
1084
1516
|
* @param options The options for the connector.
|
|
1085
1517
|
*/
|
|
1086
1518
|
constructor(options) {
|
|
1087
|
-
this.
|
|
1519
|
+
this._logging = core.ComponentFactory.getIfExists(options?.loggingComponentType ?? "logging");
|
|
1088
1520
|
this._entityStorageParticipants = entityStorageModels.EntityStorageConnectorFactory.get(options.participantEntityStorageType ?? core.StringHelper.kebabCase("ParticipantEntry"));
|
|
1089
1521
|
this._entityStorageServiceOfferings = entityStorageModels.EntityStorageConnectorFactory.get(options.serviceOfferingEntityStorageType ??
|
|
1090
1522
|
core.StringHelper.kebabCase("ServiceOfferingEntry"));
|
|
@@ -1092,7 +1524,7 @@ class FederatedCatalogueService {
|
|
|
1092
1524
|
this._entityStorageDataSpaceConnectors = entityStorageModels.EntityStorageConnectorFactory.get(options.dataSpaceConnectorStorageType ??
|
|
1093
1525
|
core.StringHelper.kebabCase("DataSpaceConnectorEntry"));
|
|
1094
1526
|
this._resolver = core.ComponentFactory.get(options.identityResolverComponentType ?? "identity-resolver");
|
|
1095
|
-
this._complianceCredentialVerifier = new ComplianceCredentialVerificationService(options.config.clearingHouseApproverList, this._resolver, options.config.subResourceCacheTtlMs, this.
|
|
1527
|
+
this._complianceCredentialVerifier = new ComplianceCredentialVerificationService(options.config.clearingHouseApproverList, this._resolver, options.config.subResourceCacheTtlMs, this._logging);
|
|
1096
1528
|
standardsSchemaOrg.SchemaOrgDataTypes.registerRedirects();
|
|
1097
1529
|
}
|
|
1098
1530
|
/**
|
|
@@ -1106,7 +1538,7 @@ class FederatedCatalogueService {
|
|
|
1106
1538
|
const complianceCredential = await this.decodeJwt(credentialJwt);
|
|
1107
1539
|
const result = await this._complianceCredentialVerifier.verify(complianceCredential);
|
|
1108
1540
|
if (!result.verified) {
|
|
1109
|
-
this.
|
|
1541
|
+
this._logging?.log({
|
|
1110
1542
|
level: "error",
|
|
1111
1543
|
source: this.CLASS_NAME,
|
|
1112
1544
|
ts: Date.now(),
|
|
@@ -1117,14 +1549,14 @@ class FederatedCatalogueService {
|
|
|
1117
1549
|
reason: result.verificationFailureReason
|
|
1118
1550
|
});
|
|
1119
1551
|
}
|
|
1120
|
-
const targetCredential = result.credentials.find(credential => credential.credentialSubject.type === standardsGaiaX.GaiaXTypes.
|
|
1552
|
+
const targetCredential = result.credentials.find(credential => credential.credentialSubject.type === standardsGaiaX.GaiaXTypes.LegalPerson);
|
|
1121
1553
|
if (core.Is.undefined(targetCredential)) {
|
|
1122
1554
|
throw new core.UnprocessableError(this.CLASS_NAME, "noEvidence");
|
|
1123
1555
|
}
|
|
1124
1556
|
const participantEntry = this.extractParticipantEntry(complianceCredential, targetCredential);
|
|
1125
1557
|
const theEntry = core.ObjectHelper.omit(participantEntry, FederatedCatalogueService._FIELDS_TO_SKIP);
|
|
1126
1558
|
await this._entityStorageParticipants.set(theEntry);
|
|
1127
|
-
await this.
|
|
1559
|
+
await this._logging?.log({
|
|
1128
1560
|
level: "info",
|
|
1129
1561
|
source: this.CLASS_NAME,
|
|
1130
1562
|
ts: Date.now(),
|
|
@@ -1175,7 +1607,7 @@ class FederatedCatalogueService {
|
|
|
1175
1607
|
}
|
|
1176
1608
|
const entries = await this._entityStorageParticipants.query({ conditions }, undefined, undefined, cursor, pageSize);
|
|
1177
1609
|
const itemList = entries.entities.map(entry => {
|
|
1178
|
-
entry.type = standardsGaiaX.GaiaXTypes.
|
|
1610
|
+
entry.type = standardsGaiaX.GaiaXTypes.LegalPerson;
|
|
1179
1611
|
return entry;
|
|
1180
1612
|
});
|
|
1181
1613
|
const result = {
|
|
@@ -1197,7 +1629,7 @@ class FederatedCatalogueService {
|
|
|
1197
1629
|
core.Guards.stringValue(this.CLASS_NAME, "entryId", entryId);
|
|
1198
1630
|
let itemsAndCursor;
|
|
1199
1631
|
switch (entryType) {
|
|
1200
|
-
case standardsGaiaX.GaiaXTypes.
|
|
1632
|
+
case standardsGaiaX.GaiaXTypes.LegalPerson:
|
|
1201
1633
|
itemsAndCursor = await this.queryParticipants(entryId);
|
|
1202
1634
|
break;
|
|
1203
1635
|
case standardsGaiaX.GaiaXTypes.DataExchangeComponent:
|
|
@@ -1234,7 +1666,7 @@ class FederatedCatalogueService {
|
|
|
1234
1666
|
const complianceCredential = await this.decodeJwt(credentialJwt);
|
|
1235
1667
|
const result = await this._complianceCredentialVerifier.verify(complianceCredential);
|
|
1236
1668
|
if (!result.verified) {
|
|
1237
|
-
this.
|
|
1669
|
+
this._logging?.log({
|
|
1238
1670
|
level: "error",
|
|
1239
1671
|
source: this.CLASS_NAME,
|
|
1240
1672
|
ts: Date.now(),
|
|
@@ -1265,7 +1697,7 @@ class FederatedCatalogueService {
|
|
|
1265
1697
|
const drEntry = core.ObjectHelper.omit(dataResourceEntry, FederatedCatalogueService._FIELDS_TO_SKIP);
|
|
1266
1698
|
await this._entityStorageDataResources.set(drEntry);
|
|
1267
1699
|
}
|
|
1268
|
-
await this.
|
|
1700
|
+
await this._logging?.log({
|
|
1269
1701
|
level: "info",
|
|
1270
1702
|
source: this.CLASS_NAME,
|
|
1271
1703
|
ts: Date.now(),
|
|
@@ -1287,7 +1719,7 @@ class FederatedCatalogueService {
|
|
|
1287
1719
|
const complianceCredential = await this.decodeJwt(credentialJwt);
|
|
1288
1720
|
const result = await this._complianceCredentialVerifier.verify(complianceCredential);
|
|
1289
1721
|
if (!result.verified) {
|
|
1290
|
-
this.
|
|
1722
|
+
this._logging?.log({
|
|
1291
1723
|
level: "error",
|
|
1292
1724
|
source: this.CLASS_NAME,
|
|
1293
1725
|
ts: Date.now(),
|
|
@@ -1310,7 +1742,7 @@ class FederatedCatalogueService {
|
|
|
1310
1742
|
await this._entityStorageDataResources.set(theEntry);
|
|
1311
1743
|
dataResourceIds.push(dataResourceEntry.id);
|
|
1312
1744
|
}
|
|
1313
|
-
await this.
|
|
1745
|
+
await this._logging?.log({
|
|
1314
1746
|
level: "info",
|
|
1315
1747
|
source: this.CLASS_NAME,
|
|
1316
1748
|
ts: Date.now(),
|
|
@@ -1377,7 +1809,7 @@ class FederatedCatalogueService {
|
|
|
1377
1809
|
const sdComplianceCredential = await this.decodeJwt(credentialJwt);
|
|
1378
1810
|
const result = await this._complianceCredentialVerifier.verify(sdComplianceCredential);
|
|
1379
1811
|
if (!result.verified) {
|
|
1380
|
-
this.
|
|
1812
|
+
this._logging?.log({
|
|
1381
1813
|
level: "error",
|
|
1382
1814
|
source: this.CLASS_NAME,
|
|
1383
1815
|
ts: Date.now(),
|
|
@@ -1407,7 +1839,7 @@ class FederatedCatalogueService {
|
|
|
1407
1839
|
const dataResourceEntry = this.extractDataResourceEntry(sdComplianceCredential, dataResourceCredential);
|
|
1408
1840
|
await this._entityStorageDataResources.set(dataResourceEntry);
|
|
1409
1841
|
}
|
|
1410
|
-
await this.
|
|
1842
|
+
await this._logging?.log({
|
|
1411
1843
|
level: "info",
|
|
1412
1844
|
source: this.CLASS_NAME,
|
|
1413
1845
|
ts: Date.now(),
|
|
@@ -1631,7 +2063,7 @@ class FederatedCatalogueService {
|
|
|
1631
2063
|
async checkParticipantExists(participantId) {
|
|
1632
2064
|
const participantData = await this._entityStorageParticipants.get(participantId);
|
|
1633
2065
|
if (!participantData) {
|
|
1634
|
-
this.
|
|
2066
|
+
this._logging?.log({
|
|
1635
2067
|
level: "error",
|
|
1636
2068
|
source: this.CLASS_NAME,
|
|
1637
2069
|
ts: Date.now(),
|
|
@@ -1654,443 +2086,6 @@ const restEntryPoints = [
|
|
|
1654
2086
|
}
|
|
1655
2087
|
];
|
|
1656
2088
|
|
|
1657
|
-
// Copyright 2024 IOTA Stiftung.
|
|
1658
|
-
// SPDX-License-Identifier: Apache-2.0.
|
|
1659
|
-
/**
|
|
1660
|
-
* Data Resource Entry.
|
|
1661
|
-
*/
|
|
1662
|
-
exports.DataResourceEntry = class DataResourceEntry {
|
|
1663
|
-
/**
|
|
1664
|
-
* The Id.
|
|
1665
|
-
*/
|
|
1666
|
-
id;
|
|
1667
|
-
/**
|
|
1668
|
-
* The trusted issuer of the compliance credential
|
|
1669
|
-
*/
|
|
1670
|
-
issuer;
|
|
1671
|
-
/**
|
|
1672
|
-
* The name.
|
|
1673
|
-
*/
|
|
1674
|
-
name;
|
|
1675
|
-
/**
|
|
1676
|
-
* The description.
|
|
1677
|
-
*/
|
|
1678
|
-
description;
|
|
1679
|
-
/**
|
|
1680
|
-
* The Id of the producer of the data described by this Data Resource.
|
|
1681
|
-
*/
|
|
1682
|
-
producedBy;
|
|
1683
|
-
/**
|
|
1684
|
-
* The copyright owner
|
|
1685
|
-
*/
|
|
1686
|
-
copyrightOwnedBy;
|
|
1687
|
-
/**
|
|
1688
|
-
* The license
|
|
1689
|
-
*/
|
|
1690
|
-
license;
|
|
1691
|
-
/**
|
|
1692
|
-
* The data exchange component used to expose the Data Resource.
|
|
1693
|
-
* Only a URL pointing to the resource is stored
|
|
1694
|
-
*/
|
|
1695
|
-
exposedThrough;
|
|
1696
|
-
/**
|
|
1697
|
-
* The Data Resource policy
|
|
1698
|
-
*/
|
|
1699
|
-
resourcePolicy;
|
|
1700
|
-
/**
|
|
1701
|
-
* Valid from
|
|
1702
|
-
*/
|
|
1703
|
-
validFrom;
|
|
1704
|
-
/**
|
|
1705
|
-
* Valid to
|
|
1706
|
-
*/
|
|
1707
|
-
validUntil;
|
|
1708
|
-
/**
|
|
1709
|
-
* Date created
|
|
1710
|
-
*/
|
|
1711
|
-
dateCreated;
|
|
1712
|
-
/**
|
|
1713
|
-
* Evidences
|
|
1714
|
-
*/
|
|
1715
|
-
evidence;
|
|
1716
|
-
};
|
|
1717
|
-
__decorate([
|
|
1718
|
-
entity.property({ type: "string", isPrimary: true }),
|
|
1719
|
-
__metadata("design:type", String)
|
|
1720
|
-
], exports.DataResourceEntry.prototype, "id", void 0);
|
|
1721
|
-
__decorate([
|
|
1722
|
-
entity.property({ type: "string" }),
|
|
1723
|
-
__metadata("design:type", String)
|
|
1724
|
-
], exports.DataResourceEntry.prototype, "issuer", void 0);
|
|
1725
|
-
__decorate([
|
|
1726
|
-
entity.property({ type: "string" }),
|
|
1727
|
-
__metadata("design:type", String)
|
|
1728
|
-
], exports.DataResourceEntry.prototype, "name", void 0);
|
|
1729
|
-
__decorate([
|
|
1730
|
-
entity.property({ type: "string", optional: true }),
|
|
1731
|
-
__metadata("design:type", String)
|
|
1732
|
-
], exports.DataResourceEntry.prototype, "description", void 0);
|
|
1733
|
-
__decorate([
|
|
1734
|
-
entity.property({ type: "string", isSecondary: true }),
|
|
1735
|
-
__metadata("design:type", String)
|
|
1736
|
-
], exports.DataResourceEntry.prototype, "producedBy", void 0);
|
|
1737
|
-
__decorate([
|
|
1738
|
-
entity.property({ type: "string" }),
|
|
1739
|
-
__metadata("design:type", String)
|
|
1740
|
-
], exports.DataResourceEntry.prototype, "copyrightOwnedBy", void 0);
|
|
1741
|
-
__decorate([
|
|
1742
|
-
entity.property({ type: "string" }),
|
|
1743
|
-
__metadata("design:type", String)
|
|
1744
|
-
], exports.DataResourceEntry.prototype, "license", void 0);
|
|
1745
|
-
__decorate([
|
|
1746
|
-
entity.property({ type: "string" }),
|
|
1747
|
-
__metadata("design:type", String)
|
|
1748
|
-
], exports.DataResourceEntry.prototype, "exposedThrough", void 0);
|
|
1749
|
-
__decorate([
|
|
1750
|
-
entity.property({ type: "array" }),
|
|
1751
|
-
__metadata("design:type", Array)
|
|
1752
|
-
], exports.DataResourceEntry.prototype, "resourcePolicy", void 0);
|
|
1753
|
-
__decorate([
|
|
1754
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1755
|
-
__metadata("design:type", String)
|
|
1756
|
-
], exports.DataResourceEntry.prototype, "validFrom", void 0);
|
|
1757
|
-
__decorate([
|
|
1758
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1759
|
-
__metadata("design:type", String)
|
|
1760
|
-
], exports.DataResourceEntry.prototype, "validUntil", void 0);
|
|
1761
|
-
__decorate([
|
|
1762
|
-
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
1763
|
-
__metadata("design:type", String)
|
|
1764
|
-
], exports.DataResourceEntry.prototype, "dateCreated", void 0);
|
|
1765
|
-
__decorate([
|
|
1766
|
-
entity.property({ type: "array" }),
|
|
1767
|
-
__metadata("design:type", Array)
|
|
1768
|
-
], exports.DataResourceEntry.prototype, "evidence", void 0);
|
|
1769
|
-
exports.DataResourceEntry = __decorate([
|
|
1770
|
-
entity.entity()
|
|
1771
|
-
], exports.DataResourceEntry);
|
|
1772
|
-
|
|
1773
|
-
// Copyright 2024 IOTA Stiftung.
|
|
1774
|
-
// SPDX-License-Identifier: Apache-2.0.
|
|
1775
|
-
/**
|
|
1776
|
-
* Data Space Connector Entry.
|
|
1777
|
-
*/
|
|
1778
|
-
exports.DataSpaceConnectorEntry = class DataSpaceConnectorEntry {
|
|
1779
|
-
/**
|
|
1780
|
-
* The Id.
|
|
1781
|
-
*/
|
|
1782
|
-
id;
|
|
1783
|
-
/**
|
|
1784
|
-
* The trusted issuer of the compliance credential.
|
|
1785
|
-
*/
|
|
1786
|
-
issuer;
|
|
1787
|
-
/**
|
|
1788
|
-
* The name.
|
|
1789
|
-
*/
|
|
1790
|
-
name;
|
|
1791
|
-
/**
|
|
1792
|
-
* The description.
|
|
1793
|
-
*/
|
|
1794
|
-
description;
|
|
1795
|
-
/**
|
|
1796
|
-
* The identity of the Data Space Connector
|
|
1797
|
-
*/
|
|
1798
|
-
identity;
|
|
1799
|
-
/**
|
|
1800
|
-
* Who maintains the Data Space Connector
|
|
1801
|
-
*/
|
|
1802
|
-
maintainer;
|
|
1803
|
-
/**
|
|
1804
|
-
* The default endpoint
|
|
1805
|
-
*/
|
|
1806
|
-
defaultEndpoint;
|
|
1807
|
-
/**
|
|
1808
|
-
* The activity push endpoint
|
|
1809
|
-
*/
|
|
1810
|
-
pushActivityEndpoint;
|
|
1811
|
-
/**
|
|
1812
|
-
* The activity subscribe endpoint
|
|
1813
|
-
*/
|
|
1814
|
-
subscriptionActivityEndpoint;
|
|
1815
|
-
/**
|
|
1816
|
-
* The pull data endpoint
|
|
1817
|
-
*/
|
|
1818
|
-
pullDataEndpoint;
|
|
1819
|
-
/**
|
|
1820
|
-
* The pull data endpoint
|
|
1821
|
-
*/
|
|
1822
|
-
offeredResource;
|
|
1823
|
-
/**
|
|
1824
|
-
* Valid from
|
|
1825
|
-
*/
|
|
1826
|
-
validFrom;
|
|
1827
|
-
/**
|
|
1828
|
-
* Valid to
|
|
1829
|
-
*/
|
|
1830
|
-
validUntil;
|
|
1831
|
-
/**
|
|
1832
|
-
* Date created
|
|
1833
|
-
*/
|
|
1834
|
-
dateCreated;
|
|
1835
|
-
/**
|
|
1836
|
-
* Evidences
|
|
1837
|
-
*/
|
|
1838
|
-
evidence;
|
|
1839
|
-
};
|
|
1840
|
-
__decorate([
|
|
1841
|
-
entity.property({ type: "string", isPrimary: true }),
|
|
1842
|
-
__metadata("design:type", String)
|
|
1843
|
-
], exports.DataSpaceConnectorEntry.prototype, "id", void 0);
|
|
1844
|
-
__decorate([
|
|
1845
|
-
entity.property({ type: "string" }),
|
|
1846
|
-
__metadata("design:type", String)
|
|
1847
|
-
], exports.DataSpaceConnectorEntry.prototype, "issuer", void 0);
|
|
1848
|
-
__decorate([
|
|
1849
|
-
entity.property({ type: "string", optional: true }),
|
|
1850
|
-
__metadata("design:type", String)
|
|
1851
|
-
], exports.DataSpaceConnectorEntry.prototype, "name", void 0);
|
|
1852
|
-
__decorate([
|
|
1853
|
-
entity.property({ type: "string", optional: true }),
|
|
1854
|
-
__metadata("design:type", String)
|
|
1855
|
-
], exports.DataSpaceConnectorEntry.prototype, "description", void 0);
|
|
1856
|
-
__decorate([
|
|
1857
|
-
entity.property({ type: "string" }),
|
|
1858
|
-
__metadata("design:type", String)
|
|
1859
|
-
], exports.DataSpaceConnectorEntry.prototype, "identity", void 0);
|
|
1860
|
-
__decorate([
|
|
1861
|
-
entity.property({ type: "string", isSecondary: true }),
|
|
1862
|
-
__metadata("design:type", String)
|
|
1863
|
-
], exports.DataSpaceConnectorEntry.prototype, "maintainer", void 0);
|
|
1864
|
-
__decorate([
|
|
1865
|
-
entity.property({ type: "object" }),
|
|
1866
|
-
__metadata("design:type", Object)
|
|
1867
|
-
], exports.DataSpaceConnectorEntry.prototype, "defaultEndpoint", void 0);
|
|
1868
|
-
__decorate([
|
|
1869
|
-
entity.property({ type: "object" }),
|
|
1870
|
-
__metadata("design:type", Object)
|
|
1871
|
-
], exports.DataSpaceConnectorEntry.prototype, "pushActivityEndpoint", void 0);
|
|
1872
|
-
__decorate([
|
|
1873
|
-
entity.property({ type: "object", optional: true }),
|
|
1874
|
-
__metadata("design:type", Object)
|
|
1875
|
-
], exports.DataSpaceConnectorEntry.prototype, "subscriptionActivityEndpoint", void 0);
|
|
1876
|
-
__decorate([
|
|
1877
|
-
entity.property({ type: "object" }),
|
|
1878
|
-
__metadata("design:type", Object)
|
|
1879
|
-
], exports.DataSpaceConnectorEntry.prototype, "pullDataEndpoint", void 0);
|
|
1880
|
-
__decorate([
|
|
1881
|
-
entity.property({ type: "array" }),
|
|
1882
|
-
__metadata("design:type", Array)
|
|
1883
|
-
], exports.DataSpaceConnectorEntry.prototype, "offeredResource", void 0);
|
|
1884
|
-
__decorate([
|
|
1885
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1886
|
-
__metadata("design:type", String)
|
|
1887
|
-
], exports.DataSpaceConnectorEntry.prototype, "validFrom", void 0);
|
|
1888
|
-
__decorate([
|
|
1889
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1890
|
-
__metadata("design:type", String)
|
|
1891
|
-
], exports.DataSpaceConnectorEntry.prototype, "validUntil", void 0);
|
|
1892
|
-
__decorate([
|
|
1893
|
-
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
1894
|
-
__metadata("design:type", String)
|
|
1895
|
-
], exports.DataSpaceConnectorEntry.prototype, "dateCreated", void 0);
|
|
1896
|
-
__decorate([
|
|
1897
|
-
entity.property({ type: "array" }),
|
|
1898
|
-
__metadata("design:type", Array)
|
|
1899
|
-
], exports.DataSpaceConnectorEntry.prototype, "evidence", void 0);
|
|
1900
|
-
exports.DataSpaceConnectorEntry = __decorate([
|
|
1901
|
-
entity.entity()
|
|
1902
|
-
], exports.DataSpaceConnectorEntry);
|
|
1903
|
-
|
|
1904
|
-
// Copyright 2024 IOTA Stiftung.
|
|
1905
|
-
// SPDX-License-Identifier: Apache-2.0.
|
|
1906
|
-
/**
|
|
1907
|
-
* Participant entry.
|
|
1908
|
-
*/
|
|
1909
|
-
exports.ParticipantEntry = class ParticipantEntry {
|
|
1910
|
-
/**
|
|
1911
|
-
* The participant Id.
|
|
1912
|
-
*/
|
|
1913
|
-
id;
|
|
1914
|
-
/**
|
|
1915
|
-
* The trusted issuer of the compliance credential
|
|
1916
|
-
*/
|
|
1917
|
-
issuer;
|
|
1918
|
-
/**
|
|
1919
|
-
* The legal registration number.
|
|
1920
|
-
*/
|
|
1921
|
-
registrationNumber;
|
|
1922
|
-
/**
|
|
1923
|
-
* The legal name.
|
|
1924
|
-
*/
|
|
1925
|
-
legalName;
|
|
1926
|
-
/**
|
|
1927
|
-
* Address
|
|
1928
|
-
*/
|
|
1929
|
-
legalAddress;
|
|
1930
|
-
/**
|
|
1931
|
-
* Valid from
|
|
1932
|
-
*/
|
|
1933
|
-
validFrom;
|
|
1934
|
-
/**
|
|
1935
|
-
* Valid to
|
|
1936
|
-
*/
|
|
1937
|
-
validUntil;
|
|
1938
|
-
/**
|
|
1939
|
-
* Date created
|
|
1940
|
-
*/
|
|
1941
|
-
dateCreated;
|
|
1942
|
-
/**
|
|
1943
|
-
* Evidences
|
|
1944
|
-
*/
|
|
1945
|
-
evidence;
|
|
1946
|
-
};
|
|
1947
|
-
__decorate([
|
|
1948
|
-
entity.property({ type: "string", isPrimary: true }),
|
|
1949
|
-
__metadata("design:type", String)
|
|
1950
|
-
], exports.ParticipantEntry.prototype, "id", void 0);
|
|
1951
|
-
__decorate([
|
|
1952
|
-
entity.property({ type: "string" }),
|
|
1953
|
-
__metadata("design:type", String)
|
|
1954
|
-
], exports.ParticipantEntry.prototype, "issuer", void 0);
|
|
1955
|
-
__decorate([
|
|
1956
|
-
entity.property({ type: "object", isSecondary: true }),
|
|
1957
|
-
__metadata("design:type", Object)
|
|
1958
|
-
], exports.ParticipantEntry.prototype, "registrationNumber", void 0);
|
|
1959
|
-
__decorate([
|
|
1960
|
-
entity.property({ type: "string", isSecondary: true }),
|
|
1961
|
-
__metadata("design:type", String)
|
|
1962
|
-
], exports.ParticipantEntry.prototype, "legalName", void 0);
|
|
1963
|
-
__decorate([
|
|
1964
|
-
entity.property({ type: "object" }),
|
|
1965
|
-
__metadata("design:type", Object)
|
|
1966
|
-
], exports.ParticipantEntry.prototype, "legalAddress", void 0);
|
|
1967
|
-
__decorate([
|
|
1968
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1969
|
-
__metadata("design:type", String)
|
|
1970
|
-
], exports.ParticipantEntry.prototype, "validFrom", void 0);
|
|
1971
|
-
__decorate([
|
|
1972
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
1973
|
-
__metadata("design:type", String)
|
|
1974
|
-
], exports.ParticipantEntry.prototype, "validUntil", void 0);
|
|
1975
|
-
__decorate([
|
|
1976
|
-
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
1977
|
-
__metadata("design:type", String)
|
|
1978
|
-
], exports.ParticipantEntry.prototype, "dateCreated", void 0);
|
|
1979
|
-
__decorate([
|
|
1980
|
-
entity.property({ type: "array" }),
|
|
1981
|
-
__metadata("design:type", Array)
|
|
1982
|
-
], exports.ParticipantEntry.prototype, "evidence", void 0);
|
|
1983
|
-
exports.ParticipantEntry = __decorate([
|
|
1984
|
-
entity.entity()
|
|
1985
|
-
], exports.ParticipantEntry);
|
|
1986
|
-
|
|
1987
|
-
// Copyright 2024 IOTA Stiftung.
|
|
1988
|
-
// SPDX-License-Identifier: Apache-2.0.
|
|
1989
|
-
/**
|
|
1990
|
-
* Service Offering Entry.
|
|
1991
|
-
*/
|
|
1992
|
-
exports.ServiceOfferingEntry = class ServiceOfferingEntry {
|
|
1993
|
-
/**
|
|
1994
|
-
* The service Id.
|
|
1995
|
-
*/
|
|
1996
|
-
id;
|
|
1997
|
-
/**
|
|
1998
|
-
* The trusted issuer of the compliance credential associated with
|
|
1999
|
-
*/
|
|
2000
|
-
issuer;
|
|
2001
|
-
/**
|
|
2002
|
-
* The service name.
|
|
2003
|
-
*/
|
|
2004
|
-
name;
|
|
2005
|
-
/**
|
|
2006
|
-
* The service description.
|
|
2007
|
-
*/
|
|
2008
|
-
description;
|
|
2009
|
-
/**
|
|
2010
|
-
* The provider Id
|
|
2011
|
-
*/
|
|
2012
|
-
providedBy;
|
|
2013
|
-
/**
|
|
2014
|
-
* The REST endpoint
|
|
2015
|
-
*/
|
|
2016
|
-
endpoint;
|
|
2017
|
-
/**
|
|
2018
|
-
* The policy
|
|
2019
|
-
*/
|
|
2020
|
-
servicePolicy;
|
|
2021
|
-
/**
|
|
2022
|
-
* Resources aggregated
|
|
2023
|
-
*/
|
|
2024
|
-
aggregationOfResources;
|
|
2025
|
-
/**
|
|
2026
|
-
* Valid from
|
|
2027
|
-
*/
|
|
2028
|
-
validFrom;
|
|
2029
|
-
/**
|
|
2030
|
-
* Valid to
|
|
2031
|
-
*/
|
|
2032
|
-
validUntil;
|
|
2033
|
-
/**
|
|
2034
|
-
* Date created
|
|
2035
|
-
*/
|
|
2036
|
-
dateCreated;
|
|
2037
|
-
/**
|
|
2038
|
-
* Evidences
|
|
2039
|
-
*/
|
|
2040
|
-
evidence;
|
|
2041
|
-
};
|
|
2042
|
-
__decorate([
|
|
2043
|
-
entity.property({ type: "string", isPrimary: true }),
|
|
2044
|
-
__metadata("design:type", String)
|
|
2045
|
-
], exports.ServiceOfferingEntry.prototype, "id", void 0);
|
|
2046
|
-
__decorate([
|
|
2047
|
-
entity.property({ type: "string" }),
|
|
2048
|
-
__metadata("design:type", String)
|
|
2049
|
-
], exports.ServiceOfferingEntry.prototype, "issuer", void 0);
|
|
2050
|
-
__decorate([
|
|
2051
|
-
entity.property({ type: "string" }),
|
|
2052
|
-
__metadata("design:type", String)
|
|
2053
|
-
], exports.ServiceOfferingEntry.prototype, "name", void 0);
|
|
2054
|
-
__decorate([
|
|
2055
|
-
entity.property({ type: "string", optional: true }),
|
|
2056
|
-
__metadata("design:type", String)
|
|
2057
|
-
], exports.ServiceOfferingEntry.prototype, "description", void 0);
|
|
2058
|
-
__decorate([
|
|
2059
|
-
entity.property({ type: "string", isSecondary: true }),
|
|
2060
|
-
__metadata("design:type", String)
|
|
2061
|
-
], exports.ServiceOfferingEntry.prototype, "providedBy", void 0);
|
|
2062
|
-
__decorate([
|
|
2063
|
-
entity.property({ type: "object" }),
|
|
2064
|
-
__metadata("design:type", Object)
|
|
2065
|
-
], exports.ServiceOfferingEntry.prototype, "endpoint", void 0);
|
|
2066
|
-
__decorate([
|
|
2067
|
-
entity.property({ type: "array" }),
|
|
2068
|
-
__metadata("design:type", Array)
|
|
2069
|
-
], exports.ServiceOfferingEntry.prototype, "servicePolicy", void 0);
|
|
2070
|
-
__decorate([
|
|
2071
|
-
entity.property({ type: "array", optional: true }),
|
|
2072
|
-
__metadata("design:type", Array)
|
|
2073
|
-
], exports.ServiceOfferingEntry.prototype, "aggregationOfResources", void 0);
|
|
2074
|
-
__decorate([
|
|
2075
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
2076
|
-
__metadata("design:type", String)
|
|
2077
|
-
], exports.ServiceOfferingEntry.prototype, "validFrom", void 0);
|
|
2078
|
-
__decorate([
|
|
2079
|
-
entity.property({ type: "string", format: "date-time" }),
|
|
2080
|
-
__metadata("design:type", String)
|
|
2081
|
-
], exports.ServiceOfferingEntry.prototype, "validUntil", void 0);
|
|
2082
|
-
__decorate([
|
|
2083
|
-
entity.property({ type: "string", format: "date-time", sortDirection: entity.SortDirection.Descending }),
|
|
2084
|
-
__metadata("design:type", String)
|
|
2085
|
-
], exports.ServiceOfferingEntry.prototype, "dateCreated", void 0);
|
|
2086
|
-
__decorate([
|
|
2087
|
-
entity.property({ type: "array" }),
|
|
2088
|
-
__metadata("design:type", Array)
|
|
2089
|
-
], exports.ServiceOfferingEntry.prototype, "evidence", void 0);
|
|
2090
|
-
exports.ServiceOfferingEntry = __decorate([
|
|
2091
|
-
entity.entity()
|
|
2092
|
-
], exports.ServiceOfferingEntry);
|
|
2093
|
-
|
|
2094
2089
|
// Copyright 2024 IOTA Stiftung.
|
|
2095
2090
|
// SPDX-License-Identifier: Apache-2.0.
|
|
2096
2091
|
/**
|