Open History to see the last commit
1import { defineConfig } from "@neon/config/v1";
2const origins = (
3 process.env.ALLOWED_ORIGINS ||
4 "http://localhost:5173,http://127.0.0.1:5173,http://localhost:4173,http://127.0.0.1:4173,https://neonbricks-app.vercel.app"
5).split(",");
6export default defineConfig({
7 aiGateway: true,
8 preview: { realtime: { allowedOrigins: origins } },
9 triggers: {
10 "ai-reconcile": {
11 type: "schedule",
12 function: "bricks",
13 cron: "* * * * *",
14 functionPath: "/api/ai/reconcile",
15 },
16 "workshop-cleanup": {
17 type: "schedule",
18 function: "bricks",
19 cron: "*/5 * * * *",
20 functionPath: "/api/cleanup",
21 },
22 },
23 functions: {
24 bricks: {
25 name: "Neon Bricks API",
26 source: "src/server/app.ts",
27 env: {
28 REALTIME_SECRET: process.env.REALTIME_SECRET!,
29 REALTIME_URL: process.env.REALTIME_URL!,
30 ALLOWED_ORIGINS: origins.join(","),
31 AI_MODEL: process.env.AI_MODEL || "gpt-5-4",
32 },
33 },
34 },
35});