@verana-labs/vs-agent-model 2.0.0-dev.96 → 2.0.0-dev.97
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/events/EventType.d.ts +1 -0
- package/build/events/EventType.js +1 -0
- package/build/events/EventType.js.map +1 -1
- package/build/events/InvitationStateUpdated.d.ts +16 -0
- package/build/events/InvitationStateUpdated.js +48 -0
- package/build/events/InvitationStateUpdated.js.map +1 -0
- package/build/events/index.d.ts +1 -0
- package/build/events/index.js +1 -0
- package/build/events/index.js.map +1 -1
- package/build/types.d.ts +11 -9
- package/package.json +1 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare enum EventType {
|
|
2
2
|
ConnectionStateUpdated = "didcomm.connections.state-updated",
|
|
3
|
+
InvitationStateUpdated = "didcomm.invitations.state-updated",
|
|
3
4
|
MessageReceived = "didcomm.basic-messages.message-received",
|
|
4
5
|
ReceiptsMessageReceived = "didcomm.receipts.message-receipts-received",
|
|
5
6
|
PresentationStateUpdated = "didcomm.presentations.state-updated",
|
|
@@ -4,6 +4,7 @@ exports.EventType = void 0;
|
|
|
4
4
|
var EventType;
|
|
5
5
|
(function (EventType) {
|
|
6
6
|
EventType["ConnectionStateUpdated"] = "didcomm.connections.state-updated";
|
|
7
|
+
EventType["InvitationStateUpdated"] = "didcomm.invitations.state-updated";
|
|
7
8
|
EventType["MessageReceived"] = "didcomm.basic-messages.message-received";
|
|
8
9
|
EventType["ReceiptsMessageReceived"] = "didcomm.receipts.message-receipts-received";
|
|
9
10
|
EventType["PresentationStateUpdated"] = "didcomm.presentations.state-updated";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EventType.js","sourceRoot":"","sources":["../../src/events/EventType.ts"],"names":[],"mappings":";;;AAAA,IAAY,
|
|
1
|
+
{"version":3,"file":"EventType.js","sourceRoot":"","sources":["../../src/events/EventType.ts"],"names":[],"mappings":";;;AAAA,IAAY,SASX;AATD,WAAY,SAAS;IACnB,yEAA4D,CAAA;IAC5D,yEAA4D,CAAA;IAC5D,wEAA2D,CAAA;IAC3D,mFAAsE,CAAA;IACtE,6EAAgE,CAAA;IAChE,0FAA6E,CAAA;IAC7E,0DAA6C,CAAA;IAC7C,qDAAwC,CAAA;AAC1C,CAAC,EATW,SAAS,yBAAT,SAAS,QASpB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Event } from './Event';
|
|
2
|
+
import { EventType } from './EventType';
|
|
3
|
+
export interface InvitationStateUpdatedOptions {
|
|
4
|
+
invitationRecordId: string;
|
|
5
|
+
state: string;
|
|
6
|
+
previousState?: string | null;
|
|
7
|
+
timestamp?: Date;
|
|
8
|
+
}
|
|
9
|
+
export declare class InvitationStateUpdated extends Event {
|
|
10
|
+
constructor(options: InvitationStateUpdatedOptions);
|
|
11
|
+
readonly type = EventType.InvitationStateUpdated;
|
|
12
|
+
static readonly type = EventType.InvitationStateUpdated;
|
|
13
|
+
invitationRecordId: string;
|
|
14
|
+
state: string;
|
|
15
|
+
previousState: string | null;
|
|
16
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
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;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.InvitationStateUpdated = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const Event_1 = require("./Event");
|
|
16
|
+
const EventType_1 = require("./EventType");
|
|
17
|
+
class InvitationStateUpdated extends Event_1.Event {
|
|
18
|
+
constructor(options) {
|
|
19
|
+
var _a, _b;
|
|
20
|
+
super();
|
|
21
|
+
this.type = InvitationStateUpdated.type;
|
|
22
|
+
if (options) {
|
|
23
|
+
this.invitationRecordId = options.invitationRecordId;
|
|
24
|
+
this.state = options.state;
|
|
25
|
+
this.previousState = (_a = options.previousState) !== null && _a !== void 0 ? _a : null;
|
|
26
|
+
this.timestamp = (_b = options.timestamp) !== null && _b !== void 0 ? _b : new Date();
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.InvitationStateUpdated = InvitationStateUpdated;
|
|
31
|
+
InvitationStateUpdated.type = EventType_1.EventType.InvitationStateUpdated;
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, class_transformer_1.Expose)(),
|
|
34
|
+
(0, class_validator_1.IsString)(),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], InvitationStateUpdated.prototype, "invitationRecordId", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, class_transformer_1.Expose)(),
|
|
39
|
+
(0, class_validator_1.IsString)(),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], InvitationStateUpdated.prototype, "state", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, class_transformer_1.Expose)(),
|
|
44
|
+
(0, class_validator_1.IsOptional)(),
|
|
45
|
+
(0, class_validator_1.IsString)(),
|
|
46
|
+
__metadata("design:type", Object)
|
|
47
|
+
], InvitationStateUpdated.prototype, "previousState", void 0);
|
|
48
|
+
//# sourceMappingURL=InvitationStateUpdated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"InvitationStateUpdated.js","sourceRoot":"","sources":["../../src/events/InvitationStateUpdated.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yDAA0C;AAC1C,qDAAsD;AAEtD,mCAA+B;AAC/B,2CAAuC;AASvC,MAAa,sBAAuB,SAAQ,aAAK;IAC/C,YAAmB,OAAsC;;QACvD,KAAK,EAAE,CAAA;QASO,SAAI,GAAG,sBAAsB,CAAC,IAAI,CAAA;QARhD,IAAI,OAAO,EAAE,CAAC;YACZ,IAAI,CAAC,kBAAkB,GAAG,OAAO,CAAC,kBAAkB,CAAA;YACpD,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,CAAA;YAC1B,IAAI,CAAC,aAAa,GAAG,MAAA,OAAO,CAAC,aAAa,mCAAI,IAAI,CAAA;YAClD,IAAI,CAAC,SAAS,GAAG,MAAA,OAAO,CAAC,SAAS,mCAAI,IAAI,IAAI,EAAE,CAAA;QAClD,CAAC;IACH,CAAC;;AATH,wDA0BC;AAdwB,2BAAI,GAAG,qBAAS,CAAC,sBAAsB,AAAnC,CAAmC;AAIvD;IAFN,IAAA,0BAAM,GAAE;IACR,IAAA,0BAAQ,GAAE;;kEACuB;AAI3B;IAFN,IAAA,0BAAM,GAAE;IACR,IAAA,0BAAQ,GAAE;;qDACU;AAKd;IAHN,IAAA,0BAAM,GAAE;IACR,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAQ,GAAE;;6DACyB"}
|
package/build/events/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ export * from './ConnectionStateUpdated';
|
|
|
2
2
|
export * from './Event';
|
|
3
3
|
export * from './EventType';
|
|
4
4
|
export * from './IndexerNotification';
|
|
5
|
+
export * from './InvitationStateUpdated';
|
|
5
6
|
export * from './MessageReceived';
|
|
6
7
|
export * from './VtFlowStateUpdated';
|
|
7
8
|
export * from './PresentationStateUpdated';
|
package/build/events/index.js
CHANGED
|
@@ -18,6 +18,7 @@ __exportStar(require("./ConnectionStateUpdated"), exports);
|
|
|
18
18
|
__exportStar(require("./Event"), exports);
|
|
19
19
|
__exportStar(require("./EventType"), exports);
|
|
20
20
|
__exportStar(require("./IndexerNotification"), exports);
|
|
21
|
+
__exportStar(require("./InvitationStateUpdated"), exports);
|
|
21
22
|
__exportStar(require("./MessageReceived"), exports);
|
|
22
23
|
__exportStar(require("./VtFlowStateUpdated"), exports);
|
|
23
24
|
__exportStar(require("./PresentationStateUpdated"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAwC;AACxC,0CAAuB;AACvB,8CAA2B;AAC3B,wDAAqC;AACrC,oDAAiC;AACjC,uDAAoC;AACpC,6DAA0C"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/events/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAwC;AACxC,0CAAuB;AACvB,8CAA2B;AAC3B,wDAAqC;AACrC,2DAAwC;AACxC,oDAAiC;AACjC,uDAAoC;AACpC,6DAA0C"}
|
package/build/types.d.ts
CHANGED
|
@@ -82,20 +82,22 @@ export interface CreatePresentationRequestResult {
|
|
|
82
82
|
url: string;
|
|
83
83
|
shortUrl: string;
|
|
84
84
|
}
|
|
85
|
-
export interface
|
|
86
|
-
|
|
87
|
-
}
|
|
88
|
-
export interface SendInvitationOptions {
|
|
89
|
-
connectionId: string;
|
|
85
|
+
export interface CreateInvitationOptions {
|
|
86
|
+
connectionId?: string;
|
|
90
87
|
did?: string;
|
|
88
|
+
reusable?: boolean;
|
|
91
89
|
label?: string;
|
|
92
90
|
imageUrl?: string;
|
|
93
91
|
goal?: string;
|
|
94
92
|
goalCode?: string;
|
|
93
|
+
useLegacyDid?: boolean;
|
|
94
|
+
didcommVersion?: DidCommVersion;
|
|
95
95
|
}
|
|
96
|
-
export interface
|
|
97
|
-
id
|
|
98
|
-
|
|
96
|
+
export interface CreateInvitationResult {
|
|
97
|
+
id?: string;
|
|
98
|
+
invitation?: Record<string, unknown>;
|
|
99
|
+
shortUrl?: string;
|
|
100
|
+
messageId?: string;
|
|
99
101
|
}
|
|
100
102
|
export interface ConnectionRecord {
|
|
101
103
|
id: string;
|
|
@@ -107,7 +109,7 @@ export interface ConnectionRecord {
|
|
|
107
109
|
alias?: string;
|
|
108
110
|
threadId?: string;
|
|
109
111
|
imageUrl?: string;
|
|
110
|
-
|
|
112
|
+
invitationId: string | null;
|
|
111
113
|
parentConnectionId: string | null;
|
|
112
114
|
invitationDid?: string;
|
|
113
115
|
didcommVersion?: DidCommVersion;
|