@ludeo/cloud-common 1.2.11 → 1.2.13
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/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/v4/events/cloud-session-stats-report.d.ts +9 -0
- package/dist/v4/events/cloud-session-stats-report.js +34 -0
- package/dist/v4/events/cloud-session-stats-report.js.map +1 -0
- package/dist/v4/events/swap-to-default-user-completed.d.ts +2 -0
- package/dist/v4/events/swap-to-default-user-completed.js +8 -0
- package/dist/v4/events/swap-to-default-user-completed.js.map +1 -1
- package/dist/v4/events/swap-to-default-user.d.ts +2 -0
- package/dist/v4/events/swap-to-default-user.js +8 -0
- package/dist/v4/events/swap-to-default-user.js.map +1 -1
- package/package.json +1 -1
- package/src/v4/events/cloud-session-stats-report.ts +24 -0
- package/src/v4/events/swap-to-default-user-completed.ts +7 -1
- package/src/v4/events/swap-to-default-user.ts +7 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { LudeoEvent } from "../../infra";
|
|
2
|
+
import { CloudSessionContext } from "../contexts";
|
|
3
|
+
export type CloudSessionStatsReportPayload = Record<string, string | number>;
|
|
4
|
+
export declare class CloudSessionStatsReport extends LudeoEvent {
|
|
5
|
+
static readonly EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
6
|
+
constructor(payload: CloudSessionStatsReportPayload, context: CloudSessionContext);
|
|
7
|
+
payload: Record<string, string | number>;
|
|
8
|
+
context: CloudSessionContext;
|
|
9
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
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.CloudSessionStatsReport = void 0;
|
|
13
|
+
const infra_1 = require("../../infra");
|
|
14
|
+
const decorators_1 = require("../../decorators");
|
|
15
|
+
const types_1 = require("../types");
|
|
16
|
+
const contexts_1 = require("../contexts");
|
|
17
|
+
class CloudSessionStatsReport extends infra_1.LudeoEvent {
|
|
18
|
+
constructor(payload, context) {
|
|
19
|
+
super(CloudSessionStatsReport.EVENT_NAME);
|
|
20
|
+
this.payload = payload;
|
|
21
|
+
this.context = context;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.CloudSessionStatsReport = CloudSessionStatsReport;
|
|
25
|
+
CloudSessionStatsReport.EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
26
|
+
__decorate([
|
|
27
|
+
(0, decorators_1.ValidateNestedType)(() => types_1.CloudSession),
|
|
28
|
+
__metadata("design:type", Object)
|
|
29
|
+
], CloudSessionStatsReport.prototype, "payload", void 0);
|
|
30
|
+
__decorate([
|
|
31
|
+
(0, decorators_1.ValidateNestedType)(() => contexts_1.CloudSessionContext),
|
|
32
|
+
__metadata("design:type", contexts_1.CloudSessionContext)
|
|
33
|
+
], CloudSessionStatsReport.prototype, "context", void 0);
|
|
34
|
+
//# sourceMappingURL=cloud-session-stats-report.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cloud-session-stats-report.js","sourceRoot":"","sources":["../../../src/v4/events/cloud-session-stats-report.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,uCAAyC;AACzC,iDAAsD;AACtD,oCAAwC;AACxC,0CAAkD;AAGlD,MAAa,uBAAwB,SAAQ,kBAAU;IAGrD,YACE,OAAuC,EACvC,OAA4B;QAE5B,KAAK,CAAC,uBAAuB,CAAC,UAAU,CAAC,CAAC;QAC1C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,0DAiBC;AAhBiB,kCAAU,GAAG,2CAA2C,CAAC;AAYzE;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,oBAAY,CAAC;;wDACE;AAGzC;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,8BAAmB,CAAC;8BACrC,8BAAmB;wDAAC"}
|
|
@@ -2,6 +2,8 @@ import { LudeoEvent } from "../../infra/ludeo-event";
|
|
|
2
2
|
import { CloudResourceContext } from "../contexts";
|
|
3
3
|
export declare class SwapToDefaultUserCompletedPayload {
|
|
4
4
|
ludeoResourceId: string;
|
|
5
|
+
connectionId: string;
|
|
6
|
+
sourceService: string;
|
|
5
7
|
}
|
|
6
8
|
export declare class SwapToDefaultUserCompleted extends LudeoEvent {
|
|
7
9
|
static readonly EVENT_NAME = "authentication.swap-to-default-user-completed";
|
|
@@ -21,6 +21,14 @@ __decorate([
|
|
|
21
21
|
(0, class_validator_1.IsUUID)(),
|
|
22
22
|
__metadata("design:type", String)
|
|
23
23
|
], SwapToDefaultUserCompletedPayload.prototype, "ludeoResourceId", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsUUID)(),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], SwapToDefaultUserCompletedPayload.prototype, "connectionId", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_validator_1.IsString)(),
|
|
30
|
+
__metadata("design:type", String)
|
|
31
|
+
], SwapToDefaultUserCompletedPayload.prototype, "sourceService", void 0);
|
|
24
32
|
class SwapToDefaultUserCompleted extends ludeo_event_1.LudeoEvent {
|
|
25
33
|
constructor(payload, context) {
|
|
26
34
|
super(SwapToDefaultUserCompleted.EVENT_NAME);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"swap-to-default-user-completed.js","sourceRoot":"","sources":["../../../src/v4/events/swap-to-default-user-completed.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"swap-to-default-user-completed.js","sourceRoot":"","sources":["../../../src/v4/events/swap-to-default-user-completed.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAmD;AACnD,yDAAqD;AACrD,oGAAqF;AACrF,0CAAmD;AAEnD,MAAa,iCAAiC;CAS7C;AATD,8EASC;AAPC;IADC,IAAA,wBAAM,GAAE;;0EACe;AAGxB;IADC,IAAA,wBAAM,GAAE;;uEACY;AAGrB;IADC,IAAA,0BAAQ,GAAE;;wEACW;AAGxB,MAAa,0BAA2B,SAAQ,wBAAU;IAGxD,YACE,OAA0C,EAC1C,OAA6B;QAE7B,KAAK,CAAC,0BAA0B,CAAC,UAAU,CAAC,CAAC;QAC7C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,gEAiBC;AAhBiB,qCAAU,GAAG,+CAA+C,CAAC;AAY7E;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,+BAAoB,CAAC;8BACtC,+BAAoB;2DAAC;AAG9B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,iCAAiC,CAAC;8BACnD,iCAAiC;2DAAC"}
|
|
@@ -2,6 +2,8 @@ import { LudeoEvent } from "../../infra/ludeo-event";
|
|
|
2
2
|
import { CloudResourceContext } from "../contexts";
|
|
3
3
|
export declare class SwapToDefaultUserPayload {
|
|
4
4
|
ludeoResourceId: string;
|
|
5
|
+
connectionId: string;
|
|
6
|
+
defaultUserSessionToken: string;
|
|
5
7
|
}
|
|
6
8
|
export declare class SwapToDefaultUser extends LudeoEvent {
|
|
7
9
|
static readonly EVENT_NAME = "cloud-resources.swap-to-default-user";
|
|
@@ -21,6 +21,14 @@ __decorate([
|
|
|
21
21
|
(0, class_validator_1.IsUUID)(),
|
|
22
22
|
__metadata("design:type", String)
|
|
23
23
|
], SwapToDefaultUserPayload.prototype, "ludeoResourceId", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsUUID)(),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], SwapToDefaultUserPayload.prototype, "connectionId", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_validator_1.IsString)(),
|
|
30
|
+
__metadata("design:type", String)
|
|
31
|
+
], SwapToDefaultUserPayload.prototype, "defaultUserSessionToken", void 0);
|
|
24
32
|
class SwapToDefaultUser extends ludeo_event_1.LudeoEvent {
|
|
25
33
|
constructor(payload, context) {
|
|
26
34
|
super(SwapToDefaultUser.EVENT_NAME);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"swap-to-default-user.js","sourceRoot":"","sources":["../../../src/v4/events/swap-to-default-user.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"swap-to-default-user.js","sourceRoot":"","sources":["../../../src/v4/events/swap-to-default-user.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAmD;AACnD,yDAAqD;AACrD,oGAAqF;AACrF,0CAAmD;AAEnD,MAAa,wBAAwB;CASpC;AATD,4DASC;AAPC;IADC,IAAA,wBAAM,GAAE;;iEACe;AAGxB;IADC,IAAA,wBAAM,GAAE;;8DACY;AAGrB;IADC,IAAA,0BAAQ,GAAE;;yEACqB;AAGlC,MAAa,iBAAkB,SAAQ,wBAAU;IAG/C,YACE,OAAiC,EACjC,OAA6B;QAE7B,KAAK,CAAC,iBAAiB,CAAC,UAAU,CAAC,CAAC;QACpC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;;AAVH,8CAiBC;AAhBiB,4BAAU,GAAG,sCAAsC,CAAC;AAYpE;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,+BAAoB,CAAC;8BACtC,+BAAoB;kDAAC;AAG9B;IADC,IAAA,mDAAkB,EAAC,GAAG,EAAE,CAAC,wBAAwB,CAAC;8BAC1C,wBAAwB;kDAAC"}
|
package/package.json
CHANGED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { LudeoEvent } from "../../infra";
|
|
2
|
+
import { ValidateNestedType } from "../../decorators";
|
|
3
|
+
import { CloudSession } from "../types";
|
|
4
|
+
import { CloudSessionContext } from "../contexts";
|
|
5
|
+
|
|
6
|
+
export type CloudSessionStatsReportPayload = Record<string, string | number>;
|
|
7
|
+
export class CloudSessionStatsReport extends LudeoEvent {
|
|
8
|
+
static readonly EVENT_NAME = "cloud-sessions.cloud-session-stats-report";
|
|
9
|
+
|
|
10
|
+
constructor(
|
|
11
|
+
payload: CloudSessionStatsReportPayload,
|
|
12
|
+
context: CloudSessionContext
|
|
13
|
+
) {
|
|
14
|
+
super(CloudSessionStatsReport.EVENT_NAME);
|
|
15
|
+
this.payload = payload;
|
|
16
|
+
this.context = context;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@ValidateNestedType(() => CloudSession)
|
|
20
|
+
payload: Record<string, string | number>;
|
|
21
|
+
|
|
22
|
+
@ValidateNestedType(() => CloudSessionContext)
|
|
23
|
+
context: CloudSessionContext;
|
|
24
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IsUUID } from "class-validator";
|
|
1
|
+
import { IsString, IsUUID } from "class-validator";
|
|
2
2
|
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
3
|
import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
|
|
4
4
|
import { CloudResourceContext } from "../contexts";
|
|
@@ -6,6 +6,12 @@ import { CloudResourceContext } from "../contexts";
|
|
|
6
6
|
export class SwapToDefaultUserCompletedPayload {
|
|
7
7
|
@IsUUID()
|
|
8
8
|
ludeoResourceId: string;
|
|
9
|
+
|
|
10
|
+
@IsUUID()
|
|
11
|
+
connectionId: string;
|
|
12
|
+
|
|
13
|
+
@IsString()
|
|
14
|
+
sourceService: string;
|
|
9
15
|
}
|
|
10
16
|
|
|
11
17
|
export class SwapToDefaultUserCompleted extends LudeoEvent {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IsUUID } from "class-validator";
|
|
1
|
+
import { IsString, IsUUID } from "class-validator";
|
|
2
2
|
import { LudeoEvent } from "../../infra/ludeo-event";
|
|
3
3
|
import { ValidateNestedType } from "../../decorators/validate-nested-type.decorator";
|
|
4
4
|
import { CloudResourceContext } from "../contexts";
|
|
@@ -6,6 +6,12 @@ import { CloudResourceContext } from "../contexts";
|
|
|
6
6
|
export class SwapToDefaultUserPayload {
|
|
7
7
|
@IsUUID()
|
|
8
8
|
ludeoResourceId: string;
|
|
9
|
+
|
|
10
|
+
@IsUUID()
|
|
11
|
+
connectionId: string;
|
|
12
|
+
|
|
13
|
+
@IsString()
|
|
14
|
+
defaultUserSessionToken: string;
|
|
9
15
|
}
|
|
10
16
|
|
|
11
17
|
export class SwapToDefaultUser extends LudeoEvent {
|