@lyrra/mcp-server 1.0.1 → 1.1.0
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/Dockerfile +16 -0
- package/README.md +59 -4
- package/dist/client.d.ts +7 -1
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +5 -5
- package/dist/client.js.map +1 -1
- package/dist/config.d.ts +1 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +1 -0
- package/dist/config.js.map +1 -1
- package/dist/http-server.d.ts +8 -0
- package/dist/http-server.d.ts.map +1 -0
- package/dist/http-server.js +466 -0
- package/dist/http-server.js.map +1 -0
- package/dist/index.js +3 -69
- package/dist/index.js.map +1 -1
- package/dist/server-factory.d.ts +8 -0
- package/dist/server-factory.d.ts.map +1 -0
- package/dist/server-factory.js +82 -0
- package/dist/server-factory.js.map +1 -0
- package/dist/tools/admin.d.ts +132 -0
- package/dist/tools/admin.d.ts.map +1 -1
- package/dist/tools/admin.js +105 -101
- package/dist/tools/admin.js.map +1 -1
- package/dist/tools/ai-designer.d.ts +148 -0
- package/dist/tools/ai-designer.d.ts.map +1 -1
- package/dist/tools/ai-designer.js +80 -76
- package/dist/tools/ai-designer.js.map +1 -1
- package/dist/tools/analytics.d.ts +47 -0
- package/dist/tools/analytics.d.ts.map +1 -1
- package/dist/tools/analytics.js +38 -34
- package/dist/tools/analytics.js.map +1 -1
- package/dist/tools/auth.d.ts +30 -0
- package/dist/tools/auth.d.ts.map +1 -1
- package/dist/tools/auth.js +31 -27
- package/dist/tools/auth.js.map +1 -1
- package/dist/tools/blocks.d.ts +200 -0
- package/dist/tools/blocks.d.ts.map +1 -1
- package/dist/tools/blocks.js +154 -150
- package/dist/tools/blocks.js.map +1 -1
- package/dist/tools/connections.d.ts +86 -0
- package/dist/tools/connections.d.ts.map +1 -1
- package/dist/tools/connections.js +70 -66
- package/dist/tools/connections.js.map +1 -1
- package/dist/tools/eduflow.d.ts +223 -0
- package/dist/tools/eduflow.d.ts.map +1 -1
- package/dist/tools/eduflow.js +114 -93
- package/dist/tools/eduflow.js.map +1 -1
- package/dist/tools/participants.d.ts +110 -0
- package/dist/tools/participants.d.ts.map +1 -1
- package/dist/tools/participants.js +62 -58
- package/dist/tools/participants.js.map +1 -1
- package/dist/tools/presentation.d.ts +116 -0
- package/dist/tools/presentation.d.ts.map +1 -1
- package/dist/tools/presentation.js +51 -47
- package/dist/tools/presentation.js.map +1 -1
- package/dist/tools/projects.d.ts +65 -0
- package/dist/tools/projects.d.ts.map +1 -1
- package/dist/tools/projects.js +48 -44
- package/dist/tools/projects.js.map +1 -1
- package/dist/tools/resources.d.ts +46 -0
- package/dist/tools/resources.d.ts.map +1 -1
- package/dist/tools/resources.js +32 -28
- package/dist/tools/resources.js.map +1 -1
- package/dist/tools/store.d.ts +62 -0
- package/dist/tools/store.d.ts.map +1 -1
- package/dist/tools/store.js +59 -55
- package/dist/tools/store.js.map +1 -1
- package/mcp-config.example.json +4 -5
- package/package.json +7 -2
- package/src/client.ts +12 -5
- package/src/config.ts +1 -0
- package/src/http-server.ts +573 -0
- package/src/index.ts +3 -94
- package/src/server-factory.ts +109 -0
- package/src/tools/admin.ts +20 -14
- package/src/tools/ai-designer.ts +16 -10
- package/src/tools/analytics.ts +13 -7
- package/src/tools/auth.ts +32 -26
- package/src/tools/blocks.ts +18 -12
- package/src/tools/connections.ts +14 -8
- package/src/tools/eduflow.ts +36 -12
- package/src/tools/participants.ts +15 -9
- package/src/tools/presentation.ts +12 -6
- package/src/tools/projects.ts +14 -8
- package/src/tools/resources.ts +12 -6
- package/src/tools/store.ts +14 -8
|
@@ -1,4 +1,90 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { LyrraClient } from '../client.js';
|
|
3
|
+
export declare function createConnectionsTools(c: LyrraClient): {
|
|
4
|
+
connection_list: {
|
|
5
|
+
description: string;
|
|
6
|
+
inputSchema: z.ZodObject<{
|
|
7
|
+
flowId: z.ZodString;
|
|
8
|
+
}, "strip", z.ZodTypeAny, {
|
|
9
|
+
flowId: string;
|
|
10
|
+
}, {
|
|
11
|
+
flowId: string;
|
|
12
|
+
}>;
|
|
13
|
+
handler: ({ flowId }: {
|
|
14
|
+
flowId: string;
|
|
15
|
+
}) => Promise<{
|
|
16
|
+
edges: any;
|
|
17
|
+
blocks: any;
|
|
18
|
+
}>;
|
|
19
|
+
};
|
|
20
|
+
connection_add: {
|
|
21
|
+
description: string;
|
|
22
|
+
inputSchema: z.ZodObject<{
|
|
23
|
+
flowId: z.ZodString;
|
|
24
|
+
source: z.ZodString;
|
|
25
|
+
target: z.ZodString;
|
|
26
|
+
label: z.ZodOptional<z.ZodString>;
|
|
27
|
+
animated: z.ZodOptional<z.ZodBoolean>;
|
|
28
|
+
}, "strip", z.ZodTypeAny, {
|
|
29
|
+
flowId: string;
|
|
30
|
+
source: string;
|
|
31
|
+
target: string;
|
|
32
|
+
label?: string | undefined;
|
|
33
|
+
animated?: boolean | undefined;
|
|
34
|
+
}, {
|
|
35
|
+
flowId: string;
|
|
36
|
+
source: string;
|
|
37
|
+
target: string;
|
|
38
|
+
label?: string | undefined;
|
|
39
|
+
animated?: boolean | undefined;
|
|
40
|
+
}>;
|
|
41
|
+
handler: ({ flowId, source, target, label, animated }: any) => Promise<{
|
|
42
|
+
success: boolean;
|
|
43
|
+
error: string;
|
|
44
|
+
edge?: undefined;
|
|
45
|
+
totalEdges?: undefined;
|
|
46
|
+
} | {
|
|
47
|
+
success: boolean;
|
|
48
|
+
edge: {
|
|
49
|
+
id: string;
|
|
50
|
+
source: any;
|
|
51
|
+
target: any;
|
|
52
|
+
label: any;
|
|
53
|
+
animated: any;
|
|
54
|
+
};
|
|
55
|
+
totalEdges: any;
|
|
56
|
+
error?: undefined;
|
|
57
|
+
}>;
|
|
58
|
+
};
|
|
59
|
+
connection_remove: {
|
|
60
|
+
description: string;
|
|
61
|
+
inputSchema: z.ZodObject<{
|
|
62
|
+
flowId: z.ZodString;
|
|
63
|
+
edgeId: z.ZodOptional<z.ZodString>;
|
|
64
|
+
source: z.ZodOptional<z.ZodString>;
|
|
65
|
+
target: z.ZodOptional<z.ZodString>;
|
|
66
|
+
}, "strip", z.ZodTypeAny, {
|
|
67
|
+
flowId: string;
|
|
68
|
+
source?: string | undefined;
|
|
69
|
+
target?: string | undefined;
|
|
70
|
+
edgeId?: string | undefined;
|
|
71
|
+
}, {
|
|
72
|
+
flowId: string;
|
|
73
|
+
source?: string | undefined;
|
|
74
|
+
target?: string | undefined;
|
|
75
|
+
edgeId?: string | undefined;
|
|
76
|
+
}>;
|
|
77
|
+
handler: ({ flowId, edgeId, source, target }: any) => Promise<{
|
|
78
|
+
success: boolean;
|
|
79
|
+
error: string;
|
|
80
|
+
remainingEdges?: undefined;
|
|
81
|
+
} | {
|
|
82
|
+
success: boolean;
|
|
83
|
+
remainingEdges: any;
|
|
84
|
+
error?: undefined;
|
|
85
|
+
}>;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
2
88
|
export declare const connectionsTools: {
|
|
3
89
|
connection_list: {
|
|
4
90
|
description: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connections.d.ts","sourceRoot":"","sources":["../../src/tools/connections.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"connections.d.ts","sourceRoot":"","sources":["../../src/tools/connections.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAG3C,wBAAgB,sBAAsB,CAAC,CAAC,EAAE,WAAW;;;;;;;;;;8BAarB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;;;;+DAkBe,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sDA6BZ,GAAG;;;;;;;;;;EAe1D;AAGD,eAAO,MAAM,gBAAgB;;;;;;;;;;8BAjEG;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;;;;+DAkBe,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sDA6BZ,GAAG;;;;;;;;;;CAkBU,CAAC"}
|
|
@@ -1,77 +1,81 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { client } from '../client.js';
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
import { client as defaultClient } from '../client.js';
|
|
3
|
+
export function createConnectionsTools(c) {
|
|
4
|
+
return {
|
|
5
|
+
connection_list: {
|
|
6
|
+
description: `Lister toutes les connexions (edges) d'un parcours EduFlow. Chaque connexion relie un bloc source à un bloc cible.
|
|
6
7
|
Règles de connexion :
|
|
7
8
|
- Le bloc "start" ne peut avoir QUE des connexions sortantes
|
|
8
9
|
- Le bloc "end" ne peut avoir QUE des connexions entrantes
|
|
9
10
|
- Un bloc "split" doit avoir au moins 2 connexions sortantes
|
|
10
11
|
- Un bloc "merge" doit avoir au moins 2 connexions entrantes
|
|
11
12
|
- Un bloc "quiz" peut avoir des connexions conditionnelles (branchement selon la réponse)`,
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
13
|
+
inputSchema: z.object({
|
|
14
|
+
flowId: z.string().uuid().describe('ID du parcours'),
|
|
15
|
+
}),
|
|
16
|
+
handler: async ({ flowId }) => {
|
|
17
|
+
const flow = await c.get(`/flows/${flowId}`, 'eduflow');
|
|
18
|
+
return {
|
|
19
|
+
edges: flow.edges || [],
|
|
20
|
+
blocks: (flow.blocks || []).map((b) => ({ id: b.id, type: b.type, title: b.title })),
|
|
21
|
+
};
|
|
22
|
+
},
|
|
21
23
|
},
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
24
|
+
connection_add: {
|
|
25
|
+
description: 'Ajouter une connexion entre deux blocs. Le parcours est un graphe orienté : source → target.',
|
|
26
|
+
inputSchema: z.object({
|
|
27
|
+
flowId: z.string().uuid().describe('ID du parcours'),
|
|
28
|
+
source: z.string().describe('ID du bloc source (d\'où part la connexion)'),
|
|
29
|
+
target: z.string().describe('ID du bloc cible (où arrive la connexion)'),
|
|
30
|
+
label: z.string().optional().describe('Label affiché sur la connexion (ex: "Bonne réponse", "Mauvaise réponse")'),
|
|
31
|
+
animated: z.boolean().optional().describe('Animer la connexion visuellement'),
|
|
32
|
+
}),
|
|
33
|
+
handler: async ({ flowId, source, target, label, animated }) => {
|
|
34
|
+
const flow = await c.get(`/flows/${flowId}`, 'eduflow');
|
|
35
|
+
const edges = flow.edges || [];
|
|
36
|
+
const newEdge = {
|
|
37
|
+
id: `e-${source}-${target}`,
|
|
38
|
+
source,
|
|
39
|
+
target,
|
|
40
|
+
label: label || '',
|
|
41
|
+
animated: animated || false,
|
|
42
|
+
};
|
|
43
|
+
// Check for duplicate
|
|
44
|
+
const exists = edges.some((e) => e.source === source && e.target === target);
|
|
45
|
+
if (exists) {
|
|
46
|
+
return { success: false, error: 'Cette connexion existe déjà' };
|
|
47
|
+
}
|
|
48
|
+
edges.push(newEdge);
|
|
49
|
+
await c.put(`/flows/${flowId}`, { edges }, 'eduflow');
|
|
50
|
+
return { success: true, edge: newEdge, totalEdges: edges.length };
|
|
51
|
+
},
|
|
50
52
|
},
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
53
|
+
connection_remove: {
|
|
54
|
+
description: 'Supprimer une connexion entre deux blocs.',
|
|
55
|
+
inputSchema: z.object({
|
|
56
|
+
flowId: z.string().uuid().describe('ID du parcours'),
|
|
57
|
+
edgeId: z.string().optional().describe('ID de la connexion à supprimer'),
|
|
58
|
+
source: z.string().optional().describe('Alternative : ID du bloc source'),
|
|
59
|
+
target: z.string().optional().describe('Alternative : ID du bloc cible'),
|
|
60
|
+
}),
|
|
61
|
+
handler: async ({ flowId, edgeId, source, target }) => {
|
|
62
|
+
const flow = await c.get(`/flows/${flowId}`, 'eduflow');
|
|
63
|
+
let edges = flow.edges || [];
|
|
64
|
+
if (edgeId) {
|
|
65
|
+
edges = edges.filter((e) => e.id !== edgeId);
|
|
66
|
+
}
|
|
67
|
+
else if (source && target) {
|
|
68
|
+
edges = edges.filter((e) => !(e.source === source && e.target === target));
|
|
69
|
+
}
|
|
70
|
+
else {
|
|
71
|
+
return { success: false, error: 'Fournir edgeId OU source+target' };
|
|
72
|
+
}
|
|
73
|
+
await c.put(`/flows/${flowId}`, { edges }, 'eduflow');
|
|
74
|
+
return { success: true, remainingEdges: edges.length };
|
|
75
|
+
},
|
|
74
76
|
},
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
// Backward compatibility for stdio mode
|
|
80
|
+
export const connectionsTools = createConnectionsTools(defaultClient);
|
|
77
81
|
//# sourceMappingURL=connections.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connections.js","sourceRoot":"","sources":["../../src/tools/connections.ts"],"names":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N,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,iCAAiC,EAAE,CAAC;gBACtE,CAAC;gBACD,MAAM,CAAC,CAAC,GAAG,CAAC,UAAU,MAAM,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,SAAS,CAAC,CAAC;gBACtD,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,CAAC,MAAM,EAAE,CAAC;YACzD,CAAC;SACF;KACA,CAAC;AACJ,CAAC;AAED,wCAAwC;AACxC,MAAM,CAAC,MAAM,gBAAgB,GAAG,sBAAsB,CAAC,aAAa,CAAC,CAAC"}
|
package/dist/tools/eduflow.d.ts
CHANGED
|
@@ -1,4 +1,208 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { LyrraClient } from '../client.js';
|
|
3
|
+
export declare function createEduflowTools(c: LyrraClient): {
|
|
4
|
+
eduflow_list: {
|
|
5
|
+
description: string;
|
|
6
|
+
inputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
|
7
|
+
handler: () => Promise<any>;
|
|
8
|
+
};
|
|
9
|
+
eduflow_get: {
|
|
10
|
+
description: string;
|
|
11
|
+
inputSchema: z.ZodObject<{
|
|
12
|
+
flowId: z.ZodString;
|
|
13
|
+
}, "strip", z.ZodTypeAny, {
|
|
14
|
+
flowId: string;
|
|
15
|
+
}, {
|
|
16
|
+
flowId: string;
|
|
17
|
+
}>;
|
|
18
|
+
handler: ({ flowId }: {
|
|
19
|
+
flowId: string;
|
|
20
|
+
}) => Promise<any>;
|
|
21
|
+
};
|
|
22
|
+
eduflow_get_urls: {
|
|
23
|
+
description: string;
|
|
24
|
+
inputSchema: z.ZodObject<{
|
|
25
|
+
flowId: z.ZodString;
|
|
26
|
+
}, "strip", z.ZodTypeAny, {
|
|
27
|
+
flowId: string;
|
|
28
|
+
}, {
|
|
29
|
+
flowId: string;
|
|
30
|
+
}>;
|
|
31
|
+
handler: ({ flowId }: {
|
|
32
|
+
flowId: string;
|
|
33
|
+
}) => Promise<{
|
|
34
|
+
preview: string;
|
|
35
|
+
public: string;
|
|
36
|
+
edit: string;
|
|
37
|
+
presentation: string;
|
|
38
|
+
analytics: string;
|
|
39
|
+
}>;
|
|
40
|
+
};
|
|
41
|
+
eduflow_create: {
|
|
42
|
+
description: string;
|
|
43
|
+
inputSchema: z.ZodObject<{
|
|
44
|
+
title: z.ZodString;
|
|
45
|
+
description: z.ZodOptional<z.ZodString>;
|
|
46
|
+
language: z.ZodOptional<z.ZodEnum<["fr", "en", "es", "it", "de"]>>;
|
|
47
|
+
}, "strip", z.ZodTypeAny, {
|
|
48
|
+
title: string;
|
|
49
|
+
description?: string | undefined;
|
|
50
|
+
language?: "fr" | "en" | "es" | "it" | "de" | undefined;
|
|
51
|
+
}, {
|
|
52
|
+
title: string;
|
|
53
|
+
description?: string | undefined;
|
|
54
|
+
language?: "fr" | "en" | "es" | "it" | "de" | undefined;
|
|
55
|
+
}>;
|
|
56
|
+
handler: (args: {
|
|
57
|
+
title: string;
|
|
58
|
+
description?: string;
|
|
59
|
+
language?: string;
|
|
60
|
+
}) => Promise<any>;
|
|
61
|
+
};
|
|
62
|
+
eduflow_update: {
|
|
63
|
+
description: string;
|
|
64
|
+
inputSchema: z.ZodObject<{
|
|
65
|
+
flowId: z.ZodString;
|
|
66
|
+
title: z.ZodOptional<z.ZodString>;
|
|
67
|
+
description: z.ZodOptional<z.ZodString>;
|
|
68
|
+
edges: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
69
|
+
id: z.ZodString;
|
|
70
|
+
source: z.ZodString;
|
|
71
|
+
target: z.ZodString;
|
|
72
|
+
label: z.ZodOptional<z.ZodString>;
|
|
73
|
+
animated: z.ZodOptional<z.ZodBoolean>;
|
|
74
|
+
}, "strip", z.ZodTypeAny, {
|
|
75
|
+
id: string;
|
|
76
|
+
source: string;
|
|
77
|
+
target: string;
|
|
78
|
+
label?: string | undefined;
|
|
79
|
+
animated?: boolean | undefined;
|
|
80
|
+
}, {
|
|
81
|
+
id: string;
|
|
82
|
+
source: string;
|
|
83
|
+
target: string;
|
|
84
|
+
label?: string | undefined;
|
|
85
|
+
animated?: boolean | undefined;
|
|
86
|
+
}>, "many">>;
|
|
87
|
+
objectives: z.ZodOptional<z.ZodAny>;
|
|
88
|
+
gamification: z.ZodOptional<z.ZodAny>;
|
|
89
|
+
presentationEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
90
|
+
presentationData: z.ZodOptional<z.ZodAny>;
|
|
91
|
+
chatbotEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
92
|
+
facialVerificationEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
93
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
94
|
+
language: z.ZodOptional<z.ZodEnum<["fr", "en", "es", "it", "de"]>>;
|
|
95
|
+
}, "strip", z.ZodTypeAny, {
|
|
96
|
+
flowId: string;
|
|
97
|
+
title?: string | undefined;
|
|
98
|
+
description?: string | undefined;
|
|
99
|
+
language?: "fr" | "en" | "es" | "it" | "de" | undefined;
|
|
100
|
+
edges?: {
|
|
101
|
+
id: string;
|
|
102
|
+
source: string;
|
|
103
|
+
target: string;
|
|
104
|
+
label?: string | undefined;
|
|
105
|
+
animated?: boolean | undefined;
|
|
106
|
+
}[] | undefined;
|
|
107
|
+
objectives?: any;
|
|
108
|
+
gamification?: any;
|
|
109
|
+
presentationEnabled?: boolean | undefined;
|
|
110
|
+
presentationData?: any;
|
|
111
|
+
chatbotEnabled?: boolean | undefined;
|
|
112
|
+
facialVerificationEnabled?: boolean | undefined;
|
|
113
|
+
deadline?: string | undefined;
|
|
114
|
+
}, {
|
|
115
|
+
flowId: string;
|
|
116
|
+
title?: string | undefined;
|
|
117
|
+
description?: string | undefined;
|
|
118
|
+
language?: "fr" | "en" | "es" | "it" | "de" | undefined;
|
|
119
|
+
edges?: {
|
|
120
|
+
id: string;
|
|
121
|
+
source: string;
|
|
122
|
+
target: string;
|
|
123
|
+
label?: string | undefined;
|
|
124
|
+
animated?: boolean | undefined;
|
|
125
|
+
}[] | undefined;
|
|
126
|
+
objectives?: any;
|
|
127
|
+
gamification?: any;
|
|
128
|
+
presentationEnabled?: boolean | undefined;
|
|
129
|
+
presentationData?: any;
|
|
130
|
+
chatbotEnabled?: boolean | undefined;
|
|
131
|
+
facialVerificationEnabled?: boolean | undefined;
|
|
132
|
+
deadline?: string | undefined;
|
|
133
|
+
}>;
|
|
134
|
+
handler: ({ flowId, ...data }: any) => Promise<any>;
|
|
135
|
+
};
|
|
136
|
+
eduflow_delete: {
|
|
137
|
+
description: string;
|
|
138
|
+
inputSchema: z.ZodObject<{
|
|
139
|
+
flowId: z.ZodString;
|
|
140
|
+
}, "strip", z.ZodTypeAny, {
|
|
141
|
+
flowId: string;
|
|
142
|
+
}, {
|
|
143
|
+
flowId: string;
|
|
144
|
+
}>;
|
|
145
|
+
handler: ({ flowId }: {
|
|
146
|
+
flowId: string;
|
|
147
|
+
}) => Promise<any>;
|
|
148
|
+
};
|
|
149
|
+
eduflow_duplicate: {
|
|
150
|
+
description: string;
|
|
151
|
+
inputSchema: z.ZodObject<{
|
|
152
|
+
flowId: z.ZodString;
|
|
153
|
+
}, "strip", z.ZodTypeAny, {
|
|
154
|
+
flowId: string;
|
|
155
|
+
}, {
|
|
156
|
+
flowId: string;
|
|
157
|
+
}>;
|
|
158
|
+
handler: ({ flowId }: {
|
|
159
|
+
flowId: string;
|
|
160
|
+
}) => Promise<any>;
|
|
161
|
+
};
|
|
162
|
+
eduflow_change_status: {
|
|
163
|
+
description: string;
|
|
164
|
+
inputSchema: z.ZodObject<{
|
|
165
|
+
flowId: z.ZodString;
|
|
166
|
+
status: z.ZodEnum<["draft", "published", "archived"]>;
|
|
167
|
+
}, "strip", z.ZodTypeAny, {
|
|
168
|
+
status: "draft" | "published" | "archived";
|
|
169
|
+
flowId: string;
|
|
170
|
+
}, {
|
|
171
|
+
status: "draft" | "published" | "archived";
|
|
172
|
+
flowId: string;
|
|
173
|
+
}>;
|
|
174
|
+
handler: ({ flowId, status }: {
|
|
175
|
+
flowId: string;
|
|
176
|
+
status: string;
|
|
177
|
+
}) => Promise<any>;
|
|
178
|
+
};
|
|
179
|
+
eduflow_export: {
|
|
180
|
+
description: string;
|
|
181
|
+
inputSchema: z.ZodObject<{
|
|
182
|
+
flowId: z.ZodString;
|
|
183
|
+
}, "strip", z.ZodTypeAny, {
|
|
184
|
+
flowId: string;
|
|
185
|
+
}, {
|
|
186
|
+
flowId: string;
|
|
187
|
+
}>;
|
|
188
|
+
handler: ({ flowId }: {
|
|
189
|
+
flowId: string;
|
|
190
|
+
}) => Promise<any>;
|
|
191
|
+
};
|
|
192
|
+
eduflow_get_public: {
|
|
193
|
+
description: string;
|
|
194
|
+
inputSchema: z.ZodObject<{
|
|
195
|
+
flowId: z.ZodString;
|
|
196
|
+
}, "strip", z.ZodTypeAny, {
|
|
197
|
+
flowId: string;
|
|
198
|
+
}, {
|
|
199
|
+
flowId: string;
|
|
200
|
+
}>;
|
|
201
|
+
handler: ({ flowId }: {
|
|
202
|
+
flowId: string;
|
|
203
|
+
}) => Promise<any>;
|
|
204
|
+
};
|
|
205
|
+
};
|
|
2
206
|
export declare const eduflowTools: {
|
|
3
207
|
eduflow_list: {
|
|
4
208
|
description: string;
|
|
@@ -18,6 +222,25 @@ export declare const eduflowTools: {
|
|
|
18
222
|
flowId: string;
|
|
19
223
|
}) => Promise<any>;
|
|
20
224
|
};
|
|
225
|
+
eduflow_get_urls: {
|
|
226
|
+
description: string;
|
|
227
|
+
inputSchema: z.ZodObject<{
|
|
228
|
+
flowId: z.ZodString;
|
|
229
|
+
}, "strip", z.ZodTypeAny, {
|
|
230
|
+
flowId: string;
|
|
231
|
+
}, {
|
|
232
|
+
flowId: string;
|
|
233
|
+
}>;
|
|
234
|
+
handler: ({ flowId }: {
|
|
235
|
+
flowId: string;
|
|
236
|
+
}) => Promise<{
|
|
237
|
+
preview: string;
|
|
238
|
+
public: string;
|
|
239
|
+
edit: string;
|
|
240
|
+
presentation: string;
|
|
241
|
+
analytics: string;
|
|
242
|
+
}>;
|
|
243
|
+
};
|
|
21
244
|
eduflow_create: {
|
|
22
245
|
description: string;
|
|
23
246
|
inputSchema: z.ZodObject<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eduflow.d.ts","sourceRoot":"","sources":["../../src/tools/eduflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"eduflow.d.ts","sourceRoot":"","sources":["../../src/tools/eduflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAI3C,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,WAAW;;;;;;;;;;;;;;;8BAejB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;8BAUlB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;wBAmBxB;YAAE,KAAK,EAAE,MAAM,CAAC;YAAC,WAAW,CAAC,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uCA2B3C,GAAG;;;;;;;;;;;8BAUZ;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;8BAUlB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;;;;sCAWV;YAAE,MAAM,EAAE,MAAM,CAAC;YAAC,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;8BAU1C;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;;;;;;;;;;8BAUlB;YAAE,MAAM,EAAE,MAAM,CAAA;SAAE;;EAKjD;AAG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