@purpleschool/gptbot 0.5.30 → 0.5.31
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/controllers/amqp/telegram-profile.ts +1 -0
- package/api/controllers/http/telegram-connect.ts +1 -0
- package/build/api/controllers/amqp/telegram-profile.js +1 -0
- package/build/api/controllers/http/telegram-connect.js +1 -0
- package/build/commands/index.js +1 -0
- package/build/commands/telegram/get-telegram-config.command.js +11 -0
- package/build/commands/telegram/index.js +17 -0
- package/build/commands/telegram-profile/check-telegram-profile-exists.command.js +3 -5
- package/commands/index.ts +1 -0
- package/commands/telegram/get-telegram-config.command.ts +12 -0
- package/commands/telegram/index.ts +1 -0
- package/commands/telegram-profile/check-telegram-profile-exists.command.ts +3 -5
- package/package.json +1 -1
|
@@ -3,4 +3,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.TELEGRAM_PROFILE_AMQP_ROUTES = void 0;
|
|
4
4
|
exports.TELEGRAM_PROFILE_AMQP_ROUTES = {
|
|
5
5
|
CREATE_NEW_USER_FROM_BOT: 'tg.profile.create-new-user-from-bot',
|
|
6
|
+
CHECK_PROFILE_EXISTS: 'tg.profile.check-exists.rpc',
|
|
6
7
|
};
|
package/build/commands/index.js
CHANGED
|
@@ -29,6 +29,7 @@ __exportStar(require("./question"), exports);
|
|
|
29
29
|
__exportStar(require("./referral"), exports);
|
|
30
30
|
__exportStar(require("./subscription"), exports);
|
|
31
31
|
__exportStar(require("./task"), exports);
|
|
32
|
+
__exportStar(require("./telegram"), exports);
|
|
32
33
|
__exportStar(require("./telegram-profile"), exports);
|
|
33
34
|
__exportStar(require("./unregistered-user"), exports);
|
|
34
35
|
__exportStar(require("./user"), exports);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetTelegramConfigCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
var GetTelegramConfigCommand;
|
|
6
|
+
(function (GetTelegramConfigCommand) {
|
|
7
|
+
GetTelegramConfigCommand.RequestSchema = zod_1.z.void();
|
|
8
|
+
GetTelegramConfigCommand.ResponseSchema = zod_1.z.object({
|
|
9
|
+
tmaLink: zod_1.z.string(),
|
|
10
|
+
});
|
|
11
|
+
})(GetTelegramConfigCommand || (exports.GetTelegramConfigCommand = GetTelegramConfigCommand = {}));
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./get-telegram-config.command"), exports);
|
|
@@ -5,12 +5,10 @@ const zod_1 = require("zod");
|
|
|
5
5
|
var CheckTelegramProfileExistsCommand;
|
|
6
6
|
(function (CheckTelegramProfileExistsCommand) {
|
|
7
7
|
CheckTelegramProfileExistsCommand.RequestBodySchema = zod_1.z.object({
|
|
8
|
-
|
|
9
|
-
platform: zod_1.z.string().nullable(),
|
|
8
|
+
telegramId: zod_1.z.number(),
|
|
10
9
|
});
|
|
11
10
|
CheckTelegramProfileExistsCommand.ResponseSchema = zod_1.z.object({
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}),
|
|
11
|
+
isSuccess: zod_1.z.boolean(),
|
|
12
|
+
exists: zod_1.z.boolean(),
|
|
15
13
|
});
|
|
16
14
|
})(CheckTelegramProfileExistsCommand || (exports.CheckTelegramProfileExistsCommand = CheckTelegramProfileExistsCommand = {}));
|
package/commands/index.ts
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace GetTelegramConfigCommand {
|
|
4
|
+
export const RequestSchema = z.void();
|
|
5
|
+
export type Request = z.infer<typeof RequestSchema>;
|
|
6
|
+
|
|
7
|
+
export const ResponseSchema = z.object({
|
|
8
|
+
tmaLink: z.string(),
|
|
9
|
+
});
|
|
10
|
+
|
|
11
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './get-telegram-config.command';
|
|
@@ -2,16 +2,14 @@ import { z } from 'zod';
|
|
|
2
2
|
|
|
3
3
|
export namespace CheckTelegramProfileExistsCommand {
|
|
4
4
|
export const RequestBodySchema = z.object({
|
|
5
|
-
|
|
6
|
-
platform: z.string().nullable(),
|
|
5
|
+
telegramId: z.number(),
|
|
7
6
|
});
|
|
8
7
|
|
|
9
8
|
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
10
9
|
|
|
11
10
|
export const ResponseSchema = z.object({
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}),
|
|
11
|
+
isSuccess: z.boolean(),
|
|
12
|
+
exists: z.boolean(),
|
|
15
13
|
});
|
|
16
14
|
|
|
17
15
|
export type Response = z.infer<typeof ResponseSchema>;
|