@triveria/wallet 0.0.55 → 0.0.56
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 +69 -3
- package/api.js +76 -1
- package/package.json +1 -1
package/api.d.ts
CHANGED
|
@@ -210,6 +210,7 @@ export declare const CredentialIssuerDefinitionCredentialFormatEnum: {
|
|
|
210
210
|
export type CredentialIssuerDefinitionCredentialFormatEnum = typeof CredentialIssuerDefinitionCredentialFormatEnum[keyof typeof CredentialIssuerDefinitionCredentialFormatEnum];
|
|
211
211
|
export declare const CredentialIssuerDefinitionCredentialIssuerEnum: {
|
|
212
212
|
readonly CtWalletSame: "CtWalletSame";
|
|
213
|
+
readonly CtRevocable: "CtRevocable";
|
|
213
214
|
readonly IssuanceQueue: "IssuanceQueue";
|
|
214
215
|
};
|
|
215
216
|
export type CredentialIssuerDefinitionCredentialIssuerEnum = typeof CredentialIssuerDefinitionCredentialIssuerEnum[keyof typeof CredentialIssuerDefinitionCredentialIssuerEnum];
|
|
@@ -499,6 +500,19 @@ export interface Did {
|
|
|
499
500
|
*/
|
|
500
501
|
'Did': string;
|
|
501
502
|
}
|
|
503
|
+
/**
|
|
504
|
+
* EBSI specific data
|
|
505
|
+
* @export
|
|
506
|
+
* @interface EbsiSpecificWalletData
|
|
507
|
+
*/
|
|
508
|
+
export interface EbsiSpecificWalletData {
|
|
509
|
+
/**
|
|
510
|
+
*
|
|
511
|
+
* @type {boolean}
|
|
512
|
+
* @memberof EbsiSpecificWalletData
|
|
513
|
+
*/
|
|
514
|
+
'isOnboarded': boolean;
|
|
515
|
+
}
|
|
502
516
|
/**
|
|
503
517
|
* A scheme providing enough information for a verifier to determine whether the evidence gathered by the issuer meets its confidence requirements for relying on the credential
|
|
504
518
|
* @export
|
|
@@ -702,6 +716,19 @@ export interface ModelError {
|
|
|
702
716
|
*/
|
|
703
717
|
'Message': string;
|
|
704
718
|
}
|
|
719
|
+
/**
|
|
720
|
+
* On successful EBSI-onboarding result contains \"did:ebsi\" decentralized identifier
|
|
721
|
+
* @export
|
|
722
|
+
* @interface OnboardResult
|
|
723
|
+
*/
|
|
724
|
+
export interface OnboardResult {
|
|
725
|
+
/**
|
|
726
|
+
*
|
|
727
|
+
* @type {string}
|
|
728
|
+
* @memberof OnboardResult
|
|
729
|
+
*/
|
|
730
|
+
'did': string;
|
|
731
|
+
}
|
|
705
732
|
/**
|
|
706
733
|
* Result of the preauthorized issuance process start. Consists of the preauthorized code, pin, and the issuer url.
|
|
707
734
|
* @export
|
|
@@ -1100,6 +1127,12 @@ export interface WalletConfig {
|
|
|
1100
1127
|
* @memberof WalletConfig
|
|
1101
1128
|
*/
|
|
1102
1129
|
'credentialVerifiers'?: Array<CredentialVerifierDefinition>;
|
|
1130
|
+
/**
|
|
1131
|
+
*
|
|
1132
|
+
* @type {EbsiSpecificWalletData}
|
|
1133
|
+
* @memberof WalletConfig
|
|
1134
|
+
*/
|
|
1135
|
+
'EBSI'?: EbsiSpecificWalletData;
|
|
1103
1136
|
}
|
|
1104
1137
|
/**
|
|
1105
1138
|
*
|
|
@@ -1226,6 +1259,14 @@ export declare const DefaultApiAxiosParamCreator: (configuration?: Configuration
|
|
|
1226
1259
|
* @throws {RequiredError}
|
|
1227
1260
|
*/
|
|
1228
1261
|
credentialRequest: (walletId: string, credentialRequest?: CredentialRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
1262
|
+
/**
|
|
1263
|
+
*
|
|
1264
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1265
|
+
* @param {string} walletId
|
|
1266
|
+
* @param {*} [options] Override http request option.
|
|
1267
|
+
* @throws {RequiredError}
|
|
1268
|
+
*/
|
|
1269
|
+
credentialRevoke: (credentialId: string, walletId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
1229
1270
|
/**
|
|
1230
1271
|
*
|
|
1231
1272
|
* @param {string} deferredId Deferred token
|
|
@@ -1448,6 +1489,14 @@ export declare const DefaultApiFp: (configuration?: Configuration) => {
|
|
|
1448
1489
|
* @throws {RequiredError}
|
|
1449
1490
|
*/
|
|
1450
1491
|
credentialRequest(walletId: string, credentialRequest?: CredentialRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<string>>>;
|
|
1492
|
+
/**
|
|
1493
|
+
*
|
|
1494
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1495
|
+
* @param {string} walletId
|
|
1496
|
+
* @param {*} [options] Override http request option.
|
|
1497
|
+
* @throws {RequiredError}
|
|
1498
|
+
*/
|
|
1499
|
+
credentialRevoke(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
1451
1500
|
/**
|
|
1452
1501
|
*
|
|
1453
1502
|
* @param {string} deferredId Deferred token
|
|
@@ -1562,7 +1611,7 @@ export declare const DefaultApiFp: (configuration?: Configuration) => {
|
|
|
1562
1611
|
* @param {*} [options] Override http request option.
|
|
1563
1612
|
* @throws {RequiredError}
|
|
1564
1613
|
*/
|
|
1565
|
-
onboardLegalEntity(walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<
|
|
1614
|
+
onboardLegalEntity(walletId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OnboardResult>>;
|
|
1566
1615
|
/**
|
|
1567
1616
|
* The call will authenticate the client and create a new wallet that will be accessible only to the client.
|
|
1568
1617
|
* @param {Wallet} [wallet]
|
|
@@ -1670,6 +1719,14 @@ export declare const DefaultApiFactory: (configuration?: Configuration, basePath
|
|
|
1670
1719
|
* @throws {RequiredError}
|
|
1671
1720
|
*/
|
|
1672
1721
|
credentialRequest(walletId: string, credentialRequest?: CredentialRequest, options?: any): AxiosPromise<Array<string>>;
|
|
1722
|
+
/**
|
|
1723
|
+
*
|
|
1724
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1725
|
+
* @param {string} walletId
|
|
1726
|
+
* @param {*} [options] Override http request option.
|
|
1727
|
+
* @throws {RequiredError}
|
|
1728
|
+
*/
|
|
1729
|
+
credentialRevoke(credentialId: string, walletId: string, options?: any): AxiosPromise<void>;
|
|
1673
1730
|
/**
|
|
1674
1731
|
*
|
|
1675
1732
|
* @param {string} deferredId Deferred token
|
|
@@ -1784,7 +1841,7 @@ export declare const DefaultApiFactory: (configuration?: Configuration, basePath
|
|
|
1784
1841
|
* @param {*} [options] Override http request option.
|
|
1785
1842
|
* @throws {RequiredError}
|
|
1786
1843
|
*/
|
|
1787
|
-
onboardLegalEntity(walletId: string, options?: any): AxiosPromise<
|
|
1844
|
+
onboardLegalEntity(walletId: string, options?: any): AxiosPromise<OnboardResult>;
|
|
1788
1845
|
/**
|
|
1789
1846
|
* The call will authenticate the client and create a new wallet that will be accessible only to the client.
|
|
1790
1847
|
* @param {Wallet} [wallet]
|
|
@@ -1902,6 +1959,15 @@ export declare class DefaultApi extends BaseAPI {
|
|
|
1902
1959
|
* @memberof DefaultApi
|
|
1903
1960
|
*/
|
|
1904
1961
|
credentialRequest(walletId: string, credentialRequest?: CredentialRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<string[], any>>;
|
|
1962
|
+
/**
|
|
1963
|
+
*
|
|
1964
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1965
|
+
* @param {string} walletId
|
|
1966
|
+
* @param {*} [options] Override http request option.
|
|
1967
|
+
* @throws {RequiredError}
|
|
1968
|
+
* @memberof DefaultApi
|
|
1969
|
+
*/
|
|
1970
|
+
credentialRevoke(credentialId: string, walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any>>;
|
|
1905
1971
|
/**
|
|
1906
1972
|
*
|
|
1907
1973
|
* @param {string} deferredId Deferred token
|
|
@@ -2031,7 +2097,7 @@ export declare class DefaultApi extends BaseAPI {
|
|
|
2031
2097
|
* @throws {RequiredError}
|
|
2032
2098
|
* @memberof DefaultApi
|
|
2033
2099
|
*/
|
|
2034
|
-
onboardLegalEntity(walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<
|
|
2100
|
+
onboardLegalEntity(walletId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<OnboardResult, any>>;
|
|
2035
2101
|
/**
|
|
2036
2102
|
* The call will authenticate the client and create a new wallet that will be accessible only to the client.
|
|
2037
2103
|
* @param {Wallet} [wallet]
|
package/api.js
CHANGED
|
@@ -37,6 +37,7 @@ exports.CredentialIssuerDefinitionCredentialFormatEnum = {
|
|
|
37
37
|
};
|
|
38
38
|
exports.CredentialIssuerDefinitionCredentialIssuerEnum = {
|
|
39
39
|
CtWalletSame: 'CtWalletSame',
|
|
40
|
+
CtRevocable: 'CtRevocable',
|
|
40
41
|
IssuanceQueue: 'IssuanceQueue'
|
|
41
42
|
};
|
|
42
43
|
exports.CredentialMetadataStatusEnum = {
|
|
@@ -364,6 +365,43 @@ const DefaultApiAxiosParamCreator = function (configuration) {
|
|
|
364
365
|
options: localVarRequestOptions,
|
|
365
366
|
};
|
|
366
367
|
}),
|
|
368
|
+
/**
|
|
369
|
+
*
|
|
370
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
371
|
+
* @param {string} walletId
|
|
372
|
+
* @param {*} [options] Override http request option.
|
|
373
|
+
* @throws {RequiredError}
|
|
374
|
+
*/
|
|
375
|
+
credentialRevoke: (credentialId, walletId, options = {}) => __awaiter(this, void 0, void 0, function* () {
|
|
376
|
+
// verify required parameter 'credentialId' is not null or undefined
|
|
377
|
+
(0, common_1.assertParamExists)('credentialRevoke', 'credentialId', credentialId);
|
|
378
|
+
// verify required parameter 'walletId' is not null or undefined
|
|
379
|
+
(0, common_1.assertParamExists)('credentialRevoke', 'walletId', walletId);
|
|
380
|
+
const localVarPath = `/credentials/{credential_id}/revoke`
|
|
381
|
+
.replace(`{${"credential_id"}}`, encodeURIComponent(String(credentialId)));
|
|
382
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
383
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
384
|
+
let baseOptions;
|
|
385
|
+
if (configuration) {
|
|
386
|
+
baseOptions = configuration.baseOptions;
|
|
387
|
+
}
|
|
388
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
389
|
+
const localVarHeaderParameter = {};
|
|
390
|
+
const localVarQueryParameter = {};
|
|
391
|
+
// authentication accessToken required
|
|
392
|
+
// http bearer authentication required
|
|
393
|
+
yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
|
|
394
|
+
if (walletId != null) {
|
|
395
|
+
localVarHeaderParameter['wallet-id'] = String(walletId);
|
|
396
|
+
}
|
|
397
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
398
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
399
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
400
|
+
return {
|
|
401
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
402
|
+
options: localVarRequestOptions,
|
|
403
|
+
};
|
|
404
|
+
}),
|
|
367
405
|
/**
|
|
368
406
|
*
|
|
369
407
|
* @param {string} deferredId Deferred token
|
|
@@ -862,7 +900,7 @@ const DefaultApiAxiosParamCreator = function (configuration) {
|
|
|
862
900
|
if (configuration) {
|
|
863
901
|
baseOptions = configuration.baseOptions;
|
|
864
902
|
}
|
|
865
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
903
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
866
904
|
const localVarHeaderParameter = {};
|
|
867
905
|
const localVarQueryParameter = {};
|
|
868
906
|
// authentication accessToken required
|
|
@@ -1172,6 +1210,22 @@ const DefaultApiFp = function (configuration) {
|
|
|
1172
1210
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, operationBasePath || basePath);
|
|
1173
1211
|
});
|
|
1174
1212
|
},
|
|
1213
|
+
/**
|
|
1214
|
+
*
|
|
1215
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1216
|
+
* @param {string} walletId
|
|
1217
|
+
* @param {*} [options] Override http request option.
|
|
1218
|
+
* @throws {RequiredError}
|
|
1219
|
+
*/
|
|
1220
|
+
credentialRevoke(credentialId, walletId, options) {
|
|
1221
|
+
var _a, _b, _c;
|
|
1222
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1223
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.credentialRevoke(credentialId, walletId, options);
|
|
1224
|
+
const index = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
1225
|
+
const operationBasePath = (_c = (_b = base_1.operationServerMap['DefaultApi.credentialRevoke']) === null || _b === void 0 ? void 0 : _b[index]) === null || _c === void 0 ? void 0 : _c.url;
|
|
1226
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, operationBasePath || basePath);
|
|
1227
|
+
});
|
|
1228
|
+
},
|
|
1175
1229
|
/**
|
|
1176
1230
|
*
|
|
1177
1231
|
* @param {string} deferredId Deferred token
|
|
@@ -1574,6 +1628,16 @@ const DefaultApiFactory = function (configuration, basePath, axios) {
|
|
|
1574
1628
|
credentialRequest(walletId, credentialRequest, options) {
|
|
1575
1629
|
return localVarFp.credentialRequest(walletId, credentialRequest, options).then((request) => request(axios, basePath));
|
|
1576
1630
|
},
|
|
1631
|
+
/**
|
|
1632
|
+
*
|
|
1633
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1634
|
+
* @param {string} walletId
|
|
1635
|
+
* @param {*} [options] Override http request option.
|
|
1636
|
+
* @throws {RequiredError}
|
|
1637
|
+
*/
|
|
1638
|
+
credentialRevoke(credentialId, walletId, options) {
|
|
1639
|
+
return localVarFp.credentialRevoke(credentialId, walletId, options).then((request) => request(axios, basePath));
|
|
1640
|
+
},
|
|
1577
1641
|
/**
|
|
1578
1642
|
*
|
|
1579
1643
|
* @param {string} deferredId Deferred token
|
|
@@ -1864,6 +1928,17 @@ class DefaultApi extends base_1.BaseAPI {
|
|
|
1864
1928
|
credentialRequest(walletId, credentialRequest, options) {
|
|
1865
1929
|
return (0, exports.DefaultApiFp)(this.configuration).credentialRequest(walletId, credentialRequest, options).then((request) => request(this.axios, this.basePath));
|
|
1866
1930
|
}
|
|
1931
|
+
/**
|
|
1932
|
+
*
|
|
1933
|
+
* @param {string} credentialId Verifiable Credential Identifier
|
|
1934
|
+
* @param {string} walletId
|
|
1935
|
+
* @param {*} [options] Override http request option.
|
|
1936
|
+
* @throws {RequiredError}
|
|
1937
|
+
* @memberof DefaultApi
|
|
1938
|
+
*/
|
|
1939
|
+
credentialRevoke(credentialId, walletId, options) {
|
|
1940
|
+
return (0, exports.DefaultApiFp)(this.configuration).credentialRevoke(credentialId, walletId, options).then((request) => request(this.axios, this.basePath));
|
|
1941
|
+
}
|
|
1867
1942
|
/**
|
|
1868
1943
|
*
|
|
1869
1944
|
* @param {string} deferredId Deferred token
|