@purpleschool/gptbot 0.5.5 → 0.5.7

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.
@@ -7,7 +7,7 @@ var ResetPasswordCommand;
7
7
  ResetPasswordCommand.RequestSchema = zod_1.z.object({
8
8
  restoreToken: zod_1.z.string(),
9
9
  newPassword: zod_1.z.string(),
10
- userId: zod_1.z.string(),
10
+ userId: zod_1.z.string().uuid(),
11
11
  });
12
12
  ResetPasswordCommand.ResponseSchema = zod_1.z.object({
13
13
  data: zod_1.z.object({
@@ -9,7 +9,7 @@ var CreateChatCommand;
9
9
  categoryId: true,
10
10
  });
11
11
  CreateChatCommand.RequestSchema = zod_1.z.object({
12
- aiModelUUID: zod_1.z.string(),
12
+ aiModelUUID: zod_1.z.string().uuid(),
13
13
  });
14
14
  CreateChatCommand.ResponseSchema = zod_1.z.object({
15
15
  data: models_1.ChatSchema.extend({
@@ -12,6 +12,7 @@ exports.AiModelSchema = zod_1.z.object({
12
12
  tokenMultiplicator: zod_1.z.number(),
13
13
  order: zod_1.z.number(),
14
14
  canUse: zod_1.z.optional(zod_1.z.boolean()),
15
+ icon: zod_1.z.nullable(zod_1.z.string()),
15
16
  contentType: zod_1.z.enum(Object.values(constants_1.AI_MODEL_CONTENT_TYPE)),
16
17
  createdAt: zod_1.z.date(),
17
18
  updatedAt: zod_1.z.date(),
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.UserToSubscriptionSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  exports.UserToSubscriptionSchema = zod_1.z.object({
6
- uuid: zod_1.z.string(),
7
- userId: zod_1.z.string(),
6
+ uuid: zod_1.z.string().uuid(),
7
+ userId: zod_1.z.string().uuid(),
8
8
  subscriptionId: zod_1.z.string(),
9
9
  initTokenBalance: zod_1.z.number(),
10
10
  active: zod_1.z.boolean(),
@@ -4,7 +4,7 @@ export namespace ResetPasswordCommand {
4
4
  export const RequestSchema = z.object({
5
5
  restoreToken: z.string(),
6
6
  newPassword: z.string(),
7
- userId: z.string(),
7
+ userId: z.string().uuid(),
8
8
  });
9
9
 
10
10
  export type Request = z.infer<typeof RequestSchema>;
@@ -9,8 +9,9 @@ export namespace CreateChatCommand {
9
9
  export type RequestByParam = z.infer<typeof RequestSchemaByParam>;
10
10
 
11
11
  export const RequestSchema = z.object({
12
- aiModelUUID: z.string(),
12
+ aiModelUUID: z.string().uuid(),
13
13
  });
14
+
14
15
  export const ResponseSchema = z.object({
15
16
  data: ChatSchema.extend({
16
17
  messages: z.array(MessageSchema),
@@ -10,6 +10,7 @@ export const AiModelSchema = z.object({
10
10
  tokenMultiplicator: z.number(),
11
11
  order: z.number(),
12
12
  canUse: z.optional(z.boolean()),
13
+ icon: z.nullable(z.string()),
13
14
  contentType: z.enum(Object.values(AI_MODEL_CONTENT_TYPE) as [TAIModelContentTypeEnum]),
14
15
  createdAt: z.date(),
15
16
  updatedAt: z.date(),
@@ -1,8 +1,8 @@
1
1
  import { z } from 'zod';
2
2
 
3
3
  export const UserToSubscriptionSchema = z.object({
4
- uuid: z.string(),
5
- userId: z.string(),
4
+ uuid: z.string().uuid(),
5
+ userId: z.string().uuid(),
6
6
  subscriptionId: z.string(),
7
7
  initTokenBalance: z.number(),
8
8
  active: z.boolean(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@purpleschool/gptbot",
3
- "version": "0.5.5",
3
+ "version": "0.5.7",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {