@lyrra/mcp-server 1.1.3 → 1.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/README.md +80 -250
  2. package/dist/auth-session.js +171 -0
  3. package/dist/eduflow-block-docs.js +438 -0
  4. package/dist/http-incoming-auth.js +48 -0
  5. package/dist/http-main.js +104 -0
  6. package/dist/index.js +16 -12
  7. package/dist/lyrra-http.js +80 -0
  8. package/dist/lyrra-mcp-core.js +174 -0
  9. package/dist/openapi-parse.js +61 -0
  10. package/dist/register-eduflow-block-tools.js +31 -0
  11. package/package.json +41 -13
  12. package/Dockerfile +0 -16
  13. package/dist/client.d.ts +0 -23
  14. package/dist/client.d.ts.map +0 -1
  15. package/dist/client.js +0 -92
  16. package/dist/client.js.map +0 -1
  17. package/dist/config.d.ts +0 -8
  18. package/dist/config.d.ts.map +0 -1
  19. package/dist/config.js +0 -8
  20. package/dist/config.js.map +0 -1
  21. package/dist/http-server.d.ts +0 -8
  22. package/dist/http-server.d.ts.map +0 -1
  23. package/dist/http-server.js +0 -481
  24. package/dist/http-server.js.map +0 -1
  25. package/dist/index.d.ts +0 -3
  26. package/dist/index.d.ts.map +0 -1
  27. package/dist/index.js.map +0 -1
  28. package/dist/resources/block-types.d.ts +0 -318
  29. package/dist/resources/block-types.d.ts.map +0 -1
  30. package/dist/resources/block-types.js +0 -297
  31. package/dist/resources/block-types.js.map +0 -1
  32. package/dist/resources/flow-schema.d.ts +0 -147
  33. package/dist/resources/flow-schema.d.ts.map +0 -1
  34. package/dist/resources/flow-schema.js +0 -143
  35. package/dist/resources/flow-schema.js.map +0 -1
  36. package/dist/server-factory.d.ts +0 -8
  37. package/dist/server-factory.d.ts.map +0 -1
  38. package/dist/server-factory.js +0 -82
  39. package/dist/server-factory.js.map +0 -1
  40. package/dist/tools/admin.d.ts +0 -265
  41. package/dist/tools/admin.d.ts.map +0 -1
  42. package/dist/tools/admin.js +0 -118
  43. package/dist/tools/admin.js.map +0 -1
  44. package/dist/tools/ai-designer.d.ts +0 -297
  45. package/dist/tools/ai-designer.d.ts.map +0 -1
  46. package/dist/tools/ai-designer.js +0 -89
  47. package/dist/tools/ai-designer.js.map +0 -1
  48. package/dist/tools/analytics.d.ts +0 -95
  49. package/dist/tools/analytics.d.ts.map +0 -1
  50. package/dist/tools/analytics.js +0 -44
  51. package/dist/tools/analytics.js.map +0 -1
  52. package/dist/tools/auth.d.ts +0 -61
  53. package/dist/tools/auth.d.ts.map +0 -1
  54. package/dist/tools/auth.js +0 -36
  55. package/dist/tools/auth.js.map +0 -1
  56. package/dist/tools/blocks.d.ts +0 -457
  57. package/dist/tools/blocks.d.ts.map +0 -1
  58. package/dist/tools/blocks.js +0 -173
  59. package/dist/tools/blocks.js.map +0 -1
  60. package/dist/tools/connections.d.ts +0 -173
  61. package/dist/tools/connections.d.ts.map +0 -1
  62. package/dist/tools/connections.js +0 -81
  63. package/dist/tools/connections.js.map +0 -1
  64. package/dist/tools/eduflow.d.ts +0 -409
  65. package/dist/tools/eduflow.d.ts.map +0 -1
  66. package/dist/tools/eduflow.js +0 -139
  67. package/dist/tools/eduflow.js.map +0 -1
  68. package/dist/tools/participants.d.ts +0 -221
  69. package/dist/tools/participants.d.ts.map +0 -1
  70. package/dist/tools/participants.js +0 -70
  71. package/dist/tools/participants.js.map +0 -1
  72. package/dist/tools/presentation.d.ts +0 -233
  73. package/dist/tools/presentation.d.ts.map +0 -1
  74. package/dist/tools/presentation.js +0 -57
  75. package/dist/tools/presentation.js.map +0 -1
  76. package/dist/tools/projects.d.ts +0 -131
  77. package/dist/tools/projects.d.ts.map +0 -1
  78. package/dist/tools/projects.js +0 -55
  79. package/dist/tools/projects.js.map +0 -1
  80. package/dist/tools/resources.d.ts +0 -93
  81. package/dist/tools/resources.d.ts.map +0 -1
  82. package/dist/tools/resources.js +0 -37
  83. package/dist/tools/resources.js.map +0 -1
  84. package/dist/tools/store.d.ts +0 -125
  85. package/dist/tools/store.d.ts.map +0 -1
  86. package/dist/tools/store.js +0 -66
  87. package/dist/tools/store.js.map +0 -1
  88. package/mcp-config.example.json +0 -14
  89. package/src/client.ts +0 -106
  90. package/src/config.ts +0 -7
  91. package/src/http-server.ts +0 -591
  92. package/src/index.ts +0 -23
  93. package/src/resources/block-types.ts +0 -298
  94. package/src/resources/flow-schema.ts +0 -148
  95. package/src/server-factory.ts +0 -109
  96. package/src/tools/admin.ts +0 -128
  97. package/src/tools/ai-designer.ts +0 -97
  98. package/src/tools/analytics.ts +0 -49
  99. package/src/tools/auth.ts +0 -39
  100. package/src/tools/blocks.ts +0 -186
  101. package/src/tools/connections.ts +0 -83
  102. package/src/tools/eduflow.ts +0 -150
  103. package/src/tools/participants.ts +0 -77
  104. package/src/tools/presentation.ts +0 -61
  105. package/src/tools/projects.ts +0 -61
  106. package/src/tools/resources.ts +0 -41
  107. package/src/tools/store.ts +0 -67
  108. package/tsconfig.json +0 -19
