@purpleschool/gptbot 0.13.4 → 0.13.6
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/http/agents/agent-ai-model.ts +6 -0
- package/api/controllers/http/agents/agent-channel.ts +10 -0
- package/api/controllers/http/agents/agent-dialog.ts +9 -0
- package/api/controllers/http/agents/agent-document.ts +8 -0
- package/api/controllers/http/agents/agent-lead-form.ts +7 -0
- package/api/controllers/http/agents/agent-lead.ts +8 -0
- package/api/controllers/http/agents/agent-template.ts +11 -0
- package/api/controllers/http/agents/agent-tool.ts +8 -0
- package/api/controllers/http/agents/agent.ts +17 -0
- package/api/controllers/http/agents/index.ts +9 -0
- package/api/controllers/http/index.ts +2 -0
- package/api/controllers/http/support-feedback.ts +7 -0
- package/api/routes.ts +97 -0
- package/build/api/controllers/http/agents/agent-ai-model.js +8 -0
- package/build/api/controllers/http/agents/agent-channel.js +12 -0
- package/build/api/controllers/http/agents/agent-dialog.js +11 -0
- package/build/api/controllers/http/agents/agent-document.js +10 -0
- package/build/api/controllers/http/agents/agent-lead-form.js +9 -0
- package/build/api/controllers/http/agents/agent-lead.js +10 -0
- package/build/api/controllers/http/agents/agent-template.js +13 -0
- package/build/api/controllers/http/agents/agent-tool.js +10 -0
- package/build/api/controllers/http/agents/agent.js +17 -0
- package/build/api/controllers/http/agents/index.js +25 -0
- package/build/api/controllers/http/index.js +2 -0
- package/build/api/controllers/http/support-feedback.js +9 -0
- package/build/api/routes.js +68 -0
- package/build/commands/agents/agent-ai-model/find-agent-ai-models.command.js +11 -0
- package/build/commands/agents/agent-ai-model/get-agent-ai-model-by-id.command.js +14 -0
- package/build/commands/agents/agent-ai-model/index.js +18 -0
- package/build/commands/agents/agent-channel/create-agent-channel.command.js +20 -0
- package/build/commands/agents/agent-channel/delete-agent-channel.command.js +14 -0
- package/build/commands/agents/agent-channel/find-agent-channels-catalog.command.js +11 -0
- package/build/commands/agents/agent-channel/find-agent-channels.command.js +14 -0
- package/build/commands/agents/agent-channel/index.js +21 -0
- package/build/commands/agents/agent-channel/update-agent-channel.command.js +31 -0
- package/build/commands/agents/agent-dialog/clear-agent-dialog-history.command.js +14 -0
- package/build/commands/agents/agent-dialog/find-agent-dialogs.command.js +21 -0
- package/build/commands/agents/agent-dialog/get-agent-dialog-by-id.command.js +15 -0
- package/build/commands/agents/agent-dialog/index.js +23 -0
- package/build/commands/agents/agent-dialog/send-agent-dialog-admin-reply.command.js +22 -0
- package/build/commands/agents/agent-dialog/send-cabinet-message.command.js +28 -0
- package/build/commands/agents/agent-dialog/start-cabinet-dialog.command.js +18 -0
- package/build/commands/agents/agent-dialog/update-agent-dialog-status.command.js +19 -0
- package/build/commands/agents/agent-document/delete-agent-document.command.js +14 -0
- package/build/commands/agents/agent-document/find-agent-documents.command.js +18 -0
- package/build/commands/agents/agent-document/index.js +20 -0
- package/build/commands/agents/agent-document/search-agent-documents.command.js +19 -0
- package/build/commands/agents/agent-document/upload-agent-document.command.js +19 -0
- package/build/commands/agents/agent-lead/create-agent-lead.command.js +16 -0
- package/build/commands/agents/agent-lead/delete-agent-lead.command.js +13 -0
- package/build/commands/agents/agent-lead/find-agent-leads.command.js +16 -0
- package/build/commands/agents/agent-lead/get-agent-lead-by-id.command.js +14 -0
- package/build/commands/agents/agent-lead/index.js +21 -0
- package/build/commands/agents/agent-lead/update-agent-lead.command.js +19 -0
- package/build/commands/agents/agent-lead-form/delete-agent-lead-form.command.js +14 -0
- package/build/commands/agents/agent-lead-form/find-agent-lead-forms.command.js +16 -0
- package/build/commands/agents/agent-lead-form/get-agent-lead-form-by-agent.command.js +14 -0
- package/build/commands/agents/agent-lead-form/get-agent-lead-form-by-id.command.js +14 -0
- package/build/commands/agents/agent-lead-form/index.js +21 -0
- package/build/commands/agents/agent-lead-form/upsert-agent-lead-form.command.js +19 -0
- package/build/commands/agents/agent-template/create-agent-template-category.command.js +17 -0
- package/build/commands/agents/agent-template/create-agent-template-instruction.command.js +20 -0
- package/build/commands/agents/agent-template/create-agent-template.command.js +21 -0
- package/build/commands/agents/agent-template/delete-agent-template-category.command.js +13 -0
- package/build/commands/agents/agent-template/delete-agent-template-instruction.command.js +14 -0
- package/build/commands/agents/agent-template/delete-agent-template.command.js +13 -0
- package/build/commands/agents/agent-template/find-agent-template-catalog.command.js +11 -0
- package/build/commands/agents/agent-template/find-agent-template-categories.command.js +19 -0
- package/build/commands/agents/agent-template/find-agent-template-instructions.command.js +20 -0
- package/build/commands/agents/agent-template/find-agent-templates.command.js +19 -0
- package/build/commands/agents/agent-template/index.js +29 -0
- package/build/commands/agents/agent-template/update-agent-template-category.command.js +21 -0
- package/build/commands/agents/agent-template/update-agent-template-instruction.command.js +22 -0
- package/build/commands/agents/agent-template/update-agent-template.command.js +25 -0
- package/build/commands/agents/agent-tool/connect-agent-tool.command.js +20 -0
- package/build/commands/agents/agent-tool/disconnect-agent-tool.command.js +14 -0
- package/build/commands/agents/agent-tool/find-agent-tools-catalog.command.js +15 -0
- package/build/commands/agents/agent-tool/find-agent-tools.command.js +14 -0
- package/build/commands/agents/agent-tool/index.js +21 -0
- package/build/commands/agents/agent-tool/update-agent-tool.command.js +21 -0
- package/build/commands/agents/agents/create-agent.command.js +24 -0
- package/build/commands/agents/agents/delete-agent.command.js +13 -0
- package/build/commands/agents/agents/find-agents.command.js +18 -0
- package/build/commands/agents/agents/get-agent-by-id.command.js +14 -0
- package/build/commands/agents/agents/get-agent-public-info.command.js +19 -0
- package/build/commands/agents/agents/index.js +22 -0
- package/build/commands/agents/agents/update-agent.command.js +30 -0
- package/build/commands/agents/index.js +25 -0
- package/build/commands/index.js +2 -0
- package/build/commands/support-feedback/check-support-feedback.command.js +24 -0
- package/build/commands/support-feedback/index.js +18 -0
- package/build/commands/support-feedback/upsert-support-feedback.command.js +18 -0
- package/build/constants/agents/enums/agent-channel-status.enum.js +9 -0
- package/build/constants/agents/enums/agent-channel-type.enum.js +9 -0
- package/build/constants/agents/enums/agent-document-status.enum.js +9 -0
- package/build/constants/agents/enums/agent-interaction-mode.enum.js +8 -0
- package/build/constants/agents/enums/agent-status.enum.js +9 -0
- package/build/constants/agents/enums/agent-tool-status.enum.js +9 -0
- package/build/constants/agents/enums/agent-tool-type.enum.js +9 -0
- package/build/constants/agents/enums/dialog-status.enum.js +11 -0
- package/build/constants/agents/enums/index.js +24 -0
- package/build/constants/agents/index.js +17 -0
- package/build/constants/index.js +1 -0
- package/build/models/agents/agent-ai-model.schema.js +14 -0
- package/build/models/agents/agent-channel-credentials.schema.js +23 -0
- package/build/models/agents/agent-channel.schema.js +17 -0
- package/build/models/agents/agent-dialog-lead.schema.js +13 -0
- package/build/models/agents/agent-dialog-message.schema.js +13 -0
- package/build/models/agents/agent-document-chunk.schema.js +15 -0
- package/build/models/agents/agent-document-find-result.schema.js +11 -0
- package/build/models/agents/agent-document-search-result.schema.js +13 -0
- package/build/models/agents/agent-document.schema.js +18 -0
- package/build/models/agents/agent-lead-find-result.schema.js +11 -0
- package/build/models/agents/agent-lead-form-field.schema.js +10 -0
- package/build/models/agents/agent-lead-form.schema.js +14 -0
- package/build/models/agents/agent-lead.schema.js +13 -0
- package/build/models/agents/agent-template-catalog.schema.js +16 -0
- package/build/models/agents/agent-template-category.schema.js +14 -0
- package/build/models/agents/agent-template-instruction.schema.js +15 -0
- package/build/models/agents/agent-template.schema.js +18 -0
- package/build/models/agents/agent-tool-catalog.schema.js +16 -0
- package/build/models/agents/agent-tool-credentials.schema.js +24 -0
- package/build/models/agents/agent-tool.schema.js +15 -0
- package/build/models/agents/agent.schema.js +25 -0
- package/build/models/agents/channel.schema.js +15 -0
- package/build/models/agents/dialog-find-result.schema.js +9 -0
- package/build/models/agents/dialog-with-messages.schema.js +9 -0
- package/build/models/agents/dialog.schema.js +32 -0
- package/build/models/agents/index.js +41 -0
- package/build/models/index.js +2 -0
- package/build/models/support-feedback.schema.js +14 -0
- package/commands/agents/agent-ai-model/find-agent-ai-models.command.ts +9 -0
- package/commands/agents/agent-ai-model/get-agent-ai-model-by-id.command.ts +14 -0
- package/commands/agents/agent-ai-model/index.ts +2 -0
- package/commands/agents/agent-channel/create-agent-channel.command.ts +22 -0
- package/commands/agents/agent-channel/delete-agent-channel.command.ts +14 -0
- package/commands/agents/agent-channel/find-agent-channels-catalog.command.ts +9 -0
- package/commands/agents/agent-channel/find-agent-channels.command.ts +14 -0
- package/commands/agents/agent-channel/index.ts +5 -0
- package/commands/agents/agent-channel/update-agent-channel.command.ts +36 -0
- package/commands/agents/agent-dialog/clear-agent-dialog-history.command.ts +16 -0
- package/commands/agents/agent-dialog/find-agent-dialogs.command.ts +21 -0
- package/commands/agents/agent-dialog/get-agent-dialog-by-id.command.ts +17 -0
- package/commands/agents/agent-dialog/index.ts +7 -0
- package/commands/agents/agent-dialog/send-agent-dialog-admin-reply.command.ts +26 -0
- package/commands/agents/agent-dialog/send-cabinet-message.command.ts +34 -0
- package/commands/agents/agent-dialog/start-cabinet-dialog.command.ts +20 -0
- package/commands/agents/agent-dialog/update-agent-dialog-status.command.ts +23 -0
- package/commands/agents/agent-document/delete-agent-document.command.ts +14 -0
- package/commands/agents/agent-document/find-agent-documents.command.ts +20 -0
- package/commands/agents/agent-document/index.ts +4 -0
- package/commands/agents/agent-document/search-agent-documents.command.ts +21 -0
- package/commands/agents/agent-document/upload-agent-document.command.ts +21 -0
- package/commands/agents/agent-lead/create-agent-lead.command.ts +16 -0
- package/commands/agents/agent-lead/delete-agent-lead.command.ts +13 -0
- package/commands/agents/agent-lead/find-agent-leads.command.ts +16 -0
- package/commands/agents/agent-lead/get-agent-lead-by-id.command.ts +14 -0
- package/commands/agents/agent-lead/index.ts +5 -0
- package/commands/agents/agent-lead/update-agent-lead.command.ts +21 -0
- package/commands/agents/agent-lead-form/delete-agent-lead-form.command.ts +14 -0
- package/commands/agents/agent-lead-form/find-agent-lead-forms.command.ts +16 -0
- package/commands/agents/agent-lead-form/get-agent-lead-form-by-agent.command.ts +14 -0
- package/commands/agents/agent-lead-form/get-agent-lead-form-by-id.command.ts +14 -0
- package/commands/agents/agent-lead-form/index.ts +5 -0
- package/commands/agents/agent-lead-form/upsert-agent-lead-form.command.ts +21 -0
- package/commands/agents/agent-template/create-agent-template-category.command.ts +17 -0
- package/commands/agents/agent-template/create-agent-template-instruction.command.ts +22 -0
- package/commands/agents/agent-template/create-agent-template.command.ts +21 -0
- package/commands/agents/agent-template/delete-agent-template-category.command.ts +13 -0
- package/commands/agents/agent-template/delete-agent-template-instruction.command.ts +14 -0
- package/commands/agents/agent-template/delete-agent-template.command.ts +13 -0
- package/commands/agents/agent-template/find-agent-template-catalog.command.ts +9 -0
- package/commands/agents/agent-template/find-agent-template-categories.command.ts +19 -0
- package/commands/agents/agent-template/find-agent-template-instructions.command.ts +22 -0
- package/commands/agents/agent-template/find-agent-templates.command.ts +19 -0
- package/commands/agents/agent-template/index.ts +13 -0
- package/commands/agents/agent-template/update-agent-template-category.command.ts +23 -0
- package/commands/agents/agent-template/update-agent-template-instruction.command.ts +24 -0
- package/commands/agents/agent-template/update-agent-template.command.ts +27 -0
- package/commands/agents/agent-tool/connect-agent-tool.command.ts +22 -0
- package/commands/agents/agent-tool/disconnect-agent-tool.command.ts +14 -0
- package/commands/agents/agent-tool/find-agent-tools-catalog.command.ts +15 -0
- package/commands/agents/agent-tool/find-agent-tools.command.ts +14 -0
- package/commands/agents/agent-tool/index.ts +5 -0
- package/commands/agents/agent-tool/update-agent-tool.command.ts +23 -0
- package/commands/agents/agents/create-agent.command.ts +24 -0
- package/commands/agents/agents/delete-agent.command.ts +13 -0
- package/commands/agents/agents/find-agents.command.ts +18 -0
- package/commands/agents/agents/get-agent-by-id.command.ts +14 -0
- package/commands/agents/agents/get-agent-public-info.command.ts +22 -0
- package/commands/agents/agents/index.ts +6 -0
- package/commands/agents/agents/update-agent.command.ts +32 -0
- package/commands/agents/index.ts +9 -0
- package/commands/index.ts +2 -0
- package/commands/support-feedback/check-support-feedback.command.ts +26 -0
- package/commands/support-feedback/index.ts +2 -0
- package/commands/support-feedback/upsert-support-feedback.command.ts +20 -0
- package/constants/agents/enums/agent-channel-status.enum.ts +5 -0
- package/constants/agents/enums/agent-channel-type.enum.ts +5 -0
- package/constants/agents/enums/agent-document-status.enum.ts +5 -0
- package/constants/agents/enums/agent-interaction-mode.enum.ts +4 -0
- package/constants/agents/enums/agent-status.enum.ts +5 -0
- package/constants/agents/enums/agent-tool-status.enum.ts +5 -0
- package/constants/agents/enums/agent-tool-type.enum.ts +5 -0
- package/constants/agents/enums/dialog-status.enum.ts +7 -0
- package/constants/agents/enums/index.ts +8 -0
- package/constants/agents/index.ts +1 -0
- package/constants/index.ts +1 -0
- package/models/agents/agent-ai-model.schema.ts +14 -0
- package/models/agents/agent-channel-credentials.schema.ts +32 -0
- package/models/agents/agent-channel.schema.ts +17 -0
- package/models/agents/agent-dialog-lead.schema.ts +13 -0
- package/models/agents/agent-dialog-message.schema.ts +13 -0
- package/models/agents/agent-document-chunk.schema.ts +15 -0
- package/models/agents/agent-document-find-result.schema.ts +11 -0
- package/models/agents/agent-document-search-result.schema.ts +16 -0
- package/models/agents/agent-document.schema.ts +18 -0
- package/models/agents/agent-lead-find-result.schema.ts +11 -0
- package/models/agents/agent-lead-form-field.schema.ts +10 -0
- package/models/agents/agent-lead-form.schema.ts +14 -0
- package/models/agents/agent-lead.schema.ts +13 -0
- package/models/agents/agent-template-catalog.schema.ts +22 -0
- package/models/agents/agent-template-category.schema.ts +14 -0
- package/models/agents/agent-template-instruction.schema.ts +15 -0
- package/models/agents/agent-template.schema.ts +18 -0
- package/models/agents/agent-tool-catalog.schema.ts +16 -0
- package/models/agents/agent-tool-credentials.schema.ts +33 -0
- package/models/agents/agent-tool.schema.ts +15 -0
- package/models/agents/agent.schema.ts +25 -0
- package/models/agents/channel.schema.ts +15 -0
- package/models/agents/dialog-find-result.schema.ts +9 -0
- package/models/agents/dialog-with-messages.schema.ts +9 -0
- package/models/agents/dialog.schema.ts +32 -0
- package/models/agents/index.ts +25 -0
- package/models/index.ts +2 -0
- package/models/support-feedback.schema.ts +12 -0
- package/package.json +1 -1
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentChannelCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
agentId: z.string().uuid(),
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
success: z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { ChannelSchema } from '../../../models/agents/channel.schema';
|
|
3
|
+
|
|
4
|
+
export namespace FindAgentChannelsCatalogCommand {
|
|
5
|
+
export const ResponseSchema = z.object({
|
|
6
|
+
data: z.array(ChannelSchema),
|
|
7
|
+
});
|
|
8
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentChannelSchema } from '../../../models/agents/agent-channel.schema';
|
|
3
|
+
|
|
4
|
+
export namespace FindAgentChannelsCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
agentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
data: z.array(AgentChannelSchema),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AGENT_CHANNEL_STATUS } from '../../../constants/agents/enums';
|
|
3
|
+
import { AgentChannelCredentialsSchema } from '../../../models/agents/agent-channel-credentials.schema';
|
|
4
|
+
import { AgentChannelSchema } from '../../../models/agents/agent-channel.schema';
|
|
5
|
+
|
|
6
|
+
export namespace UpdateAgentChannelCommand {
|
|
7
|
+
export const RequestParamsSchema = z.object({
|
|
8
|
+
agentId: z.string().uuid(),
|
|
9
|
+
id: z.string().uuid(),
|
|
10
|
+
});
|
|
11
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
12
|
+
|
|
13
|
+
export const RequestBodySchema = z.object({
|
|
14
|
+
credentials: AgentChannelCredentialsSchema.optional(),
|
|
15
|
+
status: z.nativeEnum(AGENT_CHANNEL_STATUS).optional(),
|
|
16
|
+
});
|
|
17
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
18
|
+
|
|
19
|
+
export const ResponseSchema = z.object({
|
|
20
|
+
data: AgentChannelSchema,
|
|
21
|
+
});
|
|
22
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export namespace ValidateAgentChannelCommand {
|
|
26
|
+
export const RequestParamsSchema = z.object({
|
|
27
|
+
agentId: z.string().uuid(),
|
|
28
|
+
id: z.string().uuid(),
|
|
29
|
+
});
|
|
30
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
31
|
+
|
|
32
|
+
export const ResponseSchema = z.object({
|
|
33
|
+
data: AgentChannelSchema,
|
|
34
|
+
});
|
|
35
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
36
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace ClearAgentDialogHistoryCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
dialogId: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const RequestQuerySchema = z.object({});
|
|
10
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
11
|
+
|
|
12
|
+
export const ResponseSchema = z.object({
|
|
13
|
+
success: z.boolean(),
|
|
14
|
+
});
|
|
15
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { DIALOG_STATUS } from '../../../constants/agents/enums';
|
|
3
|
+
import { DialogFindResultSchema } from '../../../models/agents/dialog-find-result.schema';
|
|
4
|
+
|
|
5
|
+
export namespace FindAgentDialogsCommand {
|
|
6
|
+
export const RequestQuerySchema = z.object({
|
|
7
|
+
agentId: z.string().uuid().optional(),
|
|
8
|
+
status: z.nativeEnum(DIALOG_STATUS).optional(),
|
|
9
|
+
source: z.string().optional(),
|
|
10
|
+
dateFrom: z.coerce.date().optional(),
|
|
11
|
+
dateTo: z.coerce.date().optional(),
|
|
12
|
+
limit: z.coerce.number().optional(),
|
|
13
|
+
offset: z.coerce.number().optional(),
|
|
14
|
+
});
|
|
15
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: DialogFindResultSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { DialogWithMessagesSchema } from '../../../models/agents/dialog-with-messages.schema';
|
|
3
|
+
|
|
4
|
+
export namespace GetAgentDialogByIdCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestQuerySchema = z.object({});
|
|
11
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
12
|
+
|
|
13
|
+
export const ResponseSchema = z.object({
|
|
14
|
+
data: DialogWithMessagesSchema,
|
|
15
|
+
});
|
|
16
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
17
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './find-agent-dialogs.command';
|
|
2
|
+
export * from './get-agent-dialog-by-id.command';
|
|
3
|
+
export * from './update-agent-dialog-status.command';
|
|
4
|
+
export * from './clear-agent-dialog-history.command';
|
|
5
|
+
export * from './send-agent-dialog-admin-reply.command';
|
|
6
|
+
export * from './start-cabinet-dialog.command';
|
|
7
|
+
export * from './send-cabinet-message.command';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace SendAgentDialogAdminReplyCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
dialogId: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const RequestQuerySchema = z.object({});
|
|
10
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
11
|
+
|
|
12
|
+
export const RequestBodySchema = z.object({
|
|
13
|
+
text: z.string().optional(),
|
|
14
|
+
images: z.array(z.string()).default([]),
|
|
15
|
+
attachments: z.array(z.string()).optional(),
|
|
16
|
+
});
|
|
17
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
18
|
+
|
|
19
|
+
export const ResponseSchema = z.object({
|
|
20
|
+
data: z.object({
|
|
21
|
+
messageId: z.string().uuid(),
|
|
22
|
+
dialogId: z.string().uuid(),
|
|
23
|
+
}),
|
|
24
|
+
});
|
|
25
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
26
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace SendCabinetMessageCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
agentId: z.string().uuid(),
|
|
6
|
+
dialogId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestBodySchema = z
|
|
11
|
+
.object({
|
|
12
|
+
text: z.string().optional(),
|
|
13
|
+
images: z.array(z.string()).optional(),
|
|
14
|
+
attachments: z.array(z.string()).optional(),
|
|
15
|
+
})
|
|
16
|
+
.refine(
|
|
17
|
+
(data) =>
|
|
18
|
+
data.text || (data.images?.length ?? 0) > 0 || (data.attachments?.length ?? 0) > 0,
|
|
19
|
+
{
|
|
20
|
+
message: 'Message must contain text, images, or attachments',
|
|
21
|
+
path: ['text'],
|
|
22
|
+
},
|
|
23
|
+
);
|
|
24
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
25
|
+
|
|
26
|
+
export const ResponseSchema = z.object({
|
|
27
|
+
data: z.object({
|
|
28
|
+
dialogId: z.string().uuid(),
|
|
29
|
+
messageId: z.string().uuid(),
|
|
30
|
+
isNewDialog: z.boolean(),
|
|
31
|
+
}),
|
|
32
|
+
});
|
|
33
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
34
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace StartCabinetDialogCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
agentId: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const RequestBodySchema = z.object({
|
|
10
|
+
userMeta: z.record(z.string(), z.unknown()).optional(),
|
|
11
|
+
});
|
|
12
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
13
|
+
|
|
14
|
+
export const ResponseSchema = z.object({
|
|
15
|
+
data: z.object({
|
|
16
|
+
dialogId: z.string().uuid(),
|
|
17
|
+
}),
|
|
18
|
+
});
|
|
19
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { DIALOG_STATUS } from '../../../constants/agents/enums';
|
|
3
|
+
import { DialogSchema } from '../../../models/agents/dialog.schema';
|
|
4
|
+
|
|
5
|
+
export namespace UpdateAgentDialogStatusCommand {
|
|
6
|
+
export const RequestParamsSchema = z.object({
|
|
7
|
+
dialogId: z.string().uuid(),
|
|
8
|
+
});
|
|
9
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
10
|
+
|
|
11
|
+
export const RequestQuerySchema = z.object({});
|
|
12
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
13
|
+
|
|
14
|
+
export const RequestBodySchema = z.object({
|
|
15
|
+
status: z.nativeEnum(DIALOG_STATUS),
|
|
16
|
+
});
|
|
17
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
18
|
+
|
|
19
|
+
export const ResponseSchema = z.object({
|
|
20
|
+
data: DialogSchema,
|
|
21
|
+
});
|
|
22
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
23
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentDocumentCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
agentId: z.string().uuid(),
|
|
6
|
+
documentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
success: z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentDocumentFindResultSchema } from '../../../models/agents/agent-document-find-result.schema';
|
|
3
|
+
|
|
4
|
+
export namespace FindAgentDocumentsCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
agentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestQuerySchema = z.object({
|
|
11
|
+
limit: z.coerce.number().optional(),
|
|
12
|
+
offset: z.coerce.number().optional(),
|
|
13
|
+
});
|
|
14
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
15
|
+
|
|
16
|
+
export const ResponseSchema = z.object({
|
|
17
|
+
data: AgentDocumentFindResultSchema,
|
|
18
|
+
});
|
|
19
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentDocumentSearchResultSchema } from '../../../models/agents/agent-document-search-result.schema';
|
|
3
|
+
|
|
4
|
+
export namespace SearchAgentDocumentsCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
agentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestBodySchema = z.object({
|
|
11
|
+
query: z.string().min(1),
|
|
12
|
+
limit: z.coerce.number().optional(),
|
|
13
|
+
threshold: z.coerce.number().optional(),
|
|
14
|
+
});
|
|
15
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: AgentDocumentSearchResultSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AGENT_DOCUMENT_STATUS } from '../../../constants/agents/enums';
|
|
3
|
+
|
|
4
|
+
export namespace UploadAgentDocumentCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
agentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseDataSchema = z.object({
|
|
11
|
+
documentId: z.string().uuid(),
|
|
12
|
+
filename: z.string(),
|
|
13
|
+
status: z.nativeEnum(AGENT_DOCUMENT_STATUS),
|
|
14
|
+
});
|
|
15
|
+
export type ResponseData = z.infer<typeof ResponseDataSchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: ResponseDataSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadSchema } from '../../../models/agents/agent-lead.schema';
|
|
3
|
+
|
|
4
|
+
export namespace CreateAgentLeadCommand {
|
|
5
|
+
export const RequestBodySchema = z.object({
|
|
6
|
+
data: z.record(z.string(), z.string()),
|
|
7
|
+
dialogId: z.string().uuid(),
|
|
8
|
+
leadFormId: z.string().uuid(),
|
|
9
|
+
});
|
|
10
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
11
|
+
|
|
12
|
+
export const ResponseSchema = z.object({
|
|
13
|
+
data: AgentLeadSchema,
|
|
14
|
+
});
|
|
15
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentLeadCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
id: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const ResponseSchema = z.object({
|
|
10
|
+
success: z.boolean(),
|
|
11
|
+
});
|
|
12
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadFindResultSchema } from '../../../models/agents/agent-lead-find-result.schema';
|
|
3
|
+
|
|
4
|
+
export namespace FindAgentLeadsCommand {
|
|
5
|
+
export const RequestQuerySchema = z.object({
|
|
6
|
+
dialogId: z.string().uuid().optional(),
|
|
7
|
+
limit: z.coerce.number().optional(),
|
|
8
|
+
offset: z.coerce.number().optional(),
|
|
9
|
+
});
|
|
10
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
11
|
+
|
|
12
|
+
export const ResponseSchema = z.object({
|
|
13
|
+
data: AgentLeadFindResultSchema,
|
|
14
|
+
});
|
|
15
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadSchema } from '../../../models/agents/agent-lead.schema';
|
|
3
|
+
|
|
4
|
+
export namespace GetAgentLeadByIdCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
data: AgentLeadSchema,
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadSchema } from '../../../models/agents/agent-lead.schema';
|
|
3
|
+
|
|
4
|
+
export namespace UpdateAgentLeadCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestBodySchema = z.object({
|
|
11
|
+
data: z.record(z.string(), z.string()),
|
|
12
|
+
dialogId: z.string().uuid(),
|
|
13
|
+
leadFormId: z.string().uuid(),
|
|
14
|
+
});
|
|
15
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: AgentLeadSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentLeadFormCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
agentId: z.string().uuid(),
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
success: z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadFormSchema } from '../../../models/agents/agent-lead-form.schema';
|
|
3
|
+
|
|
4
|
+
export namespace FindAgentLeadFormsCommand {
|
|
5
|
+
export const RequestQuerySchema = z.object({
|
|
6
|
+
agentId: z.string().uuid().optional(),
|
|
7
|
+
limit: z.coerce.number().optional(),
|
|
8
|
+
offset: z.coerce.number().optional(),
|
|
9
|
+
});
|
|
10
|
+
export type RequestQuery = z.infer<typeof RequestQuerySchema>;
|
|
11
|
+
|
|
12
|
+
export const ResponseSchema = z.object({
|
|
13
|
+
data: z.array(AgentLeadFormSchema),
|
|
14
|
+
});
|
|
15
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadFormSchema } from '../../../models/agents/agent-lead-form.schema';
|
|
3
|
+
|
|
4
|
+
export namespace GetAgentLeadFormByAgentCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
agentId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
data: AgentLeadFormSchema.nullable(),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadFormSchema } from '../../../models/agents/agent-lead-form.schema';
|
|
3
|
+
|
|
4
|
+
export namespace GetAgentLeadFormByIdCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
data: AgentLeadFormSchema,
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentLeadFormFieldSchema } from '../../../models/agents/agent-lead-form-field.schema';
|
|
3
|
+
import { AgentLeadFormSchema } from '../../../models/agents/agent-lead-form.schema';
|
|
4
|
+
|
|
5
|
+
export namespace UpsertAgentLeadFormCommand {
|
|
6
|
+
export const RequestParamsSchema = z.object({
|
|
7
|
+
agentId: z.string().uuid(),
|
|
8
|
+
});
|
|
9
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
10
|
+
|
|
11
|
+
export const RequestBodySchema = z.object({
|
|
12
|
+
fields: z.array(AgentLeadFormFieldSchema),
|
|
13
|
+
collectionTrigger: z.string().nullable(),
|
|
14
|
+
});
|
|
15
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: AgentLeadFormSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentTemplateCategorySchema } from '../../../models/agents/agent-template-category.schema';
|
|
3
|
+
|
|
4
|
+
export namespace CreateAgentTemplateCategoryCommand {
|
|
5
|
+
export const RequestBodySchema = z.object({
|
|
6
|
+
slug: z.string(),
|
|
7
|
+
name: z.string(),
|
|
8
|
+
description: z.string(),
|
|
9
|
+
order: z.number(),
|
|
10
|
+
});
|
|
11
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
12
|
+
|
|
13
|
+
export const ResponseSchema = z.object({
|
|
14
|
+
data: AgentTemplateCategorySchema,
|
|
15
|
+
});
|
|
16
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
17
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AgentTemplateInstructionSchema } from '../../../models/agents/agent-template-instruction.schema';
|
|
3
|
+
|
|
4
|
+
export namespace CreateAgentTemplateInstructionCommand {
|
|
5
|
+
export const RequestParamsSchema = z.object({
|
|
6
|
+
templateId: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const RequestBodySchema = z.object({
|
|
11
|
+
title: z.string(),
|
|
12
|
+
description: z.string(),
|
|
13
|
+
prompt: z.string(),
|
|
14
|
+
order: z.number().optional(),
|
|
15
|
+
});
|
|
16
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
17
|
+
|
|
18
|
+
export const ResponseSchema = z.object({
|
|
19
|
+
data: AgentTemplateInstructionSchema,
|
|
20
|
+
});
|
|
21
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
22
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AGENT_INTERACTION_MODE } from '../../../constants/agents/enums/agent-interaction-mode.enum';
|
|
3
|
+
import { AgentTemplateSchema } from '../../../models/agents/agent-template.schema';
|
|
4
|
+
|
|
5
|
+
export namespace CreateAgentTemplateCommand {
|
|
6
|
+
export const RequestBodySchema = z.object({
|
|
7
|
+
categoryId: z.string().uuid(),
|
|
8
|
+
name: z.string(),
|
|
9
|
+
description: z.string(),
|
|
10
|
+
iconUrl: z.string().nullable().optional(),
|
|
11
|
+
systemPrompt: z.string().nullable().optional(),
|
|
12
|
+
interactionMode: z.nativeEnum(AGENT_INTERACTION_MODE).optional(),
|
|
13
|
+
order: z.number().optional(),
|
|
14
|
+
});
|
|
15
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
16
|
+
|
|
17
|
+
export const ResponseSchema = z.object({
|
|
18
|
+
data: AgentTemplateSchema,
|
|
19
|
+
});
|
|
20
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
21
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentTemplateCategoryCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
id: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const ResponseSchema = z.object({
|
|
10
|
+
success: z.boolean(),
|
|
11
|
+
});
|
|
12
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentTemplateInstructionCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
templateId: z.string().uuid(),
|
|
6
|
+
id: z.string().uuid(),
|
|
7
|
+
});
|
|
8
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
9
|
+
|
|
10
|
+
export const ResponseSchema = z.object({
|
|
11
|
+
success: z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
export namespace DeleteAgentTemplateCommand {
|
|
4
|
+
export const RequestParamsSchema = z.object({
|
|
5
|
+
id: z.string().uuid(),
|
|
6
|
+
});
|
|
7
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
8
|
+
|
|
9
|
+
export const ResponseSchema = z.object({
|
|
10
|
+
success: z.boolean(),
|
|
11
|
+
});
|
|
12
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
13
|
+
}
|