Journal dashboard widgets and quick-add; rich-text quick-add dialogs. Dashboard draft sync for live edit previews; assistant bubble + API tools. Journal UX: stress slider, mood grid, query cap fix.
15 lines
477 B
TypeScript
15 lines
477 B
TypeScript
import { readFile } from "fs/promises";
|
|
import path from "path";
|
|
import { withApiHandler } from "@/lib/api-handler";
|
|
|
|
export async function GET(request: Request) {
|
|
return withApiHandler(request, async () => {
|
|
const specPath = path.join(process.cwd(), "docs", "api", "openapi.yaml");
|
|
const spec = await readFile(specPath, "utf8");
|
|
return new Response(spec, {
|
|
status: 200,
|
|
headers: { "Content-Type": "application/yaml; charset=utf-8" },
|
|
});
|
|
});
|
|
}
|