@tsg-dsp/tsg-sdk 0.0.0-stage → 0.20.1
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/LICENSE +201 -0
- package/README.md +273 -2
- package/dist/.generated/control-plane.d.ts +7882 -0
- package/dist/.generated/sso-bridge.d.ts +3062 -0
- package/dist/.generated/wallet.d.ts +6350 -0
- package/dist/auth/auth.provider.d.ts +45 -0
- package/dist/auth/auth.provider.d.ts.map +1 -0
- package/dist/auth/auth.provider.js +158 -0
- package/dist/auth/auth.provider.js.map +1 -0
- package/dist/auth/auth.types.d.ts +27 -0
- package/dist/auth/auth.types.d.ts.map +1 -0
- package/dist/auth/auth.types.js +2 -0
- package/dist/auth/auth.types.js.map +1 -0
- package/dist/auth/index.d.ts +3 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +3 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/browser.d.ts +1243 -0
- package/dist/browser.d.ts.map +1 -0
- package/dist/browser.js +215 -0
- package/dist/browser.js.map +1 -0
- package/dist/catalog/catalog.sdk.d.ts +149 -0
- package/dist/catalog/catalog.sdk.d.ts.map +1 -0
- package/dist/catalog/catalog.sdk.js +155 -0
- package/dist/catalog/catalog.sdk.js.map +1 -0
- package/dist/catalog/index.d.ts +2 -0
- package/dist/catalog/index.d.ts.map +1 -0
- package/dist/catalog/index.js +2 -0
- package/dist/catalog/index.js.map +1 -0
- package/dist/client.d.ts +43 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +107 -0
- package/dist/client.js.map +1 -0
- package/dist/config/index.d.ts +2 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +2 -0
- package/dist/config/index.js.map +1 -0
- package/dist/config/sdk.config.d.ts +81 -0
- package/dist/config/sdk.config.d.ts.map +1 -0
- package/dist/config/sdk.config.js +2 -0
- package/dist/config/sdk.config.js.map +1 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +24 -0
- package/dist/index.js.map +1 -0
- package/dist/metadata/index.d.ts +2 -0
- package/dist/metadata/index.d.ts.map +1 -0
- package/dist/metadata/index.js +2 -0
- package/dist/metadata/index.js.map +1 -0
- package/dist/metadata/metadata.sdk.d.ts +111 -0
- package/dist/metadata/metadata.sdk.d.ts.map +1 -0
- package/dist/metadata/metadata.sdk.js +142 -0
- package/dist/metadata/metadata.sdk.js.map +1 -0
- package/dist/negotiations/index.d.ts +2 -0
- package/dist/negotiations/index.d.ts.map +1 -0
- package/dist/negotiations/index.js +2 -0
- package/dist/negotiations/index.js.map +1 -0
- package/dist/negotiations/negotiations.sdk.d.ts +113 -0
- package/dist/negotiations/negotiations.sdk.d.ts.map +1 -0
- package/dist/negotiations/negotiations.sdk.js +146 -0
- package/dist/negotiations/negotiations.sdk.js.map +1 -0
- package/dist/requirements/index.d.ts +2 -0
- package/dist/requirements/index.d.ts.map +1 -0
- package/dist/requirements/index.js +2 -0
- package/dist/requirements/index.js.map +1 -0
- package/dist/requirements/requirements.sdk.d.ts +52 -0
- package/dist/requirements/requirements.sdk.d.ts.map +1 -0
- package/dist/requirements/requirements.sdk.js +123 -0
- package/dist/requirements/requirements.sdk.js.map +1 -0
- package/dist/sso/index.d.ts +3 -0
- package/dist/sso/index.d.ts.map +1 -0
- package/dist/sso/index.js +3 -0
- package/dist/sso/index.js.map +1 -0
- package/dist/sso/sso-management.sdk.d.ts +96 -0
- package/dist/sso/sso-management.sdk.d.ts.map +1 -0
- package/dist/sso/sso-management.sdk.js +152 -0
- package/dist/sso/sso-management.sdk.js.map +1 -0
- package/dist/sso/sso.sdk.d.ts +75 -0
- package/dist/sso/sso.sdk.d.ts.map +1 -0
- package/dist/sso/sso.sdk.js +147 -0
- package/dist/sso/sso.sdk.js.map +1 -0
- package/dist/transfers/index.d.ts +2 -0
- package/dist/transfers/index.d.ts.map +1 -0
- package/dist/transfers/index.js +2 -0
- package/dist/transfers/index.js.map +1 -0
- package/dist/transfers/transfers.sdk.d.ts +155 -0
- package/dist/transfers/transfers.sdk.d.ts.map +1 -0
- package/dist/transfers/transfers.sdk.js +186 -0
- package/dist/transfers/transfers.sdk.js.map +1 -0
- package/dist/tsg-sdk.d.ts +65 -0
- package/dist/tsg-sdk.d.ts.map +1 -0
- package/dist/tsg-sdk.js +128 -0
- package/dist/tsg-sdk.js.map +1 -0
- package/dist/utils/errors.d.ts +67 -0
- package/dist/utils/errors.d.ts.map +1 -0
- package/dist/utils/errors.js +79 -0
- package/dist/utils/errors.js.map +1 -0
- package/dist/utils/index.d.ts +4 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/index.js +4 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/polling.d.ts +20 -0
- package/dist/utils/polling.d.ts.map +1 -0
- package/dist/utils/polling.js +35 -0
- package/dist/utils/polling.js.map +1 -0
- package/dist/utils/shape-validation.d.ts +59 -0
- package/dist/utils/shape-validation.d.ts.map +1 -0
- package/dist/utils/shape-validation.js +85 -0
- package/dist/utils/shape-validation.js.map +1 -0
- package/dist/utils/validate.d.ts +47 -0
- package/dist/utils/validate.d.ts.map +1 -0
- package/dist/utils/validate.js +68 -0
- package/dist/utils/validate.js.map +1 -0
- package/dist/vendor/common-dtos/abac.policy.d.ts +60 -0
- package/dist/vendor/common-dtos/abac.policy.js +2 -0
- package/dist/vendor/common-dtos/audit.types.d.ts +74 -0
- package/dist/vendor/common-dtos/audit.types.js +9 -0
- package/dist/vendor/common-dtos/credential-requirements.d.ts +19 -0
- package/dist/vendor/common-dtos/credential-requirements.dto.d.ts +47 -0
- package/dist/vendor/common-dtos/credential-requirements.dto.js +251 -0
- package/dist/vendor/common-dtos/credential-requirements.js +181 -0
- package/dist/vendor/common-dtos/dataplane.dto.d.ts +6 -0
- package/dist/vendor/common-dtos/dataplane.dto.js +29 -0
- package/dist/vendor/common-dtos/dcp.dto.d.ts +90 -0
- package/dist/vendor/common-dtos/dcp.dto.js +490 -0
- package/dist/vendor/common-dtos/dcql.dto.d.ts +89 -0
- package/dist/vendor/common-dtos/dcql.dto.js +450 -0
- package/dist/vendor/common-dtos/did.schemas.d.ts +40 -0
- package/dist/vendor/common-dtos/did.schemas.js +260 -0
- package/dist/vendor/common-dtos/index.d.ts +19 -0
- package/dist/vendor/common-dtos/index.js +19 -0
- package/dist/vendor/common-dtos/metadata.dto.d.ts +6 -0
- package/dist/vendor/common-dtos/metadata.dto.js +30 -0
- package/dist/vendor/common-dtos/negotiations.dto.d.ts +29 -0
- package/dist/vendor/common-dtos/negotiations.dto.js +205 -0
- package/dist/vendor/common-dtos/permissions.d.ts +237 -0
- package/dist/vendor/common-dtos/permissions.js +337 -0
- package/dist/vendor/common-dtos/presentation.request.dto.d.ts +9 -0
- package/dist/vendor/common-dtos/presentation.request.dto.js +55 -0
- package/dist/vendor/common-dtos/presentation.status.dto.d.ts +13 -0
- package/dist/vendor/common-dtos/presentation.status.dto.js +83 -0
- package/dist/vendor/common-dtos/presentationdefinition.dto.d.ts +75 -0
- package/dist/vendor/common-dtos/presentationdefinition.dto.js +448 -0
- package/dist/vendor/common-dtos/signatures.dto.d.ts +32 -0
- package/dist/vendor/common-dtos/signatures.dto.js +210 -0
- package/dist/vendor/common-dtos/transfer.dto.d.ts +17 -0
- package/dist/vendor/common-dtos/transfer.dto.js +102 -0
- package/dist/vendor/common-dtos/utils.swagger.d.ts +13 -0
- package/dist/vendor/common-dtos/utils.swagger.js +63 -0
- package/dist/vendor/control-plane-dtos/index.d.ts +5 -0
- package/dist/vendor/control-plane-dtos/index.js +5 -0
- package/dist/vendor/control-plane-dtos/registry/registry.dto.d.ts +5 -0
- package/dist/vendor/control-plane-dtos/registry/registry.dto.js +26 -0
- package/dist/vendor/control-plane-dtos/registry/registry.search.dto.d.ts +29 -0
- package/dist/vendor/control-plane-dtos/registry/registry.search.dto.js +127 -0
- package/dist/vendor/control-plane-dtos/ssi/verifiablePresentations.dto.d.ts +10 -0
- package/dist/vendor/control-plane-dtos/ssi/verifiablePresentations.dto.js +44 -0
- package/dist/vendor/control-plane-dtos/status/status.dto.d.ts +38 -0
- package/dist/vendor/control-plane-dtos/status/status.dto.js +173 -0
- package/dist/vendor/sso-bridge-dtos/clients.dto.d.ts +22 -0
- package/dist/vendor/sso-bridge-dtos/clients.dto.js +113 -0
- package/dist/vendor/sso-bridge-dtos/grants.d.ts +3 -0
- package/dist/vendor/sso-bridge-dtos/grants.js +2 -0
- package/dist/vendor/sso-bridge-dtos/index.d.ts +5 -0
- package/dist/vendor/sso-bridge-dtos/index.js +5 -0
- package/dist/vendor/sso-bridge-dtos/users.dto.d.ts +24 -0
- package/dist/vendor/sso-bridge-dtos/users.dto.js +90 -0
- package/dist/vendor/wallet-dtos/clients.dto.d.ts +22 -0
- package/dist/vendor/wallet-dtos/clients.dto.js +14 -0
- package/dist/vendor/wallet-dtos/credentials.dto.d.ts +32 -0
- package/dist/vendor/wallet-dtos/credentials.dto.js +47 -0
- package/dist/vendor/wallet-dtos/index.d.ts +7 -0
- package/dist/vendor/wallet-dtos/index.js +7 -0
- package/dist/vendor/wallet-dtos/issuance.dto.d.ts +238 -0
- package/dist/vendor/wallet-dtos/issuance.dto.js +1140 -0
- package/dist/vendor/wallet-dtos/scopes.dto.d.ts +25 -0
- package/dist/vendor/wallet-dtos/scopes.dto.js +152 -0
- package/dist/vendor/wallet-dtos/status.dto.d.ts +36 -0
- package/dist/vendor/wallet-dtos/status.dto.js +170 -0
- package/dist/vendor/wallet-dtos/utils/schema-converter.d.ts +14 -0
- package/dist/vendor/wallet-dtos/utils/schema-converter.js +43 -0
- package/dist/wallet/index.d.ts +2 -0
- package/dist/wallet/index.d.ts.map +1 -0
- package/dist/wallet/index.js +2 -0
- package/dist/wallet/index.js.map +1 -0
- package/dist/wallet/wallet.sdk.d.ts +285 -0
- package/dist/wallet/wallet.sdk.d.ts.map +1 -0
- package/dist/wallet/wallet.sdk.js +384 -0
- package/dist/wallet/wallet.sdk.js.map +1 -0
- package/package.json +78 -3
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { ApiExtraModels, ApiProperty, ApiPropertyOptional, getSchemaPath } from "@nestjs/swagger";
|
|
11
|
+
import { elementOrArray } from "@tsg-dsp/common-dsp";
|
|
12
|
+
const randomUUID = "bdfd4c8e-3a44-4b9f-bc3e-1a8e26e3e99d";
|
|
13
|
+
export class JsonWebKeyDto {
|
|
14
|
+
alg;
|
|
15
|
+
crv;
|
|
16
|
+
e;
|
|
17
|
+
ext;
|
|
18
|
+
key_ops;
|
|
19
|
+
kid;
|
|
20
|
+
kty;
|
|
21
|
+
n;
|
|
22
|
+
use;
|
|
23
|
+
x;
|
|
24
|
+
y;
|
|
25
|
+
}
|
|
26
|
+
__decorate([
|
|
27
|
+
ApiPropertyOptional({ example: "RS256" }),
|
|
28
|
+
__metadata("design:type", String)
|
|
29
|
+
], JsonWebKeyDto.prototype, "alg", void 0);
|
|
30
|
+
__decorate([
|
|
31
|
+
ApiPropertyOptional({ example: "P-256" }),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], JsonWebKeyDto.prototype, "crv", void 0);
|
|
34
|
+
__decorate([
|
|
35
|
+
ApiPropertyOptional({ example: "AQAB" }),
|
|
36
|
+
__metadata("design:type", String)
|
|
37
|
+
], JsonWebKeyDto.prototype, "e", void 0);
|
|
38
|
+
__decorate([
|
|
39
|
+
ApiPropertyOptional({ example: false }),
|
|
40
|
+
__metadata("design:type", Boolean)
|
|
41
|
+
], JsonWebKeyDto.prototype, "ext", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
ApiPropertyOptional({ type: [String], example: ["sign", "verify"] }),
|
|
44
|
+
__metadata("design:type", Array)
|
|
45
|
+
], JsonWebKeyDto.prototype, "key_ops", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
ApiPropertyOptional({ example: randomUUID }),
|
|
48
|
+
__metadata("design:type", String)
|
|
49
|
+
], JsonWebKeyDto.prototype, "kid", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
ApiProperty({ example: "RSA" }),
|
|
52
|
+
__metadata("design:type", String)
|
|
53
|
+
], JsonWebKeyDto.prototype, "kty", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
ApiPropertyOptional({ example: "sample_modulus" }),
|
|
56
|
+
__metadata("design:type", String)
|
|
57
|
+
], JsonWebKeyDto.prototype, "n", void 0);
|
|
58
|
+
__decorate([
|
|
59
|
+
ApiPropertyOptional({ example: "sig" }),
|
|
60
|
+
__metadata("design:type", String)
|
|
61
|
+
], JsonWebKeyDto.prototype, "use", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
ApiPropertyOptional({ example: "sample_x_coordinate" }),
|
|
64
|
+
__metadata("design:type", String)
|
|
65
|
+
], JsonWebKeyDto.prototype, "x", void 0);
|
|
66
|
+
__decorate([
|
|
67
|
+
ApiPropertyOptional({ example: "sample_y_coordinate" }),
|
|
68
|
+
__metadata("design:type", String)
|
|
69
|
+
], JsonWebKeyDto.prototype, "y", void 0);
|
|
70
|
+
export class VerificationMethodDto {
|
|
71
|
+
id;
|
|
72
|
+
type;
|
|
73
|
+
controller;
|
|
74
|
+
publicKeyJwk;
|
|
75
|
+
}
|
|
76
|
+
__decorate([
|
|
77
|
+
ApiProperty({ example: randomUUID }),
|
|
78
|
+
__metadata("design:type", String)
|
|
79
|
+
], VerificationMethodDto.prototype, "id", void 0);
|
|
80
|
+
__decorate([
|
|
81
|
+
ApiProperty({ example: "Ed25519VerificationKey2020" }),
|
|
82
|
+
__metadata("design:type", String)
|
|
83
|
+
], VerificationMethodDto.prototype, "type", void 0);
|
|
84
|
+
__decorate([
|
|
85
|
+
ApiProperty({ example: randomUUID }),
|
|
86
|
+
__metadata("design:type", String)
|
|
87
|
+
], VerificationMethodDto.prototype, "controller", void 0);
|
|
88
|
+
__decorate([
|
|
89
|
+
ApiPropertyOptional(),
|
|
90
|
+
__metadata("design:type", JsonWebKeyDto)
|
|
91
|
+
], VerificationMethodDto.prototype, "publicKeyJwk", void 0);
|
|
92
|
+
export class ServiceDto {
|
|
93
|
+
id;
|
|
94
|
+
type;
|
|
95
|
+
serviceEndpoint;
|
|
96
|
+
}
|
|
97
|
+
__decorate([
|
|
98
|
+
ApiProperty({ example: randomUUID }),
|
|
99
|
+
__metadata("design:type", String)
|
|
100
|
+
], ServiceDto.prototype, "id", void 0);
|
|
101
|
+
__decorate([
|
|
102
|
+
ApiProperty({ example: "LinkedDomains" }),
|
|
103
|
+
__metadata("design:type", String)
|
|
104
|
+
], ServiceDto.prototype, "type", void 0);
|
|
105
|
+
__decorate([
|
|
106
|
+
ApiProperty({
|
|
107
|
+
example: "https://example.com",
|
|
108
|
+
...elementOrArray({ type: "string" })
|
|
109
|
+
}),
|
|
110
|
+
__metadata("design:type", Object)
|
|
111
|
+
], ServiceDto.prototype, "serviceEndpoint", void 0);
|
|
112
|
+
let DIDDocumentDto = class DIDDocumentDto {
|
|
113
|
+
"@context";
|
|
114
|
+
id;
|
|
115
|
+
alsoKnownAs;
|
|
116
|
+
controller;
|
|
117
|
+
verificationMethod;
|
|
118
|
+
service;
|
|
119
|
+
publicKey;
|
|
120
|
+
authentication;
|
|
121
|
+
assertionMethod;
|
|
122
|
+
keyAgreement;
|
|
123
|
+
capabilityInvocation;
|
|
124
|
+
capabilityDelegation;
|
|
125
|
+
};
|
|
126
|
+
__decorate([
|
|
127
|
+
ApiPropertyOptional({
|
|
128
|
+
example: "https://www.w3.org/ns/did/v1",
|
|
129
|
+
...elementOrArray({ type: "string" })
|
|
130
|
+
}),
|
|
131
|
+
__metadata("design:type", Object)
|
|
132
|
+
], DIDDocumentDto.prototype, "@context", void 0);
|
|
133
|
+
__decorate([
|
|
134
|
+
ApiProperty({ example: randomUUID }),
|
|
135
|
+
__metadata("design:type", String)
|
|
136
|
+
], DIDDocumentDto.prototype, "id", void 0);
|
|
137
|
+
__decorate([
|
|
138
|
+
ApiPropertyOptional({
|
|
139
|
+
type: [String],
|
|
140
|
+
example: ["https://example.com/profile"]
|
|
141
|
+
}),
|
|
142
|
+
__metadata("design:type", Array)
|
|
143
|
+
], DIDDocumentDto.prototype, "alsoKnownAs", void 0);
|
|
144
|
+
__decorate([
|
|
145
|
+
ApiPropertyOptional({
|
|
146
|
+
example: randomUUID,
|
|
147
|
+
...elementOrArray({ type: "string" })
|
|
148
|
+
}),
|
|
149
|
+
__metadata("design:type", Object)
|
|
150
|
+
], DIDDocumentDto.prototype, "controller", void 0);
|
|
151
|
+
__decorate([
|
|
152
|
+
ApiPropertyOptional({
|
|
153
|
+
type: () => [VerificationMethodDto],
|
|
154
|
+
example: [
|
|
155
|
+
{
|
|
156
|
+
id: randomUUID,
|
|
157
|
+
type: "Ed25519VerificationKey2020",
|
|
158
|
+
controller: randomUUID,
|
|
159
|
+
publicKeyJwk: {
|
|
160
|
+
kty: "RSA"
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
]
|
|
164
|
+
}),
|
|
165
|
+
__metadata("design:type", Array)
|
|
166
|
+
], DIDDocumentDto.prototype, "verificationMethod", void 0);
|
|
167
|
+
__decorate([
|
|
168
|
+
ApiPropertyOptional({
|
|
169
|
+
type: [ServiceDto],
|
|
170
|
+
example: [
|
|
171
|
+
{
|
|
172
|
+
id: randomUUID,
|
|
173
|
+
type: "LinkedDomains",
|
|
174
|
+
serviceEndpoint: "https://example.com"
|
|
175
|
+
}
|
|
176
|
+
]
|
|
177
|
+
}),
|
|
178
|
+
__metadata("design:type", Array)
|
|
179
|
+
], DIDDocumentDto.prototype, "service", void 0);
|
|
180
|
+
__decorate([
|
|
181
|
+
ApiPropertyOptional({
|
|
182
|
+
type: () => [VerificationMethodDto],
|
|
183
|
+
example: [
|
|
184
|
+
{
|
|
185
|
+
id: randomUUID,
|
|
186
|
+
type: "Ed25519VerificationKey2020",
|
|
187
|
+
controller: randomUUID,
|
|
188
|
+
publicKeyJwk: {
|
|
189
|
+
kty: "RSA"
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
]
|
|
193
|
+
}),
|
|
194
|
+
__metadata("design:type", Array)
|
|
195
|
+
], DIDDocumentDto.prototype, "publicKey", void 0);
|
|
196
|
+
__decorate([
|
|
197
|
+
ApiPropertyOptional({
|
|
198
|
+
type: "array",
|
|
199
|
+
items: {
|
|
200
|
+
oneOf: [
|
|
201
|
+
{ type: "string" },
|
|
202
|
+
{ $ref: getSchemaPath(VerificationMethodDto) }
|
|
203
|
+
]
|
|
204
|
+
}
|
|
205
|
+
}),
|
|
206
|
+
__metadata("design:type", Array)
|
|
207
|
+
], DIDDocumentDto.prototype, "authentication", void 0);
|
|
208
|
+
__decorate([
|
|
209
|
+
ApiPropertyOptional({
|
|
210
|
+
type: "array",
|
|
211
|
+
items: {
|
|
212
|
+
oneOf: [
|
|
213
|
+
{ type: "string" },
|
|
214
|
+
{ $ref: getSchemaPath(VerificationMethodDto) }
|
|
215
|
+
]
|
|
216
|
+
}
|
|
217
|
+
}),
|
|
218
|
+
__metadata("design:type", Array)
|
|
219
|
+
], DIDDocumentDto.prototype, "assertionMethod", void 0);
|
|
220
|
+
__decorate([
|
|
221
|
+
ApiPropertyOptional({
|
|
222
|
+
type: "array",
|
|
223
|
+
items: {
|
|
224
|
+
oneOf: [
|
|
225
|
+
{ type: "string" },
|
|
226
|
+
{ $ref: getSchemaPath(VerificationMethodDto) }
|
|
227
|
+
]
|
|
228
|
+
}
|
|
229
|
+
}),
|
|
230
|
+
__metadata("design:type", Array)
|
|
231
|
+
], DIDDocumentDto.prototype, "keyAgreement", void 0);
|
|
232
|
+
__decorate([
|
|
233
|
+
ApiPropertyOptional({
|
|
234
|
+
type: "array",
|
|
235
|
+
items: {
|
|
236
|
+
oneOf: [
|
|
237
|
+
{ type: "string" },
|
|
238
|
+
{ $ref: getSchemaPath(VerificationMethodDto) }
|
|
239
|
+
]
|
|
240
|
+
}
|
|
241
|
+
}),
|
|
242
|
+
__metadata("design:type", Array)
|
|
243
|
+
], DIDDocumentDto.prototype, "capabilityInvocation", void 0);
|
|
244
|
+
__decorate([
|
|
245
|
+
ApiPropertyOptional({
|
|
246
|
+
type: "array",
|
|
247
|
+
items: {
|
|
248
|
+
oneOf: [
|
|
249
|
+
{ type: "string" },
|
|
250
|
+
{ $ref: getSchemaPath(VerificationMethodDto) }
|
|
251
|
+
]
|
|
252
|
+
}
|
|
253
|
+
}),
|
|
254
|
+
__metadata("design:type", Array)
|
|
255
|
+
], DIDDocumentDto.prototype, "capabilityDelegation", void 0);
|
|
256
|
+
DIDDocumentDto = __decorate([
|
|
257
|
+
ApiExtraModels(VerificationMethodDto)
|
|
258
|
+
], DIDDocumentDto);
|
|
259
|
+
export { DIDDocumentDto };
|
|
260
|
+
//# sourceMappingURL=did.schemas.js.map
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import "reflect-metadata";
|
|
2
|
+
export * from "./abac.policy.js";
|
|
3
|
+
export * from "./audit.types.js";
|
|
4
|
+
export * from "./credential-requirements.dto.js";
|
|
5
|
+
export * from "./credential-requirements.js";
|
|
6
|
+
export * from "./dataplane.dto.js";
|
|
7
|
+
export * from "./dcp.dto.js";
|
|
8
|
+
export * from "./dcql.dto.js";
|
|
9
|
+
export * from "./did.schemas.js";
|
|
10
|
+
export * from "./metadata.dto.js";
|
|
11
|
+
export * from "./negotiations.dto.js";
|
|
12
|
+
export * from "./permissions.js";
|
|
13
|
+
export * from "./presentation.request.dto.js";
|
|
14
|
+
export * from "./presentation.status.dto.js";
|
|
15
|
+
export * from "./presentationdefinition.dto.js";
|
|
16
|
+
export * from "./signatures.dto.js";
|
|
17
|
+
export * from "./transfer.dto.js";
|
|
18
|
+
export * from "./utils.swagger.js";
|
|
19
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import "reflect-metadata";
|
|
2
|
+
export * from "./abac.policy.js";
|
|
3
|
+
export * from "./audit.types.js";
|
|
4
|
+
export * from "./credential-requirements.dto.js";
|
|
5
|
+
export * from "./credential-requirements.js";
|
|
6
|
+
export * from "./dataplane.dto.js";
|
|
7
|
+
export * from "./dcp.dto.js";
|
|
8
|
+
export * from "./dcql.dto.js";
|
|
9
|
+
export * from "./did.schemas.js";
|
|
10
|
+
export * from "./metadata.dto.js";
|
|
11
|
+
export * from "./negotiations.dto.js";
|
|
12
|
+
export * from "./permissions.js";
|
|
13
|
+
export * from "./presentation.request.dto.js";
|
|
14
|
+
export * from "./presentation.status.dto.js";
|
|
15
|
+
export * from "./presentationdefinition.dto.js";
|
|
16
|
+
export * from "./signatures.dto.js";
|
|
17
|
+
export * from "./transfer.dto.js";
|
|
18
|
+
export * from "./utils.swagger.js";
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { ApiProperty } from "@nestjs/swagger";
|
|
11
|
+
import { AgreementSchema, DatasetSchema } from "@tsg-dsp/common-dsp";
|
|
12
|
+
import { Type } from "class-transformer";
|
|
13
|
+
import { ValidateNested } from "class-validator";
|
|
14
|
+
export class MetadataDto {
|
|
15
|
+
agreement;
|
|
16
|
+
dataset;
|
|
17
|
+
}
|
|
18
|
+
__decorate([
|
|
19
|
+
ApiProperty({ type: () => AgreementSchema }),
|
|
20
|
+
Type(() => AgreementSchema),
|
|
21
|
+
ValidateNested(),
|
|
22
|
+
__metadata("design:type", Object)
|
|
23
|
+
], MetadataDto.prototype, "agreement", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
ApiProperty({ type: () => DatasetSchema }),
|
|
26
|
+
Type(() => DatasetSchema),
|
|
27
|
+
ValidateNested(),
|
|
28
|
+
__metadata("design:type", Object)
|
|
29
|
+
], MetadataDto.prototype, "dataset", void 0);
|
|
30
|
+
//# sourceMappingURL=metadata.dto.js.map
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { AgreementDto, ContractAgreementVerificationMessageDto, ContractNegotiationState, HashedMessage, MultilanguageDto, OfferDto } from "@tsg-dsp/common-dsp";
|
|
2
|
+
export type NegotiationRole = "provider" | "consumer";
|
|
3
|
+
export declare class NegotiationProcessEventDto {
|
|
4
|
+
time: Date;
|
|
5
|
+
state: ContractNegotiationState;
|
|
6
|
+
localMessage?: string;
|
|
7
|
+
code?: string;
|
|
8
|
+
reason?: MultilanguageDto[];
|
|
9
|
+
agreementMessage?: string;
|
|
10
|
+
verification?: ContractAgreementVerificationMessageDto;
|
|
11
|
+
hashedMessage?: HashedMessage;
|
|
12
|
+
type: "local" | "remote";
|
|
13
|
+
}
|
|
14
|
+
export declare class NegotiationStatusDto {
|
|
15
|
+
id: string;
|
|
16
|
+
remoteId: string;
|
|
17
|
+
remoteParty: string;
|
|
18
|
+
role: NegotiationRole;
|
|
19
|
+
remoteAddress: string;
|
|
20
|
+
state: ContractNegotiationState;
|
|
21
|
+
dataSet: string;
|
|
22
|
+
modifiedDate: Date;
|
|
23
|
+
}
|
|
24
|
+
export declare class NegotiationDetailDto extends NegotiationStatusDto {
|
|
25
|
+
offer?: OfferDto;
|
|
26
|
+
agreement?: AgreementDto;
|
|
27
|
+
events: Array<NegotiationProcessEventDto>;
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=negotiations.dto.d.ts.map
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
|
|
11
|
+
import { AgreementSchema, ContractAgreementVerificationMessageSchema, ContractNegotiationState, HashedMessageSchema, MultilanguageSchema, OfferSchema } from "@tsg-dsp/common-dsp";
|
|
12
|
+
import { Type } from "class-transformer";
|
|
13
|
+
import { IsDate, IsEnum, IsOptional, IsString, ValidateNested } from "class-validator";
|
|
14
|
+
export class NegotiationProcessEventDto {
|
|
15
|
+
time;
|
|
16
|
+
state;
|
|
17
|
+
localMessage;
|
|
18
|
+
code;
|
|
19
|
+
reason;
|
|
20
|
+
agreementMessage;
|
|
21
|
+
verification;
|
|
22
|
+
hashedMessage;
|
|
23
|
+
type;
|
|
24
|
+
}
|
|
25
|
+
__decorate([
|
|
26
|
+
ApiProperty({
|
|
27
|
+
example: "2023-10-11T00:00:00.000Z"
|
|
28
|
+
}),
|
|
29
|
+
IsDate(),
|
|
30
|
+
Type(() => Date),
|
|
31
|
+
__metadata("design:type", Date)
|
|
32
|
+
], NegotiationProcessEventDto.prototype, "time", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
ApiProperty({
|
|
35
|
+
enum: ContractNegotiationState,
|
|
36
|
+
example: Object.values(ContractNegotiationState)[0]
|
|
37
|
+
}),
|
|
38
|
+
IsEnum(ContractNegotiationState),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], NegotiationProcessEventDto.prototype, "state", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
ApiPropertyOptional({
|
|
43
|
+
example: "A local message example"
|
|
44
|
+
}),
|
|
45
|
+
IsOptional(),
|
|
46
|
+
IsString(),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], NegotiationProcessEventDto.prototype, "localMessage", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
ApiPropertyOptional({
|
|
51
|
+
example: "ERR_CODE"
|
|
52
|
+
}),
|
|
53
|
+
IsOptional(),
|
|
54
|
+
IsString(),
|
|
55
|
+
__metadata("design:type", String)
|
|
56
|
+
], NegotiationProcessEventDto.prototype, "code", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
ApiPropertyOptional({
|
|
59
|
+
type: () => [MultilanguageSchema],
|
|
60
|
+
example: []
|
|
61
|
+
}),
|
|
62
|
+
IsOptional(),
|
|
63
|
+
ValidateNested({ each: true }),
|
|
64
|
+
Type(() => MultilanguageSchema),
|
|
65
|
+
__metadata("design:type", Array)
|
|
66
|
+
], NegotiationProcessEventDto.prototype, "reason", void 0);
|
|
67
|
+
__decorate([
|
|
68
|
+
ApiPropertyOptional({
|
|
69
|
+
example: "Agreement reached on event"
|
|
70
|
+
}),
|
|
71
|
+
IsOptional(),
|
|
72
|
+
IsString(),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], NegotiationProcessEventDto.prototype, "agreementMessage", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
ApiPropertyOptional({
|
|
77
|
+
type: () => ContractAgreementVerificationMessageSchema,
|
|
78
|
+
example: {} // add a valid ContractAgreementVerificationMessageDto example if available
|
|
79
|
+
}),
|
|
80
|
+
IsOptional(),
|
|
81
|
+
ValidateNested(),
|
|
82
|
+
Type(() => ContractAgreementVerificationMessageSchema),
|
|
83
|
+
__metadata("design:type", Object)
|
|
84
|
+
], NegotiationProcessEventDto.prototype, "verification", void 0);
|
|
85
|
+
__decorate([
|
|
86
|
+
ApiPropertyOptional({
|
|
87
|
+
type: () => HashedMessageSchema,
|
|
88
|
+
example: {} // add a valid HashedMessage example if available
|
|
89
|
+
}),
|
|
90
|
+
IsOptional(),
|
|
91
|
+
ValidateNested(),
|
|
92
|
+
Type(() => HashedMessageSchema),
|
|
93
|
+
__metadata("design:type", Object)
|
|
94
|
+
], NegotiationProcessEventDto.prototype, "hashedMessage", void 0);
|
|
95
|
+
__decorate([
|
|
96
|
+
ApiProperty({
|
|
97
|
+
enum: ["local", "remote"],
|
|
98
|
+
example: "local"
|
|
99
|
+
}),
|
|
100
|
+
IsEnum(["local", "remote"]),
|
|
101
|
+
__metadata("design:type", String)
|
|
102
|
+
], NegotiationProcessEventDto.prototype, "type", void 0);
|
|
103
|
+
export class NegotiationStatusDto {
|
|
104
|
+
id;
|
|
105
|
+
remoteId;
|
|
106
|
+
remoteParty;
|
|
107
|
+
role;
|
|
108
|
+
remoteAddress;
|
|
109
|
+
state;
|
|
110
|
+
dataSet;
|
|
111
|
+
modifiedDate;
|
|
112
|
+
}
|
|
113
|
+
__decorate([
|
|
114
|
+
ApiProperty({
|
|
115
|
+
example: "3fa85f64-5717-4562-b3fc-2c963f66afa6"
|
|
116
|
+
}),
|
|
117
|
+
IsString(),
|
|
118
|
+
__metadata("design:type", String)
|
|
119
|
+
], NegotiationStatusDto.prototype, "id", void 0);
|
|
120
|
+
__decorate([
|
|
121
|
+
ApiProperty({
|
|
122
|
+
example: "3fa85f64-5717-4562-b3fc-2c963f66afa7"
|
|
123
|
+
}),
|
|
124
|
+
IsString(),
|
|
125
|
+
__metadata("design:type", String)
|
|
126
|
+
], NegotiationStatusDto.prototype, "remoteId", void 0);
|
|
127
|
+
__decorate([
|
|
128
|
+
ApiProperty({
|
|
129
|
+
example: "Remote Party Name"
|
|
130
|
+
}),
|
|
131
|
+
IsString(),
|
|
132
|
+
__metadata("design:type", String)
|
|
133
|
+
], NegotiationStatusDto.prototype, "remoteParty", void 0);
|
|
134
|
+
__decorate([
|
|
135
|
+
ApiProperty({
|
|
136
|
+
enum: ["provider", "consumer"],
|
|
137
|
+
example: "provider"
|
|
138
|
+
}),
|
|
139
|
+
IsEnum(["provider", "consumer"]),
|
|
140
|
+
__metadata("design:type", String)
|
|
141
|
+
], NegotiationStatusDto.prototype, "role", void 0);
|
|
142
|
+
__decorate([
|
|
143
|
+
ApiProperty({
|
|
144
|
+
example: "192.168.1.100"
|
|
145
|
+
}),
|
|
146
|
+
IsString(),
|
|
147
|
+
__metadata("design:type", String)
|
|
148
|
+
], NegotiationStatusDto.prototype, "remoteAddress", void 0);
|
|
149
|
+
__decorate([
|
|
150
|
+
ApiProperty({
|
|
151
|
+
enum: ContractNegotiationState,
|
|
152
|
+
example: Object.values(ContractNegotiationState)[0]
|
|
153
|
+
}),
|
|
154
|
+
IsEnum(ContractNegotiationState),
|
|
155
|
+
__metadata("design:type", String)
|
|
156
|
+
], NegotiationStatusDto.prototype, "state", void 0);
|
|
157
|
+
__decorate([
|
|
158
|
+
ApiProperty({
|
|
159
|
+
example: "defaultDataSet"
|
|
160
|
+
}),
|
|
161
|
+
IsString(),
|
|
162
|
+
__metadata("design:type", String)
|
|
163
|
+
], NegotiationStatusDto.prototype, "dataSet", void 0);
|
|
164
|
+
__decorate([
|
|
165
|
+
ApiProperty({
|
|
166
|
+
example: "2023-10-11T00:00:00.000Z"
|
|
167
|
+
}),
|
|
168
|
+
IsDate(),
|
|
169
|
+
Type(() => Date),
|
|
170
|
+
__metadata("design:type", Date)
|
|
171
|
+
], NegotiationStatusDto.prototype, "modifiedDate", void 0);
|
|
172
|
+
export class NegotiationDetailDto extends NegotiationStatusDto {
|
|
173
|
+
offer;
|
|
174
|
+
agreement;
|
|
175
|
+
events;
|
|
176
|
+
}
|
|
177
|
+
__decorate([
|
|
178
|
+
ApiPropertyOptional({
|
|
179
|
+
type: () => OfferSchema,
|
|
180
|
+
example: {} // add a valid OfferDto example if available
|
|
181
|
+
}),
|
|
182
|
+
IsOptional(),
|
|
183
|
+
ValidateNested(),
|
|
184
|
+
Type(() => OfferSchema),
|
|
185
|
+
__metadata("design:type", Object)
|
|
186
|
+
], NegotiationDetailDto.prototype, "offer", void 0);
|
|
187
|
+
__decorate([
|
|
188
|
+
ApiPropertyOptional({
|
|
189
|
+
type: () => AgreementSchema,
|
|
190
|
+
example: {} // add a valid AgreementDto example if available
|
|
191
|
+
}),
|
|
192
|
+
IsOptional(),
|
|
193
|
+
ValidateNested(),
|
|
194
|
+
Type(() => AgreementSchema),
|
|
195
|
+
__metadata("design:type", Object)
|
|
196
|
+
], NegotiationDetailDto.prototype, "agreement", void 0);
|
|
197
|
+
__decorate([
|
|
198
|
+
ApiProperty({
|
|
199
|
+
type: () => [NegotiationProcessEventDto]
|
|
200
|
+
}),
|
|
201
|
+
ValidateNested({ each: true }),
|
|
202
|
+
Type(() => NegotiationProcessEventDto),
|
|
203
|
+
__metadata("design:type", Array)
|
|
204
|
+
], NegotiationDetailDto.prototype, "events", void 0);
|
|
205
|
+
//# sourceMappingURL=negotiations.dto.js.map
|