The open-source app everyone uses to manage agents at work
TypeScript acpxagent-orchestrationagent-skillsagentic-aiai-agentsai-engineeringai-governanceai-toolsautonomous-agentsclaudeclaude-codeclaude-skillscodexhermesllmmcpmulti-agentopenclawproject-managementworkflow-automation
feat(ui): show toast notification for new join requests
Dotta67491483b733
diff --git a/ui/src/context/LiveUpdatesProvider.tsx b/ui/src/context/LiveUpdatesProvider.tsxindex d262691ea8..6a1403af9f 100644--- a/ui/src/context/LiveUpdatesProvider.tsx+++ b/ui/src/context/LiveUpdatesProvider.tsx@@ -227,6 +227,29 @@ function buildActivityToast(};}+function buildJoinRequestToast(+ payload: Record<string, unknown>,+): ToastInput | null {+ const entityType = readString(payload.entityType);+ const action = readString(payload.action);+ const entityId = readString(payload.entityId);+ const details = readRecord(payload.details);++ if (entityType !== "join_request" || !action || !entityId) return null;+ if (action !== "join.requested" && action !== "join.request_replayed") return null;++ const requestType = readString(details?.requestType);+ const label = requestType === "agent" ? "Agent" : "Someone";++ return {+ title: `${label} wants to join`,+ body: "A new join request is waiting for approval.",+ tone: "info",+ action: { label: "View inbox", href: "/inbox/new" },+ dedupeKey: `join-request:${entityId}`,+ };+}+function buildAgentStatusToast(payload: Record<string, unknown>,nameOf: (id: string) => string | null,@@ -461,7 +484,9 @@ function handleLiveEvent(if (event.type === "activity.logged") {invalidateActivityQueries(queryClient, expectedCompanyId, payload);const action = readString(payload.action);- const toast = buildActivityToast(queryClient, expectedCompanyId, payload);+ const toast =+ buildActivityToast(queryClient, expectedCompanyId, payload) ??+ buildJoinRequestToast(payload);if (toast) gatedPushToast(gate, pushToast, `activity:${action ?? "unknown"}`, toast);}}