@@ -1,61 +0,0 @@
1
- import { z } from 'zod';
2
- import { LyrraClient } from '../client.js';
3
- export declare function createAuthTools(c: LyrraClient): {
4
- auth_login: {
5
- description: string;
6
- inputSchema: z.ZodObject<{
7
- email: z.ZodString;
8
- password: z.ZodString;
9
- }, "strip", z.ZodTypeAny, {
10
- email: string;
11
- password: string;
12
- }, {
13
- email: string;
14
- password: string;
15
- }>;
16
- handler: ({ email, password }: {
17
- email: string;
18
- password: string;
19
- }) => Promise<any>;
20
- };
21
- auth_get_profile: {
22
- description: string;
23
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
24
- handler: () => Promise<any>;
25
- };
26
- auth_list_api_keys: {
27
- description: string;
28
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
29
- handler: () => Promise<any>;
30
- };
31
- };
32
- export declare const authTools: {
33
- auth_login: {
34
- description: string;
35
- inputSchema: z.ZodObject<{
36
- email: z.ZodString;
37
- password: z.ZodString;
38
- }, "strip", z.ZodTypeAny, {
39
- email: string;
40
- password: string;
41
- }, {
42
- email: string;
43
- password: string;
44
- }>;
45
- handler: ({ email, password }: {
46
- email: string;
47
- password: string;
48
- }) => Promise<any>;
49
- };
50
- auth_get_profile: {
51
- description: string;
52
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
53
- handler: () => Promise<any>;
54
- };
55
- auth_list_api_keys: {
56
- description: string;
57
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
58
- handler: () => Promise<any>;
59
- };
60
- };
61
- //# sourceMappingURL=auth.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/tools/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAG3C,wBAAgB,eAAe,CAAC,CAAC,EAAE,WAAW;;;;;;;;;;;;;uCAQH;YAAE,KAAK,EAAE,MAAM,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;EAuB7E;AAGD,eAAO,MAAM,SAAS;;;;;;;;;;;;;uCA1BqB;YAAE,KAAK,EAAE,MAAM,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;CA0BvB,CAAC"}
@@ -1,36 +0,0 @@
1
- import { z } from 'zod';
2
- import { client as defaultClient } from '../client.js';
3
- export function createAuthTools(c) {
4
- return {
5
- auth_login: {
6
- description: 'Se connecter à LYRRA Studio avec email et mot de passe. ⚠️ NE PAS utiliser si LYRRA_CLIENT_SECRET est configuré — l\'authentification est alors automatique via API Key. Utiliser uniquement si aucune clé API n\'est définie.',
7
- inputSchema: z.object({
8
- email: z.string().email().describe('Adresse email du compte'),
9
- password: z.string().describe('Mot de passe'),
10
- }),
11
- handler: async ({ email, password }) => {
12
- const result = await c.post('/auth/login', { email, password });
13
- if (result.token)
14
- c.setToken(result.token);
15
- return result;
16
- },
17
- },
18
- auth_get_profile: {
19
- description: 'Récupérer le profil de l\'utilisateur connecté (nom, email, crédits, rôle, institution, etc.).',
20
- inputSchema: z.object({}),
21
- handler: async () => {
22
- return c.get('/auth/me');
23
- },
24
- },
25
- auth_list_api_keys: {
26
- description: 'Lister toutes les clés API de l\'utilisateur connecté.',
27
- inputSchema: z.object({}),
28
- handler: async () => {
29
- return c.get('/api-keys');
30
- },
31
- },
32
- };
33
- }
34
- // Backward compatibility for stdio mode
35
- export const authTools = createAuthTools(defaultClient);
36
- //# sourceMappingURL=auth.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/tools/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,MAAM,IAAI,aAAa,EAAE,MAAM,cAAc,CAAC;AAEvD,MAAM,UAAU,eAAe,CAAC,CAAc;IAC5C,OAAO;QACL,UAAU,EAAE;YACV,WAAW,EAAE,gOAAgO;YAC7O,WAAW,EAAE,CAAC,CAAC,MAAM,CAAC;gBACpB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,QAAQ,CAAC,yBAAyB,CAAC;gBAC7D,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,cAAc,CAAC;aAC9C,CAAC;YACF,OAAO,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAuC,EAAE,EAAE;gBAC1E,MAAM,MAAM,GAAG,MAAM,CAAC,CAAC,IAAI,CAAC,aAAa,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC,CAAC;gBAChE,IAAI,MAAM,CAAC,KAAK;oBAAE,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;gBAC3C,OAAO,MAAM,CAAC;YAChB,CAAC;SACF;QAED,gBAAgB,EAAE;YAChB,WAAW,EAAE,gGAAgG;YAC7G,WAAW,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;YACzB,OAAO,EAAE,KAAK,IAAI,EAAE;gBAClB,OAAO,CAAC,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;YAC3B,CAAC;SACF;QAED,kBAAkB,EAAE;YAClB,WAAW,EAAE,wDAAwD;YACrE,WAAW,EAAE,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;YACzB,OAAO,EAAE,KAAK,IAAI,EAAE;gBAClB,OAAO,CAAC,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;YAC5B,CAAC;SACF;KACF,CAAC;AACJ,CAAC;AAED,wCAAwC;AACxC,MAAM,CAAC,MAAM,SAAS,GAAG,eAAe,CAAC,aAAa,CAAC,CAAC"}
@@ -1,457 +0,0 @@
1
- import { z } from 'zod';
2
- import { LyrraClient } from '../client.js';
3
- export declare function createBlocksTools(c: LyrraClient): {
4
- block_list_types: {
5
- description: string;
6
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
7
- handler: () => Promise<{
8
- types: {
9
- type: string;
10
- name: string;
11
- description: string;
12
- }[];
13
- }>;
14
- };
15
- block_get: {
16
- description: string;
17
- inputSchema: z.ZodObject<{
18
- flowId: z.ZodString;
19
- blockId: z.ZodString;
20
- }, "strip", z.ZodTypeAny, {
21
- flowId: string;
22
- blockId: string;
23
- }, {
24
- flowId: string;
25
- blockId: string;
26
- }>;
27
- handler: ({ flowId, blockId }: {
28
- flowId: string;
29
- blockId: string;
30
- }) => Promise<any>;
31
- };
32
- block_create: {
33
- description: string;
34
- inputSchema: z.ZodObject<{
35
- flowId: z.ZodString;
36
- type: z.ZodEnum<["text", "audio", "quiz", "video", "pdf", "image", "loop", "evaluation", "split", "merge", "timer", "start", "end", "chart", "timeline", "dys_reader", "dys_image_zones", "dys_reading_practice", "dys_clock", "glossary", "subflow", "mindmap", "form", "certification", "email", "voice_assessment", "presentation", "browser", "self_assessment"]>;
37
- title: z.ZodString;
38
- content: z.ZodRecord<z.ZodString, z.ZodAny>;
39
- positionX: z.ZodOptional<z.ZodNumber>;
40
- positionY: z.ZodOptional<z.ZodNumber>;
41
- order: z.ZodOptional<z.ZodNumber>;
42
- }, "strip", z.ZodTypeAny, {
43
- type: "email" | "start" | "end" | "text" | "audio" | "quiz" | "video" | "pdf" | "image" | "loop" | "evaluation" | "split" | "merge" | "timer" | "chart" | "timeline" | "dys_reader" | "dys_image_zones" | "dys_reading_practice" | "dys_clock" | "glossary" | "subflow" | "mindmap" | "form" | "certification" | "voice_assessment" | "presentation" | "browser" | "self_assessment";
44
- flowId: string;
45
- title: string;
46
- content: Record<string, any>;
47
- positionX?: number | undefined;
48
- positionY?: number | undefined;
49
- order?: number | undefined;
50
- }, {
51
- type: "email" | "start" | "end" | "text" | "audio" | "quiz" | "video" | "pdf" | "image" | "loop" | "evaluation" | "split" | "merge" | "timer" | "chart" | "timeline" | "dys_reader" | "dys_image_zones" | "dys_reading_practice" | "dys_clock" | "glossary" | "subflow" | "mindmap" | "form" | "certification" | "voice_assessment" | "presentation" | "browser" | "self_assessment";
52
- flowId: string;
53
- title: string;
54
- content: Record<string, any>;
55
- positionX?: number | undefined;
56
- positionY?: number | undefined;
57
- order?: number | undefined;
58
- }>;
59
- handler: ({ flowId, ...blockData }: any) => Promise<{
60
- success: boolean;
61
- block: any;
62
- }>;
63
- };
64
- block_update: {
65
- description: string;
66
- inputSchema: z.ZodObject<{
67
- flowId: z.ZodString;
68
- blockId: z.ZodString;
69
- title: z.ZodOptional<z.ZodString>;
70
- content: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
71
- positionX: z.ZodOptional<z.ZodNumber>;
72
- positionY: z.ZodOptional<z.ZodNumber>;
73
- order: z.ZodOptional<z.ZodNumber>;
74
- conditions: z.ZodOptional<z.ZodAny>;
75
- comment: z.ZodOptional<z.ZodString>;
76
- }, "strip", z.ZodTypeAny, {
77
- flowId: string;
78
- blockId: string;
79
- title?: string | undefined;
80
- content?: Record<string, any> | undefined;
81
- positionX?: number | undefined;
82
- positionY?: number | undefined;
83
- order?: number | undefined;
84
- conditions?: any;
85
- comment?: string | undefined;
86
- }, {
87
- flowId: string;
88
- blockId: string;
89
- title?: string | undefined;
90
- content?: Record<string, any> | undefined;
91
- positionX?: number | undefined;
92
- positionY?: number | undefined;
93
- order?: number | undefined;
94
- conditions?: any;
95
- comment?: string | undefined;
96
- }>;
97
- handler: ({ flowId, blockId, ...data }: any) => Promise<any>;
98
- };
99
- block_batch_update: {
100
- description: string;
101
- inputSchema: z.ZodObject<{
102
- flowId: z.ZodString;
103
- blocks: z.ZodArray<z.ZodObject<{
104
- id: z.ZodString;
105
- type: z.ZodString;
106
- title: z.ZodString;
107
- content: z.ZodAny;
108
- positionX: z.ZodOptional<z.ZodNumber>;
109
- positionY: z.ZodOptional<z.ZodNumber>;
110
- order: z.ZodOptional<z.ZodNumber>;
111
- conditions: z.ZodOptional<z.ZodAny>;
112
- comment: z.ZodOptional<z.ZodString>;
113
- }, "strip", z.ZodTypeAny, {
114
- type: string;
115
- title: string;
116
- id: string;
117
- content?: any;
118
- positionX?: number | undefined;
119
- positionY?: number | undefined;
120
- order?: number | undefined;
121
- conditions?: any;
122
- comment?: string | undefined;
123
- }, {
124
- type: string;
125
- title: string;
126
- id: string;
127
- content?: any;
128
- positionX?: number | undefined;
129
- positionY?: number | undefined;
130
- order?: number | undefined;
131
- conditions?: any;
132
- comment?: string | undefined;
133
- }>, "many">;
134
- edges: z.ZodOptional<z.ZodArray<z.ZodObject<{
135
- id: z.ZodString;
136
- source: z.ZodString;
137
- target: z.ZodString;
138
- label: z.ZodOptional<z.ZodString>;
139
- }, "strip", z.ZodTypeAny, {
140
- id: string;
141
- source: string;
142
- target: string;
143
- label?: string | undefined;
144
- }, {
145
- id: string;
146
- source: string;
147
- target: string;
148
- label?: string | undefined;
149
- }>, "many">>;
150
- }, "strip", z.ZodTypeAny, {
151
- flowId: string;
152
- blocks: {
153
- type: string;
154
- title: string;
155
- id: string;
156
- content?: any;
157
- positionX?: number | undefined;
158
- positionY?: number | undefined;
159
- order?: number | undefined;
160
- conditions?: any;
161
- comment?: string | undefined;
162
- }[];
163
- edges?: {
164
- id: string;
165
- source: string;
166
- target: string;
167
- label?: string | undefined;
168
- }[] | undefined;
169
- }, {
170
- flowId: string;
171
- blocks: {
172
- type: string;
173
- title: string;
174
- id: string;
175
- content?: any;
176
- positionX?: number | undefined;
177
- positionY?: number | undefined;
178
- order?: number | undefined;
179
- conditions?: any;
180
- comment?: string | undefined;
181
- }[];
182
- edges?: {
183
- id: string;
184
- source: string;
185
- target: string;
186
- label?: string | undefined;
187
- }[] | undefined;
188
- }>;
189
- handler: ({ flowId, blocks, edges }: any) => Promise<any>;
190
- };
191
- block_delete: {
192
- description: string;
193
- inputSchema: z.ZodObject<{
194
- flowId: z.ZodString;
195
- blockId: z.ZodString;
196
- }, "strip", z.ZodTypeAny, {
197
- flowId: string;
198
- blockId: string;
199
- }, {
200
- flowId: string;
201
- blockId: string;
202
- }>;
203
- handler: ({ flowId, blockId }: {
204
- flowId: string;
205
- blockId: string;
206
- }) => Promise<{
207
- success: boolean;
208
- remainingBlocks: any;
209
- remainingEdges: any;
210
- }>;
211
- };
212
- block_generate_tts: {
213
- description: string;
214
- inputSchema: z.ZodObject<{
215
- flowId: z.ZodString;
216
- blockId: z.ZodString;
217
- }, "strip", z.ZodTypeAny, {
218
- flowId: string;
219
- blockId: string;
220
- }, {
221
- flowId: string;
222
- blockId: string;
223
- }>;
224
- handler: ({ flowId, blockId }: {
225
- flowId: string;
226
- blockId: string;
227
- }) => Promise<any>;
228
- };
229
- };
230
- export declare const blocksTools: {
231
- block_list_types: {
232
- description: string;
233
- inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
234
- handler: () => Promise<{
235
- types: {
236
- type: string;
237
- name: string;
238
- description: string;
239
- }[];
240
- }>;
241
- };
242
- block_get: {
243
- description: string;
244
- inputSchema: z.ZodObject<{
245
- flowId: z.ZodString;
246
- blockId: z.ZodString;
247
- }, "strip", z.ZodTypeAny, {
248
- flowId: string;
249
- blockId: string;
250
- }, {
251
- flowId: string;
252
- blockId: string;
253
- }>;
254
- handler: ({ flowId, blockId }: {
255
- flowId: string;
256
- blockId: string;
257
- }) => Promise<any>;
258
- };
259
- block_create: {
260
- description: string;
261
- inputSchema: z.ZodObject<{
262
- flowId: z.ZodString;
263
- type: z.ZodEnum<["text", "audio", "quiz", "video", "pdf", "image", "loop", "evaluation", "split", "merge", "timer", "start", "end", "chart", "timeline", "dys_reader", "dys_image_zones", "dys_reading_practice", "dys_clock", "glossary", "subflow", "mindmap", "form", "certification", "email", "voice_assessment", "presentation", "browser", "self_assessment"]>;
264
- title: z.ZodString;
265
- content: z.ZodRecord<z.ZodString, z.ZodAny>;
266
- positionX: z.ZodOptional<z.ZodNumber>;
267
- positionY: z.ZodOptional<z.ZodNumber>;
268
- order: z.ZodOptional<z.ZodNumber>;
269
- }, "strip", z.ZodTypeAny, {
270
- type: "email" | "start" | "end" | "text" | "audio" | "quiz" | "video" | "pdf" | "image" | "loop" | "evaluation" | "split" | "merge" | "timer" | "chart" | "timeline" | "dys_reader" | "dys_image_zones" | "dys_reading_practice" | "dys_clock" | "glossary" | "subflow" | "mindmap" | "form" | "certification" | "voice_assessment" | "presentation" | "browser" | "self_assessment";
271
- flowId: string;
272
- title: string;
273
- content: Record<string, any>;
274
- positionX?: number | undefined;
275
- positionY?: number | undefined;
276
- order?: number | undefined;
277
- }, {
278
- type: "email" | "start" | "end" | "text" | "audio" | "quiz" | "video" | "pdf" | "image" | "loop" | "evaluation" | "split" | "merge" | "timer" | "chart" | "timeline" | "dys_reader" | "dys_image_zones" | "dys_reading_practice" | "dys_clock" | "glossary" | "subflow" | "mindmap" | "form" | "certification" | "voice_assessment" | "presentation" | "browser" | "self_assessment";
279
- flowId: string;
280
- title: string;
281
- content: Record<string, any>;
282
- positionX?: number | undefined;
283
- positionY?: number | undefined;
284
- order?: number | undefined;
285
- }>;
286
- handler: ({ flowId, ...blockData }: any) => Promise<{
287
- success: boolean;
288
- block: any;
289
- }>;
290
- };
291
- block_update: {
292
- description: string;
293
- inputSchema: z.ZodObject<{
294
- flowId: z.ZodString;
295
- blockId: z.ZodString;
296
- title: z.ZodOptional<z.ZodString>;
297
- content: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
298
- positionX: z.ZodOptional<z.ZodNumber>;
299
- positionY: z.ZodOptional<z.ZodNumber>;
300
- order: z.ZodOptional<z.ZodNumber>;
301
- conditions: z.ZodOptional<z.ZodAny>;
302
- comment: z.ZodOptional<z.ZodString>;
303
- }, "strip", z.ZodTypeAny, {
304
- flowId: string;
305
- blockId: string;
306
- title?: string | undefined;
307
- content?: Record<string, any> | undefined;
308
- positionX?: number | undefined;
309
- positionY?: number | undefined;
310
- order?: number | undefined;
311
- conditions?: any;
312
- comment?: string | undefined;
313
- }, {
314
- flowId: string;
315
- blockId: string;
316
- title?: string | undefined;
317
- content?: Record<string, any> | undefined;
318
- positionX?: number | undefined;
319
- positionY?: number | undefined;
320
- order?: number | undefined;
321
- conditions?: any;
322
- comment?: string | undefined;
323
- }>;
324
- handler: ({ flowId, blockId, ...data }: any) => Promise<any>;
325
- };
326
- block_batch_update: {
327
- description: string;
328
- inputSchema: z.ZodObject<{
329
- flowId: z.ZodString;
330
- blocks: z.ZodArray<z.ZodObject<{
331
- id: z.ZodString;
332
- type: z.ZodString;
333
- title: z.ZodString;
334
- content: z.ZodAny;
335
- positionX: z.ZodOptional<z.ZodNumber>;
336
- positionY: z.ZodOptional<z.ZodNumber>;
337
- order: z.ZodOptional<z.ZodNumber>;
338
- conditions: z.ZodOptional<z.ZodAny>;
339
- comment: z.ZodOptional<z.ZodString>;
340
- }, "strip", z.ZodTypeAny, {
341
- type: string;
342
- title: string;
343
- id: string;
344
- content?: any;
345
- positionX?: number | undefined;
346
- positionY?: number | undefined;
347
- order?: number | undefined;
348
- conditions?: any;
349
- comment?: string | undefined;
350
- }, {
351
- type: string;
352
- title: string;
353
- id: string;
354
- content?: any;
355
- positionX?: number | undefined;
356
- positionY?: number | undefined;
357
- order?: number | undefined;
358
- conditions?: any;
359
- comment?: string | undefined;
360
- }>, "many">;
361
- edges: z.ZodOptional<z.ZodArray<z.ZodObject<{
362
- id: z.ZodString;
363
- source: z.ZodString;
364
- target: z.ZodString;
365
- label: z.ZodOptional<z.ZodString>;
366
- }, "strip", z.ZodTypeAny, {
367
- id: string;
368
- source: string;
369
- target: string;
370
- label?: string | undefined;
371
- }, {
372
- id: string;
373
- source: string;
374
- target: string;
375
- label?: string | undefined;
376
- }>, "many">>;
377
- }, "strip", z.ZodTypeAny, {
378
- flowId: string;
379
- blocks: {
380
- type: string;
381
- title: string;
382
- id: string;
383
- content?: any;
384
- positionX?: number | undefined;
385
- positionY?: number | undefined;
386
- order?: number | undefined;
387
- conditions?: any;
388
- comment?: string | undefined;
389
- }[];
390
- edges?: {
391
- id: string;
392
- source: string;
393
- target: string;
394
- label?: string | undefined;
395
- }[] | undefined;
396
- }, {
397
- flowId: string;
398
- blocks: {
399
- type: string;
400
- title: string;
401
- id: string;
402
- content?: any;
403
- positionX?: number | undefined;
404
- positionY?: number | undefined;
405
- order?: number | undefined;
406
- conditions?: any;
407
- comment?: string | undefined;
408
- }[];
409
- edges?: {
410
- id: string;
411
- source: string;
412
- target: string;
413
- label?: string | undefined;
414
- }[] | undefined;
415
- }>;
416
- handler: ({ flowId, blocks, edges }: any) => Promise<any>;
417
- };
418
- block_delete: {
419
- description: string;
420
- inputSchema: z.ZodObject<{
421
- flowId: z.ZodString;
422
- blockId: z.ZodString;
423
- }, "strip", z.ZodTypeAny, {
424
- flowId: string;
425
- blockId: string;
426
- }, {
427
- flowId: string;
428
- blockId: string;
429
- }>;
430
- handler: ({ flowId, blockId }: {
431
- flowId: string;
432
- blockId: string;
433
- }) => Promise<{
434
- success: boolean;
435
- remainingBlocks: any;
436
- remainingEdges: any;
437
- }>;
438
- };
439
- block_generate_tts: {
440
- description: string;
441
- inputSchema: z.ZodObject<{
442
- flowId: z.ZodString;
443
- blockId: z.ZodString;
444
- }, "strip", z.ZodTypeAny, {
445
- flowId: string;
446
- blockId: string;
447
- }, {
448
- flowId: string;
449
- blockId: string;
450
- }>;
451
- handler: ({ flowId, blockId }: {
452
- flowId: string;
453
- blockId: string;
454
- }) => Promise<any>;
455
- };
456
- };
457
- //# sourceMappingURL=blocks.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"blocks.d.ts","sourceRoot":"","sources":["../../src/tools/blocks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAO3C,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,WAAW;;;;;;;;;;;;;;;;;;;;;;;;uCAkDP;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4CAuB9B,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gDAkCC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6CA2BN,GAAG;;;;;;;;;;;;;;uCAWT;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;uCAwBnC;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;EAK3E;AAGD,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;uCA/HiB;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4CAuB9B,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gDAkCC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6CA2BN,GAAG;;;;;;;;;;;;;;uCAWT;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;uCAwBnC;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE;;CAQjB,CAAC"}