@sphereon/ssi-sdk.data-store-types 0.34.1-feat.SSISDK.55.243
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 +0 -0
- package/dist/index.cjs +204 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +916 -0
- package/dist/index.d.ts +916 -0
- package/dist/index.js +183 -0
- package/dist/index.js.map +1 -0
- package/package.json +51 -0
- package/src/contact/AbstractContactStore.ts +71 -0
- package/src/digitalCredential/AbstractDigitalCredentialStore.ts +21 -0
- package/src/eventLogger/AbstractEventLoggerStore.ts +9 -0
- package/src/index.ts +11 -0
- package/src/issuanceBranding/AbstractIssuanceBrandingStore.ts +41 -0
- package/src/machineState/IAbstractMachineStateStore.ts +65 -0
- package/src/presentationDefinition/AbstractPDStore.ts +20 -0
- package/src/types/contact/IAbstractContactStore.ts +161 -0
- package/src/types/contact/contact.ts +295 -0
- package/src/types/contact/index.ts +2 -0
- package/src/types/digitalCredential/IAbstractDigitalCredentialStore.ts +41 -0
- package/src/types/digitalCredential/enums.ts +63 -0
- package/src/types/digitalCredential/index.ts +3 -0
- package/src/types/digitalCredential/types.ts +40 -0
- package/src/types/eventLogger/IAbstractEventLoggerStore.ts +22 -0
- package/src/types/eventLogger/eventLogger.ts +4 -0
- package/src/types/index.ts +10 -0
- package/src/types/issuanceBranding/IAbstractIssuanceBrandingStore.ts +85 -0
- package/src/types/issuanceBranding/issuanceBranding.ts +138 -0
- package/src/types/machineState/IAbstractMachineStateStore.ts +68 -0
- package/src/types/presentationDefinition/IAbstractPDStore.ts +25 -0
- package/src/types/presentationDefinition/presentationDefinition.ts +18 -0
- package/src/types/validation/validation.ts +3 -0
- package/src/utils/MappingUtils.ts +22 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,916 @@
|
|
|
1
|
+
import { ManagedIdentifierOptsOrResult } from '@sphereon/ssi-sdk-ext.identifier-resolution';
|
|
2
|
+
import { IIdentifier } from '@veramo/core';
|
|
3
|
+
import { CredentialRole, HasherSync } from '@sphereon/ssi-types';
|
|
4
|
+
import { AuditLoggingEvent, ActivityLoggingEvent, PartialAuditLoggingEvent, PartialActivityLoggingEvent } from '@sphereon/ssi-sdk.core';
|
|
5
|
+
import { DcqlQuery } from 'dcql';
|
|
6
|
+
|
|
7
|
+
interface ILocaleBranding {
|
|
8
|
+
id: string;
|
|
9
|
+
alias?: string;
|
|
10
|
+
locale?: string;
|
|
11
|
+
logo?: IImageAttributes;
|
|
12
|
+
description?: string;
|
|
13
|
+
background?: IBackgroundAttributes;
|
|
14
|
+
text?: ITextAttributes;
|
|
15
|
+
createdAt: Date;
|
|
16
|
+
lastUpdatedAt: Date;
|
|
17
|
+
}
|
|
18
|
+
interface IImageAttributes {
|
|
19
|
+
id: string;
|
|
20
|
+
uri?: string;
|
|
21
|
+
dataUri?: string;
|
|
22
|
+
mediaType?: string;
|
|
23
|
+
alt?: string;
|
|
24
|
+
dimensions?: IImageDimensions;
|
|
25
|
+
}
|
|
26
|
+
interface IBasicImageAttributes extends Omit<IImageAttributes, 'id' | 'dimensions'> {
|
|
27
|
+
dimensions?: IBasicImageDimensions;
|
|
28
|
+
}
|
|
29
|
+
interface IPartialImageAttributes extends Partial<Omit<IImageAttributes, 'dimensions'>> {
|
|
30
|
+
dimensions?: IPartialImageDimensions;
|
|
31
|
+
}
|
|
32
|
+
interface IBackgroundAttributes {
|
|
33
|
+
id: string;
|
|
34
|
+
color?: string;
|
|
35
|
+
image?: IImageAttributes;
|
|
36
|
+
}
|
|
37
|
+
interface IBasicBackgroundAttributes extends Omit<IBackgroundAttributes, 'id' | 'image'> {
|
|
38
|
+
image?: IBasicImageAttributes;
|
|
39
|
+
}
|
|
40
|
+
interface IPartialBackgroundAttributes extends Partial<Omit<IBackgroundAttributes, 'image'>> {
|
|
41
|
+
image?: IPartialImageAttributes;
|
|
42
|
+
}
|
|
43
|
+
interface ITextAttributes {
|
|
44
|
+
id: string;
|
|
45
|
+
color?: string;
|
|
46
|
+
}
|
|
47
|
+
interface IBasicTextAttributes extends Omit<ITextAttributes, 'id'> {
|
|
48
|
+
}
|
|
49
|
+
interface IPartialTextAttributes extends Partial<ITextAttributes> {
|
|
50
|
+
}
|
|
51
|
+
interface IImageDimensions {
|
|
52
|
+
id: string;
|
|
53
|
+
width: number;
|
|
54
|
+
height: number;
|
|
55
|
+
}
|
|
56
|
+
interface IBasicImageDimensions extends Omit<IImageDimensions, 'id'> {
|
|
57
|
+
}
|
|
58
|
+
interface IPartialImageDimensions extends Partial<IImageDimensions> {
|
|
59
|
+
}
|
|
60
|
+
interface ICredentialClaim {
|
|
61
|
+
id: string;
|
|
62
|
+
key: string;
|
|
63
|
+
name: string;
|
|
64
|
+
}
|
|
65
|
+
interface IBasicCredentialClaim extends Omit<ICredentialClaim, 'id'> {
|
|
66
|
+
}
|
|
67
|
+
interface IPartialCredentialClaim extends Partial<ICredentialClaim> {
|
|
68
|
+
}
|
|
69
|
+
interface ICredentialLocaleBranding extends ILocaleBranding {
|
|
70
|
+
claims?: Array<ICredentialClaim>;
|
|
71
|
+
}
|
|
72
|
+
interface IBasicCredentialLocaleBranding extends Omit<ICredentialLocaleBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'logo' | 'background' | 'text' | 'claims'> {
|
|
73
|
+
logo?: IBasicImageAttributes;
|
|
74
|
+
background?: IBasicBackgroundAttributes;
|
|
75
|
+
text?: IBasicTextAttributes;
|
|
76
|
+
claims?: Array<IBasicCredentialClaim>;
|
|
77
|
+
}
|
|
78
|
+
interface IPartialCredentialLocaleBranding extends Partial<Omit<ICredentialLocaleBranding, 'logo' | 'background' | 'text' | 'claims'>> {
|
|
79
|
+
logo?: IPartialImageAttributes;
|
|
80
|
+
background?: IPartialBackgroundAttributes;
|
|
81
|
+
text?: IPartialTextAttributes;
|
|
82
|
+
claims?: IPartialCredentialClaim;
|
|
83
|
+
}
|
|
84
|
+
interface ICredentialBranding {
|
|
85
|
+
id: string;
|
|
86
|
+
issuerCorrelationId: string;
|
|
87
|
+
vcHash: string;
|
|
88
|
+
localeBranding: Array<ICredentialLocaleBranding>;
|
|
89
|
+
createdAt: Date;
|
|
90
|
+
lastUpdatedAt: Date;
|
|
91
|
+
}
|
|
92
|
+
interface IBasicCredentialBranding extends Omit<ICredentialBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'localeBranding'> {
|
|
93
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>;
|
|
94
|
+
}
|
|
95
|
+
interface IPartialCredentialBranding extends Partial<Omit<ICredentialBranding, 'localeBranding'>> {
|
|
96
|
+
localeBranding?: IPartialCredentialLocaleBranding;
|
|
97
|
+
}
|
|
98
|
+
interface IIssuerLocaleBranding extends ILocaleBranding {
|
|
99
|
+
clientUri?: string;
|
|
100
|
+
tosUri?: string;
|
|
101
|
+
policyUri?: string;
|
|
102
|
+
contacts?: Array<string>;
|
|
103
|
+
}
|
|
104
|
+
interface IBasicIssuerLocaleBranding extends Omit<IIssuerLocaleBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'logo' | 'background' | 'text'> {
|
|
105
|
+
logo?: IBasicImageAttributes;
|
|
106
|
+
background?: IBasicBackgroundAttributes;
|
|
107
|
+
text?: IBasicTextAttributes;
|
|
108
|
+
}
|
|
109
|
+
interface IPartialIssuerLocaleBranding extends Partial<Omit<IIssuerLocaleBranding, 'logo' | 'background' | 'text' | 'contacts'>> {
|
|
110
|
+
logo?: IPartialImageAttributes;
|
|
111
|
+
background?: IPartialBackgroundAttributes;
|
|
112
|
+
text?: IPartialTextAttributes;
|
|
113
|
+
contacts?: string;
|
|
114
|
+
}
|
|
115
|
+
interface IIssuerBranding {
|
|
116
|
+
id: string;
|
|
117
|
+
issuerCorrelationId: string;
|
|
118
|
+
localeBranding: Array<IIssuerLocaleBranding>;
|
|
119
|
+
createdAt: Date;
|
|
120
|
+
lastUpdatedAt: Date;
|
|
121
|
+
}
|
|
122
|
+
interface IBasicIssuerBranding extends Omit<IIssuerBranding, 'id' | 'createdAt' | 'lastUpdatedAt' | 'localeBranding'> {
|
|
123
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>;
|
|
124
|
+
}
|
|
125
|
+
interface IPartialIssuerBranding extends Partial<Omit<IIssuerBranding, 'localeBranding'>> {
|
|
126
|
+
localeBranding?: IPartialIssuerLocaleBranding;
|
|
127
|
+
}
|
|
128
|
+
interface ICredentialBrandingFilter extends IPartialCredentialBranding {
|
|
129
|
+
}
|
|
130
|
+
interface ICredentialLocaleBrandingFilter extends IPartialCredentialLocaleBranding {
|
|
131
|
+
credentialBranding?: IPartialCredentialBranding;
|
|
132
|
+
}
|
|
133
|
+
interface IIssuerBrandingFilter extends IPartialIssuerBranding {
|
|
134
|
+
}
|
|
135
|
+
interface IIssuerLocaleBrandingFilter extends IPartialIssuerLocaleBranding {
|
|
136
|
+
issuerBranding?: IPartialIssuerBranding;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
type FindCredentialBrandingArgs = Array<ICredentialBrandingFilter>;
|
|
140
|
+
type FindCredentialLocaleBrandingArgs = Array<ICredentialLocaleBrandingFilter>;
|
|
141
|
+
type FindIssuerBrandingArgs = Array<IIssuerBrandingFilter>;
|
|
142
|
+
type FindIssuerLocaleBrandingArgs = Array<IIssuerLocaleBrandingFilter>;
|
|
143
|
+
interface IAddCredentialBrandingArgs {
|
|
144
|
+
vcHash: string;
|
|
145
|
+
issuerCorrelationId: string;
|
|
146
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>;
|
|
147
|
+
}
|
|
148
|
+
interface IGetCredentialBrandingArgs {
|
|
149
|
+
filter?: FindCredentialBrandingArgs;
|
|
150
|
+
}
|
|
151
|
+
interface IUpdateCredentialBrandingArgs {
|
|
152
|
+
credentialBranding: Omit<ICredentialBranding, 'localeBranding' | 'createdAt' | 'lastUpdatedAt'>;
|
|
153
|
+
}
|
|
154
|
+
interface IRemoveCredentialBrandingArgs {
|
|
155
|
+
filter: FindCredentialBrandingArgs;
|
|
156
|
+
}
|
|
157
|
+
interface IAddCredentialLocaleBrandingArgs {
|
|
158
|
+
credentialBrandingId: string;
|
|
159
|
+
localeBranding: Array<IBasicCredentialLocaleBranding>;
|
|
160
|
+
}
|
|
161
|
+
interface IUpdateCredentialLocaleBrandingArgs {
|
|
162
|
+
localeBranding: Omit<ILocaleBranding, 'createdAt' | 'lastUpdatedAt'>;
|
|
163
|
+
}
|
|
164
|
+
interface IRemoveCredentialLocaleBrandingArgs {
|
|
165
|
+
filter: FindCredentialLocaleBrandingArgs;
|
|
166
|
+
}
|
|
167
|
+
interface IGetCredentialLocaleBrandingArgs {
|
|
168
|
+
filter?: FindCredentialLocaleBrandingArgs;
|
|
169
|
+
}
|
|
170
|
+
interface IAddIssuerBrandingArgs {
|
|
171
|
+
issuerCorrelationId: string;
|
|
172
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>;
|
|
173
|
+
}
|
|
174
|
+
interface IGetIssuerBrandingArgs {
|
|
175
|
+
filter?: FindIssuerBrandingArgs;
|
|
176
|
+
}
|
|
177
|
+
interface IUpdateIssuerBrandingArgs {
|
|
178
|
+
issuerBranding: Omit<IIssuerBranding, 'localeBranding' | 'createdAt' | 'lastUpdatedAt'>;
|
|
179
|
+
}
|
|
180
|
+
interface IRemoveIssuerBrandingArgs {
|
|
181
|
+
filter: FindIssuerBrandingArgs;
|
|
182
|
+
}
|
|
183
|
+
interface IAddIssuerLocaleBrandingArgs {
|
|
184
|
+
issuerBrandingId: string;
|
|
185
|
+
localeBranding: Array<IBasicIssuerLocaleBranding>;
|
|
186
|
+
}
|
|
187
|
+
interface IUpdateIssuerLocaleBrandingArgs {
|
|
188
|
+
localeBranding: Omit<ILocaleBranding, 'createdAt' | 'lastUpdatedAt'>;
|
|
189
|
+
}
|
|
190
|
+
interface IRemoveIssuerLocaleBrandingArgs {
|
|
191
|
+
filter: FindIssuerLocaleBrandingArgs;
|
|
192
|
+
}
|
|
193
|
+
interface IGetIssuerLocaleBrandingArgs {
|
|
194
|
+
filter?: FindIssuerLocaleBrandingArgs;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
type MetadataTypes = string | number | Date | boolean | undefined;
|
|
198
|
+
interface IMetadataEntity {
|
|
199
|
+
label: string;
|
|
200
|
+
stringValue?: string;
|
|
201
|
+
numberValue?: number;
|
|
202
|
+
dateValue?: Date;
|
|
203
|
+
boolValue?: boolean;
|
|
204
|
+
}
|
|
205
|
+
type Party = {
|
|
206
|
+
id: string;
|
|
207
|
+
uri?: string;
|
|
208
|
+
roles: Array<CredentialRole>;
|
|
209
|
+
ownerId?: string;
|
|
210
|
+
tenantId?: string;
|
|
211
|
+
identities: Array<Identity>;
|
|
212
|
+
electronicAddresses: Array<ElectronicAddress>;
|
|
213
|
+
physicalAddresses: Array<PhysicalAddress>;
|
|
214
|
+
contact: Contact;
|
|
215
|
+
partyType: PartyType;
|
|
216
|
+
/**
|
|
217
|
+
* TODO: Integrate branding logic here in the future. What we should do is make the issuance branding plugin part of the contact-manager and retrieve any branding there is.
|
|
218
|
+
*
|
|
219
|
+
* Currently, we are only defining the branding type within the SDK without implementing the associated logic. This is because:
|
|
220
|
+
* 1. We are combining two types from the SSI-SDK to create a new type that will be used across multiple places in the wallets (web & mobile).
|
|
221
|
+
* 2. While it makes sense to have this combined type in the SDK, the logic to support database connections for these types is complex. The types belong to different modules, and we don't use them together currently.
|
|
222
|
+
* 3. Implementing the full logic now would require significant changes and cross-module interactions, which we don't have the time to address at present.
|
|
223
|
+
*
|
|
224
|
+
* For now, we are defining the type here and will use it in the mobile wallet has the logic for it. This is a temporary solution until we have the resources to integrate the branding logic fully.
|
|
225
|
+
*/
|
|
226
|
+
branding?: IIssuerLocaleBranding;
|
|
227
|
+
relationships: Array<PartyRelationship>;
|
|
228
|
+
createdAt: Date;
|
|
229
|
+
lastUpdatedAt: Date;
|
|
230
|
+
};
|
|
231
|
+
type NonPersistedParty = Omit<Party, 'id' | 'identities' | 'electronicAddresses' | 'physicalAddresses' | 'contact' | 'roles' | 'partyType' | 'relationships' | 'createdAt' | 'lastUpdatedAt'> & {
|
|
232
|
+
identities?: Array<NonPersistedIdentity>;
|
|
233
|
+
electronicAddresses?: Array<NonPersistedElectronicAddress>;
|
|
234
|
+
physicalAddresses?: Array<NonPersistedPhysicalAddress>;
|
|
235
|
+
contact: NonPersistedContact;
|
|
236
|
+
partyType: NonPersistedPartyType;
|
|
237
|
+
relationships?: Array<NonPersistedPartyRelationship>;
|
|
238
|
+
};
|
|
239
|
+
type PartialParty = Partial<Omit<Party, 'identities' | 'electronicAddresses' | 'physicalAddresses' | 'contact' | 'partyType' | 'relationships'>> & {
|
|
240
|
+
identities?: PartialIdentity;
|
|
241
|
+
electronicAddresses?: PartialElectronicAddress;
|
|
242
|
+
physicalAddresses?: PartialPhysicalAddress;
|
|
243
|
+
contact?: PartialContact;
|
|
244
|
+
partyType?: PartialPartyType;
|
|
245
|
+
relationships?: PartialPartyRelationship;
|
|
246
|
+
};
|
|
247
|
+
type Identity = {
|
|
248
|
+
id: string;
|
|
249
|
+
alias: string;
|
|
250
|
+
ownerId?: string;
|
|
251
|
+
tenantId?: string;
|
|
252
|
+
origin: IdentityOrigin;
|
|
253
|
+
roles: Array<CredentialRole>;
|
|
254
|
+
identifier: CorrelationIdentifier;
|
|
255
|
+
connection?: Connection;
|
|
256
|
+
metadata?: Array<MetadataItem<MetadataTypes>>;
|
|
257
|
+
createdAt: Date;
|
|
258
|
+
lastUpdatedAt: Date;
|
|
259
|
+
};
|
|
260
|
+
type NonPersistedIdentity = Omit<Identity, 'id' | 'identifier' | 'connection' | 'metadata' | 'origin' | 'createdAt' | 'lastUpdatedAt'> & {
|
|
261
|
+
origin: IdentityOrigin;
|
|
262
|
+
identifier: NonPersistedCorrelationIdentifier;
|
|
263
|
+
connection?: NonPersistedConnection;
|
|
264
|
+
metadata?: Array<NonPersistedMetadataItem<MetadataTypes>>;
|
|
265
|
+
};
|
|
266
|
+
type PartialIdentity = Partial<Omit<Identity, 'identifier' | 'connection' | 'metadata' | 'origin' | 'roles'>> & {
|
|
267
|
+
identifier?: PartialCorrelationIdentifier;
|
|
268
|
+
connection?: PartialConnection;
|
|
269
|
+
metadata?: PartialMetadataItem<MetadataTypes>;
|
|
270
|
+
origin?: IdentityOrigin;
|
|
271
|
+
roles?: CredentialRole;
|
|
272
|
+
partyId?: string;
|
|
273
|
+
};
|
|
274
|
+
type MetadataItem<T extends MetadataTypes> = {
|
|
275
|
+
id: string;
|
|
276
|
+
label: string;
|
|
277
|
+
value: T;
|
|
278
|
+
};
|
|
279
|
+
type NonPersistedMetadataItem<T extends MetadataTypes> = Omit<MetadataItem<T>, 'id'>;
|
|
280
|
+
type PartialMetadataItem<T extends MetadataTypes> = Partial<MetadataItem<T>>;
|
|
281
|
+
type CorrelationIdentifier = {
|
|
282
|
+
id: string;
|
|
283
|
+
ownerId?: string;
|
|
284
|
+
tenantId?: string;
|
|
285
|
+
type: CorrelationIdentifierType;
|
|
286
|
+
correlationId: string;
|
|
287
|
+
};
|
|
288
|
+
type NonPersistedCorrelationIdentifier = Omit<CorrelationIdentifier, 'id'>;
|
|
289
|
+
type PartialCorrelationIdentifier = Partial<CorrelationIdentifier>;
|
|
290
|
+
type Connection = {
|
|
291
|
+
id: string;
|
|
292
|
+
ownerId?: string;
|
|
293
|
+
tenantId?: string;
|
|
294
|
+
type: ConnectionType;
|
|
295
|
+
config: ConnectionConfig;
|
|
296
|
+
};
|
|
297
|
+
type NonPersistedConnection = Omit<Connection, 'id' | 'config'> & {
|
|
298
|
+
config: NonPersistedConnectionConfig;
|
|
299
|
+
};
|
|
300
|
+
type PartialConnection = Partial<Omit<Connection, 'config'>> & {
|
|
301
|
+
config: PartialConnectionConfig;
|
|
302
|
+
};
|
|
303
|
+
type OpenIdConfig = {
|
|
304
|
+
id: string;
|
|
305
|
+
clientId: string;
|
|
306
|
+
clientSecret: string;
|
|
307
|
+
ownerId?: string;
|
|
308
|
+
tenantId?: string;
|
|
309
|
+
scopes: Array<string>;
|
|
310
|
+
issuer: string;
|
|
311
|
+
redirectUrl: string;
|
|
312
|
+
dangerouslyAllowInsecureHttpRequests: boolean;
|
|
313
|
+
clientAuthMethod: 'basic' | 'post' | undefined;
|
|
314
|
+
};
|
|
315
|
+
type NonPersistedOpenIdConfig = Omit<OpenIdConfig, 'id'>;
|
|
316
|
+
type PartialOpenIdConfig = Partial<OpenIdConfig>;
|
|
317
|
+
type DidAuthConfig = {
|
|
318
|
+
id: string;
|
|
319
|
+
idOpts: ManagedIdentifierOptsOrResult;
|
|
320
|
+
stateId: string;
|
|
321
|
+
ownerId?: string;
|
|
322
|
+
tenantId?: string;
|
|
323
|
+
redirectUrl: string;
|
|
324
|
+
sessionId: string;
|
|
325
|
+
};
|
|
326
|
+
type NonPersistedDidAuthConfig = Omit<DidAuthConfig, 'id'>;
|
|
327
|
+
type PartialDidAuthConfig = Partial<Omit<DidAuthConfig, 'identifier'>> & {
|
|
328
|
+
identifier: Partial<IIdentifier>;
|
|
329
|
+
};
|
|
330
|
+
type ConnectionConfig = OpenIdConfig | DidAuthConfig;
|
|
331
|
+
type NonPersistedConnectionConfig = NonPersistedDidAuthConfig | NonPersistedOpenIdConfig;
|
|
332
|
+
type PartialConnectionConfig = PartialOpenIdConfig | PartialDidAuthConfig;
|
|
333
|
+
type NaturalPerson = {
|
|
334
|
+
id: string;
|
|
335
|
+
firstName: string;
|
|
336
|
+
lastName: string;
|
|
337
|
+
middleName?: string;
|
|
338
|
+
displayName: string;
|
|
339
|
+
metadata?: Array<MetadataItem<MetadataTypes>>;
|
|
340
|
+
ownerId?: string;
|
|
341
|
+
tenantId?: string;
|
|
342
|
+
createdAt: Date;
|
|
343
|
+
lastUpdatedAt: Date;
|
|
344
|
+
};
|
|
345
|
+
type NonPersistedNaturalPerson = Omit<NaturalPerson, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
346
|
+
type PartialNaturalPerson = Partial<Omit<NaturalPerson, 'metadata'>> & {
|
|
347
|
+
metadata?: PartialMetadataItem<MetadataTypes>;
|
|
348
|
+
};
|
|
349
|
+
type Organization = {
|
|
350
|
+
id: string;
|
|
351
|
+
legalName: string;
|
|
352
|
+
displayName: string;
|
|
353
|
+
metadata?: Array<MetadataItem<MetadataTypes>>;
|
|
354
|
+
ownerId?: string;
|
|
355
|
+
tenantId?: string;
|
|
356
|
+
createdAt: Date;
|
|
357
|
+
lastUpdatedAt: Date;
|
|
358
|
+
};
|
|
359
|
+
type NonPersistedOrganization = Omit<Organization, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
360
|
+
type PartialOrganization = Partial<Omit<Organization, 'metadata'>> & {
|
|
361
|
+
metadata?: PartialMetadataItem<MetadataTypes>;
|
|
362
|
+
};
|
|
363
|
+
type Contact = NaturalPerson | Organization;
|
|
364
|
+
type NonPersistedContact = NonPersistedNaturalPerson | NonPersistedOrganization;
|
|
365
|
+
type PartialContact = PartialNaturalPerson | PartialOrganization;
|
|
366
|
+
type PartyType = {
|
|
367
|
+
id: string;
|
|
368
|
+
type: PartyTypeType;
|
|
369
|
+
origin: PartyOrigin;
|
|
370
|
+
name: string;
|
|
371
|
+
tenantId: string;
|
|
372
|
+
description?: string;
|
|
373
|
+
createdAt: Date;
|
|
374
|
+
lastUpdatedAt: Date;
|
|
375
|
+
};
|
|
376
|
+
type NonPersistedPartyType = Omit<PartyType, 'id' | 'createdAt' | 'lastUpdatedAt'> & {
|
|
377
|
+
id?: string;
|
|
378
|
+
};
|
|
379
|
+
type PartialPartyType = Partial<PartyType>;
|
|
380
|
+
type PartyRelationship = {
|
|
381
|
+
id: string;
|
|
382
|
+
leftId: string;
|
|
383
|
+
rightId: string;
|
|
384
|
+
ownerId?: string;
|
|
385
|
+
tenantId?: string;
|
|
386
|
+
createdAt: Date;
|
|
387
|
+
lastUpdatedAt: Date;
|
|
388
|
+
};
|
|
389
|
+
type NonPersistedPartyRelationship = Omit<PartyRelationship, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
390
|
+
type PartialPartyRelationship = Partial<PartyRelationship>;
|
|
391
|
+
type ElectronicAddress = {
|
|
392
|
+
id: string;
|
|
393
|
+
type: ElectronicAddressType;
|
|
394
|
+
electronicAddress: string;
|
|
395
|
+
ownerId?: string;
|
|
396
|
+
tenantId?: string;
|
|
397
|
+
createdAt: Date;
|
|
398
|
+
lastUpdatedAt: Date;
|
|
399
|
+
};
|
|
400
|
+
type NonPersistedElectronicAddress = Omit<ElectronicAddress, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
401
|
+
type PartialElectronicAddress = Partial<ElectronicAddress> & {
|
|
402
|
+
partyId?: string;
|
|
403
|
+
};
|
|
404
|
+
type PhysicalAddress = {
|
|
405
|
+
id: string;
|
|
406
|
+
type: PhysicalAddressType;
|
|
407
|
+
streetName: string;
|
|
408
|
+
streetNumber: string;
|
|
409
|
+
postalCode: string;
|
|
410
|
+
cityName: string;
|
|
411
|
+
provinceName: string;
|
|
412
|
+
countryCode: string;
|
|
413
|
+
buildingName?: string;
|
|
414
|
+
ownerId?: string;
|
|
415
|
+
tenantId?: string;
|
|
416
|
+
createdAt: Date;
|
|
417
|
+
lastUpdatedAt: Date;
|
|
418
|
+
};
|
|
419
|
+
type NonPersistedPhysicalAddress = Omit<PhysicalAddress, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
420
|
+
type PartialPhysicalAddress = Partial<PhysicalAddress> & {
|
|
421
|
+
partyId?: string;
|
|
422
|
+
};
|
|
423
|
+
type ElectronicAddressType = 'email' | 'phone';
|
|
424
|
+
type PhysicalAddressType = 'home' | 'visit' | 'postal';
|
|
425
|
+
declare enum ConnectionType {
|
|
426
|
+
OPENID_CONNECT = "OIDC",
|
|
427
|
+
SIOPv2 = "SIOPv2",
|
|
428
|
+
SIOPv2_OpenID4VP = "SIOPv2+OpenID4VP"
|
|
429
|
+
}
|
|
430
|
+
declare enum CorrelationIdentifierType {
|
|
431
|
+
DID = "did",
|
|
432
|
+
URL = "url"
|
|
433
|
+
}
|
|
434
|
+
declare enum PartyTypeType {
|
|
435
|
+
NATURAL_PERSON = "naturalPerson",
|
|
436
|
+
ORGANIZATION = "organization"
|
|
437
|
+
}
|
|
438
|
+
declare enum PartyOrigin {
|
|
439
|
+
INTERNAL = "INTERNAL",
|
|
440
|
+
EXTERNAL = "EXTERNAL"
|
|
441
|
+
}
|
|
442
|
+
declare enum IdentityOrigin {
|
|
443
|
+
INTERNAL = "INTERNAL",
|
|
444
|
+
EXTERNAL = "EXTERNAL"
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
type FindPartyArgs = Array<PartialParty>;
|
|
448
|
+
type FindIdentityArgs = Array<PartialIdentity>;
|
|
449
|
+
type FindPartyTypeArgs = Array<PartialPartyType>;
|
|
450
|
+
type FindRelationshipArgs = Array<PartialPartyRelationship>;
|
|
451
|
+
type FindElectronicAddressArgs = Array<PartialElectronicAddress>;
|
|
452
|
+
type FindPhysicalAddressArgs = Array<PartialPhysicalAddress>;
|
|
453
|
+
type GetPartyArgs = {
|
|
454
|
+
partyId: string;
|
|
455
|
+
};
|
|
456
|
+
type GetPartiesArgs = {
|
|
457
|
+
filter?: FindPartyArgs;
|
|
458
|
+
};
|
|
459
|
+
type AddPartyArgs = {
|
|
460
|
+
uri?: string;
|
|
461
|
+
partyType: NonPersistedPartyType;
|
|
462
|
+
contact: NonPersistedContact;
|
|
463
|
+
identities?: Array<NonPersistedIdentity>;
|
|
464
|
+
electronicAddresses?: Array<NonPersistedElectronicAddress>;
|
|
465
|
+
physicalAddresses?: Array<NonPersistedPhysicalAddress>;
|
|
466
|
+
};
|
|
467
|
+
type UpdatePartyArgs = {
|
|
468
|
+
party: Omit<Party, 'identities' | 'electronicAddresses' | 'partyType' | 'createdAt' | 'lastUpdatedAt'>;
|
|
469
|
+
};
|
|
470
|
+
type RemovePartyArgs = {
|
|
471
|
+
partyId: string;
|
|
472
|
+
};
|
|
473
|
+
type GetIdentityArgs = {
|
|
474
|
+
identityId: string;
|
|
475
|
+
};
|
|
476
|
+
type GetIdentitiesArgs = {
|
|
477
|
+
filter?: FindIdentityArgs;
|
|
478
|
+
};
|
|
479
|
+
type AddIdentityArgs = {
|
|
480
|
+
partyId: string;
|
|
481
|
+
identity: NonPersistedIdentity;
|
|
482
|
+
};
|
|
483
|
+
type UpdateIdentityArgs = {
|
|
484
|
+
identity: Identity;
|
|
485
|
+
};
|
|
486
|
+
type RemoveIdentityArgs = {
|
|
487
|
+
identityId: string;
|
|
488
|
+
};
|
|
489
|
+
type RemoveRelationshipArgs = {
|
|
490
|
+
relationshipId: string;
|
|
491
|
+
};
|
|
492
|
+
type AddRelationshipArgs = {
|
|
493
|
+
leftId: string;
|
|
494
|
+
rightId: string;
|
|
495
|
+
};
|
|
496
|
+
type GetRelationshipArgs = {
|
|
497
|
+
relationshipId: string;
|
|
498
|
+
};
|
|
499
|
+
type GetRelationshipsArgs = {
|
|
500
|
+
filter: FindRelationshipArgs;
|
|
501
|
+
};
|
|
502
|
+
type UpdateRelationshipArgs = {
|
|
503
|
+
relationship: Omit<PartyRelationship, 'createdAt' | 'lastUpdatedAt'>;
|
|
504
|
+
};
|
|
505
|
+
type AddPartyTypeArgs = {
|
|
506
|
+
type: PartyTypeType;
|
|
507
|
+
origin: PartyOrigin;
|
|
508
|
+
name: string;
|
|
509
|
+
tenantId: string;
|
|
510
|
+
description?: string;
|
|
511
|
+
};
|
|
512
|
+
type GetPartyTypeArgs = {
|
|
513
|
+
partyTypeId: string;
|
|
514
|
+
};
|
|
515
|
+
type GetPartyTypesArgs = {
|
|
516
|
+
filter?: FindPartyTypeArgs;
|
|
517
|
+
};
|
|
518
|
+
type UpdatePartyTypeArgs = {
|
|
519
|
+
partyType: Omit<PartyType, 'createdAt' | 'lastUpdatedAt'>;
|
|
520
|
+
};
|
|
521
|
+
type RemovePartyTypeArgs = {
|
|
522
|
+
partyTypeId: string;
|
|
523
|
+
};
|
|
524
|
+
type GetElectronicAddressArgs = {
|
|
525
|
+
electronicAddressId: string;
|
|
526
|
+
};
|
|
527
|
+
type GetElectronicAddressesArgs = {
|
|
528
|
+
filter?: FindElectronicAddressArgs;
|
|
529
|
+
};
|
|
530
|
+
type AddElectronicAddressArgs = {
|
|
531
|
+
partyId: string;
|
|
532
|
+
electronicAddress: NonPersistedElectronicAddress;
|
|
533
|
+
};
|
|
534
|
+
type UpdateElectronicAddressArgs = {
|
|
535
|
+
electronicAddress: ElectronicAddress;
|
|
536
|
+
};
|
|
537
|
+
type RemoveElectronicAddressArgs = {
|
|
538
|
+
electronicAddressId: string;
|
|
539
|
+
};
|
|
540
|
+
type GetPhysicalAddressArgs = {
|
|
541
|
+
physicalAddressId: string;
|
|
542
|
+
};
|
|
543
|
+
type GetPhysicalAddressesArgs = {
|
|
544
|
+
filter?: FindPhysicalAddressArgs;
|
|
545
|
+
};
|
|
546
|
+
type AddPhysicalAddressArgs = {
|
|
547
|
+
partyId: string;
|
|
548
|
+
physicalAddress: NonPersistedPhysicalAddress;
|
|
549
|
+
};
|
|
550
|
+
type UpdatePhysicalAddressArgs = {
|
|
551
|
+
physicalAddress: PhysicalAddress;
|
|
552
|
+
};
|
|
553
|
+
type RemovePhysicalAddressArgs = {
|
|
554
|
+
physicalAddressId: string;
|
|
555
|
+
};
|
|
556
|
+
|
|
557
|
+
type DcqlQueryItem = {
|
|
558
|
+
id: string;
|
|
559
|
+
queryId: string;
|
|
560
|
+
tenantId?: string;
|
|
561
|
+
version: string;
|
|
562
|
+
name?: string;
|
|
563
|
+
purpose?: string;
|
|
564
|
+
query: DcqlQuery;
|
|
565
|
+
createdAt: Date;
|
|
566
|
+
lastUpdatedAt: Date;
|
|
567
|
+
};
|
|
568
|
+
type ImportDcqlQueryItem = Omit<DcqlQueryItem, 'id' | 'tenantId' | 'version' | 'createdAt' | 'lastUpdatedAt'>;
|
|
569
|
+
type NonPersistedDcqlQueryItem = Omit<DcqlQueryItem, 'id' | 'createdAt' | 'lastUpdatedAt'>;
|
|
570
|
+
type PartialDcqlQueryItem = Partial<DcqlQueryItem>;
|
|
571
|
+
type DcqlQueryItemFilter = Partial<Omit<DcqlQueryItem, 'query'>>;
|
|
572
|
+
|
|
573
|
+
type FindDcqlQueryArgs = Array<DcqlQueryItemFilter>;
|
|
574
|
+
type GetDefinitionArgs = {
|
|
575
|
+
itemId: string;
|
|
576
|
+
};
|
|
577
|
+
type HasDefinitionArgs = GetDefinitionArgs;
|
|
578
|
+
type GetDefinitionsArgs = {
|
|
579
|
+
filter?: FindDcqlQueryArgs;
|
|
580
|
+
};
|
|
581
|
+
type HasDefinitionsArgs = GetDefinitionsArgs;
|
|
582
|
+
type AddDefinitionArgs = NonPersistedDcqlQueryItem;
|
|
583
|
+
type UpdateDefinitionArgs = DcqlQueryItem;
|
|
584
|
+
type DeleteDefinitionArgs = {
|
|
585
|
+
itemId: string;
|
|
586
|
+
};
|
|
587
|
+
type DeleteDefinitionsArgs = GetDefinitionsArgs;
|
|
588
|
+
|
|
589
|
+
type ValidationConstraint = {
|
|
590
|
+
[x: string]: string;
|
|
591
|
+
};
|
|
592
|
+
|
|
593
|
+
type NonPersistedAuditLoggingEvent = Omit<AuditLoggingEvent, 'id' | 'type'>;
|
|
594
|
+
type NonPersistedActivityLoggingEvent = Omit<ActivityLoggingEvent, 'id' | 'type'>;
|
|
595
|
+
|
|
596
|
+
type FindAuditLoggingEventArgs = Array<PartialAuditLoggingEvent>;
|
|
597
|
+
type FindActivityLoggingEventArgs = Array<PartialActivityLoggingEvent>;
|
|
598
|
+
type StoreAuditEventArgs = {
|
|
599
|
+
event: NonPersistedAuditLoggingEvent;
|
|
600
|
+
};
|
|
601
|
+
type StoreActivityEventArgs = {
|
|
602
|
+
event: NonPersistedActivityLoggingEvent;
|
|
603
|
+
};
|
|
604
|
+
type GetAuditEventsArgs = {
|
|
605
|
+
filter?: FindAuditLoggingEventArgs;
|
|
606
|
+
};
|
|
607
|
+
type GetActivityEventsArgs = {
|
|
608
|
+
filter?: FindActivityLoggingEventArgs;
|
|
609
|
+
};
|
|
610
|
+
|
|
611
|
+
type StoreMachineStatePersistArgs = Omit<StoreMachineStateInfo, 'createdAt' | 'updatedAt'>;
|
|
612
|
+
type StoreMachineStatesFindActiveArgs = Partial<Pick<StoreMachineStateInfo, 'machineName' | 'tenantId' | 'instanceId'>>;
|
|
613
|
+
type FindMachineStatesFilterArgs = Array<Partial<Omit<StoreMachineStateInfo, 'state'>>>;
|
|
614
|
+
type StoreFindMachineStatesArgs = {
|
|
615
|
+
filter: FindMachineStatesFilterArgs;
|
|
616
|
+
};
|
|
617
|
+
type StoreMachineStateGetArgs = Pick<StoreMachineStateInfo, 'instanceId' | 'tenantId'>;
|
|
618
|
+
type StoreMachineStateDeleteArgs = StoreMachineStateGetArgs;
|
|
619
|
+
type StoreMachineStateDeleteExpiredArgs = {
|
|
620
|
+
machineName?: string;
|
|
621
|
+
tenantId?: string;
|
|
622
|
+
deleteDoneStates?: boolean;
|
|
623
|
+
};
|
|
624
|
+
interface StoreMachineStateInfo {
|
|
625
|
+
/**
|
|
626
|
+
* Unique instance ID of the machine
|
|
627
|
+
*/
|
|
628
|
+
instanceId: string;
|
|
629
|
+
/**
|
|
630
|
+
* Session Id of the machine. Not necessarily unique
|
|
631
|
+
*/
|
|
632
|
+
sessionId?: string;
|
|
633
|
+
/**
|
|
634
|
+
* Machine name
|
|
635
|
+
*/
|
|
636
|
+
machineName: string;
|
|
637
|
+
/**
|
|
638
|
+
* The latest state name. Can be empty for a newly initialize machine
|
|
639
|
+
*/
|
|
640
|
+
latestStateName?: string;
|
|
641
|
+
/**
|
|
642
|
+
* event types like SET_TOC, SET_FIRSTNAME, .... Will be xstate.init on a newly initialized machine
|
|
643
|
+
*/
|
|
644
|
+
latestEventType: string;
|
|
645
|
+
/**
|
|
646
|
+
* Serialized Machine state
|
|
647
|
+
*/
|
|
648
|
+
state: string;
|
|
649
|
+
/**
|
|
650
|
+
* Represents the creation date
|
|
651
|
+
*/
|
|
652
|
+
createdAt: Date;
|
|
653
|
+
/**
|
|
654
|
+
* Represents the expiration date
|
|
655
|
+
*/
|
|
656
|
+
expiresAt?: Date;
|
|
657
|
+
/**
|
|
658
|
+
* Represents the update date
|
|
659
|
+
*/
|
|
660
|
+
updatedAt: Date;
|
|
661
|
+
/**
|
|
662
|
+
* Represents a counter for tracking updates.
|
|
663
|
+
*/
|
|
664
|
+
updatedCount: number;
|
|
665
|
+
completedAt?: Date;
|
|
666
|
+
tenantId?: string;
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
declare enum DocumentType {
|
|
670
|
+
VC = "VC",
|
|
671
|
+
VP = "VP",
|
|
672
|
+
P = "P",
|
|
673
|
+
C = "C"
|
|
674
|
+
}
|
|
675
|
+
declare enum RegulationType {
|
|
676
|
+
PID = "PID",
|
|
677
|
+
QEAA = "QEAA",
|
|
678
|
+
EAA = "EAA",
|
|
679
|
+
NON_REGULATED = "NON_REGULATED"
|
|
680
|
+
}
|
|
681
|
+
declare enum CredentialDocumentFormat {
|
|
682
|
+
JSON_LD = "JSON_LD",
|
|
683
|
+
JWT = "JWT",
|
|
684
|
+
SD_JWT = "SD_JWT",
|
|
685
|
+
MSO_MDOC = "MSO_MDOC"
|
|
686
|
+
}
|
|
687
|
+
declare namespace CredentialDocumentFormat {
|
|
688
|
+
function fromSpecValue(credentialFormat: string): CredentialDocumentFormat;
|
|
689
|
+
function toSpecValue(documentFormat: CredentialDocumentFormat, documentType: DocumentType): "mso_mdoc" | "dc+sd-jwt" | "jwt_vc_json" | "ldp_vc" | "ldp_vp" | "jwt_vp_json";
|
|
690
|
+
}
|
|
691
|
+
declare enum CredentialCorrelationType {
|
|
692
|
+
DID = "DID",
|
|
693
|
+
X509_SAN = "X509_SAN",
|
|
694
|
+
KID = "KID",
|
|
695
|
+
URL = "URL"
|
|
696
|
+
}
|
|
697
|
+
declare enum CredentialStateType {
|
|
698
|
+
REVOKED = "REVOKED",
|
|
699
|
+
VERIFIED = "VERIFIED",
|
|
700
|
+
EXPIRED = "EXPIRED"
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
/**
|
|
704
|
+
* DigitalCredential
|
|
705
|
+
*
|
|
706
|
+
* @public
|
|
707
|
+
*/
|
|
708
|
+
type DigitalCredential = {
|
|
709
|
+
id: string;
|
|
710
|
+
parentId?: string;
|
|
711
|
+
documentType: DocumentType;
|
|
712
|
+
documentFormat: CredentialDocumentFormat;
|
|
713
|
+
credentialRole: CredentialRole;
|
|
714
|
+
regulationType: RegulationType;
|
|
715
|
+
rawDocument: string;
|
|
716
|
+
uniformDocument: string;
|
|
717
|
+
credentialId?: string;
|
|
718
|
+
hash: string;
|
|
719
|
+
kmsKeyRef?: string;
|
|
720
|
+
identifierMethod?: string;
|
|
721
|
+
issuerCorrelationType: CredentialCorrelationType;
|
|
722
|
+
subjectCorrelationType?: CredentialCorrelationType;
|
|
723
|
+
rpCorrelationType?: CredentialCorrelationType;
|
|
724
|
+
isIssuerSigned?: boolean;
|
|
725
|
+
issuerCorrelationId: string;
|
|
726
|
+
subjectCorrelationId?: string;
|
|
727
|
+
rpCorrelationId?: string;
|
|
728
|
+
verifiedState?: CredentialStateType;
|
|
729
|
+
tenantId?: string;
|
|
730
|
+
createdAt: Date;
|
|
731
|
+
presentedAt?: Date;
|
|
732
|
+
lastUpdatedAt: Date;
|
|
733
|
+
validUntil?: Date;
|
|
734
|
+
validFrom?: Date;
|
|
735
|
+
verifiedAt?: Date;
|
|
736
|
+
revokedAt?: Date;
|
|
737
|
+
};
|
|
738
|
+
type NonPersistedDigitalCredential = Omit<DigitalCredential, 'id' | 'regulationType'> & {
|
|
739
|
+
regulationType?: RegulationType;
|
|
740
|
+
};
|
|
741
|
+
|
|
742
|
+
type GetCredentialArgs = {
|
|
743
|
+
id: string;
|
|
744
|
+
} | {
|
|
745
|
+
hash: string;
|
|
746
|
+
};
|
|
747
|
+
type FindDigitalCredentialArgs = Array<Partial<DigitalCredential>>;
|
|
748
|
+
type GetCredentialsArgs = {
|
|
749
|
+
filter?: FindDigitalCredentialArgs;
|
|
750
|
+
offset?: number;
|
|
751
|
+
limit?: number;
|
|
752
|
+
order?: string;
|
|
753
|
+
};
|
|
754
|
+
type GetCredentialsResponse = {
|
|
755
|
+
data: Array<DigitalCredential>;
|
|
756
|
+
total: number;
|
|
757
|
+
};
|
|
758
|
+
type AddCredentialArgs = {
|
|
759
|
+
rawDocument: string;
|
|
760
|
+
kmsKeyRef?: string;
|
|
761
|
+
identifierMethod?: string;
|
|
762
|
+
regulationType?: RegulationType;
|
|
763
|
+
parentId?: string;
|
|
764
|
+
issuerCorrelationType: CredentialCorrelationType;
|
|
765
|
+
subjectCorrelationType?: CredentialCorrelationType;
|
|
766
|
+
issuerCorrelationId: string;
|
|
767
|
+
subjectCorrelationId?: string;
|
|
768
|
+
credentialRole: CredentialRole;
|
|
769
|
+
tenantId?: string;
|
|
770
|
+
state?: CredentialStateType;
|
|
771
|
+
verifiedAt?: Date;
|
|
772
|
+
revokedAt?: Date;
|
|
773
|
+
opts?: {
|
|
774
|
+
maxTimeSkewInMS?: number;
|
|
775
|
+
hasher?: HasherSync;
|
|
776
|
+
};
|
|
777
|
+
};
|
|
778
|
+
type UpdateCredentialStateArgs = GetCredentialArgs & {
|
|
779
|
+
verifiedState: CredentialStateType;
|
|
780
|
+
verifiedAt?: Date;
|
|
781
|
+
revokedAt?: Date;
|
|
782
|
+
};
|
|
783
|
+
type RemoveCredentialArgs = GetCredentialArgs;
|
|
784
|
+
|
|
785
|
+
declare abstract class AbstractContactStore {
|
|
786
|
+
abstract getParty(args: GetPartyArgs): Promise<Party>;
|
|
787
|
+
abstract getParties(args?: GetPartiesArgs): Promise<Array<Party>>;
|
|
788
|
+
abstract addParty(args: AddPartyArgs): Promise<Party>;
|
|
789
|
+
abstract updateParty(args: UpdatePartyArgs): Promise<Party>;
|
|
790
|
+
abstract removeParty(args: RemovePartyArgs): Promise<void>;
|
|
791
|
+
abstract getIdentity(args: GetIdentityArgs): Promise<Identity>;
|
|
792
|
+
abstract getIdentities(args?: GetIdentitiesArgs): Promise<Array<Identity>>;
|
|
793
|
+
abstract addIdentity(args: AddIdentityArgs): Promise<Identity>;
|
|
794
|
+
abstract updateIdentity(args: UpdateIdentityArgs): Promise<Identity>;
|
|
795
|
+
abstract removeIdentity(args: RemoveIdentityArgs): Promise<void>;
|
|
796
|
+
abstract getRelationship(args: GetRelationshipArgs): Promise<PartyRelationship>;
|
|
797
|
+
abstract getRelationships(args?: GetRelationshipsArgs): Promise<Array<PartyRelationship>>;
|
|
798
|
+
abstract addRelationship(args: AddRelationshipArgs): Promise<PartyRelationship>;
|
|
799
|
+
abstract updateRelationship(args: UpdateRelationshipArgs): Promise<PartyRelationship>;
|
|
800
|
+
abstract removeRelationship(args: RemoveRelationshipArgs): Promise<void>;
|
|
801
|
+
abstract getPartyType(args: GetPartyTypeArgs): Promise<PartyType>;
|
|
802
|
+
abstract getPartyTypes(args?: GetPartyTypesArgs): Promise<Array<PartyType>>;
|
|
803
|
+
abstract addPartyType(args: AddPartyTypeArgs): Promise<PartyType>;
|
|
804
|
+
abstract updatePartyType(args: UpdatePartyTypeArgs): Promise<PartyType>;
|
|
805
|
+
abstract removePartyType(args: RemovePartyTypeArgs): Promise<void>;
|
|
806
|
+
abstract getElectronicAddress(args: GetElectronicAddressArgs): Promise<ElectronicAddress>;
|
|
807
|
+
abstract getElectronicAddresses(args?: GetElectronicAddressesArgs): Promise<Array<ElectronicAddress>>;
|
|
808
|
+
abstract addElectronicAddress(args: AddElectronicAddressArgs): Promise<ElectronicAddress>;
|
|
809
|
+
abstract updateElectronicAddress(args: UpdateElectronicAddressArgs): Promise<ElectronicAddress>;
|
|
810
|
+
abstract removeElectronicAddress(args: RemoveElectronicAddressArgs): Promise<void>;
|
|
811
|
+
abstract getPhysicalAddress(args: GetPhysicalAddressArgs): Promise<PhysicalAddress>;
|
|
812
|
+
abstract getPhysicalAddresses(args?: GetPhysicalAddressesArgs): Promise<Array<PhysicalAddress>>;
|
|
813
|
+
abstract addPhysicalAddress(args: AddPhysicalAddressArgs): Promise<PhysicalAddress>;
|
|
814
|
+
abstract updatePhysicalAddress(args: UpdatePhysicalAddressArgs): Promise<PhysicalAddress>;
|
|
815
|
+
abstract removePhysicalAddress(args: RemovePhysicalAddressArgs): Promise<void>;
|
|
816
|
+
}
|
|
817
|
+
|
|
818
|
+
declare abstract class AbstractDigitalCredentialStore {
|
|
819
|
+
abstract getCredential(args: GetCredentialArgs): Promise<DigitalCredential>;
|
|
820
|
+
abstract getCredentials(args?: GetCredentialsArgs): Promise<GetCredentialsResponse>;
|
|
821
|
+
abstract addCredential(args: AddCredentialArgs): Promise<DigitalCredential>;
|
|
822
|
+
abstract updateCredentialState(args: UpdateCredentialStateArgs): Promise<DigitalCredential>;
|
|
823
|
+
abstract removeCredential(args: RemoveCredentialArgs): Promise<boolean>;
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
declare abstract class AbstractIssuanceBrandingStore {
|
|
827
|
+
abstract addCredentialBranding(args: IAddCredentialBrandingArgs): Promise<ICredentialBranding>;
|
|
828
|
+
abstract getCredentialBranding(args?: IGetCredentialBrandingArgs): Promise<Array<ICredentialBranding>>;
|
|
829
|
+
abstract updateCredentialBranding(args: IUpdateCredentialBrandingArgs): Promise<ICredentialBranding>;
|
|
830
|
+
abstract removeCredentialBranding(args: IRemoveCredentialBrandingArgs): Promise<void>;
|
|
831
|
+
abstract addCredentialLocaleBranding(args: IAddCredentialLocaleBrandingArgs): Promise<ICredentialBranding>;
|
|
832
|
+
abstract getCredentialLocaleBranding(args?: IGetCredentialLocaleBrandingArgs): Promise<Array<ICredentialLocaleBranding>>;
|
|
833
|
+
abstract updateCredentialLocaleBranding(args: IUpdateCredentialLocaleBrandingArgs): Promise<ICredentialLocaleBranding>;
|
|
834
|
+
abstract removeCredentialLocaleBranding(args: IRemoveCredentialLocaleBrandingArgs): Promise<void>;
|
|
835
|
+
abstract addIssuerBranding(args: IAddIssuerBrandingArgs): Promise<IIssuerBranding>;
|
|
836
|
+
abstract getIssuerBranding(args?: IGetIssuerBrandingArgs): Promise<Array<IIssuerBranding>>;
|
|
837
|
+
abstract updateIssuerBranding(args: IUpdateIssuerBrandingArgs): Promise<IIssuerBranding>;
|
|
838
|
+
abstract removeIssuerBranding(args: IRemoveIssuerBrandingArgs): Promise<void>;
|
|
839
|
+
abstract addIssuerLocaleBranding(args: IAddIssuerLocaleBrandingArgs): Promise<IIssuerBranding>;
|
|
840
|
+
abstract getIssuerLocaleBranding(args?: IGetIssuerLocaleBrandingArgs): Promise<Array<IIssuerLocaleBranding>>;
|
|
841
|
+
abstract updateIssuerLocaleBranding(args: IUpdateIssuerLocaleBrandingArgs): Promise<IIssuerLocaleBranding>;
|
|
842
|
+
abstract removeIssuerLocaleBranding(args: IRemoveIssuerLocaleBrandingArgs): Promise<void>;
|
|
843
|
+
}
|
|
844
|
+
|
|
845
|
+
declare abstract class AbstractEventLoggerStore {
|
|
846
|
+
abstract getAuditEvents(args: GetAuditEventsArgs): Promise<Array<AuditLoggingEvent>>;
|
|
847
|
+
abstract getActivityEvents(args: GetActivityEventsArgs): Promise<Array<ActivityLoggingEvent>>;
|
|
848
|
+
abstract storeAuditEvent(args: StoreAuditEventArgs): Promise<AuditLoggingEvent>;
|
|
849
|
+
abstract storeActivityEvent(args: StoreActivityEventArgs): Promise<ActivityLoggingEvent>;
|
|
850
|
+
}
|
|
851
|
+
|
|
852
|
+
/**
|
|
853
|
+
* Represents an abstract class for storing machine states.
|
|
854
|
+
* This class provides methods for persisting, retrieving, and deleting machine states.
|
|
855
|
+
*
|
|
856
|
+
* @interface
|
|
857
|
+
*/
|
|
858
|
+
declare abstract class IAbstractMachineStateStore {
|
|
859
|
+
/**
|
|
860
|
+
* Persists the machine state.
|
|
861
|
+
*
|
|
862
|
+
* @param {StoreMachineStatePersistArgs} state - The object containing the machine state to persist.
|
|
863
|
+
* @return {Promise<StoreMachineStateInfo>} - A Promise that resolves to the information about the persisted machine state.
|
|
864
|
+
*/
|
|
865
|
+
abstract persistMachineState(state: StoreMachineStatePersistArgs): Promise<StoreMachineStateInfo>;
|
|
866
|
+
/**
|
|
867
|
+
* Finds active machine states based on the given arguments.
|
|
868
|
+
*
|
|
869
|
+
* @param {StoreMachineStatesFindActiveArgs} args - The arguments for finding active machine states.
|
|
870
|
+
* @return {Promise<Array<StoreMachineStateInfo>>} - A promise that resolves with an array of active machine states.
|
|
871
|
+
*/
|
|
872
|
+
abstract findActiveMachineStates(args: StoreMachineStatesFindActiveArgs): Promise<Array<StoreMachineStateInfo>>;
|
|
873
|
+
/**
|
|
874
|
+
* Retrieves the state of a particular machine.
|
|
875
|
+
*
|
|
876
|
+
* @param {StoreMachineStateGetArgs} args - The arguments for retrieving the machine state.
|
|
877
|
+
* @returns {Promise<StoreMachineStateInfo>} - A promise that resolves to the machine state information.
|
|
878
|
+
*/
|
|
879
|
+
abstract getMachineState(args: StoreMachineStateGetArgs): Promise<StoreMachineStateInfo>;
|
|
880
|
+
/**
|
|
881
|
+
* Finds the machine states based on the given arguments.
|
|
882
|
+
*
|
|
883
|
+
* @param {StoreFindMachineStatesArgs} [args] - The arguments to filter the machine states.
|
|
884
|
+
* @returns {Promise<Array<StoreMachineStateInfo>>} - A promise that resolves to an array of machine state information.
|
|
885
|
+
*/
|
|
886
|
+
abstract findMachineStates(args?: StoreFindMachineStatesArgs): Promise<Array<StoreMachineStateInfo>>;
|
|
887
|
+
/**
|
|
888
|
+
* Deletes a machine state.
|
|
889
|
+
*
|
|
890
|
+
* @param {StoreMachineStateDeleteArgs} args - The arguments for deleting the machine state.
|
|
891
|
+
* @return {Promise<boolean>} - A promise that resolves to a boolean indicating if the machine state was successfully deleted or not.
|
|
892
|
+
*/
|
|
893
|
+
abstract deleteMachineState(args: StoreMachineStateDeleteArgs): Promise<boolean>;
|
|
894
|
+
/**
|
|
895
|
+
* Deletes expired machine states from the database.
|
|
896
|
+
*
|
|
897
|
+
* @param {StoreMachineStateDeleteExpiredArgs} args - The arguments for deleting expired machine states.
|
|
898
|
+
* @return {Promise<number>} - A promise that resolves to the number of deleted machine states.
|
|
899
|
+
*/
|
|
900
|
+
abstract deleteExpiredMachineStates(args: StoreMachineStateDeleteExpiredArgs): Promise<number>;
|
|
901
|
+
}
|
|
902
|
+
|
|
903
|
+
declare abstract class AbstractPDStore {
|
|
904
|
+
abstract hasDefinition(args: GetDefinitionArgs): Promise<boolean>;
|
|
905
|
+
abstract hasDefinitions(args: GetDefinitionsArgs): Promise<boolean>;
|
|
906
|
+
abstract getDefinition(args: GetDefinitionArgs): Promise<DcqlQueryItem>;
|
|
907
|
+
abstract getDefinitions(args: GetDefinitionsArgs): Promise<Array<DcqlQueryItem>>;
|
|
908
|
+
abstract addDefinition(args: AddDefinitionArgs): Promise<DcqlQueryItem>;
|
|
909
|
+
abstract updateDefinition(args: UpdateDefinitionArgs): Promise<DcqlQueryItem>;
|
|
910
|
+
abstract deleteDefinition(args: DeleteDefinitionArgs): Promise<void>;
|
|
911
|
+
abstract deleteDefinitions(args: DeleteDefinitionsArgs): Promise<number>;
|
|
912
|
+
}
|
|
913
|
+
|
|
914
|
+
declare function ensureRawDocument(input: string | object): string;
|
|
915
|
+
|
|
916
|
+
export { AbstractContactStore, AbstractDigitalCredentialStore, AbstractEventLoggerStore, AbstractIssuanceBrandingStore, AbstractPDStore, type AddCredentialArgs, type AddDefinitionArgs, type AddElectronicAddressArgs, type AddIdentityArgs, type AddPartyArgs, type AddPartyTypeArgs, type AddPhysicalAddressArgs, type AddRelationshipArgs, type Connection, type ConnectionConfig, ConnectionType, type Contact, type CorrelationIdentifier, CorrelationIdentifierType, CredentialCorrelationType, CredentialDocumentFormat, CredentialStateType, type DcqlQueryItem, type DcqlQueryItemFilter, type DeleteDefinitionArgs, type DeleteDefinitionsArgs, type DidAuthConfig, type DigitalCredential, DocumentType, type ElectronicAddress, type ElectronicAddressType, type FindActivityLoggingEventArgs, type FindAuditLoggingEventArgs, type FindCredentialBrandingArgs, type FindCredentialLocaleBrandingArgs, type FindDcqlQueryArgs, type FindDigitalCredentialArgs, type FindElectronicAddressArgs, type FindIdentityArgs, type FindIssuerBrandingArgs, type FindIssuerLocaleBrandingArgs, type FindMachineStatesFilterArgs, type FindPartyArgs, type FindPartyTypeArgs, type FindPhysicalAddressArgs, type FindRelationshipArgs, type GetActivityEventsArgs, type GetAuditEventsArgs, type GetCredentialArgs, type GetCredentialsArgs, type GetCredentialsResponse, type GetDefinitionArgs, type GetDefinitionsArgs, type GetElectronicAddressArgs, type GetElectronicAddressesArgs, type GetIdentitiesArgs, type GetIdentityArgs, type GetPartiesArgs, type GetPartyArgs, type GetPartyTypeArgs, type GetPartyTypesArgs, type GetPhysicalAddressArgs, type GetPhysicalAddressesArgs, type GetRelationshipArgs, type GetRelationshipsArgs, type HasDefinitionArgs, type HasDefinitionsArgs, IAbstractMachineStateStore, type IAddCredentialBrandingArgs, type IAddCredentialLocaleBrandingArgs, type IAddIssuerBrandingArgs, type IAddIssuerLocaleBrandingArgs, type IBackgroundAttributes, type IBasicBackgroundAttributes, type IBasicCredentialBranding, type IBasicCredentialClaim, type IBasicCredentialLocaleBranding, type IBasicImageAttributes, type IBasicImageDimensions, type IBasicIssuerBranding, type IBasicIssuerLocaleBranding, type IBasicTextAttributes, type ICredentialBranding, type ICredentialBrandingFilter, type ICredentialClaim, type ICredentialLocaleBranding, type ICredentialLocaleBrandingFilter, type IGetCredentialBrandingArgs, type IGetCredentialLocaleBrandingArgs, type IGetIssuerBrandingArgs, type IGetIssuerLocaleBrandingArgs, type IImageAttributes, type IImageDimensions, type IIssuerBranding, type IIssuerBrandingFilter, type IIssuerLocaleBranding, type IIssuerLocaleBrandingFilter, type ILocaleBranding, type IMetadataEntity, type IPartialBackgroundAttributes, type IPartialCredentialBranding, type IPartialCredentialClaim, type IPartialCredentialLocaleBranding, type IPartialImageAttributes, type IPartialImageDimensions, type IPartialIssuerBranding, type IPartialIssuerLocaleBranding, type IPartialTextAttributes, type IRemoveCredentialBrandingArgs, type IRemoveCredentialLocaleBrandingArgs, type IRemoveIssuerBrandingArgs, type IRemoveIssuerLocaleBrandingArgs, type ITextAttributes, type IUpdateCredentialBrandingArgs, type IUpdateCredentialLocaleBrandingArgs, type IUpdateIssuerBrandingArgs, type IUpdateIssuerLocaleBrandingArgs, type Identity, IdentityOrigin, type ImportDcqlQueryItem, type MetadataItem, type MetadataTypes, type NaturalPerson, type NonPersistedActivityLoggingEvent, type NonPersistedAuditLoggingEvent, type NonPersistedConnection, type NonPersistedConnectionConfig, type NonPersistedContact, type NonPersistedCorrelationIdentifier, type NonPersistedDcqlQueryItem, type NonPersistedDidAuthConfig, type NonPersistedDigitalCredential, type NonPersistedElectronicAddress, type NonPersistedIdentity, type NonPersistedMetadataItem, type NonPersistedNaturalPerson, type NonPersistedOpenIdConfig, type NonPersistedOrganization, type NonPersistedParty, type NonPersistedPartyRelationship, type NonPersistedPartyType, type NonPersistedPhysicalAddress, type OpenIdConfig, type Organization, type PartialConnection, type PartialConnectionConfig, type PartialContact, type PartialCorrelationIdentifier, type PartialDcqlQueryItem, type PartialDidAuthConfig, type PartialElectronicAddress, type PartialIdentity, type PartialMetadataItem, type PartialNaturalPerson, type PartialOpenIdConfig, type PartialOrganization, type PartialParty, type PartialPartyRelationship, type PartialPartyType, type PartialPhysicalAddress, type Party, PartyOrigin, type PartyRelationship, type PartyType, PartyTypeType, type PhysicalAddress, type PhysicalAddressType, RegulationType, type RemoveCredentialArgs, type RemoveElectronicAddressArgs, type RemoveIdentityArgs, type RemovePartyArgs, type RemovePartyTypeArgs, type RemovePhysicalAddressArgs, type RemoveRelationshipArgs, type StoreActivityEventArgs, type StoreAuditEventArgs, type StoreFindMachineStatesArgs, type StoreMachineStateDeleteArgs, type StoreMachineStateDeleteExpiredArgs, type StoreMachineStateGetArgs, type StoreMachineStateInfo, type StoreMachineStatePersistArgs, type StoreMachineStatesFindActiveArgs, type UpdateCredentialStateArgs, type UpdateDefinitionArgs, type UpdateElectronicAddressArgs, type UpdateIdentityArgs, type UpdatePartyArgs, type UpdatePartyTypeArgs, type UpdatePhysicalAddressArgs, type UpdateRelationshipArgs, type ValidationConstraint, ensureRawDocument };
|