@lyxa.ai/core 1.4.310 → 1.4.311
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/libraries/llm/interfaces/common-llm-interfaces.d.ts +1 -0
- package/dist/libraries/llm/interfaces/common-llm-interfaces.js.map +1 -1
- package/dist/libraries/llm/llm-provider-service.js +1 -1
- package/dist/libraries/llm/llm-provider-service.js.map +1 -1
- package/dist/libraries/socket/events/chatroom-message-send.socket.event.d.ts +33 -33
- package/dist/libraries/socket/events/order-actions.socket.event.d.ts +20 -20
- package/dist/libraries/socket/events/rider-location-update.socket.event.d.ts +8 -8
- package/dist/libraries/socket/events/ticket-actions.socket.event.d.ts +8 -8
- package/dist/libraries/socket/events/ticket-assign.socket.event.d.ts +40 -40
- package/dist/libraries/trpc/middlewares/auth.d.ts +2 -2
- package/dist/libraries/trpc/middlewares/createRoleProtectedProcedure.d.ts +2 -2
- package/dist/libraries/trpc/middlewares/phone-verified.d.ts +2 -2
- package/dist/libraries/trpc/middlewares/publicUserDecoder.d.ts +2 -2
- package/dist/types/README.md +1 -1
- package/dist/types/package.json +1 -1
- package/dist/types/utilities/validation/common-validation.d.ts +12 -12
- package/dist/utilities/pagination.d.ts +3 -3
- package/dist/utilities/validation/common-validation.d.ts +72 -72
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common-llm-interfaces.js","sourceRoot":"/","sources":["libraries/llm/interfaces/common-llm-interfaces.ts"],"names":[],"mappings":"","sourcesContent":["import { LLMProvider } from '../llm-provider-service';\n\nexport interface IAICompletionProvider {\n\tgenerateSearchVariantsChunksInBatch(\n\t\titems: ItemTextInput[],\n\t\tmodel?: string,\n\t\tinstructions?: string,\n\t\toptions?: {\n\t\t\tchunkSize?: number;\n\t\t\tmaxArabic?: number;\n\t\t\tmaxArabizi?: number;\n\t\t\tmaxTransliteration?: number;\n\t\t\tpollIntervalMs?: number;\n\t\t\tmaxWaitMs?: number;\n\t\t}\n\t): Promise<TextVariantResult[]>;\n}\n\nexport interface TextVariantResult {\n\tid: string;\n\toriginal: string;\n\tarabic?: string[];\n\tarabizi?: string[];\n\tarabicTransliteration?: string[];\n}\n\nexport interface AiConfiguration {\n\tprovider: LLMProvider;\n\tmodel?: string;\n\tinstructions?: string;\n\tprompt?: string;\n}\n\nexport interface ItemTextInput {\n\tid: string;\n\ttext: string;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"common-llm-interfaces.js","sourceRoot":"/","sources":["libraries/llm/interfaces/common-llm-interfaces.ts"],"names":[],"mappings":"","sourcesContent":["import { LLMProvider } from '../llm-provider-service';\n\nexport interface IAICompletionProvider {\n\tgenerateSearchVariantsChunksInBatch(\n\t\titems: ItemTextInput[],\n\t\tmodel?: string,\n\t\tinstructions?: string,\n\t\toptions?: {\n\t\t\tchunkSize?: number;\n\t\t\tmaxArabic?: number;\n\t\t\tmaxArabizi?: number;\n\t\t\tmaxTransliteration?: number;\n\t\t\tpollIntervalMs?: number;\n\t\t\tmaxWaitMs?: number;\n\t\t}\n\t): Promise<TextVariantResult[]>;\n}\n\nexport interface TextVariantResult {\n\tid: string;\n\toriginal: string;\n\tarabic?: string[];\n\tarabizi?: string[];\n\tarabicTransliteration?: string[];\n}\n\nexport interface AiConfiguration {\n\tprovider: LLMProvider;\n\tmodel?: string;\n\tinstructions?: string;\n\tprompt?: string;\n\tchunkSize?: number\n}\n\nexport interface ItemTextInput {\n\tid: string;\n\ttext: string;\n}\n"]}
|
|
@@ -30,7 +30,7 @@ class LLMCompletionService {
|
|
|
30
30
|
async generateSearchVariants(payload, aiConfigurations) {
|
|
31
31
|
const provider = await this.getProvider();
|
|
32
32
|
console.log(`You are using llm provider: ${this.provider} with model: ${aiConfigurations.model ?? 'gpt-5-nano'}`);
|
|
33
|
-
return provider.generateSearchVariantsChunksInBatch(payload, aiConfigurations.model, aiConfigurations.instructions);
|
|
33
|
+
return provider.generateSearchVariantsChunksInBatch(payload, aiConfigurations.model, aiConfigurations.instructions, { chunkSize: aiConfigurations.chunkSize });
|
|
34
34
|
}
|
|
35
35
|
async getProvider() {
|
|
36
36
|
if (!this.providerInstance) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"llm-provider-service.js","sourceRoot":"/","sources":["libraries/llm/llm-provider-service.ts"],"names":[],"mappings":";;;AAAA,6BAAqC;AAOrC,+DAA+D;AAC/D,iEAAuE;AAEvE,IAAY,WAGX;AAHD,WAAY,WAAW;IACtB,gCAAiB,CAAA;IACjB,gCAAiB,CAAA;AAClB,CAAC,EAHW,WAAW,2BAAX,WAAW,QAGtB;AAID,MAAa,oBAAoB;IAgBH;IAfrB,gBAAgB,GAAiC,IAAI,CAAC;IAE7C,SAAS,GAAyC;QAClE,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE,KAAK,IAAI,EAAE;YAChC,MAAM,MAAM,GAAG,MAAM,IAAA,gBAAY,GAAE,CAAC,iBAAiB,EAAE,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC;YACjF,IAAI,CAAC,MAAM,EAAE,CAAC;gBACb,MAAM,IAAA,8BAAe,EAAC,iCAAiC,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC;YAC9E,CAAC;YACD,OAAO,IAAI,0CAAwB,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;QAC3D,CAAC;QACD,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE,KAAK,IAAI,EAAE;YAChC,MAAM,IAAA,8BAAe,EAAC,YAAY,WAAW,CAAC,MAAM,yBAAyB,CAAC,CAAC;QAChF,CAAC;KACD,CAAC;IAEF,YAA6B,QAAqB;QAArB,aAAQ,GAAR,QAAQ,CAAa;IAAG,CAAC;IAEtD,KAAK,CAAC,sBAAsB,CAC3B,OAAwB,EACxB,gBAAiC;QAEjC,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC;QAC1C,OAAO,CAAC,GAAG,CACV,+BAA+B,IAAI,CAAC,QAAQ,gBAAgB,gBAAgB,CAAC,KAAK,IAAI,YAAY,EAAE,CACpG,CAAC;QACF,OAAO,QAAQ,CAAC,mCAAmC,CAClD,OAAO,EACP,gBAAgB,CAAC,KAAK,EACtB,gBAAgB,CAAC,YAAY,
|
|
1
|
+
{"version":3,"file":"llm-provider-service.js","sourceRoot":"/","sources":["libraries/llm/llm-provider-service.ts"],"names":[],"mappings":";;;AAAA,6BAAqC;AAOrC,+DAA+D;AAC/D,iEAAuE;AAEvE,IAAY,WAGX;AAHD,WAAY,WAAW;IACtB,gCAAiB,CAAA;IACjB,gCAAiB,CAAA;AAClB,CAAC,EAHW,WAAW,2BAAX,WAAW,QAGtB;AAID,MAAa,oBAAoB;IAgBH;IAfrB,gBAAgB,GAAiC,IAAI,CAAC;IAE7C,SAAS,GAAyC;QAClE,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE,KAAK,IAAI,EAAE;YAChC,MAAM,MAAM,GAAG,MAAM,IAAA,gBAAY,GAAE,CAAC,iBAAiB,EAAE,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC;YACjF,IAAI,CAAC,MAAM,EAAE,CAAC;gBACb,MAAM,IAAA,8BAAe,EAAC,iCAAiC,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC;YAC9E,CAAC;YACD,OAAO,IAAI,0CAAwB,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;QAC3D,CAAC;QACD,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE,KAAK,IAAI,EAAE;YAChC,MAAM,IAAA,8BAAe,EAAC,YAAY,WAAW,CAAC,MAAM,yBAAyB,CAAC,CAAC;QAChF,CAAC;KACD,CAAC;IAEF,YAA6B,QAAqB;QAArB,aAAQ,GAAR,QAAQ,CAAa;IAAG,CAAC;IAEtD,KAAK,CAAC,sBAAsB,CAC3B,OAAwB,EACxB,gBAAiC;QAEjC,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC;QAC1C,OAAO,CAAC,GAAG,CACV,+BAA+B,IAAI,CAAC,QAAQ,gBAAgB,gBAAgB,CAAC,KAAK,IAAI,YAAY,EAAE,CACpG,CAAC;QACF,OAAO,QAAQ,CAAC,mCAAmC,CAClD,OAAO,EACP,gBAAgB,CAAC,KAAK,EACtB,gBAAgB,CAAC,YAAY,EAC7B,EAAE,SAAS,EAAE,gBAAgB,CAAC,SAAS,EAAE,CACzC,CAAC;IACH,CAAC;IAEO,KAAK,CAAC,WAAW;QACxB,IAAI,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC;YAC5B,MAAM,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;YAC9C,IAAI,CAAC,OAAO,EAAE,CAAC;gBACd,MAAM,IAAA,8BAAe,EAAC,6BAA6B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;YACrE,CAAC;YACD,IAAI,CAAC,gBAAgB,GAAG,MAAM,OAAO,EAAE,CAAC;QACzC,CAAC;QACD,OAAO,IAAI,CAAC,gBAAgB,CAAC;IAC9B,CAAC;CACD;AA5CD,oDA4CC","sourcesContent":["import { getLibraries } from '../..';\nimport {\n\tItemTextInput,\n\tAiConfiguration,\n\tTextVariantResult,\n\tIAICompletionProvider,\n} from './interfaces/common-llm-interfaces';\nimport { badRequestError } from '../../utilities/error-common';\nimport { OpenAICompletionProvider } from './providers/openai-provider';\n\nexport enum LLMProvider {\n\tOPENAI = 'openai',\n\tGEMINI = 'gemini',\n}\n\ntype ProviderFactory = () => Promise<IAICompletionProvider>;\n\nexport class LLMCompletionService {\n\tprivate providerInstance: IAICompletionProvider | null = null;\n\n\tprivate readonly factories: Record<LLMProvider, ProviderFactory> = {\n\t\t[LLMProvider.OPENAI]: async () => {\n\t\t\tconst apiKey = await getLibraries().getSecretsService().getKey('OPENAI_API_KEY');\n\t\t\tif (!apiKey) {\n\t\t\t\tthrow badRequestError(`No API key found for provider ${LLMProvider.OPENAI}`);\n\t\t\t}\n\t\t\treturn new OpenAICompletionProvider(apiKey, 'gpt-5-mini');\n\t\t},\n\t\t[LLMProvider.GEMINI]: async () => {\n\t\t\tthrow badRequestError(`Provider ${LLMProvider.GEMINI} is not implemented yet`);\n\t\t},\n\t};\n\n\tconstructor(private readonly provider: LLMProvider) {}\n\n\tasync generateSearchVariants(\n\t\tpayload: ItemTextInput[],\n\t\taiConfigurations: AiConfiguration\n\t): Promise<TextVariantResult[]> {\n\t\tconst provider = await this.getProvider();\n\t\tconsole.log(\n\t\t\t`You are using llm provider: ${this.provider} with model: ${aiConfigurations.model ?? 'gpt-5-nano'}`\n\t\t);\n\t\treturn provider.generateSearchVariantsChunksInBatch(\n\t\t\tpayload,\n\t\t\taiConfigurations.model,\n\t\t\taiConfigurations.instructions,\n\t\t\t{ chunkSize: aiConfigurations.chunkSize }\n\t\t);\n\t}\n\n\tprivate async getProvider(): Promise<IAICompletionProvider> {\n\t\tif (!this.providerInstance) {\n\t\t\tconst factory = this.factories[this.provider];\n\t\t\tif (!factory) {\n\t\t\t\tthrow badRequestError(`Unsupported LLM provider: ${this.provider}`);\n\t\t\t}\n\t\t\tthis.providerInstance = await factory();\n\t\t}\n\t\treturn this.providerInstance;\n\t}\n}"]}
|
|
@@ -20,13 +20,13 @@ export declare const ChatroomMessageSendOutputSchema: z.ZodObject<{
|
|
|
20
20
|
name: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
21
21
|
type: z.ZodNativeEnum<typeof UserRef>;
|
|
22
22
|
}, "strip", z.ZodTypeAny, {
|
|
23
|
+
type: UserRef;
|
|
23
24
|
name: string;
|
|
24
25
|
id: import("mongoose").Types.ObjectId;
|
|
25
|
-
type: UserRef;
|
|
26
26
|
}, {
|
|
27
|
+
type: UserRef;
|
|
27
28
|
name: string;
|
|
28
29
|
id: import("mongoose").Types.ObjectId;
|
|
29
|
-
type: UserRef;
|
|
30
30
|
}>;
|
|
31
31
|
content: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
32
32
|
media: z.ZodArray<z.ZodObject<{
|
|
@@ -36,14 +36,14 @@ export declare const ChatroomMessageSendOutputSchema: z.ZodObject<{
|
|
|
36
36
|
thumbnailUrl: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
37
37
|
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
38
38
|
}, "strip", z.ZodTypeAny, {
|
|
39
|
-
mediaType: MediaType;
|
|
40
39
|
mediaUrl: string;
|
|
40
|
+
mediaType: MediaType;
|
|
41
41
|
mimeType: string;
|
|
42
42
|
name?: string | undefined;
|
|
43
43
|
thumbnailUrl?: string | undefined;
|
|
44
44
|
}, {
|
|
45
|
-
mediaType: MediaType;
|
|
46
45
|
mediaUrl: string;
|
|
46
|
+
mediaType: MediaType;
|
|
47
47
|
mimeType: string;
|
|
48
48
|
name?: string | undefined;
|
|
49
49
|
thumbnailUrl?: string | undefined;
|
|
@@ -63,17 +63,17 @@ export declare const ChatroomMessageSendOutputSchema: z.ZodObject<{
|
|
|
63
63
|
orderId: z.ZodOptional<z.ZodEffects<z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>, import("mongoose").Types.ObjectId, import("mongoose").Types.ObjectId>>;
|
|
64
64
|
createdAt: z.ZodEffects<z.ZodEffects<z.ZodDate, Date, Date>, Date, Date>;
|
|
65
65
|
}, "strip", z.ZodTypeAny, {
|
|
66
|
-
createdAt: Date;
|
|
67
66
|
_id: import("mongoose").Types.ObjectId;
|
|
68
|
-
|
|
67
|
+
createdAt: Date;
|
|
69
68
|
sender: {
|
|
69
|
+
type: UserRef;
|
|
70
70
|
name: string;
|
|
71
71
|
id: import("mongoose").Types.ObjectId;
|
|
72
|
-
type: UserRef;
|
|
73
72
|
};
|
|
73
|
+
senderType: UserRef;
|
|
74
74
|
media: {
|
|
75
|
-
mediaType: MediaType;
|
|
76
75
|
mediaUrl: string;
|
|
76
|
+
mediaType: MediaType;
|
|
77
77
|
mimeType: string;
|
|
78
78
|
name?: string | undefined;
|
|
79
79
|
thumbnailUrl?: string | undefined;
|
|
@@ -85,21 +85,21 @@ export declare const ChatroomMessageSendOutputSchema: z.ZodObject<{
|
|
|
85
85
|
longitude?: number | undefined;
|
|
86
86
|
} | undefined;
|
|
87
87
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
88
|
-
content?: string | undefined;
|
|
89
88
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
89
|
+
content?: string | undefined;
|
|
90
90
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
91
91
|
}, {
|
|
92
|
-
createdAt: Date;
|
|
93
92
|
_id: import("mongoose").Types.ObjectId;
|
|
94
|
-
|
|
93
|
+
createdAt: Date;
|
|
95
94
|
sender: {
|
|
95
|
+
type: UserRef;
|
|
96
96
|
name: string;
|
|
97
97
|
id: import("mongoose").Types.ObjectId;
|
|
98
|
-
type: UserRef;
|
|
99
98
|
};
|
|
99
|
+
senderType: UserRef;
|
|
100
100
|
media: {
|
|
101
|
-
mediaType: MediaType;
|
|
102
101
|
mediaUrl: string;
|
|
102
|
+
mediaType: MediaType;
|
|
103
103
|
mimeType: string;
|
|
104
104
|
name?: string | undefined;
|
|
105
105
|
thumbnailUrl?: string | undefined;
|
|
@@ -111,8 +111,8 @@ export declare const ChatroomMessageSendOutputSchema: z.ZodObject<{
|
|
|
111
111
|
longitude?: number | undefined;
|
|
112
112
|
} | undefined;
|
|
113
113
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
114
|
-
content?: string | undefined;
|
|
115
114
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
115
|
+
content?: string | undefined;
|
|
116
116
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
117
117
|
}>;
|
|
118
118
|
export declare const ChatroomMessageSendPushOutputSchema: z.ZodObject<{
|
|
@@ -124,14 +124,14 @@ export declare const ChatroomMessageSendPushOutputSchema: z.ZodObject<{
|
|
|
124
124
|
}, "strip", z.ZodTypeAny, {
|
|
125
125
|
type: ChatroomType;
|
|
126
126
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
127
|
-
lastMessage?: string | undefined;
|
|
128
127
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
128
|
+
lastMessage?: string | undefined;
|
|
129
129
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
130
130
|
}, {
|
|
131
131
|
type: ChatroomType;
|
|
132
132
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
133
|
-
lastMessage?: string | undefined;
|
|
134
133
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
134
|
+
lastMessage?: string | undefined;
|
|
135
135
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
136
136
|
}>;
|
|
137
137
|
export type ChatlistMessageSendPushOutputDTO = DTO<typeof ChatroomMessageSendPushOutputSchema>;
|
|
@@ -156,13 +156,13 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
156
156
|
name: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
157
157
|
type: z.ZodNativeEnum<typeof UserRef>;
|
|
158
158
|
}, "strip", z.ZodTypeAny, {
|
|
159
|
+
type: UserRef;
|
|
159
160
|
name: string;
|
|
160
161
|
id: import("mongoose").Types.ObjectId;
|
|
161
|
-
type: UserRef;
|
|
162
162
|
}, {
|
|
163
|
+
type: UserRef;
|
|
163
164
|
name: string;
|
|
164
165
|
id: import("mongoose").Types.ObjectId;
|
|
165
|
-
type: UserRef;
|
|
166
166
|
}>;
|
|
167
167
|
content: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
168
168
|
media: z.ZodArray<z.ZodObject<{
|
|
@@ -172,14 +172,14 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
172
172
|
thumbnailUrl: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
173
173
|
name: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
174
174
|
}, "strip", z.ZodTypeAny, {
|
|
175
|
-
mediaType: MediaType;
|
|
176
175
|
mediaUrl: string;
|
|
176
|
+
mediaType: MediaType;
|
|
177
177
|
mimeType: string;
|
|
178
178
|
name?: string | undefined;
|
|
179
179
|
thumbnailUrl?: string | undefined;
|
|
180
180
|
}, {
|
|
181
|
-
mediaType: MediaType;
|
|
182
181
|
mediaUrl: string;
|
|
182
|
+
mediaType: MediaType;
|
|
183
183
|
mimeType: string;
|
|
184
184
|
name?: string | undefined;
|
|
185
185
|
thumbnailUrl?: string | undefined;
|
|
@@ -199,17 +199,17 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
199
199
|
orderId: z.ZodOptional<z.ZodEffects<z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>, import("mongoose").Types.ObjectId, import("mongoose").Types.ObjectId>>;
|
|
200
200
|
createdAt: z.ZodEffects<z.ZodEffects<z.ZodDate, Date, Date>, Date, Date>;
|
|
201
201
|
}, "strip", z.ZodTypeAny, {
|
|
202
|
-
createdAt: Date;
|
|
203
202
|
_id: import("mongoose").Types.ObjectId;
|
|
204
|
-
|
|
203
|
+
createdAt: Date;
|
|
205
204
|
sender: {
|
|
205
|
+
type: UserRef;
|
|
206
206
|
name: string;
|
|
207
207
|
id: import("mongoose").Types.ObjectId;
|
|
208
|
-
type: UserRef;
|
|
209
208
|
};
|
|
209
|
+
senderType: UserRef;
|
|
210
210
|
media: {
|
|
211
|
-
mediaType: MediaType;
|
|
212
211
|
mediaUrl: string;
|
|
212
|
+
mediaType: MediaType;
|
|
213
213
|
mimeType: string;
|
|
214
214
|
name?: string | undefined;
|
|
215
215
|
thumbnailUrl?: string | undefined;
|
|
@@ -221,21 +221,21 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
221
221
|
longitude?: number | undefined;
|
|
222
222
|
} | undefined;
|
|
223
223
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
224
|
-
content?: string | undefined;
|
|
225
224
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
225
|
+
content?: string | undefined;
|
|
226
226
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
227
227
|
}, {
|
|
228
|
-
createdAt: Date;
|
|
229
228
|
_id: import("mongoose").Types.ObjectId;
|
|
230
|
-
|
|
229
|
+
createdAt: Date;
|
|
231
230
|
sender: {
|
|
231
|
+
type: UserRef;
|
|
232
232
|
name: string;
|
|
233
233
|
id: import("mongoose").Types.ObjectId;
|
|
234
|
-
type: UserRef;
|
|
235
234
|
};
|
|
235
|
+
senderType: UserRef;
|
|
236
236
|
media: {
|
|
237
|
-
mediaType: MediaType;
|
|
238
237
|
mediaUrl: string;
|
|
238
|
+
mediaType: MediaType;
|
|
239
239
|
mimeType: string;
|
|
240
240
|
name?: string | undefined;
|
|
241
241
|
thumbnailUrl?: string | undefined;
|
|
@@ -247,8 +247,8 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
247
247
|
longitude?: number | undefined;
|
|
248
248
|
} | undefined;
|
|
249
249
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
250
|
-
content?: string | undefined;
|
|
251
250
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
251
|
+
content?: string | undefined;
|
|
252
252
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
253
253
|
}>;
|
|
254
254
|
pushNotificationOutput: z.ZodObject<{
|
|
@@ -260,14 +260,14 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
260
260
|
}, "strip", z.ZodTypeAny, {
|
|
261
261
|
type: ChatroomType;
|
|
262
262
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
263
|
-
lastMessage?: string | undefined;
|
|
264
263
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
264
|
+
lastMessage?: string | undefined;
|
|
265
265
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
266
266
|
}, {
|
|
267
267
|
type: ChatroomType;
|
|
268
268
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
269
|
-
lastMessage?: string | undefined;
|
|
270
269
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
270
|
+
lastMessage?: string | undefined;
|
|
271
271
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
272
272
|
}>;
|
|
273
273
|
};
|
|
@@ -278,8 +278,8 @@ export declare class ChatroomMessageSendSocketEvent extends BaseSocketEvent<type
|
|
|
278
278
|
getPushNotificationPayload(): {
|
|
279
279
|
type: ChatroomType;
|
|
280
280
|
orderId?: import("mongoose").Types.ObjectId | undefined;
|
|
281
|
-
lastMessage?: string | undefined;
|
|
282
281
|
ticketId?: import("mongoose").Types.ObjectId | undefined;
|
|
282
|
+
lastMessage?: string | undefined;
|
|
283
283
|
chatroomId?: import("mongoose").Types.ObjectId | undefined;
|
|
284
284
|
} | undefined;
|
|
285
285
|
protected getIdentifier(): string;
|
|
@@ -39,8 +39,8 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
39
39
|
riderTips: z.ZodNumber;
|
|
40
40
|
secondaryRiderTips: z.ZodNumber;
|
|
41
41
|
}, "strip", z.ZodTypeAny, {
|
|
42
|
-
deliveryFee: number;
|
|
43
42
|
total: number;
|
|
43
|
+
deliveryFee: number;
|
|
44
44
|
secondaryDeliveryFee: number;
|
|
45
45
|
riderTips: number;
|
|
46
46
|
secondaryRiderTips: number;
|
|
@@ -48,8 +48,8 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
48
48
|
paidAmount: number;
|
|
49
49
|
secondaryPaidAmount: number;
|
|
50
50
|
}, {
|
|
51
|
-
deliveryFee: number;
|
|
52
51
|
total: number;
|
|
52
|
+
deliveryFee: number;
|
|
53
53
|
secondaryDeliveryFee: number;
|
|
54
54
|
riderTips: number;
|
|
55
55
|
secondaryRiderTips: number;
|
|
@@ -60,8 +60,8 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
60
60
|
}, "strip", z.ZodTypeAny, {
|
|
61
61
|
paymentMethod: PaymentMethod;
|
|
62
62
|
pricing: {
|
|
63
|
-
deliveryFee: number;
|
|
64
63
|
total: number;
|
|
64
|
+
deliveryFee: number;
|
|
65
65
|
secondaryDeliveryFee: number;
|
|
66
66
|
riderTips: number;
|
|
67
67
|
secondaryRiderTips: number;
|
|
@@ -73,8 +73,8 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
73
73
|
}, {
|
|
74
74
|
paymentMethod: PaymentMethod;
|
|
75
75
|
pricing: {
|
|
76
|
-
deliveryFee: number;
|
|
77
76
|
total: number;
|
|
77
|
+
deliveryFee: number;
|
|
78
78
|
secondaryDeliveryFee: number;
|
|
79
79
|
riderTips: number;
|
|
80
80
|
secondaryRiderTips: number;
|
|
@@ -88,20 +88,21 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
88
88
|
triggerAt: z.ZodEffects<z.ZodEffects<z.ZodDate, Date, Date>, Date, Date>;
|
|
89
89
|
orderActionType: z.ZodNativeEnum<typeof OrderAction>;
|
|
90
90
|
}, "strip", z.ZodTypeAny, {
|
|
91
|
-
createdAt: Date;
|
|
92
91
|
_id: import("mongoose").Types.ObjectId;
|
|
92
|
+
createdAt: Date;
|
|
93
93
|
user: {
|
|
94
94
|
_id: import("mongoose").Types.ObjectId;
|
|
95
95
|
name: string;
|
|
96
96
|
};
|
|
97
97
|
orderId: string;
|
|
98
98
|
shopId: import("mongoose").Types.ObjectId;
|
|
99
|
+
paymentMethod: PaymentMethod;
|
|
99
100
|
triggerAt: Date;
|
|
100
101
|
adjustedFinance: {
|
|
101
102
|
paymentMethod: PaymentMethod;
|
|
102
103
|
pricing: {
|
|
103
|
-
deliveryFee: number;
|
|
104
104
|
total: number;
|
|
105
|
+
deliveryFee: number;
|
|
105
106
|
secondaryDeliveryFee: number;
|
|
106
107
|
riderTips: number;
|
|
107
108
|
secondaryRiderTips: number;
|
|
@@ -111,26 +112,26 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
111
112
|
};
|
|
112
113
|
shopProfit: number;
|
|
113
114
|
};
|
|
114
|
-
paymentMethod: PaymentMethod;
|
|
115
115
|
orderActionType: OrderAction;
|
|
116
116
|
orderStatus: RegularOrderStatus;
|
|
117
117
|
orderAction: OrderAction;
|
|
118
118
|
preparationTimeMinutes: number;
|
|
119
119
|
}, {
|
|
120
|
-
createdAt: Date;
|
|
121
120
|
_id: string | import("mongoose").Types.ObjectId;
|
|
121
|
+
createdAt: Date;
|
|
122
122
|
user: {
|
|
123
123
|
_id: string | import("mongoose").Types.ObjectId;
|
|
124
124
|
name: string;
|
|
125
125
|
};
|
|
126
126
|
orderId: string;
|
|
127
127
|
shopId: string | import("mongoose").Types.ObjectId;
|
|
128
|
+
paymentMethod: PaymentMethod;
|
|
128
129
|
triggerAt: Date;
|
|
129
130
|
adjustedFinance: {
|
|
130
131
|
paymentMethod: PaymentMethod;
|
|
131
132
|
pricing: {
|
|
132
|
-
deliveryFee: number;
|
|
133
133
|
total: number;
|
|
134
|
+
deliveryFee: number;
|
|
134
135
|
secondaryDeliveryFee: number;
|
|
135
136
|
riderTips: number;
|
|
136
137
|
secondaryRiderTips: number;
|
|
@@ -140,7 +141,6 @@ export declare const OrderActionsOutputSchema: z.ZodObject<{
|
|
|
140
141
|
};
|
|
141
142
|
shopProfit: number;
|
|
142
143
|
};
|
|
143
|
-
paymentMethod: PaymentMethod;
|
|
144
144
|
orderActionType: OrderAction;
|
|
145
145
|
orderStatus: RegularOrderStatus;
|
|
146
146
|
orderAction: OrderAction;
|
|
@@ -183,8 +183,8 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
183
183
|
riderTips: z.ZodNumber;
|
|
184
184
|
secondaryRiderTips: z.ZodNumber;
|
|
185
185
|
}, "strip", z.ZodTypeAny, {
|
|
186
|
-
deliveryFee: number;
|
|
187
186
|
total: number;
|
|
187
|
+
deliveryFee: number;
|
|
188
188
|
secondaryDeliveryFee: number;
|
|
189
189
|
riderTips: number;
|
|
190
190
|
secondaryRiderTips: number;
|
|
@@ -192,8 +192,8 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
192
192
|
paidAmount: number;
|
|
193
193
|
secondaryPaidAmount: number;
|
|
194
194
|
}, {
|
|
195
|
-
deliveryFee: number;
|
|
196
195
|
total: number;
|
|
196
|
+
deliveryFee: number;
|
|
197
197
|
secondaryDeliveryFee: number;
|
|
198
198
|
riderTips: number;
|
|
199
199
|
secondaryRiderTips: number;
|
|
@@ -204,8 +204,8 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
204
204
|
}, "strip", z.ZodTypeAny, {
|
|
205
205
|
paymentMethod: PaymentMethod;
|
|
206
206
|
pricing: {
|
|
207
|
-
deliveryFee: number;
|
|
208
207
|
total: number;
|
|
208
|
+
deliveryFee: number;
|
|
209
209
|
secondaryDeliveryFee: number;
|
|
210
210
|
riderTips: number;
|
|
211
211
|
secondaryRiderTips: number;
|
|
@@ -217,8 +217,8 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
217
217
|
}, {
|
|
218
218
|
paymentMethod: PaymentMethod;
|
|
219
219
|
pricing: {
|
|
220
|
-
deliveryFee: number;
|
|
221
220
|
total: number;
|
|
221
|
+
deliveryFee: number;
|
|
222
222
|
secondaryDeliveryFee: number;
|
|
223
223
|
riderTips: number;
|
|
224
224
|
secondaryRiderTips: number;
|
|
@@ -232,20 +232,21 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
232
232
|
triggerAt: z.ZodEffects<z.ZodEffects<z.ZodDate, Date, Date>, Date, Date>;
|
|
233
233
|
orderActionType: z.ZodNativeEnum<typeof OrderAction>;
|
|
234
234
|
}, "strip", z.ZodTypeAny, {
|
|
235
|
-
createdAt: Date;
|
|
236
235
|
_id: import("mongoose").Types.ObjectId;
|
|
236
|
+
createdAt: Date;
|
|
237
237
|
user: {
|
|
238
238
|
_id: import("mongoose").Types.ObjectId;
|
|
239
239
|
name: string;
|
|
240
240
|
};
|
|
241
241
|
orderId: string;
|
|
242
242
|
shopId: import("mongoose").Types.ObjectId;
|
|
243
|
+
paymentMethod: PaymentMethod;
|
|
243
244
|
triggerAt: Date;
|
|
244
245
|
adjustedFinance: {
|
|
245
246
|
paymentMethod: PaymentMethod;
|
|
246
247
|
pricing: {
|
|
247
|
-
deliveryFee: number;
|
|
248
248
|
total: number;
|
|
249
|
+
deliveryFee: number;
|
|
249
250
|
secondaryDeliveryFee: number;
|
|
250
251
|
riderTips: number;
|
|
251
252
|
secondaryRiderTips: number;
|
|
@@ -255,26 +256,26 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
255
256
|
};
|
|
256
257
|
shopProfit: number;
|
|
257
258
|
};
|
|
258
|
-
paymentMethod: PaymentMethod;
|
|
259
259
|
orderActionType: OrderAction;
|
|
260
260
|
orderStatus: RegularOrderStatus;
|
|
261
261
|
orderAction: OrderAction;
|
|
262
262
|
preparationTimeMinutes: number;
|
|
263
263
|
}, {
|
|
264
|
-
createdAt: Date;
|
|
265
264
|
_id: string | import("mongoose").Types.ObjectId;
|
|
265
|
+
createdAt: Date;
|
|
266
266
|
user: {
|
|
267
267
|
_id: string | import("mongoose").Types.ObjectId;
|
|
268
268
|
name: string;
|
|
269
269
|
};
|
|
270
270
|
orderId: string;
|
|
271
271
|
shopId: string | import("mongoose").Types.ObjectId;
|
|
272
|
+
paymentMethod: PaymentMethod;
|
|
272
273
|
triggerAt: Date;
|
|
273
274
|
adjustedFinance: {
|
|
274
275
|
paymentMethod: PaymentMethod;
|
|
275
276
|
pricing: {
|
|
276
|
-
deliveryFee: number;
|
|
277
277
|
total: number;
|
|
278
|
+
deliveryFee: number;
|
|
278
279
|
secondaryDeliveryFee: number;
|
|
279
280
|
riderTips: number;
|
|
280
281
|
secondaryRiderTips: number;
|
|
@@ -284,7 +285,6 @@ export declare class OrderActionsSocketEvent extends BaseSocketEvent<typeof Orde
|
|
|
284
285
|
};
|
|
285
286
|
shopProfit: number;
|
|
286
287
|
};
|
|
287
|
-
paymentMethod: PaymentMethod;
|
|
288
288
|
orderActionType: OrderAction;
|
|
289
289
|
orderStatus: RegularOrderStatus;
|
|
290
290
|
orderAction: OrderAction;
|
|
@@ -19,18 +19,18 @@ export declare const RiderLocationUpdateSocketOutputSchema: z.ZodObject<{
|
|
|
19
19
|
bearing: z.ZodOptional<z.ZodNumber>;
|
|
20
20
|
updatedAt: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
21
21
|
}, "strip", z.ZodTypeAny, {
|
|
22
|
-
updatedAt: Date;
|
|
23
22
|
_id: import("mongoose").Types.ObjectId;
|
|
24
|
-
|
|
23
|
+
updatedAt: Date;
|
|
25
24
|
latitude: number;
|
|
26
25
|
longitude: number;
|
|
26
|
+
riderId: import("mongoose").Types.ObjectId;
|
|
27
27
|
bearing?: number | undefined;
|
|
28
28
|
}, {
|
|
29
|
-
updatedAt: string | Date;
|
|
30
29
|
_id: string | import("mongoose").Types.ObjectId;
|
|
31
|
-
|
|
30
|
+
updatedAt: string | Date;
|
|
32
31
|
latitude: number;
|
|
33
32
|
longitude: number;
|
|
33
|
+
riderId: string | import("mongoose").Types.ObjectId;
|
|
34
34
|
bearing?: number | undefined;
|
|
35
35
|
}>;
|
|
36
36
|
export type RiderLocationUpdateSocketInputDTO = DTO<typeof RiderLocationUpdateSocketInputSchema>;
|
|
@@ -55,18 +55,18 @@ export declare class RiderLocationUpdateSocketEvent extends BaseSocketEvent<type
|
|
|
55
55
|
bearing: z.ZodOptional<z.ZodNumber>;
|
|
56
56
|
updatedAt: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
57
57
|
}, "strip", z.ZodTypeAny, {
|
|
58
|
-
updatedAt: Date;
|
|
59
58
|
_id: import("mongoose").Types.ObjectId;
|
|
60
|
-
|
|
59
|
+
updatedAt: Date;
|
|
61
60
|
latitude: number;
|
|
62
61
|
longitude: number;
|
|
62
|
+
riderId: import("mongoose").Types.ObjectId;
|
|
63
63
|
bearing?: number | undefined;
|
|
64
64
|
}, {
|
|
65
|
-
updatedAt: string | Date;
|
|
66
65
|
_id: string | import("mongoose").Types.ObjectId;
|
|
67
|
-
|
|
66
|
+
updatedAt: string | Date;
|
|
68
67
|
latitude: number;
|
|
69
68
|
longitude: number;
|
|
69
|
+
riderId: string | import("mongoose").Types.ObjectId;
|
|
70
70
|
bearing?: number | undefined;
|
|
71
71
|
}>;
|
|
72
72
|
};
|
|
@@ -12,19 +12,19 @@ export declare const TicketActionsSocketOutputSchema: z.ZodObject<{
|
|
|
12
12
|
title: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
13
13
|
silent: z.ZodOptional<z.ZodBoolean>;
|
|
14
14
|
}, "strip", z.ZodTypeAny, {
|
|
15
|
-
_id: import("mongoose").Types.ObjectId;
|
|
16
15
|
status: TicketStatus;
|
|
17
16
|
type: TicketType;
|
|
17
|
+
_id: import("mongoose").Types.ObjectId;
|
|
18
|
+
silent?: boolean | undefined;
|
|
18
19
|
title?: string | undefined;
|
|
19
20
|
content?: string | undefined;
|
|
20
|
-
silent?: boolean | undefined;
|
|
21
21
|
}, {
|
|
22
|
-
_id: import("mongoose").Types.ObjectId;
|
|
23
22
|
status: TicketStatus;
|
|
24
23
|
type: TicketType;
|
|
24
|
+
_id: import("mongoose").Types.ObjectId;
|
|
25
|
+
silent?: boolean | undefined;
|
|
25
26
|
title?: string | undefined;
|
|
26
27
|
content?: string | undefined;
|
|
27
|
-
silent?: boolean | undefined;
|
|
28
28
|
}>;
|
|
29
29
|
export declare const TicketActionsPushOutputSchema: z.ZodObject<{
|
|
30
30
|
ticketId: z.ZodEffects<z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>, import("mongoose").Types.ObjectId, import("mongoose").Types.ObjectId>;
|
|
@@ -59,19 +59,19 @@ export declare class TicketActionsSocketEvent extends BaseSocketEvent<typeof Tic
|
|
|
59
59
|
title: z.ZodOptional<z.ZodString> | z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
|
|
60
60
|
silent: z.ZodOptional<z.ZodBoolean>;
|
|
61
61
|
}, "strip", z.ZodTypeAny, {
|
|
62
|
-
_id: import("mongoose").Types.ObjectId;
|
|
63
62
|
status: TicketStatus;
|
|
64
63
|
type: TicketType;
|
|
64
|
+
_id: import("mongoose").Types.ObjectId;
|
|
65
|
+
silent?: boolean | undefined;
|
|
65
66
|
title?: string | undefined;
|
|
66
67
|
content?: string | undefined;
|
|
67
|
-
silent?: boolean | undefined;
|
|
68
68
|
}, {
|
|
69
|
-
_id: import("mongoose").Types.ObjectId;
|
|
70
69
|
status: TicketStatus;
|
|
71
70
|
type: TicketType;
|
|
71
|
+
_id: import("mongoose").Types.ObjectId;
|
|
72
|
+
silent?: boolean | undefined;
|
|
72
73
|
title?: string | undefined;
|
|
73
74
|
content?: string | undefined;
|
|
74
|
-
silent?: boolean | undefined;
|
|
75
75
|
}>;
|
|
76
76
|
pushNotificationOutput: z.ZodObject<{
|
|
77
77
|
ticketId: z.ZodEffects<z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>, import("mongoose").Types.ObjectId, import("mongoose").Types.ObjectId>;
|