mirror of
https://github.com/luckyyzh/pi-agent-integrated.git
synced 2026-10-03 02:59:35 +00:00
feat: integrate Pi backend and Pi Web
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import { getAgentDir } from "@earendil-works/pi-coding-agent";
|
||||
import {
|
||||
getManagedRuntimePaths,
|
||||
isManagedRuntime,
|
||||
} from "@/lib/app-runtime";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
export async function GET() {
|
||||
if (!isManagedRuntime()) {
|
||||
return Response.json({ managed: false, agentDir: getAgentDir() });
|
||||
}
|
||||
|
||||
const paths = getManagedRuntimePaths();
|
||||
return Response.json({
|
||||
managed: true,
|
||||
appRoot: paths.appRoot,
|
||||
dataDir: paths.dataDir,
|
||||
agentDir: paths.agentDir,
|
||||
resourcesDir: paths.resourcesDir,
|
||||
skillRoots: paths.managedSkillRoots,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user