Skip to content

feat(conduit): add Build-insights button + POST endpoint; fix command to a home-relative path - #1647

Open
elhoim wants to merge 2 commits into
danielmiessler:mainfrom
elhoim:feat/conduit-build-button
Open

feat(conduit): add Build-insights button + POST endpoint; fix command to a home-relative path#1647
elhoim wants to merge 2 commits into
danielmiessler:mainfrom
elhoim:feat/conduit-build-button

Conversation

@elhoim

@elhoim elhoim commented Jul 26, 2026

Copy link
Copy Markdown

What this adds

The Conduit page's empty state used to only tell you to run a bun command by hand (bun Conduit/BuildInsight.ts, which fails unless your cwd is LIFEOS/PULSE/). This adds a real Build insights now button and fixes the fallback command.

Backend (modules/conduit.ts): a new POST /api/conduit/build route runs BuildInsight.ts (the same script the hourly launchd job runs) and returns { ok, output }. GET is not handled, so only the button's POST triggers it.

Frontend (conduit/page.tsx): the empty state now shows a Build insights now button that POSTs to the endpoint, shows a Building… state, reports the result, and refetches the insight. The terminal fallback command is corrected to a home-relative path: bun ~/.claude/LIFEOS/PULSE/Conduit/BuildInsight.ts.

Verification (live)

  • bun build modules/conduit.ts → OK; bun run build (Observability) → compiled, /conduit route emitted.
  • curl -X POST /api/conduit/build{"ok":true,"output":"[]\n"} (runs the script; [] because no events today).
  • curl /conduit → 200; GET /api/conduit/build → 404 (POST-only).
  • Visual button interaction not browser-verified (headless host, no Chrome) — logic compiles and the endpoint it calls is confirmed working.

Files

  • LifeOS/install/LIFEOS/PULSE/modules/conduit.ts
  • LifeOS/install/LIFEOS/PULSE/Observability/src/app/conduit/page.tsx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant