@trash-streamers/contracts 1.1.89 → 1.1.90
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.
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { Observable } from "rxjs";
|
|
2
|
+
import { FieldMask } from "./common";
|
|
3
|
+
export declare const protobufPackage = "system.chats.v1";
|
|
4
|
+
export interface GetUserMessagesRequest {
|
|
5
|
+
userId: string;
|
|
6
|
+
publicKey: string;
|
|
7
|
+
selectMask: FieldMask | undefined;
|
|
8
|
+
}
|
|
9
|
+
export interface GetUserMessagesResponse {
|
|
10
|
+
chatId: string;
|
|
11
|
+
encryptedChatKey: string;
|
|
12
|
+
messages: SystemMessageResponse[];
|
|
13
|
+
}
|
|
14
|
+
export interface SystemMessageResponse {
|
|
15
|
+
id: string;
|
|
16
|
+
senderId: string;
|
|
17
|
+
content: string;
|
|
18
|
+
authTag: string;
|
|
19
|
+
initialVector: string;
|
|
20
|
+
isEdited: boolean;
|
|
21
|
+
isDeleted: boolean;
|
|
22
|
+
createdAt: Date | undefined;
|
|
23
|
+
updatedAt: Date | undefined;
|
|
24
|
+
}
|
|
25
|
+
export declare const SYSTEM_CHATS_V1_PACKAGE_NAME = "system.chats.v1";
|
|
26
|
+
export interface SystemChatsServiceClient {
|
|
27
|
+
getUserMessages(request: GetUserMessagesRequest): Observable<GetUserMessagesResponse>;
|
|
28
|
+
}
|
|
29
|
+
export interface SystemChatsServiceController {
|
|
30
|
+
getUserMessages(request: GetUserMessagesRequest): Promise<GetUserMessagesResponse> | Observable<GetUserMessagesResponse> | GetUserMessagesResponse;
|
|
31
|
+
}
|
|
32
|
+
export declare function SystemChatsServiceControllerMethods(): (constructor: Function) => void;
|
|
33
|
+
export declare const SYSTEM_CHATS_SERVICE_NAME = "SystemChatsService";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.10.1
|
|
5
|
+
// protoc v6.33.5
|
|
6
|
+
// source: system-chats.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.SYSTEM_CHATS_SERVICE_NAME = exports.SYSTEM_CHATS_V1_PACKAGE_NAME = exports.protobufPackage = void 0;
|
|
9
|
+
exports.SystemChatsServiceControllerMethods = SystemChatsServiceControllerMethods;
|
|
10
|
+
/* eslint-disable */
|
|
11
|
+
const microservices_1 = require("@nestjs/microservices");
|
|
12
|
+
const protobufjs_1 = require("protobufjs");
|
|
13
|
+
exports.protobufPackage = "system.chats.v1";
|
|
14
|
+
exports.SYSTEM_CHATS_V1_PACKAGE_NAME = "system.chats.v1";
|
|
15
|
+
protobufjs_1.wrappers[".google.protobuf.Timestamp"] = {
|
|
16
|
+
fromObject(value) {
|
|
17
|
+
return { seconds: value.getTime() / 1000, nanos: (value.getTime() % 1000) * 1e6 };
|
|
18
|
+
},
|
|
19
|
+
toObject(message) {
|
|
20
|
+
return new Date(message.seconds * 1000 + message.nanos / 1e6);
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
function SystemChatsServiceControllerMethods() {
|
|
24
|
+
return function (constructor) {
|
|
25
|
+
const grpcMethods = ["getUserMessages"];
|
|
26
|
+
for (const method of grpcMethods) {
|
|
27
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
28
|
+
(0, microservices_1.GrpcMethod)("SystemChatsService", method)(constructor.prototype[method], method, descriptor);
|
|
29
|
+
}
|
|
30
|
+
const grpcStreamMethods = [];
|
|
31
|
+
for (const method of grpcStreamMethods) {
|
|
32
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
33
|
+
(0, microservices_1.GrpcStreamMethod)("SystemChatsService", method)(constructor.prototype[method], method, descriptor);
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
exports.SYSTEM_CHATS_SERVICE_NAME = "SystemChatsService";
|
package/package.json
CHANGED