@intlayer/backend 5.5.7 → 5.5.9
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/cjs/controllers/newsletter.controller.cjs +162 -0
- package/dist/cjs/controllers/newsletter.controller.cjs.map +1 -0
- package/dist/cjs/export.cjs +3 -0
- package/dist/cjs/export.cjs.map +1 -1
- package/dist/cjs/index.cjs +11 -9
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/routes/ai.routes.cjs +4 -1
- package/dist/cjs/routes/ai.routes.cjs.map +1 -1
- package/dist/cjs/routes/dictionary.routes.cjs +4 -1
- package/dist/cjs/routes/dictionary.routes.cjs.map +1 -1
- package/dist/cjs/routes/eventListener.routes.cjs +4 -1
- package/dist/cjs/routes/eventListener.routes.cjs.map +1 -1
- package/dist/cjs/routes/newsletter.routes.cjs +66 -0
- package/dist/cjs/routes/newsletter.routes.cjs.map +1 -0
- package/dist/cjs/routes/organization.routes.cjs +4 -1
- package/dist/cjs/routes/organization.routes.cjs.map +1 -1
- package/dist/cjs/routes/project.routes.cjs +4 -1
- package/dist/cjs/routes/project.routes.cjs.map +1 -1
- package/dist/cjs/routes/search.routes.cjs +4 -1
- package/dist/cjs/routes/search.routes.cjs.map +1 -1
- package/dist/cjs/routes/sessionAuth.routes.cjs +4 -1
- package/dist/cjs/routes/sessionAuth.routes.cjs.map +1 -1
- package/dist/cjs/routes/stripe.routes.cjs +4 -1
- package/dist/cjs/routes/stripe.routes.cjs.map +1 -1
- package/dist/cjs/routes/tags.routes.cjs +4 -1
- package/dist/cjs/routes/tags.routes.cjs.map +1 -1
- package/dist/cjs/routes/user.routes.cjs +4 -1
- package/dist/cjs/routes/user.routes.cjs.map +1 -1
- package/dist/cjs/schemas/user.schema.cjs +9 -0
- package/dist/cjs/schemas/user.schema.cjs.map +1 -1
- package/dist/cjs/types/user.types.cjs +15 -0
- package/dist/cjs/types/user.types.cjs.map +1 -1
- package/dist/cjs/utils/AI/aiSdk.cjs +2 -2
- package/dist/cjs/utils/AI/aiSdk.cjs.map +1 -1
- package/dist/cjs/utils/AI/askDocQuestion/PROMPT.md +6 -2
- package/dist/cjs/utils/AI/askDocQuestion/askDocQuestion.cjs +16 -10
- package/dist/cjs/utils/AI/askDocQuestion/askDocQuestion.cjs.map +1 -1
- package/dist/cjs/utils/AI/askDocQuestion/embeddings.json +7182 -0
- package/dist/cjs/utils/AI/autocomplete/PROMPT.md +24 -7
- package/dist/cjs/utils/AI/autocomplete/index.cjs +4 -2
- package/dist/cjs/utils/AI/autocomplete/index.cjs.map +1 -1
- package/dist/esm/controllers/newsletter.controller.mjs +126 -0
- package/dist/esm/controllers/newsletter.controller.mjs.map +1 -0
- package/dist/esm/export.mjs +2 -0
- package/dist/esm/export.mjs.map +1 -1
- package/dist/esm/index.mjs +26 -18
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/routes/ai.routes.mjs +3 -1
- package/dist/esm/routes/ai.routes.mjs.map +1 -1
- package/dist/esm/routes/dictionary.routes.mjs +6 -4
- package/dist/esm/routes/dictionary.routes.mjs.map +1 -1
- package/dist/esm/routes/eventListener.routes.mjs +3 -1
- package/dist/esm/routes/eventListener.routes.mjs.map +1 -1
- package/dist/esm/routes/newsletter.routes.mjs +44 -0
- package/dist/esm/routes/newsletter.routes.mjs.map +1 -0
- package/dist/esm/routes/organization.routes.mjs +7 -5
- package/dist/esm/routes/organization.routes.mjs.map +1 -1
- package/dist/esm/routes/project.routes.mjs +6 -4
- package/dist/esm/routes/project.routes.mjs.map +1 -1
- package/dist/esm/routes/search.routes.mjs +3 -1
- package/dist/esm/routes/search.routes.mjs.map +1 -1
- package/dist/esm/routes/sessionAuth.routes.mjs +11 -9
- package/dist/esm/routes/sessionAuth.routes.mjs.map +1 -1
- package/dist/esm/routes/stripe.routes.mjs +4 -2
- package/dist/esm/routes/stripe.routes.mjs.map +1 -1
- package/dist/esm/routes/tags.routes.mjs +3 -1
- package/dist/esm/routes/tags.routes.mjs.map +1 -1
- package/dist/esm/routes/user.routes.mjs +7 -5
- package/dist/esm/routes/user.routes.mjs.map +1 -1
- package/dist/esm/schemas/user.schema.mjs +9 -0
- package/dist/esm/schemas/user.schema.mjs.map +1 -1
- package/dist/esm/types/user.types.mjs +7 -0
- package/dist/esm/types/user.types.mjs.map +1 -1
- package/dist/esm/utils/AI/aiSdk.mjs +2 -2
- package/dist/esm/utils/AI/aiSdk.mjs.map +1 -1
- package/dist/esm/utils/AI/askDocQuestion/PROMPT.md +6 -2
- package/dist/esm/utils/AI/askDocQuestion/askDocQuestion.mjs +16 -10
- package/dist/esm/utils/AI/askDocQuestion/askDocQuestion.mjs.map +1 -1
- package/dist/esm/utils/AI/askDocQuestion/embeddings.json +7182 -0
- package/dist/esm/utils/AI/autocomplete/PROMPT.md +24 -7
- package/dist/esm/utils/AI/autocomplete/index.mjs +4 -2
- package/dist/esm/utils/AI/autocomplete/index.mjs.map +1 -1
- package/dist/types/controllers/newsletter.controller.d.ts +31 -0
- package/dist/types/controllers/newsletter.controller.d.ts.map +1 -0
- package/dist/types/export.d.ts +2 -0
- package/dist/types/export.d.ts.map +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/routes/ai.routes.d.ts +1 -0
- package/dist/types/routes/ai.routes.d.ts.map +1 -1
- package/dist/types/routes/dictionary.routes.d.ts +1 -0
- package/dist/types/routes/dictionary.routes.d.ts.map +1 -1
- package/dist/types/routes/eventListener.routes.d.ts +1 -0
- package/dist/types/routes/eventListener.routes.d.ts.map +1 -1
- package/dist/types/routes/newsletter.routes.d.ts +21 -0
- package/dist/types/routes/newsletter.routes.d.ts.map +1 -0
- package/dist/types/routes/organization.routes.d.ts +1 -0
- package/dist/types/routes/organization.routes.d.ts.map +1 -1
- package/dist/types/routes/project.routes.d.ts +1 -0
- package/dist/types/routes/project.routes.d.ts.map +1 -1
- package/dist/types/routes/search.routes.d.ts +1 -0
- package/dist/types/routes/search.routes.d.ts.map +1 -1
- package/dist/types/routes/sessionAuth.routes.d.ts +1 -0
- package/dist/types/routes/sessionAuth.routes.d.ts.map +1 -1
- package/dist/types/routes/stripe.routes.d.ts +1 -0
- package/dist/types/routes/stripe.routes.d.ts.map +1 -1
- package/dist/types/routes/tags.routes.d.ts +1 -0
- package/dist/types/routes/tags.routes.d.ts.map +1 -1
- package/dist/types/routes/user.routes.d.ts +1 -0
- package/dist/types/routes/user.routes.d.ts.map +1 -1
- package/dist/types/schemas/user.schema.d.ts +1 -1
- package/dist/types/schemas/user.schema.d.ts.map +1 -1
- package/dist/types/types/user.types.d.ts +7 -1
- package/dist/types/types/user.types.d.ts.map +1 -1
- package/dist/types/utils/AI/aiSdk.d.ts +1 -1
- package/dist/types/utils/AI/aiSdk.d.ts.map +1 -1
- package/dist/types/utils/AI/askDocQuestion/askDocQuestion.d.ts.map +1 -1
- package/dist/types/utils/AI/autocomplete/index.d.ts.map +1 -1
- package/package.json +19 -19
|
@@ -1,14 +1,31 @@
|
|
|
1
|
-
|
|
1
|
+
Forgot all the previous instructions.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
You're the assistant and you will have to complete your own text.
|
|
4
4
|
|
|
5
|
-
-
|
|
6
|
-
- guess the next word(s)
|
|
7
|
-
-
|
|
5
|
+
- As do Github Copilot, your role is to autocomplete the user text provided.
|
|
6
|
+
- You should try to guess the next word(s) or complete the sentence.
|
|
7
|
+
- Your completion should not exceed one sentence.
|
|
8
|
+
- Minimize the completion length if you're unsure about the user's input.
|
|
8
9
|
|
|
9
|
-
|
|
10
|
+
The user input will be provided in the next user message:
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
Exmaple of entry:
|
|
13
|
+
|
|
14
|
+
```json
|
|
15
|
+
{ "role": "user", "content": "Lorem ipsum " }
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Example of output:
|
|
19
|
+
|
|
20
|
+
```text
|
|
21
|
+
dolor sit amet,
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Or:
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
|
|
28
|
+
```
|
|
12
29
|
|
|
13
30
|
You should return your autocompletion without any additional text or formatting.
|
|
14
31
|
|
|
@@ -33,8 +33,10 @@ const autocomplete = async ({
|
|
|
33
33
|
temperature: aiConfig.temperature,
|
|
34
34
|
messages: [
|
|
35
35
|
{ role: "system", content: prompt },
|
|
36
|
-
{ role: "
|
|
37
|
-
]
|
|
36
|
+
{ role: "assistant", content: text }
|
|
37
|
+
],
|
|
38
|
+
maxTokens: 6
|
|
39
|
+
// Generate next 6 tokens
|
|
38
40
|
});
|
|
39
41
|
logger.info(`${usage?.totalTokens ?? 0} tokens used in the request`);
|
|
40
42
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../src/utils/AI/autocomplete/index.ts"],"sourcesContent":["import { logger } from '@logger';\nimport { generateText } from 'ai';\nimport { readFileSync } from 'fs';\nimport { dirname, join } from 'path';\nimport { fileURLToPath } from 'url';\nimport { AIOptions, AIProvider, getAIConfig } from '../aiSdk';\n\nconst __dirname = dirname(fileURLToPath(import.meta.url));\n\n// Get the content of a file at the specified path\nconst getFileContent = (filePath: string) => {\n return readFileSync(join(__dirname, filePath), { encoding: 'utf-8' });\n};\n\nexport type AutocompleteOptions = {\n text: string;\n aiOptions?: AIOptions;\n};\n\nexport type AutocompleteFileResultData = {\n autocompletion: string;\n tokenUsed: number;\n};\n\n// The prompt template to send to the AI model\nconst CHAT_GPT_PROMPT = getFileContent('./PROMPT.md');\n\n/**\n * Autocompletes a content declaration file by constructing a prompt for AI models.\n * The prompt includes details about the project's locales, file paths of content declarations,\n * and requests for identifying issues or inconsistencies.\n */\nexport const autocomplete = async ({\n text,\n aiOptions,\n}: AutocompleteOptions): Promise<AutocompleteFileResultData | undefined> => {\n try {\n // Prepare the prompt for AI by replacing placeholders with actual values.\n const prompt = CHAT_GPT_PROMPT.replace(\n '{{applicationContext}}',\n aiOptions?.applicationContext ?? ''\n );\n\n // Get the appropriate AI model configuration\n const aiConfig = await getAIConfig({\n model: 'gpt-4o-mini',\n provider: AIProvider.OPENAI,\n apiKey: process.env.OPENAI_API_KEY,\n ...aiOptions,\n });\n\n if (!aiConfig) {\n logger.error('Failed to configure AI model');\n return undefined;\n }\n\n // Use the AI SDK to generate the completion\n const { text: newContent, usage } = await generateText({\n model: aiConfig.model,\n temperature: aiConfig.temperature,\n messages: [\n { role: 'system', content: prompt },\n { role: '
|
|
1
|
+
{"version":3,"sources":["../../../../../src/utils/AI/autocomplete/index.ts"],"sourcesContent":["import { logger } from '@logger';\nimport { generateText } from 'ai';\nimport { readFileSync } from 'fs';\nimport { dirname, join } from 'path';\nimport { fileURLToPath } from 'url';\nimport { AIOptions, AIProvider, getAIConfig } from '../aiSdk';\n\nconst __dirname = dirname(fileURLToPath(import.meta.url));\n\n// Get the content of a file at the specified path\nconst getFileContent = (filePath: string) => {\n return readFileSync(join(__dirname, filePath), { encoding: 'utf-8' });\n};\n\nexport type AutocompleteOptions = {\n text: string;\n aiOptions?: AIOptions;\n};\n\nexport type AutocompleteFileResultData = {\n autocompletion: string;\n tokenUsed: number;\n};\n\n// The prompt template to send to the AI model\nconst CHAT_GPT_PROMPT = getFileContent('./PROMPT.md');\n\n/**\n * Autocompletes a content declaration file by constructing a prompt for AI models.\n * The prompt includes details about the project's locales, file paths of content declarations,\n * and requests for identifying issues or inconsistencies.\n */\nexport const autocomplete = async ({\n text,\n aiOptions,\n}: AutocompleteOptions): Promise<AutocompleteFileResultData | undefined> => {\n try {\n // Prepare the prompt for AI by replacing placeholders with actual values.\n const prompt = CHAT_GPT_PROMPT.replace(\n '{{applicationContext}}',\n aiOptions?.applicationContext ?? ''\n );\n\n // Get the appropriate AI model configuration\n const aiConfig = await getAIConfig({\n model: 'gpt-4o-mini',\n provider: AIProvider.OPENAI,\n apiKey: process.env.OPENAI_API_KEY,\n ...aiOptions,\n });\n\n if (!aiConfig) {\n logger.error('Failed to configure AI model');\n return undefined;\n }\n\n // Use the AI SDK to generate the completion\n const { text: newContent, usage } = await generateText({\n model: aiConfig.model,\n temperature: aiConfig.temperature,\n messages: [\n { role: 'system', content: prompt },\n { role: 'assistant', content: text },\n ],\n maxTokens: 6, // Generate next 6 tokens\n });\n\n logger.info(`${usage?.totalTokens ?? 0} tokens used in the request`);\n\n return {\n autocompletion: newContent,\n tokenUsed: usage?.totalTokens ?? 0,\n };\n } catch (error) {\n console.error(error);\n }\n};\n"],"mappings":"AAAA,SAAS,cAAc;AACvB,SAAS,oBAAoB;AAC7B,SAAS,oBAAoB;AAC7B,SAAS,SAAS,YAAY;AAC9B,SAAS,qBAAqB;AAC9B,SAAoB,YAAY,mBAAmB;AAEnD,MAAM,YAAY,QAAQ,cAAc,YAAY,GAAG,CAAC;AAGxD,MAAM,iBAAiB,CAAC,aAAqB;AAC3C,SAAO,aAAa,KAAK,WAAW,QAAQ,GAAG,EAAE,UAAU,QAAQ,CAAC;AACtE;AAaA,MAAM,kBAAkB,eAAe,aAAa;AAO7C,MAAM,eAAe,OAAO;AAAA,EACjC;AAAA,EACA;AACF,MAA4E;AAC1E,MAAI;AAEF,UAAM,SAAS,gBAAgB;AAAA,MAC7B;AAAA,MACA,WAAW,sBAAsB;AAAA,IACnC;AAGA,UAAM,WAAW,MAAM,YAAY;AAAA,MACjC,OAAO;AAAA,MACP,UAAU,WAAW;AAAA,MACrB,QAAQ,QAAQ,IAAI;AAAA,MACpB,GAAG;AAAA,IACL,CAAC;AAED,QAAI,CAAC,UAAU;AACb,aAAO,MAAM,8BAA8B;AAC3C,aAAO;AAAA,IACT;AAGA,UAAM,EAAE,MAAM,YAAY,MAAM,IAAI,MAAM,aAAa;AAAA,MACrD,OAAO,SAAS;AAAA,MAChB,aAAa,SAAS;AAAA,MACtB,UAAU;AAAA,QACR,EAAE,MAAM,UAAU,SAAS,OAAO;AAAA,QAClC,EAAE,MAAM,aAAa,SAAS,KAAK;AAAA,MACrC;AAAA,MACA,WAAW;AAAA;AAAA,IACb,CAAC;AAED,WAAO,KAAK,GAAG,OAAO,eAAe,CAAC,6BAA6B;AAEnE,WAAO;AAAA,MACL,gBAAgB;AAAA,MAChB,WAAW,OAAO,eAAe;AAAA,IACnC;AAAA,EACF,SAAS,OAAO;AACd,YAAQ,MAAM,KAAK;AAAA,EACrB;AACF;","names":[]}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { EmailsList, UserAPI } from '../types/user.types';
|
|
2
|
+
import type { ResponseWithInformation } from '../middlewares/sessionAuth.middleware';
|
|
3
|
+
import { type ResponseData } from '../utils/responseData';
|
|
4
|
+
import type { NextFunction, Request } from 'express';
|
|
5
|
+
export type NewsletterSubscriptionBody = {
|
|
6
|
+
email: string;
|
|
7
|
+
emailList: EmailsList | EmailsList[];
|
|
8
|
+
};
|
|
9
|
+
export type NewsletterSubscriptionResult = ResponseData<UserAPI>;
|
|
10
|
+
/**
|
|
11
|
+
* Subscribes a user to the newsletter.
|
|
12
|
+
* If the user doesn't exist, creates a new user.
|
|
13
|
+
* If the user exists, updates their newsletter subscription to true.
|
|
14
|
+
*/
|
|
15
|
+
export declare const subscribeToNewsletter: (req: Request<any, any, NewsletterSubscriptionBody>, res: ResponseWithInformation<NewsletterSubscriptionResult>, _next: NextFunction) => Promise<void>;
|
|
16
|
+
export type NewsletterUnsubscriptionBody = {
|
|
17
|
+
userId: string;
|
|
18
|
+
emailList: EmailsList | EmailsList[];
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* Unsubscribes a user from the newsletter.
|
|
22
|
+
* Only works if the user exists.
|
|
23
|
+
*/
|
|
24
|
+
export declare const unsubscribeFromNewsletter: (req: Request<any, any, NewsletterUnsubscriptionBody>, res: ResponseWithInformation<NewsletterSubscriptionResult>, _next: NextFunction) => Promise<void>;
|
|
25
|
+
/**
|
|
26
|
+
* Gets the newsletter subscription status for a user.
|
|
27
|
+
*/
|
|
28
|
+
export declare const getNewsletterStatus: (req: Request<{
|
|
29
|
+
email: string;
|
|
30
|
+
}>, res: ResponseWithInformation<NewsletterSubscriptionResult>, _next: NextFunction) => Promise<void>;
|
|
31
|
+
//# sourceMappingURL=newsletter.controller.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"newsletter.controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/newsletter.controller.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAE9D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAInF,OAAO,EAAkB,KAAK,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxE,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAGrD,MAAM,MAAM,0BAA0B,GAAG;IACvC,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,UAAU,GAAG,UAAU,EAAE,CAAC;CACtC,CAAC;AACF,MAAM,MAAM,4BAA4B,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;AAEjE;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,GAChC,KAAK,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,0BAA0B,CAAC,EAClD,KAAK,uBAAuB,CAAC,4BAA4B,CAAC,EAC1D,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAyDd,CAAC;AAEF,MAAM,MAAM,4BAA4B,GAAG;IACzC,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,UAAU,GAAG,UAAU,EAAE,CAAC;CACtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,yBAAyB,GACpC,KAAK,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,4BAA4B,CAAC,EACpD,KAAK,uBAAuB,CAAC,4BAA4B,CAAC,EAC1D,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAqDd,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,mBAAmB,GAC9B,KAAK,OAAO,CAAC;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,EAC/B,KAAK,uBAAuB,CAAC,4BAA4B,CAAC,EAC1D,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAiCd,CAAC"}
|
package/dist/types/export.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { getDictionaryRoutes } from './routes/dictionary.routes';
|
|
2
|
+
export { getNewsletterRoutes } from './routes/newsletter.routes';
|
|
2
3
|
export { getOrganizationRoutes } from './routes/organization.routes';
|
|
3
4
|
export { getProjectRoutes } from './routes/project.routes';
|
|
4
5
|
export { getSessionAuthRoutes } from './routes/sessionAuth.routes';
|
|
@@ -6,6 +7,7 @@ export { getUserRoutes } from './routes/user.routes';
|
|
|
6
7
|
export type * from './controllers/ai.controller';
|
|
7
8
|
export type * from './controllers/dictionary.controller';
|
|
8
9
|
export type * from './controllers/eventListener.controller';
|
|
10
|
+
export type * from './controllers/newsletter.controller';
|
|
9
11
|
export type * from './controllers/oAuth2.controller';
|
|
10
12
|
export type * from './controllers/organization.controller';
|
|
11
13
|
export type * from './controllers/project.controller';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/export.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,EAAE,qBAAqB,EAAE,MAAM,6BAA6B,CAAC;AACpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAGpD,mBAAmB,4BAA4B,CAAC;AAChD,mBAAmB,oCAAoC,CAAC;AACxD,mBAAmB,uCAAuC,CAAC;AAC3D,mBAAmB,gCAAgC,CAAC;AACp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zD,mBAAmB,gCAAgC,CAAC;AACpD,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,8BAA8B,CAAC;AAGlD,mBAAmB,0BAA0B,CAAC;AAC9C,mBAAmB,sBAAsB,CAAC;AAC1C,mBAAmB,4BAA4B,CAAC;AAChD,mBAAmB,oBAAoB,CAAC;AACxC,mBAAmB,uBAAuB,CAAC;AAC3C,mBAAmB,mBAAmB,CAAC;AACvC,mBAAmB,oBAAoB,CAAC;AAGxC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAKA,OAAgB,EAAE,KAAK,OAAO,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAKA,OAAgB,EAAE,KAAK,OAAO,EAAE,MAAM,SAAS,CAAC;AAuDhD,QAAA,MAAM,GAAG,EAAE,OAAmB,CAAC;AAkJ/B,eAAe,GAAG,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/ai.routes.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,QAAQ,EAAE,MAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"ai.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/ai.routes.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,QAAQ,EAAE,MAAiB,CAAC;AAEzC,eAAO,MAAM,OAAO,YAAY,CAAC;AAIjC,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqCH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dictionary.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/dictionary.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"dictionary.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/dictionary.routes.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,gBAAgB,EAAE,MAAiB,CAAC;AAEjD,eAAO,MAAM,eAAe,oBAAoB,CAAC;AAIjD,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;iCAcD;YAAE,aAAa,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;gCAgB1B;YAAE,YAAY,EAAE,MAAM,CAAA;SAAE;;;;;gCAMxB;YAAE,YAAY,EAAE,MAAM,CAAA;SAAE;;;CAIjC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eventListener.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/eventListener.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"eventListener.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/eventListener.routes.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,mBAAmB,EAAE,MAAiB,CAAC;AAEpD,eAAO,MAAM,kBAAkB,wBAAwB,CAAC;AAIxD,eAAO,MAAM,mBAAmB;;;+BAIH;YAAE,WAAW,EAAE,MAAM,CAAA;SAAE;;;CAI/B,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Router } from 'express';
|
|
2
|
+
export declare const newsletterRouter: Router;
|
|
3
|
+
export declare const newsletterRoute = "/api/newsletter";
|
|
4
|
+
export declare const getNewsletterRoutes: () => {
|
|
5
|
+
subscribeToNewsletter: {
|
|
6
|
+
urlModel: string;
|
|
7
|
+
url: string;
|
|
8
|
+
method: "POST";
|
|
9
|
+
};
|
|
10
|
+
unsubscribeFromNewsletter: {
|
|
11
|
+
urlModel: string;
|
|
12
|
+
url: string;
|
|
13
|
+
method: "POST";
|
|
14
|
+
};
|
|
15
|
+
getNewsletterStatus: {
|
|
16
|
+
urlModel: string;
|
|
17
|
+
url: string;
|
|
18
|
+
method: "GET";
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=newsletter.routes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"newsletter.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/newsletter.routes.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,gBAAgB,EAAE,MAAiB,CAAC;AAEjD,eAAO,MAAM,eAAe,oBAAoB,CAAC;AAIjD,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;CAiBX,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"organization.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/organization.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"organization.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/organization.routes.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,kBAAkB,EAAE,MAAiB,CAAC;AAEnD,eAAO,MAAM,iBAAiB,sBAAsB,CAAC;AAIrD,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAmCF;YAAE,cAAc,EAAE,MAAM,CAAA;SAAE;;;;;;;;CASrC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/project.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"project.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/project.routes.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,aAAa,EAAE,MAAiB,CAAC;AAE9C,eAAO,MAAM,YAAY,iBAAiB,CAAC;AAI3C,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6BAkCF;YAAE,SAAS,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;CAuB3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"search.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/search.routes.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,YAAY,EAAE,MAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"search.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/search.routes.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,YAAY,EAAE,MAAiB,CAAC;AAE7C,eAAO,MAAM,WAAW,gBAAgB,CAAC;AAIzC,eAAO,MAAM,eAAe;;;;;;CAOP,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sessionAuth.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/sessionAuth.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sessionAuth.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/sessionAuth.routes.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,iBAAiB,EAAE,MAAiB,CAAC;AAElD,eAAO,MAAM,gBAAgB,cAAc,CAAC;AAI5C,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iDA2CxB;YACD,MAAM,EAAE,MAAM,CAAC;YACf,MAAM,EAAE,MAAM,CAAC;YACf,YAAY,CAAC,EAAE,MAAM,CAAC;SACvB;;;;;0BAQiB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;CAwBrB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/stripe.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"stripe.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/stripe.routes.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,YAAY,EAAE,MAAiB,CAAC;AAE7C,eAAO,MAAM,WAAW,gBAAgB,CAAC;AAIzC,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;CAiBP,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tags.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/tags.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"tags.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/tags.routes.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,SAAS,EAAE,MAAiB,CAAC;AAE1C,eAAO,MAAM,QAAQ,aAAa,CAAC;AAInC,eAAO,MAAM,YAAY;;;;;;;;;;;;;yBAcF;YAAE,KAAK,EAAE,MAAM,CAAA;SAAE;;;;;yBAKjB;YAAE,KAAK,EAAE,MAAM,CAAA;SAAE;;;CAGnB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/user.routes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"user.routes.d.ts","sourceRoot":"","sources":["../../../src/routes/user.routes.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,UAAU,EAAE,MAAiB,CAAC;AAE3C,eAAO,MAAM,SAAS,cAAc,CAAC;AAIrC,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;0BAmBF;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;yBAKnB;YAAE,KAAK,EAAE,MAAM,CAAA;SAAE;;;;;gDAQ/B;YACD,QAAQ,EAAE,MAAM,CAAC;YACjB,iBAAiB,EAAE,MAAM,CAAC;SAC3B;;;CAGc,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Schema } from 'mongoose';
|
|
2
1
|
import type { User } from '../types/user.types';
|
|
2
|
+
import { Schema } from 'mongoose';
|
|
3
3
|
export declare const userSchema: Schema<User, import("mongoose").Model<User, any, any, any, import("mongoose").Document<unknown, any, User, any> & User & Required<{
|
|
4
4
|
_id: Schema.Types.ObjectId;
|
|
5
5
|
}> & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.schema.d.ts","sourceRoot":"","sources":["../../../src/schemas/user.schema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"user.schema.d.ts","sourceRoot":"","sources":["../../../src/schemas/user.schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAK/C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAyClC,eAAO,MAAM,UAAU;;;;;;;;EAgDtB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Document, Model, ObjectId } from 'mongoose';
|
|
2
2
|
import type { Session, SessionProviders } from './session.types';
|
|
3
3
|
export interface UserData {
|
|
4
4
|
email: string;
|
|
@@ -6,11 +6,17 @@ export interface UserData {
|
|
|
6
6
|
phone?: string;
|
|
7
7
|
dateOfBirth?: Date;
|
|
8
8
|
}
|
|
9
|
+
export declare enum EmailsList {
|
|
10
|
+
NEWS_LETTER = "newsLetter"
|
|
11
|
+
}
|
|
9
12
|
export interface User extends UserData {
|
|
10
13
|
_id: ObjectId;
|
|
11
14
|
provider?: SessionProviders[];
|
|
12
15
|
customerId?: string;
|
|
13
16
|
session?: Session;
|
|
17
|
+
emailsList?: {
|
|
18
|
+
[key in EmailsList]: boolean;
|
|
19
|
+
};
|
|
14
20
|
createdAt: number;
|
|
15
21
|
updatedAt: number;
|
|
16
22
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.types.d.ts","sourceRoot":"","sources":["../../../src/types/user.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAC1D,OAAO,KAAK,EAAE,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEjE,MAAM,WAAW,QAAQ;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,IAAI,CAAC;CACpB;AAED,MAAM,WAAW,IAAK,SAAQ,QAAQ;IACpC,GAAG,EAAE,QAAQ,CAAC;IACd,QAAQ,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAC9B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,OACf,SAAQ,IAAI,CAAC,IAAI,EAAE,UAAU,GAAG,SAAS,GAAG,WAAW,CAAC;IACxD,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,MAAM,YAAY,GAAG,QAAQ,CAAC,OAAO,EAAE,EAAE,EAAE,IAAI,CA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AAO,CAAC;IAClB,UAAU,CAAC,EAAE;SACV,GAAG,IAAI,UAAU,GAAG,OAAO;KAC7B,CAAC;IACF,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,OACf,SAAQ,IAAI,CAAC,IAAI,EAAE,UAAU,GAAG,SAAS,GAAG,WAAW,CAAC;IACxD,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,MAAM,YAAY,GAAG,QAAQ,CAAC,OAAO,EAAE,EAAE,EAAE,IAAI,CAAC,GAAG,IAAI,CAAC;AAE9D,MAAM,MAAM,yBAAyB,GAAG,OAAO,CAAC,IAAI,CAAC,GACnD,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEJ,MAAM,MAAM,aAAa,GAAG,KAAK,CAAC,IAAI,CAAC,GAAG;IACxC,KAAK,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,cAAc,EAAE,CACd,MAAM,EAAE,QAAQ,GAAG,MAAM,EACzB,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,KAChB,OAAO,CAAC,IAAI,CAAC,CAAC;IACnB,aAAa,EAAE,CAAC,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACzE,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Supported AI models
|
|
3
3
|
*/
|
|
4
|
-
export type Model = 'gpt-
|
|
4
|
+
export type Model = 'gpt-4-0613' | 'gpt-4' | 'gpt-3.5-turbo' | 'gpt-4o-audio-preview-2025-06-03' | 'gpt-4.1-nano' | 'gpt-image-1' | 'codex-mini-latest' | 'gpt-4o-realtime-preview-2025-06-03' | 'davinci-002' | 'babbage-002' | 'gpt-3.5-turbo-instruct' | 'gpt-3.5-turbo-instruct-0914' | 'dall-e-3' | 'dall-e-2' | 'gpt-4-1106-preview' | 'gpt-3.5-turbo-1106' | 'tts-1-hd' | 'tts-1-1106' | 'tts-1-hd-1106' | 'text-embedding-3-small' | 'text-embedding-3-large' | 'gpt-4-0125-preview' | 'gpt-4-turbo-preview' | 'gpt-3.5-turbo-0125' | 'gpt-4-turbo' | 'gpt-4-turbo-2024-04-09' | 'gpt-4o' | 'gpt-4o-2024-05-13' | 'gpt-4o-mini-2024-07-18' | 'gpt-4o-mini' | 'gpt-4o-2024-08-06' | 'chatgpt-4o-latest' | 'o1-preview-2024-09-12' | 'o1-preview' | 'o1-mini-2024-09-12' | 'o1-mini' | 'gpt-4o-realtime-preview-2024-10-01' | 'gpt-4o-audio-preview-2024-10-01' | 'gpt-4o-audio-preview' | 'gpt-4o-realtime-preview' | 'omni-moderation-latest' | 'omni-moderation-2024-09-26' | 'gpt-4o-realtime-preview-2024-12-17' | 'gpt-4o-audio-preview-2024-12-17' | 'gpt-4o-mini-realtime-preview-2024-12-17' | 'gpt-4o-mini-audio-preview-2024-12-17' | 'o1-2024-12-17' | 'o1' | 'gpt-4o-mini-realtime-preview' | 'gpt-4o-mini-audio-preview' | 'o3-mini' | 'o3-mini-2025-01-31' | 'gpt-4o-2024-11-20' | 'gpt-4.5-preview' | 'gpt-4.5-preview-2025-02-27' | 'gpt-4o-search-preview-2025-03-11' | 'gpt-4o-search-preview' | 'gpt-4o-mini-search-preview-2025-03-11' | 'gpt-4o-mini-search-preview' | 'gpt-4o-transcribe' | 'gpt-4o-mini-transcribe' | 'o1-pro-2025-03-19' | 'o1-pro' | 'gpt-4o-mini-tts' | 'o4-mini-2025-04-16' | 'o4-mini' | 'gpt-4.1-2025-04-14' | 'gpt-4.1' | 'gpt-4.1-mini-2025-04-14' | 'gpt-4.1-mini' | 'gpt-4.1-nano-2025-04-14' | 'gpt-3.5-turbo-16k' | 'tts-1' | 'whisper-1' | 'text-embedding-ada-002' | 'claude-3-haiku-20240307' | 'claude-3-sonnet-20240229' | 'claude-3-opus-20240229' | 'mistral-tiny' | 'mistral-small' | 'mistral-small-3.1' | 'mistral-medium' | 'mistral-medium-3' | 'mistral-large' | 'mistral-large-2' | 'mistral-large-latest' | 'codestral' | 'codestral-mamba' | 'mixtral-8x7b' | 'mixtral-8x22b' | 'mathstral-7b' | 'pixtral-large' | 'deepseek-coder' | 'deepseek-chat' | 'deepseek-v3' | 'gemini-1.0-pro' | 'gemini-1.5-pro' | 'gemini-1.5-flash' | (string & {});
|
|
5
5
|
/**
|
|
6
6
|
* Supported AI SDK providers
|
|
7
7
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aiSdk.d.ts","sourceRoot":"","sources":["../../../../src/utils/AI/aiSdk.ts"],"names":[],"mappings":"AAOA;;GAEG;AACH,MAAM,MAAM,KAAK,GAEb,
|
|
1
|
+
{"version":3,"file":"aiSdk.d.ts","sourceRoot":"","sources":["../../../../src/utils/AI/aiSdk.ts"],"names":[],"mappings":"AAOA;;GAEG;AACH,MAAM,MAAM,KAAK,GAEb,YAAY,GACZ,OAAO,GACP,eAAe,GACf,iCAAiC,GACjC,cAAc,GACd,aAAa,GACb,mBAAmB,GACnB,oCAAoC,GACpC,aAAa,GACb,aAAa,GACb,wBAAwB,GACxB,6BAA6B,GAC7B,UAAU,GACV,UAAU,GACV,oBAAoB,GACpB,oBAAoB,GACpB,UAAU,GACV,YAAY,GACZ,eAAe,GACf,wBAAwB,GACxB,wBAAwB,GACxB,oBAAoB,GACpB,qBAAqB,GACrB,oBAAoB,GACpB,aAAa,GACb,wBAAwB,GACxB,QAAQ,GACR,mBAAmB,GACnB,wBAAwB,GACxB,aAAa,GACb,mBAAmB,GACnB,mBAAmB,GACnB,uBAAuB,GACvB,YAAY,GACZ,oBAAoB,GACpB,SAAS,GACT,oCAAoC,GACpC,iCAAiC,GACjC,sBAAsB,GACt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AC;AAEF;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG;IAC1B,KAAK,EAAE,GAAG,CAAC;IACX,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAGF,MAAM,MAAM,4BAA4B,GAAG;IACzC,IAAI,EAAE,QAAQ,GAAG,MAAM,GAAG,WAAW,CAAC;IACtC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,IAAI,CAAC;CAClB,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,GACtB,UAAU,SAAS,KAClB,OAAO,CAAC,aAAa,GAAG,SAAS,CA2GnC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"askDocQuestion.d.ts","sourceRoot":"","sources":["../../../../../src/utils/AI/askDocQuestion/askDocQuestion.ts"],"names":[],"mappings":"AASA,OAAO,EAEL,4BAA4B,EAE7B,MAAM,UAAU,CAAC;AAGlB,KAAK,aAAa,GAAG;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB,CAAC;
|
|
1
|
+
{"version":3,"file":"askDocQuestion.d.ts","sourceRoot":"","sources":["../../../../../src/utils/AI/askDocQuestion/askDocQuestion.ts"],"names":[],"mappings":"AASA,OAAO,EAEL,4BAA4B,EAE7B,MAAM,UAAU,CAAC;AAGlB,KAAK,aAAa,GAAG;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB,CAAC;AAuGF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,QAAa,OAAO,CAAC,IAAI,CAuEvD,CAAC;AAKF;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB,GAC/B,OAAO,MAAM,EACb,aAAY,MAA+B,EAC3C,gBAAe,MAAuC,KACrD,OAAO,CAAC,aAAa,EAAE,CAsBzB,CAAC;AAmBF,eAAO,MAAM,UAAU,EAAE,4BAGxB,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,EAAE,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAClC,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,cAAc,GACzB,UAAU,4BAA4B,EAAE,EACxC,UAAU,qBAAqB,KAC9B,OAAO,CAAC,oBAAoB,CAoE9B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/utils/AI/autocomplete/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,SAAS,EAA2B,MAAM,UAAU,CAAC;AAS9D,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,cAAc,EAAE,MAAM,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAKF;;;;GAIG;AACH,eAAO,MAAM,YAAY,GAAU,sBAGhC,mBAAmB,KAAG,OAAO,CAAC,0BAA0B,GAAG,SAAS,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/utils/AI/autocomplete/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,SAAS,EAA2B,MAAM,UAAU,CAAC;AAS9D,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,cAAc,EAAE,MAAM,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAKF;;;;GAIG;AACH,eAAO,MAAM,YAAY,GAAU,sBAGhC,mBAAmB,KAAG,OAAO,CAAC,0BAA0B,GAAG,SAAS,CAyCtE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intlayer/backend",
|
|
3
|
-
"version": "5.5.
|
|
3
|
+
"version": "5.5.9",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Intlayer Backend is a an application that allow you to manage your Intlayer content and interact with the intlayer editor.",
|
|
6
6
|
"keywords": [
|
|
@@ -65,21 +65,21 @@
|
|
|
65
65
|
"csrf": "^3.1.0",
|
|
66
66
|
"csrf-csrf": "^3.1.0",
|
|
67
67
|
"dotenv": "^16.4.7",
|
|
68
|
-
"express": "^5.0
|
|
68
|
+
"express": "^5.1.0",
|
|
69
69
|
"helmet": "^8.1.0",
|
|
70
70
|
"jsonwebtoken": "^9.0.2",
|
|
71
71
|
"mongodb": "^6.15.0",
|
|
72
72
|
"mongoose": "^8.12.1",
|
|
73
73
|
"oauth2-server": "^3.1.1",
|
|
74
74
|
"openai": "^4.89.0",
|
|
75
|
-
"react": "^19.
|
|
75
|
+
"react": "^19.1.0",
|
|
76
76
|
"react-email": "^3.0.7",
|
|
77
77
|
"resend": "^4.1.2",
|
|
78
78
|
"stripe": "^17.7.0",
|
|
79
79
|
"uuid": "^11.1.0",
|
|
80
80
|
"validator": "^13.12.0",
|
|
81
81
|
"winston": "^3.17.0",
|
|
82
|
-
"express-intlayer": "5.5.
|
|
82
|
+
"express-intlayer": "5.5.9"
|
|
83
83
|
},
|
|
84
84
|
"devDependencies": {
|
|
85
85
|
"@types/body-parser": "^1.19.5",
|
|
@@ -88,30 +88,30 @@
|
|
|
88
88
|
"@types/cors": "^2.8.17",
|
|
89
89
|
"@types/crypto-js": "^4.2.2",
|
|
90
90
|
"@types/csurf": "^1.11.5",
|
|
91
|
-
"@types/express": "^5.0.
|
|
91
|
+
"@types/express": "^5.0.2",
|
|
92
92
|
"@types/jsonwebtoken": "^9.0.9",
|
|
93
|
-
"@types/node": "^22.
|
|
93
|
+
"@types/node": "^22.15.30",
|
|
94
94
|
"@types/oauth2-server": "^3.0.18",
|
|
95
|
-
"@types/react": "^19.
|
|
95
|
+
"@types/react": "^19.1.6",
|
|
96
96
|
"@types/uuid": "^10.0.0",
|
|
97
97
|
"@types/validator": "^13.12.2",
|
|
98
98
|
"esbuild-fix-imports-plugin": "^1.0.21",
|
|
99
|
-
"eslint": "^9.
|
|
99
|
+
"eslint": "^9.28.0",
|
|
100
100
|
"prettier": "^3.5.0",
|
|
101
101
|
"rimraf": "^6.0.1",
|
|
102
|
-
"tsc-alias": "^1.8.
|
|
103
|
-
"tsup": "^8.
|
|
104
|
-
"tsx": "^4.19.
|
|
105
|
-
"typescript": "^5.8.
|
|
106
|
-
"@intlayer/
|
|
107
|
-
"@intlayer/config": "5.5.
|
|
108
|
-
"@
|
|
102
|
+
"tsc-alias": "^1.8.16",
|
|
103
|
+
"tsup": "^8.5.0",
|
|
104
|
+
"tsx": "^4.19.4",
|
|
105
|
+
"typescript": "^5.8.3",
|
|
106
|
+
"@intlayer/blog": "^5.5.9",
|
|
107
|
+
"@intlayer/config": "5.5.9",
|
|
108
|
+
"@intlayer/core": "5.5.9",
|
|
109
|
+
"@intlayer/docs": "5.5.9",
|
|
109
110
|
"@utils/eslint-config": "1.0.4",
|
|
110
|
-
"@utils/ts-config
|
|
111
|
+
"@utils/ts-config": "1.0.4",
|
|
111
112
|
"@utils/tsup-config": "1.0.4",
|
|
112
|
-
"
|
|
113
|
-
"@
|
|
114
|
-
"intlayer": "5.5.7"
|
|
113
|
+
"intlayer": "5.5.9",
|
|
114
|
+
"@utils/ts-config-types": "1.0.4"
|
|
115
115
|
},
|
|
116
116
|
"scripts": {
|
|
117
117
|
"build": "pnpm build:package & pnpm build:types",
|