apteva 0.4.32 → 0.4.44
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/ActivityPage.c48n83h2.js +3 -0
- package/dist/ApiDocsPage.yzcxx5ax.js +4 -0
- package/dist/App.09yb8t0b.js +1 -0
- package/dist/App.152mbs1r.js +4 -0
- package/dist/App.3a67nx9w.js +4 -0
- package/dist/App.9epx6785.js +4 -0
- package/dist/App.d8955awp.js +4 -0
- package/dist/App.drwb57jq.js +4 -0
- package/dist/App.gssbmajb.js +4 -0
- package/dist/App.qw70pc29.js +53 -0
- package/dist/App.qzbx5wtj.js +4 -0
- package/dist/App.r5serxkt.js +8 -0
- package/dist/App.tpmp9020.js +20 -0
- package/dist/App.v2wb4d7d.js +61 -0
- package/dist/App.vxmaaj0m.js +13 -0
- package/dist/App.w4p2tda9.js +4 -0
- package/dist/App.wv2ng55q.js +221 -0
- package/dist/App.yncnrn0f.js +4 -0
- package/dist/ConnectionsPage.k6cspyqq.js +3 -0
- package/dist/McpPage.cdxm48xj.js +3 -0
- package/dist/SettingsPage.evpv7c2y.js +3 -0
- package/dist/SkillsPage.pvzp6c1a.js +3 -0
- package/dist/TasksPage.6jnvbpsy.js +3 -0
- package/dist/TelemetryPage.t7vk24zc.js +3 -0
- package/dist/TestsPage.5x6658aa.js +3 -0
- package/dist/ThreadsPage.3fvhtevh.js +3 -0
- package/dist/apteva-kit.css +1 -1
- package/dist/index.html +1 -1
- package/dist/styles.css +1 -1
- package/package.json +10 -9
- package/src/crypto.ts +4 -3
- package/src/db.ts +171 -36
- package/src/integrations/agentdojo.ts +95 -12
- package/src/integrations/index.ts +7 -0
- package/src/mcp-platform.ts +870 -142
- package/src/openapi.ts +96 -0
- package/src/providers.ts +60 -34
- package/src/routes/api/agent-utils.ts +59 -47
- package/src/routes/api/agents.ts +71 -2
- package/src/routes/api/integrations.ts +11 -5
- package/src/routes/api/mcp.ts +5 -4
- package/src/routes/api/meta-agent.ts +37 -1
- package/src/routes/api/projects.ts +3 -3
- package/src/routes/api/providers.ts +121 -30
- package/src/routes/api/skills.ts +2 -3
- package/src/routes/api/system.ts +98 -14
- package/src/routes/api/telemetry.ts +19 -1
- package/src/routes/share.ts +85 -0
- package/src/server.ts +43 -32
- package/src/triggers/agentdojo.ts +2 -2
- package/src/web/App.tsx +107 -21
- package/src/web/components/activity/ActivityPage.tsx +242 -389
- package/src/web/components/agents/AgentCard.tsx +19 -27
- package/src/web/components/agents/AgentPanel.tsx +358 -198
- package/src/web/components/agents/AgentsView.tsx +4 -4
- package/src/web/components/agents/CreateAgentModal.tsx +21 -79
- package/src/web/components/api/ApiDocsPage.tsx +66 -66
- package/src/web/components/auth/CreateAccountStep.tsx +16 -16
- package/src/web/components/auth/LoginPage.tsx +10 -10
- package/src/web/components/common/Icons.tsx +8 -0
- package/src/web/components/common/LoadingSpinner.tsx +2 -2
- package/src/web/components/common/Modal.tsx +8 -8
- package/src/web/components/common/Select.tsx +11 -10
- package/src/web/components/connections/ConnectionsPage.tsx +4 -4
- package/src/web/components/connections/IntegrationsTab.tsx +18 -18
- package/src/web/components/connections/OverviewTab.tsx +13 -13
- package/src/web/components/connections/TriggersTab.tsx +99 -99
- package/src/web/components/dashboard/Dashboard.tsx +177 -52
- package/src/web/components/index.ts +1 -1
- package/src/web/components/layout/Header.tsx +50 -34
- package/src/web/components/layout/Sidebar.tsx +41 -16
- package/src/web/components/mcp/IntegrationsPanel.tsx +160 -69
- package/src/web/components/mcp/McpPage.tsx +218 -209
- package/src/web/components/meta-agent/MetaAgent.tsx +15 -11
- package/src/web/components/onboarding/OnboardingWizard.tsx +25 -25
- package/src/web/components/settings/SettingsPage.tsx +389 -221
- package/src/web/components/skills/SkillsPage.tsx +88 -88
- package/src/web/components/tasks/TasksPage.tsx +385 -68
- package/src/web/components/telemetry/TelemetryPage.tsx +294 -39
- package/src/web/components/tests/TestsPage.tsx +50 -50
- package/src/web/components/threads/ThreadsPage.tsx +315 -0
- package/src/web/context/AuthContext.tsx +3 -3
- package/src/web/context/ProjectContext.tsx +8 -3
- package/src/web/context/TelemetryContext.tsx +24 -6
- package/src/web/context/ThemeContext.tsx +69 -0
- package/src/web/context/index.ts +3 -1
- package/src/web/styles.css +25 -7
- package/src/web/themes.ts +99 -0
- package/src/web/types.ts +4 -7
- package/dist/ActivityPage.41nbye4r.js +0 -3
- package/dist/ApiDocsPage.4smnt8m3.js +0 -4
- package/dist/App.0sbax9et.js +0 -4
- package/dist/App.0ws427h8.js +0 -4
- package/dist/App.6q6bar8b.js +0 -4
- package/dist/App.80301vdb.js +0 -4
- package/dist/App.af2wg84v.js +0 -267
- package/dist/App.ca1rz1ph.js +0 -4
- package/dist/App.ensa6z0r.js +0 -4
- package/dist/App.f8g7tych.js +0 -13
- package/dist/App.mvtqv6qc.js +0 -20
- package/dist/App.ncgc9cxy.js +0 -4
- package/dist/App.p02f4ret.js +0 -1
- package/dist/App.p0fb1pds.js +0 -4
- package/dist/App.pmaq48sj.js +0 -4
- package/dist/App.yv87t9m5.js +0 -4
- package/dist/App.zjmfm8p6.js +0 -4
- package/dist/ConnectionsPage.anb3rv9a.js +0 -3
- package/dist/McpPage.y396h6fy.js +0 -3
- package/dist/SettingsPage.p1hc60gk.js +0 -3
- package/dist/SkillsPage.yj3xdsay.js +0 -3
- package/dist/TasksPage.sjv0khtv.js +0 -3
- package/dist/TelemetryPage.2qm4w16r.js +0 -3
- package/dist/TestsPage.zzs4qfj8.js +0 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React
|
|
1
|
+
import React from "react";
|
|
2
2
|
import { MemoryIcon, TasksIcon, VisionIcon, OperatorIcon, McpIcon, RealtimeIcon, FilesIcon, MultiAgentIcon, SkillsIcon, ActivityIcon } from "../common/Icons";
|
|
3
|
-
import { useAgentActivity, useProjects
|
|
3
|
+
import { useAgentActivity, useProjects } from "../../context";
|
|
4
4
|
import type { Agent, AgentFeatures } from "../../types";
|
|
5
5
|
|
|
6
6
|
interface AgentCardProps {
|
|
@@ -22,41 +22,33 @@ const FEATURE_ICONS: { key: keyof AgentFeatures; icon: React.ComponentType<{ cla
|
|
|
22
22
|
{ key: "agents", icon: MultiAgentIcon, label: "Multi-Agent" },
|
|
23
23
|
];
|
|
24
24
|
|
|
25
|
-
export function AgentCard({ agent, selected, onSelect, onToggle, showProject }: AgentCardProps) {
|
|
25
|
+
export const AgentCard = React.memo(function AgentCard({ agent, selected, onSelect, onToggle, showProject }: AgentCardProps) {
|
|
26
26
|
const enabledFeatures = FEATURE_ICONS.filter(f => agent.features?.[f.key]);
|
|
27
27
|
const mcpServers = agent.mcpServerDetails || [];
|
|
28
28
|
const skills = agent.skillDetails || [];
|
|
29
29
|
const { isActive, label: activityLabel } = useAgentActivity(agent.id);
|
|
30
30
|
const { projects } = useProjects();
|
|
31
|
-
const { authFetch } = useAuth();
|
|
32
31
|
const project = agent.projectId ? projects.find(p => p.id === agent.projectId) : null;
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
useEffect(() => {
|
|
36
|
-
authFetch(`/api/subscriptions?agent_id=${agent.id}`)
|
|
37
|
-
.then(res => res.ok ? res.json() : { subscriptions: [] })
|
|
38
|
-
.then(data => setSubscriptions(data.subscriptions || []))
|
|
39
|
-
.catch(() => {});
|
|
40
|
-
}, [agent.id, authFetch]);
|
|
32
|
+
const subscriptions = agent.subscriptions || [];
|
|
41
33
|
|
|
42
34
|
return (
|
|
43
35
|
<div
|
|
44
36
|
onClick={onSelect}
|
|
45
|
-
className={`bg-[
|
|
37
|
+
className={`bg-[var(--color-surface)] rounded p-5 border transition cursor-pointer flex flex-col h-full ${
|
|
46
38
|
selected
|
|
47
|
-
? 'border-[
|
|
48
|
-
: 'border-[
|
|
39
|
+
? 'border-[var(--color-accent)]'
|
|
40
|
+
: 'border-[var(--color-border)] hover:border-[var(--color-border-light)]'
|
|
49
41
|
}`}
|
|
50
42
|
>
|
|
51
43
|
<div className="flex items-start justify-between mb-3">
|
|
52
44
|
<div>
|
|
53
45
|
<h3 className="font-semibold text-lg">{agent.name}</h3>
|
|
54
|
-
<p className="text-sm text-[
|
|
46
|
+
<p className="text-sm text-[var(--color-text-muted)]">
|
|
55
47
|
{agent.provider} / {agent.model}
|
|
56
|
-
{agent.port && <span className="text-[
|
|
48
|
+
{agent.port && <span className="text-[var(--color-text-faint)]"> · :{agent.port}</span>}
|
|
57
49
|
</p>
|
|
58
50
|
{showProject && project && (
|
|
59
|
-
<p className="text-sm text-[
|
|
51
|
+
<p className="text-sm text-[var(--color-text-muted)] flex items-center gap-1.5 mt-1">
|
|
60
52
|
<span className="w-2 h-2 rounded-full" style={{ backgroundColor: project.color }} />
|
|
61
53
|
{project.name}
|
|
62
54
|
</p>
|
|
@@ -70,7 +62,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
70
62
|
{enabledFeatures.map(({ key, icon: Icon, label }) => (
|
|
71
63
|
<span
|
|
72
64
|
key={key}
|
|
73
|
-
className="inline-flex items-center gap-1 px-2 py-0.5 rounded bg-[
|
|
65
|
+
className="inline-flex items-center gap-1 px-2 py-0.5 rounded bg-[var(--color-accent-10)] text-[var(--color-accent-70)] text-xs"
|
|
74
66
|
title={label}
|
|
75
67
|
>
|
|
76
68
|
<Icon className="w-3 h-3" />
|
|
@@ -92,7 +84,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
92
84
|
className={`inline-flex items-center gap-1 px-2 py-0.5 rounded text-xs ${
|
|
93
85
|
isAvailable
|
|
94
86
|
? "bg-green-500/10 text-green-400"
|
|
95
|
-
: "bg-[
|
|
87
|
+
: "bg-[var(--color-surface-raised)] text-[var(--color-text-muted)]"
|
|
96
88
|
}`}
|
|
97
89
|
title={`MCP: ${server.name} (${isAvailable ? "available" : server.status})`}
|
|
98
90
|
>
|
|
@@ -113,7 +105,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
113
105
|
className={`inline-flex items-center gap-1 px-2 py-0.5 rounded text-xs ${
|
|
114
106
|
skill.enabled
|
|
115
107
|
? "bg-purple-500/10 text-purple-400"
|
|
116
|
-
: "bg-[
|
|
108
|
+
: "bg-[var(--color-surface-raised)] text-[var(--color-text-muted)]"
|
|
117
109
|
}`}
|
|
118
110
|
title={`Skill: ${skill.name} v${skill.version}`}
|
|
119
111
|
>
|
|
@@ -133,7 +125,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
133
125
|
className={`inline-flex items-center gap-1 px-2 py-0.5 rounded text-xs ${
|
|
134
126
|
sub.enabled
|
|
135
127
|
? "bg-cyan-500/10 text-cyan-400"
|
|
136
|
-
: "bg-[
|
|
128
|
+
: "bg-[var(--color-surface-raised)] text-[var(--color-text-muted)]"
|
|
137
129
|
}`}
|
|
138
130
|
title={`Trigger: ${sub.trigger_slug.replace(/_/g, " ")}`}
|
|
139
131
|
>
|
|
@@ -144,7 +136,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
144
136
|
</div>
|
|
145
137
|
)}
|
|
146
138
|
|
|
147
|
-
<p className="text-sm text-[
|
|
139
|
+
<p className="text-sm text-[var(--color-text-muted)] line-clamp-2 mb-4 flex-1">
|
|
148
140
|
{agent.systemPrompt}
|
|
149
141
|
</p>
|
|
150
142
|
|
|
@@ -153,9 +145,9 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
153
145
|
disabled={agent.status === "starting" || agent.status === "stopping"}
|
|
154
146
|
className={`w-full px-3 py-1.5 rounded text-sm font-medium transition mt-auto ${
|
|
155
147
|
agent.status === "starting" || agent.status === "stopping"
|
|
156
|
-
? "bg-[
|
|
148
|
+
? "bg-[var(--color-surface-raised)] text-[var(--color-text-muted)] cursor-wait"
|
|
157
149
|
: agent.status === "running"
|
|
158
|
-
? "bg-
|
|
150
|
+
? "bg-red-500/15 text-red-500 hover:bg-red-500/25 border border-red-500/20"
|
|
159
151
|
: "bg-[#3b82f6]/20 text-[#3b82f6] hover:bg-[#3b82f6]/30"
|
|
160
152
|
}`}
|
|
161
153
|
>
|
|
@@ -163,7 +155,7 @@ export function AgentCard({ agent, selected, onSelect, onToggle, showProject }:
|
|
|
163
155
|
</button>
|
|
164
156
|
</div>
|
|
165
157
|
);
|
|
166
|
-
}
|
|
158
|
+
});
|
|
167
159
|
|
|
168
160
|
function StatusBadge({ status, isActive, activityLabel }: { status: Agent["status"]; isActive?: boolean; activityLabel?: string }) {
|
|
169
161
|
if (status === "running" && isActive && activityLabel) {
|
|
@@ -183,7 +175,7 @@ function StatusBadge({ status, isActive, activityLabel }: { status: Agent["statu
|
|
|
183
175
|
? "bg-yellow-500/20 text-yellow-400 animate-pulse"
|
|
184
176
|
: status === "running"
|
|
185
177
|
? "bg-[#3b82f6]/20 text-[#3b82f6]"
|
|
186
|
-
: "bg-[
|
|
178
|
+
: "bg-[var(--color-surface-raised)] text-[var(--color-text-muted)]"
|
|
187
179
|
}`}
|
|
188
180
|
>
|
|
189
181
|
{status}
|