@credo-ts/cheqd 0.6.1-pr-2091-20241119140918 → 0.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/CheqdApi.d.mts +45 -0
- package/build/CheqdApi.d.mts.map +1 -0
- package/build/CheqdApi.mjs +26 -0
- package/build/CheqdApi.mjs.map +1 -0
- package/build/CheqdModule.d.mts +15 -0
- package/build/CheqdModule.d.mts.map +1 -0
- package/build/CheqdModule.mjs +25 -0
- package/build/CheqdModule.mjs.map +1 -0
- package/build/CheqdModuleConfig.d.mts +21 -0
- package/build/CheqdModuleConfig.d.mts.map +1 -0
- package/build/CheqdModuleConfig.mjs +14 -0
- package/build/CheqdModuleConfig.mjs.map +1 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorate.mjs +10 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorateMetadata.mjs +7 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorateParam.mjs +9 -0
- package/build/anoncreds/index.d.mts +1 -0
- package/build/anoncreds/index.mjs +1 -0
- package/build/anoncreds/services/CheqdAnonCredsRegistry.d.mts +32 -0
- package/build/anoncreds/services/CheqdAnonCredsRegistry.d.mts.map +1 -0
- package/build/anoncreds/services/CheqdAnonCredsRegistry.mjs +349 -0
- package/build/anoncreds/services/CheqdAnonCredsRegistry.mjs.map +1 -0
- package/build/anoncreds/utils/identifiers.mjs +56 -0
- package/build/anoncreds/utils/identifiers.mjs.map +1 -0
- package/build/anoncreds/utils/transform.mjs +104 -0
- package/build/anoncreds/utils/transform.mjs.map +1 -0
- package/build/dids/CheqdDidRegistrar.d.mts +102 -0
- package/build/dids/CheqdDidRegistrar.d.mts.map +1 -0
- package/build/dids/CheqdDidRegistrar.mjs +446 -0
- package/build/dids/CheqdDidRegistrar.mjs.map +1 -0
- package/build/dids/CheqdDidResolver.d.mts +30 -0
- package/build/dids/CheqdDidResolver.d.mts.map +1 -0
- package/build/dids/CheqdDidResolver.mjs +135 -0
- package/build/dids/CheqdDidResolver.mjs.map +1 -0
- package/build/dids/didCheqdUtil.mjs +113 -0
- package/build/dids/didCheqdUtil.mjs.map +1 -0
- package/build/dids/index.d.mts +2 -0
- package/build/dids/index.mjs +2 -0
- package/build/index.d.mts +10 -0
- package/build/index.mjs +11 -0
- package/build/ledger/CheqdLedgerService.d.mts +35 -0
- package/build/ledger/CheqdLedgerService.d.mts.map +1 -0
- package/build/ledger/CheqdLedgerService.mjs +114 -0
- package/build/ledger/CheqdLedgerService.mjs.map +1 -0
- package/build/ledger/index.d.mts +1 -0
- package/build/ledger/index.mjs +1 -0
- package/package.json +22 -22
- package/build/CheqdApi.d.ts +0 -38
- package/build/CheqdApi.js +0 -34
- package/build/CheqdApi.js.map +0 -1
- package/build/CheqdModule.d.ts +0 -11
- package/build/CheqdModule.js +0 -33
- package/build/CheqdModule.js.map +0 -1
- package/build/CheqdModuleConfig.d.ts +0 -17
- package/build/CheqdModuleConfig.js +0 -14
- package/build/CheqdModuleConfig.js.map +0 -1
- package/build/anoncreds/index.d.ts +0 -1
- package/build/anoncreds/index.js +0 -6
- package/build/anoncreds/index.js.map +0 -1
- package/build/anoncreds/services/CheqdAnonCredsRegistry.d.ts +0 -19
- package/build/anoncreds/services/CheqdAnonCredsRegistry.js +0 -368
- package/build/anoncreds/services/CheqdAnonCredsRegistry.js.map +0 -1
- package/build/anoncreds/utils/identifiers.d.ts +0 -13
- package/build/anoncreds/utils/identifiers.js +0 -53
- package/build/anoncreds/utils/identifiers.js.map +0 -1
- package/build/anoncreds/utils/transform.d.ts +0 -43
- package/build/anoncreds/utils/transform.js +0 -170
- package/build/anoncreds/utils/transform.js.map +0 -1
- package/build/dids/CheqdDidRegistrar.d.ts +0 -86
- package/build/dids/CheqdDidRegistrar.js +0 -334
- package/build/dids/CheqdDidRegistrar.js.map +0 -1
- package/build/dids/CheqdDidResolver.d.ts +0 -25
- package/build/dids/CheqdDidResolver.js +0 -171
- package/build/dids/CheqdDidResolver.js.map +0 -1
- package/build/dids/didCheqdUtil.d.ts +0 -28
- package/build/dids/didCheqdUtil.js +0 -129
- package/build/dids/didCheqdUtil.js.map +0 -1
- package/build/dids/index.d.ts +0 -2
- package/build/dids/index.js +0 -8
- package/build/dids/index.js.map +0 -1
- package/build/index.d.ts +0 -5
- package/build/index.js +0 -17
- package/build/index.js.map +0 -1
- package/build/ledger/CheqdLedgerService.d.ts +0 -37
- package/build/ledger/CheqdLedgerService.js +0 -135
- package/build/ledger/CheqdLedgerService.js.map +0 -1
- package/build/ledger/index.d.ts +0 -1
- package/build/ledger/index.js +0 -6
- package/build/ledger/index.js.map +0 -1
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import type { AnonCredsCredentialDefinition, AnonCredsRevocationRegistryDefinition, AnonCredsRevocationStatusList, AnonCredsSchema } from '@credo-ts/anoncreds';
|
|
2
|
-
export declare class CheqdSchema {
|
|
3
|
-
constructor(options: Omit<AnonCredsSchema, 'issuerId'>);
|
|
4
|
-
name: string;
|
|
5
|
-
attrNames: string[];
|
|
6
|
-
version: string;
|
|
7
|
-
}
|
|
8
|
-
export declare class CheqdCredentialDefinitionValue {
|
|
9
|
-
primary: Record<string, unknown>;
|
|
10
|
-
revocation?: unknown;
|
|
11
|
-
}
|
|
12
|
-
export declare class CheqdCredentialDefinition {
|
|
13
|
-
constructor(options: Omit<AnonCredsCredentialDefinition, 'issuerId'>);
|
|
14
|
-
schemaId: string;
|
|
15
|
-
type: 'CL';
|
|
16
|
-
tag: string;
|
|
17
|
-
value: CheqdCredentialDefinitionValue;
|
|
18
|
-
}
|
|
19
|
-
export declare class AccumKey {
|
|
20
|
-
z: string;
|
|
21
|
-
}
|
|
22
|
-
export declare class PublicKeys {
|
|
23
|
-
accumKey: AccumKey;
|
|
24
|
-
}
|
|
25
|
-
export declare class CheqdRevocationRegistryDefinitionValue {
|
|
26
|
-
publicKeys: PublicKeys;
|
|
27
|
-
maxCredNum: number;
|
|
28
|
-
tailsLocation: string;
|
|
29
|
-
tailsHash: string;
|
|
30
|
-
}
|
|
31
|
-
export declare class CheqdRevocationRegistryDefinition {
|
|
32
|
-
constructor(options: Omit<AnonCredsRevocationRegistryDefinition, 'issuerId'>);
|
|
33
|
-
revocDefType: 'CL_ACCUM';
|
|
34
|
-
credDefId: string;
|
|
35
|
-
tag: string;
|
|
36
|
-
value: CheqdRevocationRegistryDefinitionValue;
|
|
37
|
-
}
|
|
38
|
-
export declare class CheqdRevocationStatusList {
|
|
39
|
-
constructor(options: Omit<AnonCredsRevocationStatusList, 'issuerId'>);
|
|
40
|
-
revRegDefId: string;
|
|
41
|
-
revocationList: number[];
|
|
42
|
-
currentAccumulator: string;
|
|
43
|
-
}
|
|
@@ -1,170 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// These functions will throw an error if the JSON doesn't
|
|
3
|
-
// match the expected interface, even if the JSON is valid.
|
|
4
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
5
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
6
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
7
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
8
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
9
|
-
};
|
|
10
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
11
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
12
|
-
};
|
|
13
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
-
exports.CheqdRevocationStatusList = exports.CheqdRevocationRegistryDefinition = exports.CheqdRevocationRegistryDefinitionValue = exports.PublicKeys = exports.AccumKey = exports.CheqdCredentialDefinition = exports.CheqdCredentialDefinitionValue = exports.CheqdSchema = void 0;
|
|
15
|
-
const class_transformer_1 = require("class-transformer");
|
|
16
|
-
const class_validator_1 = require("class-validator");
|
|
17
|
-
class CheqdSchema {
|
|
18
|
-
constructor(options) {
|
|
19
|
-
if (options) {
|
|
20
|
-
this.name = options.name;
|
|
21
|
-
this.attrNames = options.attrNames;
|
|
22
|
-
this.version = options.version;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
exports.CheqdSchema = CheqdSchema;
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, class_validator_1.IsString)(),
|
|
29
|
-
__metadata("design:type", String)
|
|
30
|
-
], CheqdSchema.prototype, "name", void 0);
|
|
31
|
-
__decorate([
|
|
32
|
-
(0, class_validator_1.IsArray)(),
|
|
33
|
-
(0, class_validator_1.IsString)({ each: true }),
|
|
34
|
-
(0, class_validator_1.ArrayMinSize)(1),
|
|
35
|
-
__metadata("design:type", Array)
|
|
36
|
-
], CheqdSchema.prototype, "attrNames", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, class_validator_1.IsString)(),
|
|
39
|
-
__metadata("design:type", String)
|
|
40
|
-
], CheqdSchema.prototype, "version", void 0);
|
|
41
|
-
class CheqdCredentialDefinitionValue {
|
|
42
|
-
}
|
|
43
|
-
exports.CheqdCredentialDefinitionValue = CheqdCredentialDefinitionValue;
|
|
44
|
-
__decorate([
|
|
45
|
-
(0, class_validator_1.IsObject)(),
|
|
46
|
-
__metadata("design:type", Object)
|
|
47
|
-
], CheqdCredentialDefinitionValue.prototype, "primary", void 0);
|
|
48
|
-
__decorate([
|
|
49
|
-
(0, class_validator_1.IsObject)(),
|
|
50
|
-
(0, class_validator_1.IsOptional)(),
|
|
51
|
-
__metadata("design:type", Object)
|
|
52
|
-
], CheqdCredentialDefinitionValue.prototype, "revocation", void 0);
|
|
53
|
-
class CheqdCredentialDefinition {
|
|
54
|
-
constructor(options) {
|
|
55
|
-
if (options) {
|
|
56
|
-
this.schemaId = options.schemaId;
|
|
57
|
-
this.type = options.type;
|
|
58
|
-
this.tag = options.tag;
|
|
59
|
-
this.value = options.value;
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
exports.CheqdCredentialDefinition = CheqdCredentialDefinition;
|
|
64
|
-
__decorate([
|
|
65
|
-
(0, class_validator_1.IsString)(),
|
|
66
|
-
__metadata("design:type", String)
|
|
67
|
-
], CheqdCredentialDefinition.prototype, "schemaId", void 0);
|
|
68
|
-
__decorate([
|
|
69
|
-
(0, class_validator_1.Contains)('CL'),
|
|
70
|
-
__metadata("design:type", String)
|
|
71
|
-
], CheqdCredentialDefinition.prototype, "type", void 0);
|
|
72
|
-
__decorate([
|
|
73
|
-
(0, class_validator_1.IsString)(),
|
|
74
|
-
__metadata("design:type", String)
|
|
75
|
-
], CheqdCredentialDefinition.prototype, "tag", void 0);
|
|
76
|
-
__decorate([
|
|
77
|
-
(0, class_validator_1.ValidateNested)(),
|
|
78
|
-
(0, class_validator_1.IsInstance)(CheqdCredentialDefinitionValue),
|
|
79
|
-
(0, class_transformer_1.Type)(() => CheqdCredentialDefinitionValue),
|
|
80
|
-
__metadata("design:type", CheqdCredentialDefinitionValue)
|
|
81
|
-
], CheqdCredentialDefinition.prototype, "value", void 0);
|
|
82
|
-
class AccumKey {
|
|
83
|
-
}
|
|
84
|
-
exports.AccumKey = AccumKey;
|
|
85
|
-
__decorate([
|
|
86
|
-
(0, class_validator_1.IsString)(),
|
|
87
|
-
__metadata("design:type", String)
|
|
88
|
-
], AccumKey.prototype, "z", void 0);
|
|
89
|
-
class PublicKeys {
|
|
90
|
-
}
|
|
91
|
-
exports.PublicKeys = PublicKeys;
|
|
92
|
-
__decorate([
|
|
93
|
-
(0, class_validator_1.ValidateNested)(),
|
|
94
|
-
(0, class_validator_1.IsInstance)(AccumKey),
|
|
95
|
-
(0, class_transformer_1.Type)(() => AccumKey),
|
|
96
|
-
__metadata("design:type", AccumKey)
|
|
97
|
-
], PublicKeys.prototype, "accumKey", void 0);
|
|
98
|
-
class CheqdRevocationRegistryDefinitionValue {
|
|
99
|
-
}
|
|
100
|
-
exports.CheqdRevocationRegistryDefinitionValue = CheqdRevocationRegistryDefinitionValue;
|
|
101
|
-
__decorate([
|
|
102
|
-
(0, class_validator_1.ValidateNested)(),
|
|
103
|
-
(0, class_validator_1.IsInstance)(PublicKeys),
|
|
104
|
-
(0, class_transformer_1.Type)(() => PublicKeys),
|
|
105
|
-
__metadata("design:type", PublicKeys)
|
|
106
|
-
], CheqdRevocationRegistryDefinitionValue.prototype, "publicKeys", void 0);
|
|
107
|
-
__decorate([
|
|
108
|
-
(0, class_validator_1.IsNumber)(),
|
|
109
|
-
__metadata("design:type", Number)
|
|
110
|
-
], CheqdRevocationRegistryDefinitionValue.prototype, "maxCredNum", void 0);
|
|
111
|
-
__decorate([
|
|
112
|
-
(0, class_validator_1.IsString)(),
|
|
113
|
-
__metadata("design:type", String)
|
|
114
|
-
], CheqdRevocationRegistryDefinitionValue.prototype, "tailsLocation", void 0);
|
|
115
|
-
__decorate([
|
|
116
|
-
(0, class_validator_1.IsString)(),
|
|
117
|
-
__metadata("design:type", String)
|
|
118
|
-
], CheqdRevocationRegistryDefinitionValue.prototype, "tailsHash", void 0);
|
|
119
|
-
class CheqdRevocationRegistryDefinition {
|
|
120
|
-
constructor(options) {
|
|
121
|
-
if (options) {
|
|
122
|
-
this.revocDefType = options.revocDefType;
|
|
123
|
-
this.credDefId = options.credDefId;
|
|
124
|
-
this.tag = options.tag;
|
|
125
|
-
this.value = options.value;
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
exports.CheqdRevocationRegistryDefinition = CheqdRevocationRegistryDefinition;
|
|
130
|
-
__decorate([
|
|
131
|
-
(0, class_validator_1.Contains)('CL_ACCUM'),
|
|
132
|
-
__metadata("design:type", String)
|
|
133
|
-
], CheqdRevocationRegistryDefinition.prototype, "revocDefType", void 0);
|
|
134
|
-
__decorate([
|
|
135
|
-
(0, class_validator_1.IsString)(),
|
|
136
|
-
__metadata("design:type", String)
|
|
137
|
-
], CheqdRevocationRegistryDefinition.prototype, "credDefId", void 0);
|
|
138
|
-
__decorate([
|
|
139
|
-
(0, class_validator_1.IsString)(),
|
|
140
|
-
__metadata("design:type", String)
|
|
141
|
-
], CheqdRevocationRegistryDefinition.prototype, "tag", void 0);
|
|
142
|
-
__decorate([
|
|
143
|
-
(0, class_validator_1.ValidateNested)(),
|
|
144
|
-
(0, class_validator_1.IsInstance)(CheqdRevocationRegistryDefinitionValue),
|
|
145
|
-
(0, class_transformer_1.Type)(() => CheqdRevocationRegistryDefinitionValue),
|
|
146
|
-
__metadata("design:type", CheqdRevocationRegistryDefinitionValue)
|
|
147
|
-
], CheqdRevocationRegistryDefinition.prototype, "value", void 0);
|
|
148
|
-
class CheqdRevocationStatusList {
|
|
149
|
-
constructor(options) {
|
|
150
|
-
if (options) {
|
|
151
|
-
this.revRegDefId = options.revRegDefId;
|
|
152
|
-
this.revocationList = options.revocationList;
|
|
153
|
-
this.currentAccumulator = options.currentAccumulator;
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
exports.CheqdRevocationStatusList = CheqdRevocationStatusList;
|
|
158
|
-
__decorate([
|
|
159
|
-
(0, class_validator_1.IsString)(),
|
|
160
|
-
__metadata("design:type", String)
|
|
161
|
-
], CheqdRevocationStatusList.prototype, "revRegDefId", void 0);
|
|
162
|
-
__decorate([
|
|
163
|
-
(0, class_validator_1.IsNumber)({}, { each: true }),
|
|
164
|
-
__metadata("design:type", Array)
|
|
165
|
-
], CheqdRevocationStatusList.prototype, "revocationList", void 0);
|
|
166
|
-
__decorate([
|
|
167
|
-
(0, class_validator_1.IsString)(),
|
|
168
|
-
__metadata("design:type", String)
|
|
169
|
-
], CheqdRevocationStatusList.prototype, "currentAccumulator", void 0);
|
|
170
|
-
//# sourceMappingURL=transform.js.map
|
|
@@ -1 +0,0 @@
|
|
|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AHN,IAAA,gCAAc,GAAE;IAChB,IAAA,4BAAU,EAAC,sCAAsC,CAAC;IAClD,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,sCAAsC,CAAC;8BACpC,sCAAsC;gEAAA;AAGvD,MAAa,yBAAyB;IACpC,YAAmB,OAAwD;QACzE,IAAI,OAAO,EAAE,CAAC;YACZ,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,WAAW,CAAA;YACtC,IAAI,CAAC,cAAc,GAAG,OAAO,CAAC,cAAc,CAAA;YAC5C,IAAI,CAAC,kBAAkB,GAAG,OAAO,CAAC,kBAAkB,CAAA;QACtD,CAAC;IACH,CAAC;CAUF;AAjBD,8DAiBC;AAPQ;IADN,IAAA,0BAAQ,GAAE;;8DACgB;AAGpB;IADN,IAAA,0BAAQ,EAAC,EAAE,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;;iEACG;AAGzB;IADN,IAAA,0BAAQ,GAAE;;qEACuB"}
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
import type { CheqdNetwork, DidStdFee, TVerificationKey, VerificationMethods } from '@cheqd/sdk';
|
|
2
|
-
import type { AgentContext, DidRegistrar, DidCreateOptions, DidCreateResult, DidDeactivateResult, DidUpdateResult, DidUpdateOptions } from '@credo-ts/core';
|
|
3
|
-
import { MethodSpecificIdAlgo } from '@cheqd/sdk';
|
|
4
|
-
import { MsgCreateResourcePayload } from '@cheqd/ts-proto/cheqd/resource/v2';
|
|
5
|
-
import { DidDocument, Buffer } from '@credo-ts/core';
|
|
6
|
-
export declare class CheqdDidRegistrar implements DidRegistrar {
|
|
7
|
-
readonly supportedMethods: string[];
|
|
8
|
-
create(agentContext: AgentContext, options: CheqdDidCreateOptions): Promise<DidCreateResult>;
|
|
9
|
-
update(agentContext: AgentContext, options: CheqdDidUpdateOptions): Promise<DidUpdateResult>;
|
|
10
|
-
deactivate(agentContext: AgentContext, options: CheqdDidDeactivateOptions): Promise<DidDeactivateResult>;
|
|
11
|
-
createResource(agentContext: AgentContext, did: string, resource: CheqdCreateResourceOptions): Promise<{
|
|
12
|
-
resourceMetadata: {};
|
|
13
|
-
resourceRegistrationMetadata: {};
|
|
14
|
-
resourceState: {
|
|
15
|
-
state: string;
|
|
16
|
-
reason: string;
|
|
17
|
-
resourceId?: undefined;
|
|
18
|
-
resource?: undefined;
|
|
19
|
-
};
|
|
20
|
-
} | {
|
|
21
|
-
resourceMetadata: {};
|
|
22
|
-
resourceRegistrationMetadata: {};
|
|
23
|
-
resourceState: {
|
|
24
|
-
state: string;
|
|
25
|
-
resourceId: string;
|
|
26
|
-
resource: MsgCreateResourcePayload;
|
|
27
|
-
reason?: undefined;
|
|
28
|
-
};
|
|
29
|
-
}>;
|
|
30
|
-
private signPayload;
|
|
31
|
-
}
|
|
32
|
-
export interface CheqdDidCreateWithoutDidDocumentOptions extends DidCreateOptions {
|
|
33
|
-
method: 'cheqd';
|
|
34
|
-
did?: undefined;
|
|
35
|
-
didDocument?: undefined;
|
|
36
|
-
options: {
|
|
37
|
-
network: `${CheqdNetwork}`;
|
|
38
|
-
fee?: DidStdFee;
|
|
39
|
-
versionId?: string;
|
|
40
|
-
methodSpecificIdAlgo?: `${MethodSpecificIdAlgo}`;
|
|
41
|
-
};
|
|
42
|
-
secret: {
|
|
43
|
-
verificationMethod: IVerificationMethod;
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
export interface CheqdDidCreateFromDidDocumentOptions extends DidCreateOptions {
|
|
47
|
-
method: 'cheqd';
|
|
48
|
-
did?: undefined;
|
|
49
|
-
didDocument: DidDocument;
|
|
50
|
-
options?: {
|
|
51
|
-
fee?: DidStdFee;
|
|
52
|
-
versionId?: string;
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
export type CheqdDidCreateOptions = CheqdDidCreateFromDidDocumentOptions | CheqdDidCreateWithoutDidDocumentOptions;
|
|
56
|
-
export interface CheqdDidUpdateOptions extends DidUpdateOptions {
|
|
57
|
-
did: string;
|
|
58
|
-
didDocument: DidDocument;
|
|
59
|
-
options: {
|
|
60
|
-
fee?: DidStdFee;
|
|
61
|
-
versionId?: string;
|
|
62
|
-
};
|
|
63
|
-
secret?: {
|
|
64
|
-
verificationMethod: IVerificationMethod;
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
export interface CheqdDidDeactivateOptions extends DidCreateOptions {
|
|
68
|
-
method: 'cheqd';
|
|
69
|
-
did: string;
|
|
70
|
-
options: {
|
|
71
|
-
fee?: DidStdFee;
|
|
72
|
-
versionId?: string;
|
|
73
|
-
};
|
|
74
|
-
}
|
|
75
|
-
export interface CheqdCreateResourceOptions extends Pick<MsgCreateResourcePayload, 'id' | 'name' | 'resourceType'> {
|
|
76
|
-
data: string | Uint8Array | object;
|
|
77
|
-
collectionId?: MsgCreateResourcePayload['collectionId'];
|
|
78
|
-
version?: MsgCreateResourcePayload['version'];
|
|
79
|
-
alsoKnownAs?: MsgCreateResourcePayload['alsoKnownAs'];
|
|
80
|
-
}
|
|
81
|
-
interface IVerificationMethod {
|
|
82
|
-
type: `${VerificationMethods}`;
|
|
83
|
-
id: TVerificationKey<string, number>;
|
|
84
|
-
privateKey?: Buffer;
|
|
85
|
-
}
|
|
86
|
-
export {};
|
|
@@ -1,334 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.CheqdDidRegistrar = void 0;
|
|
4
|
-
const sdk_1 = require("@cheqd/sdk");
|
|
5
|
-
const v2_1 = require("@cheqd/ts-proto/cheqd/resource/v2");
|
|
6
|
-
const core_1 = require("@credo-ts/core");
|
|
7
|
-
const identifiers_1 = require("../anoncreds/utils/identifiers");
|
|
8
|
-
const ledger_1 = require("../ledger");
|
|
9
|
-
const didCheqdUtil_1 = require("./didCheqdUtil");
|
|
10
|
-
class CheqdDidRegistrar {
|
|
11
|
-
constructor() {
|
|
12
|
-
this.supportedMethods = ['cheqd'];
|
|
13
|
-
}
|
|
14
|
-
async create(agentContext, options) {
|
|
15
|
-
var _a, _b, _c;
|
|
16
|
-
const didRepository = agentContext.dependencyManager.resolve(core_1.DidRepository);
|
|
17
|
-
const cheqdLedgerService = agentContext.dependencyManager.resolve(ledger_1.CheqdLedgerService);
|
|
18
|
-
let didDocument;
|
|
19
|
-
const versionId = (_b = (_a = options.options) === null || _a === void 0 ? void 0 : _a.versionId) !== null && _b !== void 0 ? _b : core_1.utils.uuid();
|
|
20
|
-
try {
|
|
21
|
-
if (options.didDocument && (0, didCheqdUtil_1.validateSpecCompliantPayload)(options.didDocument)) {
|
|
22
|
-
didDocument = options.didDocument;
|
|
23
|
-
const cheqdDid = (0, identifiers_1.parseCheqdDid)(options.didDocument.id);
|
|
24
|
-
if (!cheqdDid) {
|
|
25
|
-
return {
|
|
26
|
-
didDocumentMetadata: {},
|
|
27
|
-
didRegistrationMetadata: {},
|
|
28
|
-
didState: {
|
|
29
|
-
state: 'failed',
|
|
30
|
-
reason: `Unable to parse cheqd did ${options.didDocument.id}`,
|
|
31
|
-
},
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
else if ((_c = options.secret) === null || _c === void 0 ? void 0 : _c.verificationMethod) {
|
|
36
|
-
const withoutDidDocumentOptions = options;
|
|
37
|
-
const verificationMethod = withoutDidDocumentOptions.secret.verificationMethod;
|
|
38
|
-
const methodSpecificIdAlgo = withoutDidDocumentOptions.options.methodSpecificIdAlgo;
|
|
39
|
-
const privateKey = verificationMethod.privateKey;
|
|
40
|
-
if (privateKey && !(0, core_1.isValidPrivateKey)(privateKey, core_1.KeyType.Ed25519)) {
|
|
41
|
-
return {
|
|
42
|
-
didDocumentMetadata: {},
|
|
43
|
-
didRegistrationMetadata: {},
|
|
44
|
-
didState: {
|
|
45
|
-
state: 'failed',
|
|
46
|
-
reason: 'Invalid private key provided',
|
|
47
|
-
},
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
const key = await agentContext.wallet.createKey({
|
|
51
|
-
keyType: core_1.KeyType.Ed25519,
|
|
52
|
-
privateKey: privateKey,
|
|
53
|
-
});
|
|
54
|
-
didDocument = (0, didCheqdUtil_1.generateDidDoc)({
|
|
55
|
-
verificationMethod: verificationMethod.type,
|
|
56
|
-
verificationMethodId: verificationMethod.id || 'key-1',
|
|
57
|
-
methodSpecificIdAlgo: methodSpecificIdAlgo || sdk_1.MethodSpecificIdAlgo.Uuid,
|
|
58
|
-
network: withoutDidDocumentOptions.options.network,
|
|
59
|
-
publicKey: core_1.TypedArrayEncoder.toHex(key.publicKey),
|
|
60
|
-
});
|
|
61
|
-
const contextMapping = {
|
|
62
|
-
Ed25519VerificationKey2018: 'https://w3id.org/security/suites/ed25519-2018/v1',
|
|
63
|
-
Ed25519VerificationKey2020: 'https://w3id.org/security/suites/ed25519-2020/v1',
|
|
64
|
-
JsonWebKey2020: 'https://w3id.org/security/suites/jws-2020/v1',
|
|
65
|
-
};
|
|
66
|
-
const contextUrl = contextMapping[verificationMethod.type];
|
|
67
|
-
// Add the context to the did document
|
|
68
|
-
// NOTE: cheqd sdk uses https://www.w3.org/ns/did/v1 while Credo did doc uses https://w3id.org/did/v1
|
|
69
|
-
// We should align these at some point. For now we just return a consistent value.
|
|
70
|
-
didDocument.context = ['https://www.w3.org/ns/did/v1', contextUrl];
|
|
71
|
-
}
|
|
72
|
-
else {
|
|
73
|
-
return {
|
|
74
|
-
didDocumentMetadata: {},
|
|
75
|
-
didRegistrationMetadata: {},
|
|
76
|
-
didState: {
|
|
77
|
-
state: 'failed',
|
|
78
|
-
reason: 'Provide a didDocument or at least one verificationMethod with seed in secret',
|
|
79
|
-
},
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
const didDocumentJson = didDocument.toJSON();
|
|
83
|
-
const payloadToSign = await (0, didCheqdUtil_1.createMsgCreateDidDocPayloadToSign)(didDocumentJson, versionId);
|
|
84
|
-
const signInputs = await this.signPayload(agentContext, payloadToSign, didDocument.verificationMethod);
|
|
85
|
-
const response = await cheqdLedgerService.create(didDocumentJson, signInputs, versionId);
|
|
86
|
-
if (response.code !== 0) {
|
|
87
|
-
throw new Error(`${response.rawLog}`);
|
|
88
|
-
}
|
|
89
|
-
// Save the did so we know we created it and can issue with it
|
|
90
|
-
const didRecord = new core_1.DidRecord({
|
|
91
|
-
did: didDocument.id,
|
|
92
|
-
role: core_1.DidDocumentRole.Created,
|
|
93
|
-
didDocument,
|
|
94
|
-
});
|
|
95
|
-
await didRepository.save(agentContext, didRecord);
|
|
96
|
-
return {
|
|
97
|
-
didDocumentMetadata: {},
|
|
98
|
-
didRegistrationMetadata: {},
|
|
99
|
-
didState: {
|
|
100
|
-
state: 'finished',
|
|
101
|
-
did: didDocument.id,
|
|
102
|
-
didDocument,
|
|
103
|
-
secret: options.secret,
|
|
104
|
-
},
|
|
105
|
-
};
|
|
106
|
-
}
|
|
107
|
-
catch (error) {
|
|
108
|
-
agentContext.config.logger.error(`Error registering DID`, error);
|
|
109
|
-
return {
|
|
110
|
-
didDocumentMetadata: {},
|
|
111
|
-
didRegistrationMetadata: {},
|
|
112
|
-
didState: {
|
|
113
|
-
state: 'failed',
|
|
114
|
-
reason: `unknownError: ${error.message}`,
|
|
115
|
-
},
|
|
116
|
-
};
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
async update(agentContext, options) {
|
|
120
|
-
var _a, _b, _c;
|
|
121
|
-
const didRepository = agentContext.dependencyManager.resolve(core_1.DidRepository);
|
|
122
|
-
const cheqdLedgerService = agentContext.dependencyManager.resolve(ledger_1.CheqdLedgerService);
|
|
123
|
-
const versionId = ((_a = options.options) === null || _a === void 0 ? void 0 : _a.versionId) || core_1.utils.uuid();
|
|
124
|
-
const verificationMethod = (_b = options.secret) === null || _b === void 0 ? void 0 : _b.verificationMethod;
|
|
125
|
-
let didDocument;
|
|
126
|
-
let didRecord;
|
|
127
|
-
try {
|
|
128
|
-
if (options.didDocument && (0, didCheqdUtil_1.validateSpecCompliantPayload)(options.didDocument)) {
|
|
129
|
-
didDocument = options.didDocument;
|
|
130
|
-
const resolvedDocument = await cheqdLedgerService.resolve(didDocument.id);
|
|
131
|
-
didRecord = await didRepository.findCreatedDid(agentContext, didDocument.id);
|
|
132
|
-
if (!resolvedDocument.didDocument || resolvedDocument.didDocumentMetadata.deactivated || !didRecord) {
|
|
133
|
-
return {
|
|
134
|
-
didDocumentMetadata: {},
|
|
135
|
-
didRegistrationMetadata: {},
|
|
136
|
-
didState: {
|
|
137
|
-
state: 'failed',
|
|
138
|
-
reason: 'Did not found',
|
|
139
|
-
},
|
|
140
|
-
};
|
|
141
|
-
}
|
|
142
|
-
if (verificationMethod) {
|
|
143
|
-
const privateKey = verificationMethod.privateKey;
|
|
144
|
-
if (privateKey && !(0, core_1.isValidPrivateKey)(privateKey, core_1.KeyType.Ed25519)) {
|
|
145
|
-
return {
|
|
146
|
-
didDocumentMetadata: {},
|
|
147
|
-
didRegistrationMetadata: {},
|
|
148
|
-
didState: {
|
|
149
|
-
state: 'failed',
|
|
150
|
-
reason: 'Invalid private key provided',
|
|
151
|
-
},
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
const key = await agentContext.wallet.createKey({
|
|
155
|
-
keyType: core_1.KeyType.Ed25519,
|
|
156
|
-
privateKey: privateKey,
|
|
157
|
-
});
|
|
158
|
-
(_c = didDocument.verificationMethod) === null || _c === void 0 ? void 0 : _c.concat(core_1.JsonTransformer.fromJSON((0, sdk_1.createDidVerificationMethod)([verificationMethod.type], [
|
|
159
|
-
{
|
|
160
|
-
methodSpecificId: didDocument.id.split(':')[3],
|
|
161
|
-
didUrl: didDocument.id,
|
|
162
|
-
keyId: `${didDocument.id}#${verificationMethod.id}`,
|
|
163
|
-
publicKey: core_1.TypedArrayEncoder.toHex(key.publicKey),
|
|
164
|
-
},
|
|
165
|
-
]), core_1.VerificationMethod));
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
else {
|
|
169
|
-
return {
|
|
170
|
-
didDocumentMetadata: {},
|
|
171
|
-
didRegistrationMetadata: {},
|
|
172
|
-
didState: {
|
|
173
|
-
state: 'failed',
|
|
174
|
-
reason: 'Provide a valid didDocument',
|
|
175
|
-
},
|
|
176
|
-
};
|
|
177
|
-
}
|
|
178
|
-
const payloadToSign = await (0, didCheqdUtil_1.createMsgCreateDidDocPayloadToSign)(didDocument, versionId);
|
|
179
|
-
const signInputs = await this.signPayload(agentContext, payloadToSign, didDocument.verificationMethod);
|
|
180
|
-
const response = await cheqdLedgerService.update(didDocument, signInputs, versionId);
|
|
181
|
-
if (response.code !== 0) {
|
|
182
|
-
throw new Error(`${response.rawLog}`);
|
|
183
|
-
}
|
|
184
|
-
// Save the did so we know we created it and can issue with it
|
|
185
|
-
didRecord.didDocument = didDocument;
|
|
186
|
-
await didRepository.update(agentContext, didRecord);
|
|
187
|
-
return {
|
|
188
|
-
didDocumentMetadata: {},
|
|
189
|
-
didRegistrationMetadata: {},
|
|
190
|
-
didState: {
|
|
191
|
-
state: 'finished',
|
|
192
|
-
did: didDocument.id,
|
|
193
|
-
didDocument,
|
|
194
|
-
secret: options.secret,
|
|
195
|
-
},
|
|
196
|
-
};
|
|
197
|
-
}
|
|
198
|
-
catch (error) {
|
|
199
|
-
agentContext.config.logger.error(`Error updating DID`, error);
|
|
200
|
-
return {
|
|
201
|
-
didDocumentMetadata: {},
|
|
202
|
-
didRegistrationMetadata: {},
|
|
203
|
-
didState: {
|
|
204
|
-
state: 'failed',
|
|
205
|
-
reason: `unknownError: ${error.message}`,
|
|
206
|
-
},
|
|
207
|
-
};
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
async deactivate(agentContext, options) {
|
|
211
|
-
var _a;
|
|
212
|
-
const didRepository = agentContext.dependencyManager.resolve(core_1.DidRepository);
|
|
213
|
-
const cheqdLedgerService = agentContext.dependencyManager.resolve(ledger_1.CheqdLedgerService);
|
|
214
|
-
const did = options.did;
|
|
215
|
-
const versionId = ((_a = options.options) === null || _a === void 0 ? void 0 : _a.versionId) || core_1.utils.uuid();
|
|
216
|
-
try {
|
|
217
|
-
const { didDocument, didDocumentMetadata } = await cheqdLedgerService.resolve(did);
|
|
218
|
-
const didRecord = await didRepository.findCreatedDid(agentContext, did);
|
|
219
|
-
if (!didDocument || didDocumentMetadata.deactivated || !didRecord) {
|
|
220
|
-
return {
|
|
221
|
-
didDocumentMetadata: {},
|
|
222
|
-
didRegistrationMetadata: {},
|
|
223
|
-
didState: {
|
|
224
|
-
state: 'failed',
|
|
225
|
-
reason: 'Did not found',
|
|
226
|
-
},
|
|
227
|
-
};
|
|
228
|
-
}
|
|
229
|
-
const payloadToSign = (0, didCheqdUtil_1.createMsgDeactivateDidDocPayloadToSign)(didDocument, versionId);
|
|
230
|
-
const didDocumentInstance = core_1.JsonTransformer.fromJSON(didDocument, core_1.DidDocument);
|
|
231
|
-
const signInputs = await this.signPayload(agentContext, payloadToSign, didDocumentInstance.verificationMethod);
|
|
232
|
-
const response = await cheqdLedgerService.deactivate(didDocument, signInputs, versionId);
|
|
233
|
-
if (response.code !== 0) {
|
|
234
|
-
throw new Error(`${response.rawLog}`);
|
|
235
|
-
}
|
|
236
|
-
await didRepository.update(agentContext, didRecord);
|
|
237
|
-
return {
|
|
238
|
-
didDocumentMetadata: {},
|
|
239
|
-
didRegistrationMetadata: {},
|
|
240
|
-
didState: {
|
|
241
|
-
state: 'finished',
|
|
242
|
-
did: didDocument.id,
|
|
243
|
-
didDocument: core_1.JsonTransformer.fromJSON(didDocument, core_1.DidDocument),
|
|
244
|
-
secret: options.secret,
|
|
245
|
-
},
|
|
246
|
-
};
|
|
247
|
-
}
|
|
248
|
-
catch (error) {
|
|
249
|
-
agentContext.config.logger.error(`Error deactivating DID`, error);
|
|
250
|
-
return {
|
|
251
|
-
didDocumentMetadata: {},
|
|
252
|
-
didRegistrationMetadata: {},
|
|
253
|
-
didState: {
|
|
254
|
-
state: 'failed',
|
|
255
|
-
reason: `unknownError: ${error.message}`,
|
|
256
|
-
},
|
|
257
|
-
};
|
|
258
|
-
}
|
|
259
|
-
}
|
|
260
|
-
async createResource(agentContext, did, resource) {
|
|
261
|
-
const didRepository = agentContext.dependencyManager.resolve(core_1.DidRepository);
|
|
262
|
-
const cheqdLedgerService = agentContext.dependencyManager.resolve(ledger_1.CheqdLedgerService);
|
|
263
|
-
const { didDocument, didDocumentMetadata } = await cheqdLedgerService.resolve(did);
|
|
264
|
-
const didRecord = await didRepository.findCreatedDid(agentContext, did);
|
|
265
|
-
if (!didDocument || didDocumentMetadata.deactivated || !didRecord) {
|
|
266
|
-
return {
|
|
267
|
-
resourceMetadata: {},
|
|
268
|
-
resourceRegistrationMetadata: {},
|
|
269
|
-
resourceState: {
|
|
270
|
-
state: 'failed',
|
|
271
|
-
reason: `DID: ${did} not found`,
|
|
272
|
-
},
|
|
273
|
-
};
|
|
274
|
-
}
|
|
275
|
-
try {
|
|
276
|
-
let data;
|
|
277
|
-
if (typeof resource.data === 'string') {
|
|
278
|
-
data = core_1.TypedArrayEncoder.fromBase64(resource.data);
|
|
279
|
-
}
|
|
280
|
-
else if (typeof resource.data == 'object') {
|
|
281
|
-
data = core_1.TypedArrayEncoder.fromString(JSON.stringify(resource.data));
|
|
282
|
-
}
|
|
283
|
-
else {
|
|
284
|
-
data = resource.data;
|
|
285
|
-
}
|
|
286
|
-
const resourcePayload = v2_1.MsgCreateResourcePayload.fromPartial({
|
|
287
|
-
collectionId: did.split(':')[3],
|
|
288
|
-
id: resource.id,
|
|
289
|
-
resourceType: resource.resourceType,
|
|
290
|
-
name: resource.name,
|
|
291
|
-
version: resource.version,
|
|
292
|
-
alsoKnownAs: resource.alsoKnownAs,
|
|
293
|
-
data,
|
|
294
|
-
});
|
|
295
|
-
const payloadToSign = v2_1.MsgCreateResourcePayload.encode(resourcePayload).finish();
|
|
296
|
-
const didDocumentInstance = core_1.JsonTransformer.fromJSON(didDocument, core_1.DidDocument);
|
|
297
|
-
const signInputs = await this.signPayload(agentContext, payloadToSign, didDocumentInstance.verificationMethod);
|
|
298
|
-
const response = await cheqdLedgerService.createResource(did, resourcePayload, signInputs);
|
|
299
|
-
if (response.code !== 0) {
|
|
300
|
-
throw new Error(`${response.rawLog}`);
|
|
301
|
-
}
|
|
302
|
-
return {
|
|
303
|
-
resourceMetadata: {},
|
|
304
|
-
resourceRegistrationMetadata: {},
|
|
305
|
-
resourceState: {
|
|
306
|
-
state: 'finished',
|
|
307
|
-
resourceId: resourcePayload.id,
|
|
308
|
-
resource: resourcePayload,
|
|
309
|
-
},
|
|
310
|
-
};
|
|
311
|
-
}
|
|
312
|
-
catch (error) {
|
|
313
|
-
return {
|
|
314
|
-
resourceMetadata: {},
|
|
315
|
-
resourceRegistrationMetadata: {},
|
|
316
|
-
resourceState: {
|
|
317
|
-
state: 'failed',
|
|
318
|
-
reason: `unknownError: ${error.message}`,
|
|
319
|
-
},
|
|
320
|
-
};
|
|
321
|
-
}
|
|
322
|
-
}
|
|
323
|
-
async signPayload(agentContext, payload, verificationMethod = []) {
|
|
324
|
-
return await Promise.all(verificationMethod.map(async (method) => {
|
|
325
|
-
const key = (0, core_1.getKeyFromVerificationMethod)(method);
|
|
326
|
-
return {
|
|
327
|
-
verificationMethodId: method.id,
|
|
328
|
-
signature: await agentContext.wallet.sign({ data: core_1.Buffer.from(payload), key }),
|
|
329
|
-
};
|
|
330
|
-
}));
|
|
331
|
-
}
|
|
332
|
-
}
|
|
333
|
-
exports.CheqdDidRegistrar = CheqdDidRegistrar;
|
|
334
|
-
//# sourceMappingURL=CheqdDidRegistrar.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CheqdDidRegistrar.js","sourceRoot":"","sources":["../../src/dids/CheqdDidRegistrar.ts"],"names":[],"mappings":";;;AAYA,oCAA8E;AAC9E,0DAA4E;AAC5E,yCAauB;AAEvB,gEAA8D;AAC9D,sCAA8C;AAE9C,iDAKuB;AAEvB,MAAa,iBAAiB;IAA9B;QACkB,qBAAgB,GAAG,CAAC,OAAO,CAAC,CAAA;IAuW9C,CAAC;I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