repositories
loading repo index
repositories
loading repo index
repository
loading code, commits, and activity
The Living OS cockpit
stars
latest
clone command
git clone gitlawb://did:key:z6Mku78K...XywC/living-os-cockp...git clone gitlawb://did:key:z6Mku78K.../living-os-cockp...59751530feat: surface worker supervisor health in live work8h ago| import { NextResponse } from 'next/server'; |
| #2 | import { recentEvents, logEvent } from '@/lib/events'; |
| #3 |
| #4 | export const runtime = 'nodejs'; |
| #5 |
| #6 | export async function GET() { |
| #7 | const events = await recentEvents(30); |
| #8 | return NextResponse.json({ events }); |
| #9 | } |
| #10 |
| #11 | export async function POST(req: Request) { |
| #12 | const body = await req.json(); |
| #13 | await logEvent({ |
| #14 | kind: body.kind, |
| #15 | source: body.source, |
| #16 | summary: body.summary, |
| #17 | level: body.level ?? 'info', |
| #18 | }); |
| #19 | return NextResponse.json({ ok: true }); |
| #20 | } |
| #21 |