@triveria/wallet 0.0.324 → 0.0.326
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/api.d.ts +170 -1
- package/api.js +176 -1
- package/package.json +1 -1
package/api.d.ts
CHANGED
|
@@ -102,16 +102,31 @@ export interface CredentialCreatePayload {
|
|
|
102
102
|
[key: string]: any;
|
|
103
103
|
'credentialSubject': CredentialSubject;
|
|
104
104
|
'credentialDraftMetadata': CredentialDraftMetadata;
|
|
105
|
+
/**
|
|
106
|
+
* ID of the credential issuer (`CredentialIssuerDefinition.id`, from the wallet configuration or the trust framework) that issues the draft. When set, the draft can only be queued for issuance by this issuer.
|
|
107
|
+
*/
|
|
108
|
+
'issuerId'?: string;
|
|
105
109
|
/**
|
|
106
110
|
* If true, the credential draft is checked against its schema. Defaults to true.
|
|
107
111
|
*/
|
|
108
112
|
'validateSchema'?: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* If true, a VCDM 2.0 draft must define every property in its JSON-LD context, now and when it is issued. Defaults to the `jsonld.enforceOnCreate` setting.
|
|
115
|
+
*/
|
|
116
|
+
'validateJsonLd'?: boolean;
|
|
109
117
|
}
|
|
110
118
|
/**
|
|
111
119
|
* Accompanying information about the verifiable credential draft - schema, type, format etc.
|
|
112
120
|
*/
|
|
113
121
|
export interface CredentialDraftMetadata {
|
|
114
|
-
|
|
122
|
+
/**
|
|
123
|
+
* Context URLs or inline context objects. When the first item is not a base VC context (https://www.w3.org/2018/credentials/v1 or https://www.w3.org/ns/credentials/v2), the base context of `vcdmVersion` is put in front of them.
|
|
124
|
+
*/
|
|
125
|
+
'contexts'?: Array<any>;
|
|
126
|
+
'vcdmVersion'?: VcdmVersion;
|
|
127
|
+
'vcdmName'?: string;
|
|
128
|
+
'vcdmDescription'?: string;
|
|
129
|
+
'credentialSchemaType'?: CredentialSchemaType;
|
|
115
130
|
'id': string;
|
|
116
131
|
'name': string;
|
|
117
132
|
'type': string;
|
|
@@ -134,6 +149,10 @@ export interface CredentialIdObject {
|
|
|
134
149
|
export interface CredentialImport {
|
|
135
150
|
'credential': string;
|
|
136
151
|
'name': string;
|
|
152
|
+
/**
|
|
153
|
+
* If true, a VCDM 2.0 credential is refused unless its JSON-LD context defines every property.
|
|
154
|
+
*/
|
|
155
|
+
'validateJsonLd'?: boolean;
|
|
137
156
|
}
|
|
138
157
|
/**
|
|
139
158
|
* Request for addition of already created VC draft to issuance queue for a client. If clientId is used, it will be used as the queue item id, otherwise a new ID will be created.
|
|
@@ -168,6 +187,7 @@ export interface CredentialIssuerDefinition {
|
|
|
168
187
|
* Human readable issuer description
|
|
169
188
|
*/
|
|
170
189
|
'description'?: string;
|
|
190
|
+
'vcdmIssuer'?: VcdmIssuerProperties;
|
|
171
191
|
/**
|
|
172
192
|
* Unique identifier of the issuer
|
|
173
193
|
*/
|
|
@@ -207,6 +227,14 @@ export interface CredentialIssuerDefinition {
|
|
|
207
227
|
* When true, the token request for this credential must carry a DPoP proof (RFC 9449), so the access token is sender-constrained (FAPI 2.0 Security Profile §5.3.2.1). Defaults to false (DPoP optional).
|
|
208
228
|
*/
|
|
209
229
|
'requiresDpop'?: boolean;
|
|
230
|
+
/**
|
|
231
|
+
* Purpose of the status entry attached to the issued credentials. Defaults to `revocation`. `suspension` needs a VCDM 2.0 credential, whose status is a W3C Bitstring Status List entry.
|
|
232
|
+
*/
|
|
233
|
+
'statusPurpose'?: StatusPurpose;
|
|
234
|
+
/**
|
|
235
|
+
* If true, the `statusListIndex` of a W3C Bitstring Status List entry is written as a JSON number instead of the string the W3C Bitstring Status List v1.0 specification defines, for credential schemas that type it as a number (such as UNTP 0.7.0). W3C VCDM only. Defaults to false.
|
|
236
|
+
*/
|
|
237
|
+
'numericStatusListIndex'?: boolean;
|
|
210
238
|
/**
|
|
211
239
|
* When true, a wallet may request this credential without an offer, by an authorization request naming its credential configuration in `authorization_details` or `scope` (OID4VCI 1.0 §5.1). The holder then authorizes as `authorization` requires; with `none` or `oauthNoAuth` anyone may obtain the credential. Defaults to false.
|
|
212
240
|
*/
|
|
@@ -251,6 +279,10 @@ export interface CredentialMetadata {
|
|
|
251
279
|
'walletId': string;
|
|
252
280
|
'ownerId': string;
|
|
253
281
|
'name': string;
|
|
282
|
+
/**
|
|
283
|
+
* ID of the credential issuer (`CredentialIssuerDefinition.id`, from the wallet configuration or the trust framework) that issues the draft. When set, the draft can only be queued for issuance by this issuer.
|
|
284
|
+
*/
|
|
285
|
+
'issuerId'?: string;
|
|
254
286
|
'interaction': CredentialMetadataInteractionEnum;
|
|
255
287
|
'message'?: string;
|
|
256
288
|
'type': string;
|
|
@@ -281,11 +313,17 @@ export declare const CredentialMetadataStatusEnum: {
|
|
|
281
313
|
readonly Draft: "draft";
|
|
282
314
|
readonly Valid: "valid";
|
|
283
315
|
readonly Invalid: "invalid";
|
|
316
|
+
readonly Revoked: "revoked";
|
|
317
|
+
readonly Suspended: "suspended";
|
|
284
318
|
};
|
|
285
319
|
export type CredentialMetadataStatusEnum = typeof CredentialMetadataStatusEnum[keyof typeof CredentialMetadataStatusEnum];
|
|
286
320
|
export interface CredentialMetadataPatchPayload {
|
|
287
321
|
[key: string]: any;
|
|
288
322
|
'name'?: string;
|
|
323
|
+
/**
|
|
324
|
+
* ID of the credential issuer (`CredentialIssuerDefinition.id`, from the wallet configuration or the trust framework) that issues the draft. When set, the draft can only be queued for issuance by this issuer.
|
|
325
|
+
*/
|
|
326
|
+
'issuerId'?: string;
|
|
289
327
|
/**
|
|
290
328
|
* Flag to set automatic acceptance of verification requests which resolve to this credential
|
|
291
329
|
*/
|
|
@@ -303,6 +341,8 @@ export declare const CredentialNotificationEventTypeEnum: {
|
|
|
303
341
|
readonly CredentialIssued: "credential.issued";
|
|
304
342
|
readonly CredentialReceived: "credential.received";
|
|
305
343
|
readonly CredentialRevoked: "credential.revoked";
|
|
344
|
+
readonly CredentialSuspended: "credential.suspended";
|
|
345
|
+
readonly CredentialUnsuspended: "credential.unsuspended";
|
|
306
346
|
};
|
|
307
347
|
export type CredentialNotificationEventTypeEnum = typeof CredentialNotificationEventTypeEnum[keyof typeof CredentialNotificationEventTypeEnum];
|
|
308
348
|
/**
|
|
@@ -312,6 +352,21 @@ export interface CredentialPatchPayload {
|
|
|
312
352
|
[key: string]: any;
|
|
313
353
|
'credentialSubject': CredentialSubject;
|
|
314
354
|
'name': string;
|
|
355
|
+
/**
|
|
356
|
+
* Replaces the draft\'s contexts; the same rules apply as on create.
|
|
357
|
+
*/
|
|
358
|
+
'contexts'?: Array<any>;
|
|
359
|
+
'vcdmName'?: string;
|
|
360
|
+
'vcdmDescription'?: string;
|
|
361
|
+
/**
|
|
362
|
+
* ID of the credential issuer (`CredentialIssuerDefinition.id`, from the wallet configuration or the trust framework) that issues the draft. When set, the draft can only be queued for issuance by this issuer.
|
|
363
|
+
*/
|
|
364
|
+
'issuerId'?: string;
|
|
365
|
+
'credentialSchemaType'?: CredentialSchemaType;
|
|
366
|
+
/**
|
|
367
|
+
* If true, a VCDM 2.0 draft must define every property in its JSON-LD context, now and when it is issued. Unset keeps what the draft was created with.
|
|
368
|
+
*/
|
|
369
|
+
'validateJsonLd'?: boolean;
|
|
315
370
|
/**
|
|
316
371
|
* If true, the credential draft is checked against its schema. Defaults to true.
|
|
317
372
|
*/
|
|
@@ -351,6 +406,14 @@ export interface CredentialRequirementsIssuerConfig {
|
|
|
351
406
|
*/
|
|
352
407
|
'credentialVerifierId': string;
|
|
353
408
|
}
|
|
409
|
+
/**
|
|
410
|
+
* The `credentialSchema.type` emitted in a W3C VCDM credential. Defaults to FullJsonSchemaValidator2021 with a VCDM 1.1 context and to JsonSchema with a VCDM 2.0 one.
|
|
411
|
+
*/
|
|
412
|
+
export declare const CredentialSchemaType: {
|
|
413
|
+
readonly FullJsonSchemaValidator2021: "FullJsonSchemaValidator2021";
|
|
414
|
+
readonly JsonSchema: "JsonSchema";
|
|
415
|
+
};
|
|
416
|
+
export type CredentialSchemaType = typeof CredentialSchemaType[keyof typeof CredentialSchemaType];
|
|
354
417
|
/**
|
|
355
418
|
* @type CredentialSubject
|
|
356
419
|
* Set of objects that MUST contain one or more claims that are each related to a subject of the verifiable credential. When the credential is in W3C VCDM, the subject is in its compacted form with claim keys in their full IRI form.
|
|
@@ -579,6 +642,19 @@ export interface EbsiConfiguration {
|
|
|
579
642
|
'trustedSchemasRegistry': string;
|
|
580
643
|
'mainSchema': string;
|
|
581
644
|
'statusListSchema': string;
|
|
645
|
+
/**
|
|
646
|
+
* Schema of the W3C Bitstring Status List credentials published for VCDM 2.0 credentials. Defaults to the deployment\'s `ebsi.bitstringStatusListSchema` setting. When both are empty, the lists are published without a `credentialSchema`.
|
|
647
|
+
*/
|
|
648
|
+
'bitstringStatusListSchema'?: string;
|
|
649
|
+
'trustChainVcdm'?: VcdmVersion;
|
|
650
|
+
/**
|
|
651
|
+
* Schema of VCDM 2.0 trust chain credentials (`VerifiableTrustModel`), used when trustChainVcdm is 2.0.
|
|
652
|
+
*/
|
|
653
|
+
'trustModelSchema'?: string;
|
|
654
|
+
/**
|
|
655
|
+
* TIR URL of the root authorisation of the wallet\'s trust chain, which VCDM 2.0 accreditations name in their `AccreditationPolicy`. Required when trustChainVcdm is 2.0.
|
|
656
|
+
*/
|
|
657
|
+
'trustChainRootAuthorisation'?: string;
|
|
582
658
|
}
|
|
583
659
|
/**
|
|
584
660
|
* EBSI specific data
|
|
@@ -1046,6 +1122,14 @@ export declare const SigningKeyIdentifier: {
|
|
|
1046
1122
|
readonly X509: "x509";
|
|
1047
1123
|
};
|
|
1048
1124
|
export type SigningKeyIdentifier = typeof SigningKeyIdentifier[keyof typeof SigningKeyIdentifier];
|
|
1125
|
+
/**
|
|
1126
|
+
* https://www.w3.org/TR/vc-bitstring-status-list/#bitstringstatuslistentry
|
|
1127
|
+
*/
|
|
1128
|
+
export declare const StatusPurpose: {
|
|
1129
|
+
readonly Revocation: "revocation";
|
|
1130
|
+
readonly Suspension: "suspension";
|
|
1131
|
+
};
|
|
1132
|
+
export type StatusPurpose = typeof StatusPurpose[keyof typeof StatusPurpose];
|
|
1049
1133
|
/**
|
|
1050
1134
|
* The subsystem status impact on the overall system
|
|
1051
1135
|
*/
|
|
@@ -1151,6 +1235,25 @@ export interface VcOffer {
|
|
|
1151
1235
|
*/
|
|
1152
1236
|
'Url': string;
|
|
1153
1237
|
}
|
|
1238
|
+
/**
|
|
1239
|
+
* Properties of the VCDM `issuer` object besides `id`, which is always the wallet\'s identifier (W3C VCDM only).
|
|
1240
|
+
*/
|
|
1241
|
+
export interface VcdmIssuerProperties {
|
|
1242
|
+
[key: string]: any;
|
|
1243
|
+
'name'?: string;
|
|
1244
|
+
'type'?: Array<string>;
|
|
1245
|
+
'issuerAlsoKnownAs'?: Array<{
|
|
1246
|
+
[key: string]: any;
|
|
1247
|
+
}>;
|
|
1248
|
+
}
|
|
1249
|
+
/**
|
|
1250
|
+
* The W3C VC Data Model version of a W3C VCDM credential: `1.1` (https://www.w3.org/2018/credentials/v1) or `2.0` (https://www.w3.org/ns/credentials/v2). The wallet does not choose it. On a draft, the client sets it, and it defaults to 2.0; a draft whose `contexts` start with a base context must not name a different version. On an EBSI configuration (`trustChainVcdm`), it is the version of the trust chain credentials the wallet issues; that one defaults to 1.1.
|
|
1251
|
+
*/
|
|
1252
|
+
export declare const VcdmVersion: {
|
|
1253
|
+
readonly _11: "1.1";
|
|
1254
|
+
readonly _20: "2.0";
|
|
1255
|
+
};
|
|
1256
|
+
export type VcdmVersion = typeof VcdmVersion[keyof typeof VcdmVersion];
|
|
1154
1257
|
export interface VerifiedLinkedVp {
|
|
1155
1258
|
'linkedVpId': string;
|
|
1156
1259
|
/**
|
|
@@ -1357,6 +1460,8 @@ export declare const WalletNotificationEventType: {
|
|
|
1357
1460
|
readonly CredentialIssued: "credential.issued";
|
|
1358
1461
|
readonly CredentialReceived: "credential.received";
|
|
1359
1462
|
readonly CredentialRevoked: "credential.revoked";
|
|
1463
|
+
readonly CredentialSuspended: "credential.suspended";
|
|
1464
|
+
readonly CredentialUnsuspended: "credential.unsuspended";
|
|
1360
1465
|
readonly WmpInvitationAccepted: "wmp.invitation_accepted";
|
|
1361
1466
|
readonly WmpCredentialOffer: "wmp.credential_offer";
|
|
1362
1467
|
readonly WmpCredentialVerificationRequest: "wmp.credential_verification_request";
|
|
@@ -1777,6 +1882,22 @@ export declare const DefaultApiAxiosParamCreator: (configuration?: Configuration
|
|
|
1777
1882
|
* @throws {RequiredError}
|
|
1778
1883
|
*/
|
|
1779
1884
|
credentialRevoke: (credentialId: string, walletId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
1885
|
+
/**
|
|
1886
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
1887
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1888
|
+
* @param {string} walletId
|
|
1889
|
+
* @param {*} [options] Override http request option.
|
|
1890
|
+
* @throws {RequiredError}
|
|
1891
|
+
*/
|
|
1892
|
+
credentialSuspend: (credentialId: string, walletId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
1893
|
+
/**
|
|
1894
|
+
* Lift the suspension of a Verifiable Credential.
|
|
1895
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1896
|
+
* @param {string} walletId
|
|
1897
|
+
* @param {*} [options] Override http request option.
|
|
1898
|
+
* @throws {RequiredError}
|
|
1899
|
+
*/
|
|
1900
|
+
credentialUnsuspend: (credentialId: string, walletId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
1780
1901
|
/**
|
|
1781
1902
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
1782
1903
|
* @param {string} deferredId Deferred token
|
|
@@ -2443,6 +2564,22 @@ export declare const DefaultApiFp: (configuration?: Configuration) => {
|
|
|
2443
2564
|
* @throws {RequiredError}
|
|
2444
2565
|
*/
|
|
2445
2566
|
credentialRevoke(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
2567
|
+
/**
|
|
2568
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
2569
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
2570
|
+
* @param {string} walletId
|
|
2571
|
+
* @param {*} [options] Override http request option.
|
|
2572
|
+
* @throws {RequiredError}
|
|
2573
|
+
*/
|
|
2574
|
+
credentialSuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
2575
|
+
/**
|
|
2576
|
+
* Lift the suspension of a Verifiable Credential.
|
|
2577
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
2578
|
+
* @param {string} walletId
|
|
2579
|
+
* @param {*} [options] Override http request option.
|
|
2580
|
+
* @throws {RequiredError}
|
|
2581
|
+
*/
|
|
2582
|
+
credentialUnsuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
2446
2583
|
/**
|
|
2447
2584
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
2448
2585
|
* @param {string} deferredId Deferred token
|
|
@@ -3111,6 +3248,22 @@ export declare const DefaultApiFactory: (configuration?: Configuration, basePath
|
|
|
3111
3248
|
* @throws {RequiredError}
|
|
3112
3249
|
*/
|
|
3113
3250
|
credentialRevoke(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
|
|
3251
|
+
/**
|
|
3252
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
3253
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3254
|
+
* @param {string} walletId
|
|
3255
|
+
* @param {*} [options] Override http request option.
|
|
3256
|
+
* @throws {RequiredError}
|
|
3257
|
+
*/
|
|
3258
|
+
credentialSuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
|
|
3259
|
+
/**
|
|
3260
|
+
* Lift the suspension of a Verifiable Credential.
|
|
3261
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3262
|
+
* @param {string} walletId
|
|
3263
|
+
* @param {*} [options] Override http request option.
|
|
3264
|
+
* @throws {RequiredError}
|
|
3265
|
+
*/
|
|
3266
|
+
credentialUnsuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
|
|
3114
3267
|
/**
|
|
3115
3268
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
3116
3269
|
* @param {string} deferredId Deferred token
|
|
@@ -3779,6 +3932,22 @@ export declare class DefaultApi extends BaseAPI {
|
|
|
3779
3932
|
* @throws {RequiredError}
|
|
3780
3933
|
*/
|
|
3781
3934
|
credentialRevoke(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
3935
|
+
/**
|
|
3936
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
3937
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3938
|
+
* @param {string} walletId
|
|
3939
|
+
* @param {*} [options] Override http request option.
|
|
3940
|
+
* @throws {RequiredError}
|
|
3941
|
+
*/
|
|
3942
|
+
credentialSuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
3943
|
+
/**
|
|
3944
|
+
* Lift the suspension of a Verifiable Credential.
|
|
3945
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3946
|
+
* @param {string} walletId
|
|
3947
|
+
* @param {*} [options] Override http request option.
|
|
3948
|
+
* @throws {RequiredError}
|
|
3949
|
+
*/
|
|
3950
|
+
credentialUnsuspend(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
3782
3951
|
/**
|
|
3783
3952
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
3784
3953
|
* @param {string} deferredId Deferred token
|
package/api.js
CHANGED
|
@@ -25,7 +25,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
25
25
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
26
26
|
};
|
|
27
27
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
|
-
exports.WmpEntityListEntityTypeEnum = exports.CredentialPayloadGetFormEnum = exports.CredentialListInteractionEnum = exports.CredentialClaimMetadataGetMetadataScopeEnum = exports.DefaultApi = exports.DefaultApiFactory = exports.DefaultApiFp = exports.DefaultApiAxiosParamCreator = exports.XadesSignatureType = exports.WmpRequestType = exports.WmpProvideIdentityAssertionTypeEnum = exports.WmpProcessVerificationRequestTypeEnum = exports.WmpProcessOfferRequestTypeEnum = exports.WmpMessageSendStatus = exports.WmpAuthenticateSessionTypeEnum = exports.WmpAckReadRequestTypeEnum = exports.WmpAckProcessedRequestTypeEnum = exports.WalletNotificationEventType = exports.WalletCapability = exports.VaultType = exports.TrustListKind = exports.TrustFrameworkType = exports.SystemImpactStatusEnum = exports.SigningKeyIdentifier = exports.RevokeAccreditationRequestTypeEnum = exports.PresentationDefinitionSubmissionRequirementsRuleEnum = exports.OidcRevisionOidc4vpEnum = exports.OidcRevisionOidc4vciEnum = exports.ObjectVerticalAlignment = exports.ObjectHorizontalAlignment = exports.ListSort = exports.InteractionAuthorizationRequirementsRequirementTypeEnum = exports.HealthStatusStatusEnum = exports.EntityAccreditationRequestTypeEnum = exports.DocumentSignatureValidityVerificationResultEnum = exports.DeferredStatusEnum = exports.CredentialPropertyToVerify = exports.CredentialNotificationEventTypeEnum = exports.CredentialMetadataStatusEnum = exports.CredentialMetadataInteractionEnum = exports.CredentialIssuerDefinitionAuthorizationEnum = exports.CredentialIssuerDefinitionCredentialIssuerEnum = exports.CredentialFormat = exports.CertificateStatus = exports.AccreditationRequestTypeEnum = void 0;
|
|
28
|
+
exports.WmpEntityListEntityTypeEnum = exports.CredentialPayloadGetFormEnum = exports.CredentialListInteractionEnum = exports.CredentialClaimMetadataGetMetadataScopeEnum = exports.DefaultApi = exports.DefaultApiFactory = exports.DefaultApiFp = exports.DefaultApiAxiosParamCreator = exports.XadesSignatureType = exports.WmpRequestType = exports.WmpProvideIdentityAssertionTypeEnum = exports.WmpProcessVerificationRequestTypeEnum = exports.WmpProcessOfferRequestTypeEnum = exports.WmpMessageSendStatus = exports.WmpAuthenticateSessionTypeEnum = exports.WmpAckReadRequestTypeEnum = exports.WmpAckProcessedRequestTypeEnum = exports.WalletNotificationEventType = exports.WalletCapability = exports.VcdmVersion = exports.VaultType = exports.TrustListKind = exports.TrustFrameworkType = exports.SystemImpactStatusEnum = exports.StatusPurpose = exports.SigningKeyIdentifier = exports.RevokeAccreditationRequestTypeEnum = exports.PresentationDefinitionSubmissionRequirementsRuleEnum = exports.OidcRevisionOidc4vpEnum = exports.OidcRevisionOidc4vciEnum = exports.ObjectVerticalAlignment = exports.ObjectHorizontalAlignment = exports.ListSort = exports.InteractionAuthorizationRequirementsRequirementTypeEnum = exports.HealthStatusStatusEnum = exports.EntityAccreditationRequestTypeEnum = exports.DocumentSignatureValidityVerificationResultEnum = exports.DeferredStatusEnum = exports.CredentialSchemaType = exports.CredentialPropertyToVerify = exports.CredentialNotificationEventTypeEnum = exports.CredentialMetadataStatusEnum = exports.CredentialMetadataInteractionEnum = exports.CredentialIssuerDefinitionAuthorizationEnum = exports.CredentialIssuerDefinitionCredentialIssuerEnum = exports.CredentialFormat = exports.CertificateStatus = exports.AccreditationRequestTypeEnum = void 0;
|
|
29
29
|
const axios_1 = __importDefault(require("axios"));
|
|
30
30
|
// Some imports not used depending on template conditions
|
|
31
31
|
// @ts-ignore
|
|
@@ -78,12 +78,16 @@ exports.CredentialMetadataStatusEnum = {
|
|
|
78
78
|
Draft: 'draft',
|
|
79
79
|
Valid: 'valid',
|
|
80
80
|
Invalid: 'invalid',
|
|
81
|
+
Revoked: 'revoked',
|
|
82
|
+
Suspended: 'suspended',
|
|
81
83
|
};
|
|
82
84
|
exports.CredentialNotificationEventTypeEnum = {
|
|
83
85
|
CredentialCreated: 'credential.created',
|
|
84
86
|
CredentialIssued: 'credential.issued',
|
|
85
87
|
CredentialReceived: 'credential.received',
|
|
86
88
|
CredentialRevoked: 'credential.revoked',
|
|
89
|
+
CredentialSuspended: 'credential.suspended',
|
|
90
|
+
CredentialUnsuspended: 'credential.unsuspended',
|
|
87
91
|
};
|
|
88
92
|
/**
|
|
89
93
|
* Credential property that will be verified. `verifySchema` is only applicable in W3C VCDM credentials. With other types, this field will be ignored.
|
|
@@ -94,6 +98,13 @@ exports.CredentialPropertyToVerify = {
|
|
|
94
98
|
VerifySchema: 'verifySchema',
|
|
95
99
|
VerifyKeyBinding: 'verifyKeyBinding',
|
|
96
100
|
};
|
|
101
|
+
/**
|
|
102
|
+
* The `credentialSchema.type` emitted in a W3C VCDM credential. Defaults to FullJsonSchemaValidator2021 with a VCDM 1.1 context and to JsonSchema with a VCDM 2.0 one.
|
|
103
|
+
*/
|
|
104
|
+
exports.CredentialSchemaType = {
|
|
105
|
+
FullJsonSchemaValidator2021: 'FullJsonSchemaValidator2021',
|
|
106
|
+
JsonSchema: 'JsonSchema',
|
|
107
|
+
};
|
|
97
108
|
exports.DeferredStatusEnum = {
|
|
98
109
|
InProgress: 'in_progress',
|
|
99
110
|
Completed: 'completed',
|
|
@@ -160,6 +171,13 @@ exports.SigningKeyIdentifier = {
|
|
|
160
171
|
Jwk: 'jwk',
|
|
161
172
|
X509: 'x509',
|
|
162
173
|
};
|
|
174
|
+
/**
|
|
175
|
+
* https://www.w3.org/TR/vc-bitstring-status-list/#bitstringstatuslistentry
|
|
176
|
+
*/
|
|
177
|
+
exports.StatusPurpose = {
|
|
178
|
+
Revocation: 'revocation',
|
|
179
|
+
Suspension: 'suspension',
|
|
180
|
+
};
|
|
163
181
|
exports.SystemImpactStatusEnum = {
|
|
164
182
|
Ok: 'ok',
|
|
165
183
|
Limited: 'limited',
|
|
@@ -190,6 +208,13 @@ exports.VaultType = {
|
|
|
190
208
|
VaultOvhKms: 'vaultOvhKms',
|
|
191
209
|
VaultKmip: 'vaultKmip',
|
|
192
210
|
};
|
|
211
|
+
/**
|
|
212
|
+
* The W3C VC Data Model version of a W3C VCDM credential: `1.1` (https://www.w3.org/2018/credentials/v1) or `2.0` (https://www.w3.org/ns/credentials/v2). The wallet does not choose it. On a draft, the client sets it, and it defaults to 2.0; a draft whose `contexts` start with a base context must not name a different version. On an EBSI configuration (`trustChainVcdm`), it is the version of the trust chain credentials the wallet issues; that one defaults to 1.1.
|
|
213
|
+
*/
|
|
214
|
+
exports.VcdmVersion = {
|
|
215
|
+
_11: '1.1',
|
|
216
|
+
_20: '2.0',
|
|
217
|
+
};
|
|
193
218
|
/**
|
|
194
219
|
* Defines the capabilities which the wallet has. It may be any of \"holder\", \"issuer\" and \"verifier\".
|
|
195
220
|
*/
|
|
@@ -209,6 +234,8 @@ exports.WalletNotificationEventType = {
|
|
|
209
234
|
CredentialIssued: 'credential.issued',
|
|
210
235
|
CredentialReceived: 'credential.received',
|
|
211
236
|
CredentialRevoked: 'credential.revoked',
|
|
237
|
+
CredentialSuspended: 'credential.suspended',
|
|
238
|
+
CredentialUnsuspended: 'credential.unsuspended',
|
|
212
239
|
WmpInvitationAccepted: 'wmp.invitation_accepted',
|
|
213
240
|
WmpCredentialOffer: 'wmp.credential_offer',
|
|
214
241
|
WmpCredentialVerificationRequest: 'wmp.credential_verification_request',
|
|
@@ -766,6 +793,82 @@ const DefaultApiAxiosParamCreator = function (configuration) {
|
|
|
766
793
|
options: localVarRequestOptions,
|
|
767
794
|
};
|
|
768
795
|
}),
|
|
796
|
+
/**
|
|
797
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
798
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
799
|
+
* @param {string} walletId
|
|
800
|
+
* @param {*} [options] Override http request option.
|
|
801
|
+
* @throws {RequiredError}
|
|
802
|
+
*/
|
|
803
|
+
credentialSuspend: (credentialId_1, walletId_1, ...args_1) => __awaiter(this, [credentialId_1, walletId_1, ...args_1], void 0, function* (credentialId, walletId, options = {}) {
|
|
804
|
+
// verify required parameter 'credentialId' is not null or undefined
|
|
805
|
+
(0, common_1.assertParamExists)('credentialSuspend', 'credentialId', credentialId);
|
|
806
|
+
// verify required parameter 'walletId' is not null or undefined
|
|
807
|
+
(0, common_1.assertParamExists)('credentialSuspend', 'walletId', walletId);
|
|
808
|
+
const localVarPath = `/credentials/{credential_id}/suspend`
|
|
809
|
+
.replace('{credential_id}', encodeURIComponent(String(credentialId)));
|
|
810
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
811
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
812
|
+
let baseOptions;
|
|
813
|
+
if (configuration) {
|
|
814
|
+
baseOptions = configuration.baseOptions;
|
|
815
|
+
}
|
|
816
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
817
|
+
const localVarHeaderParameter = {};
|
|
818
|
+
const localVarQueryParameter = {};
|
|
819
|
+
// authentication accessToken required
|
|
820
|
+
// http bearer authentication required
|
|
821
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
822
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
823
|
+
if (walletId != null) {
|
|
824
|
+
localVarHeaderParameter['wallet-id'] = String(walletId);
|
|
825
|
+
}
|
|
826
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
827
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
828
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
829
|
+
return {
|
|
830
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
831
|
+
options: localVarRequestOptions,
|
|
832
|
+
};
|
|
833
|
+
}),
|
|
834
|
+
/**
|
|
835
|
+
* Lift the suspension of a Verifiable Credential.
|
|
836
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
837
|
+
* @param {string} walletId
|
|
838
|
+
* @param {*} [options] Override http request option.
|
|
839
|
+
* @throws {RequiredError}
|
|
840
|
+
*/
|
|
841
|
+
credentialUnsuspend: (credentialId_1, walletId_1, ...args_1) => __awaiter(this, [credentialId_1, walletId_1, ...args_1], void 0, function* (credentialId, walletId, options = {}) {
|
|
842
|
+
// verify required parameter 'credentialId' is not null or undefined
|
|
843
|
+
(0, common_1.assertParamExists)('credentialUnsuspend', 'credentialId', credentialId);
|
|
844
|
+
// verify required parameter 'walletId' is not null or undefined
|
|
845
|
+
(0, common_1.assertParamExists)('credentialUnsuspend', 'walletId', walletId);
|
|
846
|
+
const localVarPath = `/credentials/{credential_id}/suspend`
|
|
847
|
+
.replace('{credential_id}', encodeURIComponent(String(credentialId)));
|
|
848
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
849
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
850
|
+
let baseOptions;
|
|
851
|
+
if (configuration) {
|
|
852
|
+
baseOptions = configuration.baseOptions;
|
|
853
|
+
}
|
|
854
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
855
|
+
const localVarHeaderParameter = {};
|
|
856
|
+
const localVarQueryParameter = {};
|
|
857
|
+
// authentication accessToken required
|
|
858
|
+
// http bearer authentication required
|
|
859
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
860
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
861
|
+
if (walletId != null) {
|
|
862
|
+
localVarHeaderParameter['wallet-id'] = String(walletId);
|
|
863
|
+
}
|
|
864
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
865
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
866
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
867
|
+
return {
|
|
868
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
869
|
+
options: localVarRequestOptions,
|
|
870
|
+
};
|
|
871
|
+
}),
|
|
769
872
|
/**
|
|
770
873
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
771
874
|
* @param {string} deferredId Deferred token
|
|
@@ -3532,6 +3635,38 @@ const DefaultApiFp = function (configuration) {
|
|
|
3532
3635
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
3533
3636
|
});
|
|
3534
3637
|
},
|
|
3638
|
+
/**
|
|
3639
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
3640
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3641
|
+
* @param {string} walletId
|
|
3642
|
+
* @param {*} [options] Override http request option.
|
|
3643
|
+
* @throws {RequiredError}
|
|
3644
|
+
*/
|
|
3645
|
+
credentialSuspend(credentialId, walletId, options) {
|
|
3646
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
3647
|
+
var _a, _b, _c;
|
|
3648
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.credentialSuspend(credentialId, walletId, options);
|
|
3649
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
3650
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['DefaultApi.credentialSuspend']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
3651
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
3652
|
+
});
|
|
3653
|
+
},
|
|
3654
|
+
/**
|
|
3655
|
+
* Lift the suspension of a Verifiable Credential.
|
|
3656
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
3657
|
+
* @param {string} walletId
|
|
3658
|
+
* @param {*} [options] Override http request option.
|
|
3659
|
+
* @throws {RequiredError}
|
|
3660
|
+
*/
|
|
3661
|
+
credentialUnsuspend(credentialId, walletId, options) {
|
|
3662
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
3663
|
+
var _a, _b, _c;
|
|
3664
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.credentialUnsuspend(credentialId, walletId, options);
|
|
3665
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
3666
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['DefaultApi.credentialUnsuspend']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
3667
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
3668
|
+
});
|
|
3669
|
+
},
|
|
3535
3670
|
/**
|
|
3536
3671
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
3537
3672
|
* @param {string} deferredId Deferred token
|
|
@@ -4768,6 +4903,26 @@ const DefaultApiFactory = function (configuration, basePath, axios) {
|
|
|
4768
4903
|
credentialRevoke(credentialId, walletId, options) {
|
|
4769
4904
|
return localVarFp.credentialRevoke(credentialId, walletId, options).then((request) => request(axios, basePath));
|
|
4770
4905
|
},
|
|
4906
|
+
/**
|
|
4907
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
4908
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
4909
|
+
* @param {string} walletId
|
|
4910
|
+
* @param {*} [options] Override http request option.
|
|
4911
|
+
* @throws {RequiredError}
|
|
4912
|
+
*/
|
|
4913
|
+
credentialSuspend(credentialId, walletId, options) {
|
|
4914
|
+
return localVarFp.credentialSuspend(credentialId, walletId, options).then((request) => request(axios, basePath));
|
|
4915
|
+
},
|
|
4916
|
+
/**
|
|
4917
|
+
* Lift the suspension of a Verifiable Credential.
|
|
4918
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
4919
|
+
* @param {string} walletId
|
|
4920
|
+
* @param {*} [options] Override http request option.
|
|
4921
|
+
* @throws {RequiredError}
|
|
4922
|
+
*/
|
|
4923
|
+
credentialUnsuspend(credentialId, walletId, options) {
|
|
4924
|
+
return localVarFp.credentialUnsuspend(credentialId, walletId, options).then((request) => request(axios, basePath));
|
|
4925
|
+
},
|
|
4771
4926
|
/**
|
|
4772
4927
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
4773
4928
|
* @param {string} deferredId Deferred token
|
|
@@ -5594,6 +5749,26 @@ class DefaultApi extends base_1.BaseAPI {
|
|
|
5594
5749
|
credentialRevoke(credentialId, walletId, options) {
|
|
5595
5750
|
return (0, exports.DefaultApiFp)(this.configuration).credentialRevoke(credentialId, walletId, options).then((request) => request(this.axios, this.basePath));
|
|
5596
5751
|
}
|
|
5752
|
+
/**
|
|
5753
|
+
* Suspend a Verifiable Credential issued with the `suspension` status purpose (W3C Bitstring Status List v1.0). A suspension can be lifted with `DELETE`.
|
|
5754
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
5755
|
+
* @param {string} walletId
|
|
5756
|
+
* @param {*} [options] Override http request option.
|
|
5757
|
+
* @throws {RequiredError}
|
|
5758
|
+
*/
|
|
5759
|
+
credentialSuspend(credentialId, walletId, options) {
|
|
5760
|
+
return (0, exports.DefaultApiFp)(this.configuration).credentialSuspend(credentialId, walletId, options).then((request) => request(this.axios, this.basePath));
|
|
5761
|
+
}
|
|
5762
|
+
/**
|
|
5763
|
+
* Lift the suspension of a Verifiable Credential.
|
|
5764
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
5765
|
+
* @param {string} walletId
|
|
5766
|
+
* @param {*} [options] Override http request option.
|
|
5767
|
+
* @throws {RequiredError}
|
|
5768
|
+
*/
|
|
5769
|
+
credentialUnsuspend(credentialId, walletId, options) {
|
|
5770
|
+
return (0, exports.DefaultApiFp)(this.configuration).credentialUnsuspend(credentialId, walletId, options).then((request) => request(this.axios, this.basePath));
|
|
5771
|
+
}
|
|
5597
5772
|
/**
|
|
5598
5773
|
* Polls the status of a deferred credential issuance. Returns `in_progress` while the operation is still pending, or `completed` with the resulting credential ID when done. Clients should poll this endpoint until a terminal status is reached.
|
|
5599
5774
|
* @param {string} deferredId Deferred token
|