AI Engineering Workspace
PartialChat, files, terminal and preview in one place. Chat sessions run on a durable Postgres-backed queue (chat only: no tools or shell). Live models need an API key; the terminal is unavailable.
Project files
read-only- ..
- ai.ts
- apps.ts
- audit.ts
- auth.ts
- central-core.d.mts
- central-core.mjs
- central.ts
- cloud.ts
- config.ts
- crypto.ts
- db.ts
- design.ts
- engines.ts
- files.ts
- gates.ts
- gateway.ts
- marketplace-core.d.mts
- marketplace-core.mjs
- metrics.ts
- modules.ts
- motion.ts
- nexus-core.d.mts
- nexus-core.mjs
- oidc-core.d.mts
- oidc-core.mjs
- oidc.ts
- providers.ts
- proxy-core.d.mts
- proxy-core.mjs
- pwauth-core.d.mts
- pwauth-core.mjs
- requirements.ts
- rls.sql.d.mts
- rls.sql.mjs
- services-content.ts
- ssrf.ts
- status.ts
- tenant.ts
- tlsgate.ts
- workspace.ts
app/src/app/api/settings/route.ts
1import { requireWrite } from "@/lib/auth";2import { setSetting } from "@/lib/db";3import { audit } from "@/lib/audit";4export async function POST(req: Request) {5 const deny = await requireWrite(); if (deny) return deny;6 const b = await req.json().catch(() => ({}));7 for (const k of ["product_name", "tagline"] as const) if (typeof b[k] === "string" && b[k].trim().length >= 2 && b[k].length <= 60) await setSetting(k, b[k].trim());8 for (const k of ["ai.monthly_cap_usd", "ai.project_cap_usd"] as const) { const v = Number(b[k]); if (b[k] !== undefined && v > 0 && v <= 1000) { await setSetting(k, String(v)); await audit("admin", "settings.update", k, { v }); } }9 if (b["ai.pricing"] && typeof b["ai.pricing"] === "object") { const o: Record<string, { in: number; out: number }> = {}; for (const [m, p] of Object.entries(b["ai.pricing"] as Record<string, any>)) if (/^[\w.-]{1,40}$/.test(m) && p.in >= 0 && p.out >= 0 && p.in < 1000 && p.out < 1000) o[m] = { in: Number(p.in), out: Number(p.out) }; await setSetting("ai.pricing", JSON.stringify(o)); await audit("admin", "settings.update", "ai.pricing"); }10 await audit("admin", "settings.update", "branding"); return Response.json({ ok: true });11}12
Conversation
PartialSign in to start AI sessions.
Task checklist
- Application shell deployed
- Persistent projects
- Agent runtime
- Sandboxed terminal
Execution activity
No agent sessions. Git HEAD fb22adb on master.
Approval requests
None pending.